Help Center - Personal Account
  • Home
  • Payments and Transfers
  • Disputes and Limitations
  • My Account
  • My Wallet
  • Login & Security
  • Seller Tools

How do I set SDK logging levels for Java, .NET, and PHP?

Set Java and .NET SDK logging levels
Here's how:
  • For the Java SDK, set the value of the level element in SDK_root/lib/log4j.properties.
  • For the .NET SDK (console only), set the value of the level element in the SDK_root/bin/Console.exe.config file.

If you're not using the console, copy the logging-related elements in the Console.exe.config file and paste them into your own assembly descriptor.
  • Level Description ALL.
  • Same as DEBUG ERROR.
  • Log only severe errors.
  • INFO - Date and time of API operation, operation name, elapsed time, success or failure indication.
  • DEBUG - Full text of SOAP requests and responses and other debugging messages.

Notes:
  • Because DEBUG logging can degrade the performance of the SDK, be careful about using it for day-to-day operation.
  • Because SOAP requests and responses are asynchronous, the recording of requests and responses might appear out of sequence in the log file.
     

Set PHP SDK logging levels
Here's how: For the PHP SDK, set the value of the log_level parameter in the SDK_root/Services_PayPal/PayPal/conf/paypal-sdk.php file.
  • Level Description PEAR_LOG_ERR.
  • Log only severe errors.
  • PEAR_LOG_INFO - Default log level. Date and time of API operation, operation name, elapsed time, success or failure indication.
  • PEAR_LOG_DEBUG - Full text of SOAP requests and responses and other debugging messages.

Because SOAP requests and responses are asynchronous, the recording of requests and responses might appear out of sequence in the log file.

More ways we can help