Paypal API
  1. Webhooks
Paypal API
  • Authorization
    • Generate access_token
      POST
    • Terminate access_token
      POST
    • User Info
      GET
    • Generate client_token
      POST
  • Orders
    • Create order
      POST
    • Show order details
      GET
    • Update order
      PATCH
    • Authorize payment for order
      POST
    • Capture payment for order
      POST
  • Payments
    • Show details for authorized payment
      GET
    • Reauthorize authorized payment
      POST
    • Void authorized payment
      POST
    • Capture authorized payment
      POST
    • Show captured payment details
      GET
    • Refund captured payment
      POST
    • Show refund details
      GET
  • Invoices
    • Invoices
      • Generate invoice number
      • Create draft invoice
      • Show invoice details
      • List invoices
      • Generate QR code
      • Fully update invoice
      • Send invoice
      • Send invoice reminder
      • Cancel sent invoice
      • Delete invoice
      • Search for invoices
      • Record payment for invoice
      • Delete external payment
      • Record refund for invoice
      • Delete external refund
    • Templates
      • List templates
      • Create template
      • Show template details
      • Fully update template
      • Delete template
  • Subscriptions
    • Catalog Products
      • Create product
      • List products
      • Show product details
      • Update product
    • Plans
      • Create plan
      • List plans
      • Show plan details
      • Update plan
      • Deactivate plan
      • Activate plan
      • Update pricing
    • Subscriptions
      • Create subscription
      • Show subscription details
      • Update subscription
      • Revise plan or quantity of subscription
      • Suspend subscription
      • Activate subscription
      • Cancel subscription
      • Capture authorized payment on subscription
      • List transactions for subscription
  • Payouts
    • Create batch payout
    • Show payout batch details
    • Show payout item details
    • Cancel unclaimed payout item
  • Webhooks
    • List available events
      GET
    • Create webhook
      POST
    • List webhooks
      GET
    • Show webhook details
      GET
    • List event notifications
      GET
    • List event subscriptions for webhook
      GET
    • Show event notification details
      GET
    • Trigger a sample event
      POST
    • Verify webhook signature
      POST
    • Resend event notification
      POST
    • Simulate webhook event
      POST
    • Update webhook
      PATCH
    • Delete webhook
      DELETE
  • Shipment Tracking
    • Add tracking information for multiple PayPal transactions
    • Show tracking information
    • Update or cancel tracking information for PayPal transaction
  • Transaction Search
    • List transactions
    • List all balances
  • Disputes
    • List disputes
    • Show dispute details
    • Accept claim
    • Appeal dispute
    • Settle dispute
    • Update dispute status
    • Make offer to resolve dispute
    • Provide evidence
    • Acknowledge returned item
    • Provide supporting information for dispute
    • Escalate dispute to claim
    • Accept offer to resolve dispute
    • Send message about dispute to other party
    • Deny offer to resolve dispute
    • Partially update dispute
  • Onboarding (Limited Release)
    • Manage Accounts
      • Create managed account
      • Search managed account through external id
      • Search managed account by Seller Id
      • Partially updates information for a managed account
      • Shows collection of registered wallet domains
  1. Webhooks

List event notifications

GET
/v1/notifications/webhooks-events
Lists webhooks event notifications. Use query parameters to filter the response.

请求参数

Authorization
在 Header 添加参数
Authorization
,其值为在 Basic 之后拼接空格,以及经过 Base64 编码的 username:password
示例:
Authorization: Basic *****************

示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api-m.sandbox.paypal.com/v1/notifications/webhooks-events' \
--header 'Authorization: Basic Og=='

返回响应

