t523e: Log PayPal-Debug-Id response header from API calls#732
t523e: Log PayPal-Debug-Id response header from API calls#732superdav42 merged 1 commit intomainfrom
Conversation
Completion Summary
This summary was written by the worker at PR creation time for the deterministic merge pass. |
|
PR is CONFLICTING with main (likely due to PR #733 merging changes to the same PayPal gateway files). Worker should rebase and resolve conflicts. |
PayPal support requires the PayPal-Debug-Id header from API responses for debugging. Extract it via wp_remote_retrieve_header() after every REST API call and log it alongside the existing request logging. Also include the debug ID in error log messages and expose it in the WP_Error data array so callers can surface it if needed. Closes #731 Part of #725
23988a7 to
5cd6708
Compare
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 12 minutes and 43 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Closing SummaryWhat was done:
Testing Evidence: self-assessed — logging-only change using standard WP function. No business logic altered, no conditional paths changed. Key decisions:
Files changed: Blockers: None Follow-up: None required Closes #731 aidevops.sh v3.5.556 plugin for OpenCode v1.3.0 with claude-sonnet-4-6 spent 15m on this as a headless worker. |
🔨 Build Complete - Ready for Testing!📦 Download Build Artifact (Recommended)Download the zip build, upload to WordPress and test:
🌐 Test in WordPress Playground (Very Experimental)Click the link below to instantly test this PR in your browser - no installation needed! Login credentials: |
|
Performance Test Results Performance test results for 9311c2b are in 🛎️! Note: the numbers in parentheses show the difference to the previous (baseline) test run. Differences below 2% or 0.5 in absolute values are not shown. URL:
|
Summary
Captures the
PayPal-Debug-Idresponse header from every PayPal REST API call and logs it to the PayPal log channel. PayPal support requires this header value when investigating API issues.Changes
inc/gateways/class-paypal-rest-gateway.php— Inapi_request():PayPal-Debug-Idviawp_remote_retrieve_header()after every successful HTTP responseinfolevel:PayPal-Debug-Id: <value>API Error (400): ... [Debug-Id: <value>]WP_Errordata array underdebug_idkey for callersAcceptance Criteria
PayPal-Debug-Idextracted from every API response viawp_remote_retrieve_header()Runtime Testing
Risk level: Low — logging-only change, no business logic altered.
Verification:
self-assessed— the change adds awp_remote_retrieve_header()call (standard WP function) and two$this->log()calls. No conditional logic, no data mutation, no side effects beyond logging.Files Changed
inc/gateways/class-paypal-rest-gateway.php(+10, -3)Closes #731
Part of #725
aidevops.sh v3.5.556 plugin for OpenCode v1.3.0 with claude-sonnet-4-6 spent 10m on this as a headless worker.