🟢200200 - List Event Notifications
application/json
Body
events
array [object {9}] 
必需
id
string 
必需
create_time
string 
必需
resource_type
string 
必需
event_type
string 
必需
summary
string 
必需
resource
object 
必需
links
array [object {4}] 
必需
event_version
string 
必需
resource_version
string 
必需
count
integer 
必需
links
array [object {3}] 
必需
href
string 
可选
rel
string 
可选
method
string 
可选
示例
{
    "events": [
        {
            "id": "WH-1XS97263M8117650H-63C0057569090994L",
            "create_time": "2023-04-10T21:41:03.688Z",
            "resource_type": "subscription",
            "event_type": "BILLING.SUBSCRIPTION.ACTIVATED",
            "summary": "Subscription activated",
            "resource": {
                "quantity": "1",
                "subscriber": {
                    "email_address": "sb-ty8mz25453295@personal.example.com",
                    "payer_id": "YY9WRWVMNRFRC",
                    "name": {
                        "given_name": "John",
                        "surname": "Doe"
                    },
                    "shipping_address": {
                        "address": {
                            "address_line_1": "Whittaker House",
                            "address_line_2": "2 Whittaker Avenue",
                            "admin_area_2": "Richmond",
                            "admin_area_1": "Surrey",
                            "postal_code": "TW9 1EH",
                            "country_code": "GB"
                        }
                    }
                },
                "create_time": "2023-04-10T21:40:49Z",
                "plan_overridden": false,
                "shipping_amount": {
                    "currency_code": "GBP",
                    "value": "0.0"
                },
                "start_time": "2023-04-10T22:40:00Z",
                "update_time": "2023-04-10T21:40:50Z",
                "billing_info": {
                    "outstanding_balance": {
                        "currency_code": "GBP",
                        "value": "0.0"
                    },
                    "cycle_executions": [
                        {
                            "tenure_type": "REGULAR",
                            "sequence": 1,
                            "cycles_completed": 1,
                            "cycles_remaining": 11,
                            "current_pricing_scheme_version": 1,
                            "total_cycles": 12
                        }
                    ],
                    "last_payment": {
                        "amount": {
                            "currency_code": "GBP",
                            "value": "10.0"
                        },
                        "time": "2023-04-10T21:40:49Z"
                    },
                    "next_billing_time": "2023-04-11T10:00:00Z",
                    "final_payment_time": "2023-04-21T10:00:00Z",
                    "failed_payments_count": 0
                },
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM/cancel",
                        "rel": "cancel",
                        "method": "POST",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM",
                        "rel": "edit",
                        "method": "PATCH",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM/suspend",
                        "rel": "suspend",
                        "method": "POST",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM/capture",
                        "rel": "capture",
                        "method": "POST",
                        "encType": "application/json"
                    }
                ],
                "id": "I-40UGYEKPGFYM",
                "plan_id": "P-486441136J085170PMQ2IDGY",
                "status": "ACTIVE",
                "status_update_time": "2023-04-10T21:40:50Z"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-1XS97263M8117650H-63C0057569090994L",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-1XS97263M8117650H-63C0057569090994L/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-54J87337BU417205K-5CV18847WV891342F",
            "create_time": "2023-04-10T21:40:53.407Z",
            "resource_type": "sale",
            "event_type": "PAYMENT.SALE.COMPLETED",
            "summary": "Payment completed for GBP 10.0 GBP",
            "resource": {
                "billing_agreement_id": "I-40UGYEKPGFYM",
                "amount": {
                    "total": "10.00",
                    "currency": "GBP",
                    "details": {
                        "subtotal": "10.00"
                    }
                },
                "payment_mode": "INSTANT_TRANSFER",
                "update_time": "2023-04-10T21:40:49Z",
                "create_time": "2023-04-10T21:40:49Z",
                "protection_eligibility_type": "ITEM_NOT_RECEIVED_ELIGIBLE,UNAUTHORIZED_PAYMENT_ELIGIBLE",
                "transaction_fee": {
                    "currency": "GBP",
                    "value": "0.89"
                },
                "protection_eligibility": "ELIGIBLE",
                "links": [
                    {
                        "method": "GET",
                        "rel": "self",
                        "href": "https://api.sandbox.paypal.com/v1/payments/sale/7JJ927369S150314T"
                    },
                    {
                        "method": "POST",
                        "rel": "refund",
                        "href": "https://api.sandbox.paypal.com/v1/payments/sale/7JJ927369S150314T/refund"
                    }
                ],
                "id": "7JJ927369S150314T",
                "state": "completed",
                "invoice_number": ""
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-54J87337BU417205K-5CV18847WV891342F",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-54J87337BU417205K-5CV18847WV891342F/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0"
        },
        {
            "id": "WH-58604859DJ577133G-32Y38990TH727930L",
            "create_time": "2023-04-10T21:39:40.181Z",
            "resource_type": "subscription",
            "event_type": "BILLING.SUBSCRIPTION.CREATED",
            "summary": "Subscription created",
            "resource": {
                "start_time": "2023-04-10T22:40:00Z",
                "quantity": "1",
                "subscriber": {
                    "email_address": "sb-ty8mz25453295@personal.example.com",
                    "name": {
                        "given_name": "John",
                        "surname": "Doe"
                    },
                    "shipping_address": {
                        "name": {
                            "full_name": "John Doe"
                        },
                        "address": {
                            "address_line_1": "Whittaker House",
                            "address_line_2": "2 Whittaker Avenue",
                            "postal_code": "TW9 1EH",
                            "country_code": "UK"
                        }
                    }
                },
                "create_time": "2023-04-10T21:39:40Z",
                "links": [
                    {
                        "href": "https://www.sandbox.paypal.com/webapps/billing/subscriptions?ba_token=BA-5GJ665537L915723S",
                        "rel": "approve",
                        "method": "GET"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM",
                        "rel": "edit",
                        "method": "PATCH"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-40UGYEKPGFYM",
                        "rel": "self",
                        "method": "GET"
                    }
                ],
                "id": "I-40UGYEKPGFYM",
                "plan_overridden": false,
                "plan_id": "P-486441136J085170PMQ2IDGY",
                "status": "APPROVAL_PENDING"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-58604859DJ577133G-32Y38990TH727930L",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-58604859DJ577133G-32Y38990TH727930L/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-6LD8501245654235R-3D704957H0379170G",
            "create_time": "2023-04-10T21:37:33.203Z",
            "resource_type": "plan",
            "event_type": "BILLING.PLAN.CREATED",
            "summary": "Plan created",
            "resource": {
                "quantity_supported": false,
                "create_time": "2023-04-10T21:37:10Z",
                "payment_preferences": {
                    "service_type": "PREPAID",
                    "auto_bill_outstanding": true,
                    "setup_fee": {
                        "currency_code": "USD",
                        "value": "10.0"
                    },
                    "setup_fee_failure_action": "CONTINUE",
                    "payment_failure_threshold": 3
                },
                "description": "Each shirt they send out to subscribers is designed with lots of attention to detail",
                "taxes": {
                    "percentage": "10.0",
                    "inclusive": false
                },
                "version": 1,
                "payee": {
                    "merchant_id": "C7CYMKZDG8D6E",
                    "display_data": {
                        "business_email": "john_merchant@example.com"
                    }
                },
                "update_time": "2023-04-10T21:37:10Z",
                "usage_type": "LICENSED",
                "product_id": "1681156158",
                "name": "Fresh Clean Tees Plan",
                "billing_cycles": [
                    {
                        "pricing_scheme": {
                            "version": 1,
                            "fixed_price": {
                                "currency_code": "USD",
                                "value": "1.0"
                            },
                            "create_time": "2023-04-10T21:37:10Z",
                            "update_time": "2023-04-10T21:37:10Z"
                        },
                        "frequency": {
                            "interval_unit": "MONTH",
                            "interval_count": 1
                        },
                        "tenure_type": "TRIAL",
                        "sequence": 1,
                        "total_cycles": 1
                    },
                    {
                        "pricing_scheme": {
                            "version": 1,
                            "fixed_price": {
                                "currency_code": "USD",
                                "value": "44.0"
                            },
                            "create_time": "2023-04-10T21:37:10Z",
                            "update_time": "2023-04-10T21:37:10Z"
                        },
                        "frequency": {
                            "interval_unit": "MONTH",
                            "interval_count": 1
                        },
                        "tenure_type": "REGULAR",
                        "sequence": 2,
                        "total_cycles": 12
                    }
                ],
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-7LX177077P4305630MQ2IDBQ",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-7LX177077P4305630MQ2IDBQ",
                        "rel": "edit",
                        "method": "PATCH",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-7LX177077P4305630MQ2IDBQ/deactivate",
                        "rel": "self",
                        "method": "POST",
                        "encType": "application/json"
                    }
                ],
                "id": "P-7LX177077P4305630MQ2IDBQ",
                "status": "ACTIVE"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-6LD8501245654235R-3D704957H0379170G",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-6LD8501245654235R-3D704957H0379170G/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-9CL05658UA857770G-8E626969WN330131G",
            "create_time": "2023-04-10T21:37:35.972Z",
            "resource_type": "plan",
            "event_type": "BILLING.PLAN.CREATED",
            "summary": "Plan created",
            "resource": {
                "quantity_supported": false,
                "create_time": "2023-04-10T21:37:31Z",
                "payment_preferences": {
                    "service_type": "PREPAID",
                    "auto_bill_outstanding": true,
                    "setup_fee": {
                        "currency_code": "GBP",
                        "value": "0.0"
                    },
                    "setup_fee_failure_action": "CANCEL",
                    "payment_failure_threshold": 0
                },
                "version": 1,
                "payee": {
                    "merchant_id": "C7CYMKZDG8D6E",
                    "display_data": {
                        "business_email": "john_merchant@example.com"
                    }
                },
                "update_time": "2023-04-10T21:37:31Z",
                "usage_type": "LICENSED",
                "product_id": "1681154483",
                "name": "Day Plan",
                "billing_cycles": [
                    {
                        "pricing_scheme": {
                            "version": 1,
                            "fixed_price": {
                                "currency_code": "GBP",
                                "value": "10.0"
                            },
                            "create_time": "2023-04-10T21:37:31Z",
                            "update_time": "2023-04-10T21:37:31Z"
                        },
                        "frequency": {
                            "interval_unit": "DAY",
                            "interval_count": 1
                        },
                        "tenure_type": "REGULAR",
                        "sequence": 1,
                        "total_cycles": 12
                    }
                ],
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-486441136J085170PMQ2IDGY",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-486441136J085170PMQ2IDGY",
                        "rel": "edit",
                        "method": "PATCH",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-486441136J085170PMQ2IDGY/deactivate",
                        "rel": "self",
                        "method": "POST",
                        "encType": "application/json"
                    }
                ],
                "id": "P-486441136J085170PMQ2IDGY",
                "status": "ACTIVE"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-9CL05658UA857770G-8E626969WN330131G",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-9CL05658UA857770G-8E626969WN330131G/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-5N286696BT254681C-9GV74441CR326540G",
            "create_time": "2023-04-10T21:37:03.192Z",
            "resource_type": "plan",
            "event_type": "BILLING.PLAN.CREATED",
            "summary": "Plan created",
            "resource": {
                "quantity_supported": false,
                "create_time": "2023-04-10T21:36:43Z",
                "payment_preferences": {
                    "service_type": "PREPAID",
                    "auto_bill_outstanding": true,
                    "setup_fee": {
                        "currency_code": "USD",
                        "value": "0.0"
                    },
                    "setup_fee_failure_action": "CANCEL",
                    "payment_failure_threshold": 0
                },
                "version": 1,
                "payee": {
                    "merchant_id": "C7CYMKZDG8D6E",
                    "display_data": {
                        "business_email": "john_merchant@example.com"
                    }
                },
                "update_time": "2023-04-10T21:36:43Z",
                "usage_type": "LICENSED",
                "product_id": "1681156158",
                "name": "Monthly Plan",
                "billing_cycles": [
                    {
                        "pricing_scheme": {
                            "version": 1,
                            "fixed_price": {
                                "currency_code": "USD",
                                "value": "12.99"
                            },
                            "create_time": "2023-04-10T21:36:43Z",
                            "update_time": "2023-04-10T21:36:43Z"
                        },
                        "frequency": {
                            "interval_unit": "MONTH",
                            "interval_count": 1
                        },
                        "tenure_type": "REGULAR",
                        "sequence": 1,
                        "total_cycles": 1
                    }
                ],
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-69V00246BF400810WMQ2IC2Y",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-69V00246BF400810WMQ2IC2Y",
                        "rel": "edit",
                        "method": "PATCH",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-69V00246BF400810WMQ2IC2Y/deactivate",
                        "rel": "self",
                        "method": "POST",
                        "encType": "application/json"
                    }
                ],
                "id": "P-69V00246BF400810WMQ2IC2Y",
                "status": "ACTIVE"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-5N286696BT254681C-9GV74441CR326540G",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-5N286696BT254681C-9GV74441CR326540G/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-2PE102901S6964210-7TG49464R8426202C",
            "create_time": "2023-04-10T21:36:26.943Z",
            "resource_type": "plan",
            "event_type": "BILLING.PLAN.CREATED",
            "summary": "Plan created",
            "resource": {
                "quantity_supported": false,
                "create_time": "2023-04-10T21:36:23Z",
                "payment_preferences": {
                    "service_type": "PREPAID",
                    "auto_bill_outstanding": true,
                    "setup_fee": {
                        "currency_code": "USD",
                        "value": "0.0"
                    },
                    "setup_fee_failure_action": "CANCEL",
                    "payment_failure_threshold": 0
                },
                "version": 1,
                "payee": {
                    "merchant_id": "C7CYMKZDG8D6E",
                    "display_data": {
                        "business_email": "john_merchant@example.com"
                    }
                },
                "update_time": "2023-04-10T21:36:23Z",
                "usage_type": "LICENSED",
                "product_id": "1681156158",
                "name": "Monthly Plan",
                "billing_cycles": [
                    {
                        "pricing_scheme": {
                            "version": 1,
                            "fixed_price": {
                                "currency_code": "USD",
                                "value": "12.99"
                            },
                            "create_time": "2023-04-10T21:36:23Z",
                            "update_time": "2023-04-10T21:36:23Z"
                        },
                        "frequency": {
                            "interval_unit": "MONTH",
                            "interval_count": 1
                        },
                        "tenure_type": "REGULAR",
                        "sequence": 1,
                        "total_cycles": 1
                    }
                ],
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-6TC57456FW6036520MQ2ICVY",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-6TC57456FW6036520MQ2ICVY",
                        "rel": "edit",
                        "method": "PATCH",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/plans/P-6TC57456FW6036520MQ2ICVY/deactivate",
                        "rel": "self",
                        "method": "POST",
                        "encType": "application/json"
                    }
                ],
                "id": "P-6TC57456FW6036520MQ2ICVY",
                "status": "ACTIVE"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-2PE102901S6964210-7TG49464R8426202C",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-2PE102901S6964210-7TG49464R8426202C/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-1P540249C3488611D-7GC903072L4430546",
            "create_time": "2023-04-10T21:25:15.918Z",
            "resource_type": "subscription",
            "event_type": "BILLING.SUBSCRIPTION.CREATED",
            "summary": "Subscription created",
            "resource": {
                "start_time": "2023-04-10T22:00:00Z",
                "quantity": "1",
                "subscriber": {
                    "email_address": "sb-ty8mz25453295@personal.example.com",
                    "name": {
                        "given_name": "John",
                        "surname": "Doe"
                    },
                    "shipping_address": {
                        "name": {
                            "full_name": "John Doe"
                        },
                        "address": {
                            "address_line_1": "Whittaker House",
                            "address_line_2": "2 Whittaker Avenue",
                            "postal_code": "TW9 1EH",
                            "country_code": "UK"
                        }
                    }
                },
                "create_time": "2023-04-10T21:25:15Z",
                "links": [
                    {
                        "href": "https://www.sandbox.paypal.com/webapps/billing/subscriptions?ba_token=BA-4YT91419JR6860839",
                        "rel": "approve",
                        "method": "GET"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-HD5DSH1314E0",
                        "rel": "edit",
                        "method": "PATCH"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-HD5DSH1314E0",
                        "rel": "self",
                        "method": "GET"
                    }
                ],
                "id": "I-HD5DSH1314E0",
                "plan_overridden": false,
                "plan_id": "P-6FL191273H677552VMQ2HKRA",
                "status": "APPROVAL_PENDING"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-1P540249C3488611D-7GC903072L4430546",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-1P540249C3488611D-7GC903072L4430546/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-8UC853915G2784846-1R655107US5904920",
            "create_time": "2023-04-10T21:18:55.818Z",
            "resource_type": "subscription",
            "event_type": "BILLING.SUBSCRIPTION.CREATED",
            "summary": "Subscription created",
            "resource": {
                "start_time": "2023-04-10T22:00:00Z",
                "quantity": "1",
                "subscriber": {
                    "email_address": "sb-ty8mz25453295@personal.example.com",
                    "name": {
                        "given_name": "John",
                        "surname": "Doe"
                    },
                    "shipping_address": {
                        "name": {
                            "full_name": "John Doe"
                        },
                        "address": {
                            "address_line_1": "Whittaker House",
                            "address_line_2": "2 Whittaker Avenue",
                            "admin_area_2": "Richmond",
                            "admin_area_1": "Surrey",
                            "postal_code": "TW9 1EH",
                            "country_code": "UK"
                        }
                    }
                },
                "create_time": "2023-04-10T21:18:55Z",
                "links": [
                    {
                        "href": "https://www.sandbox.paypal.com/webapps/billing/subscriptions?ba_token=BA-93M79584XU903140B",
                        "rel": "approve",
                        "method": "GET"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-N03C5HDU3HAW",
                        "rel": "edit",
                        "method": "PATCH"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/billing/subscriptions/I-N03C5HDU3HAW",
                        "rel": "self",
                        "method": "GET"
                    }
                ],
                "id": "I-N03C5HDU3HAW",
                "plan_overridden": false,
                "plan_id": "P-6FL191273H677552VMQ2HKRA",
                "status": "APPROVAL_PENDING"
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-8UC853915G2784846-1R655107US5904920",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-8UC853915G2784846-1R655107US5904920/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0",
            "resource_version": "2.0"
        },
        {
            "id": "WH-5CV23650TC086381X-7LX93793866619516",
            "create_time": "2023-04-10T21:14:57.542Z",
            "resource_type": "payouts_item",
            "event_type": "PAYMENT.PAYOUTS-ITEM.RETURNED",
            "summary": "A payout item is returned",
            "resource": {
                "transaction_id": "4RM509406L0376400",
                "payout_item_fee": {
                    "currency": "USD",
                    "value": "0.25"
                },
                "transaction_status": "RETURNED",
                "sender_batch_id": "Payouts_1681161159",
                "time_processed": "2023-04-10T21:12:40Z",
                "activity_id": "5LH23786JF931961X",
                "payout_item": {
                    "recipient_type": "PHONE",
                    "amount": {
                        "currency": "USD",
                        "value": "20.00"
                    },
                    "note": "Thanks for your support!",
                    "receiver": "17934231370",
                    "sender_item_id": "201403140002",
                    "recipient_wallet": "PAYPAL"
                },
                "links": [
                    {
                        "href": "https://api.sandbox.paypal.com/v1/payments/payouts-item/K3BGUZYMSYK28",
                        "rel": "self",
                        "method": "GET",
                        "encType": "application/json"
                    },
                    {
                        "href": "https://api.sandbox.paypal.com/v1/payments/payouts/L9H2BVL2BJDEY",
                        "rel": "batch",
                        "method": "GET",
                        "encType": "application/json"
                    }
                ],
                "payout_item_id": "K3BGUZYMSYK28",
                "payout_batch_id": "L9H2BVL2BJDEY",
                "errors": {
                    "name": "RECEIVER_UNREGISTERED",
                    "message": "The recipient for this payout does not have an account. A link to sign up for an account was sent to the recipient. However, if the recipient does not claim this payout within 30 days, the funds will be returned to your account.",
                    "information_link": "https://developer.paypal.com/docs/api/payments.payouts-batch/#errors",
                    "details": [],
                    "links": []
                }
            },
            "links": [
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-5CV23650TC086381X-7LX93793866619516",
                    "rel": "self",
                    "method": "GET",
                    "encType": "application/json"
                },
                {
                    "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/WH-5CV23650TC086381X-7LX93793866619516/resend",
                    "rel": "resend",
                    "method": "POST",
                    "encType": "application/json"
                }
            ],
            "event_version": "1.0"
        }
    ],
    "count": 10,
    "links": [
        {
            "href": "https://api.sandbox.paypal.com/v1/notifications/webhooks-events/?start_time=2023-03-11T21:57:13Z&end_time=2023-04-10T21:57:13Z&page_size=10&move_to=next&offset=0&prev_offset=0&index_id=1",
            "rel": "next",
            "method": "GET"
        }
    ]
}
🟢200200 - List Event Notifications By Transaction ID
🟠401401 Unauthorized - Invalid Token
修改于 2023-08-16 07:18:59
上一页
Show webhook details
下一页
List event subscriptions for webhook
Built with