Payments
PayPal mock API
Stateful PayPal replica: OAuth token, Orders v2 (approve, capture, authorize), refunds, catalog products, billing plans and subscriptions, and webhooks.
At a glance
- Operations
- 55
- Stateful operations
- 30
- Stateful resources
- 7
- Webhook events
- 6
- Vendor API version
- orders v2, payments v2, catalogs v1, billing v1, webhooks v1
- Verification
- Spec-verified
How it works
Use PayPal without calling PayPal Holdings, Inc.
- Install the mock from the library into a workspace. It runs as a virtual service.
- Point your client's base URL at the virtual service instead of the vendor.
- Authenticate the way you already do. The mock accepts the same credential shape:
Authorization: Bearer A21AAMockAccessToken State
Resources that remember
Writes persist per caller, so a create followed by a read returns what you created.
| Resource | Operations |
|---|---|
| OAuth token | 1 |
| Orders and authorizations | 7 |
| Captures and refunds | 3 |
| Catalog products | 4 |
| Billing plans | 5 |
| Subscriptions | 5 |
| Webhooks | 5 |
Webhooks
Events your handlers can receive
- CHECKOUT.ORDER.APPROVED
- CHECKOUT.ORDER.COMPLETED
- PAYMENT.CAPTURE.COMPLETED
- PAYMENT.CAPTURE.REFUNDED
- BILLING.SUBSCRIPTION.ACTIVATED
- BILLING.SUBSCRIPTION.CANCELLED
Deliveries are unsigned: PayPal signs with a certificate chain verified through its verify-webhook-signature API; the mock sends PAYPAL-TRANSMISSION-* headers and its own verify endpoint confirms them
Coverage
55 operations
30 of them are stateful. The largest groups:
| Group | Operations |
|---|---|
| Other operations | 25 |
| Orders and authorizations | 7 |
| Billing plans | 5 |
| Subscriptions | 5 |
| Webhooks | 5 |
| Catalog products | 4 |
Verification
Spec-verified
Generated operations are checked against the vendor OpenAPI description, which proves shape and routing. Stateful operations and scenario suites prove behaviour. Responses are not yet compared with a live vendor sandbox.
2 operations cannot be checked against the specification.
Source and limits
License, source and limits
- Generated from the PayPal Holdings, Inc. API description, licensed under Apache-2.0.
- PayPal Holdings, Inc. API documentation
- Source specification
- Source specification
- Source specification
- Source specification
- Source specification
One merchant per Virtual Service: all bearer tokens share one state. Each collection holds up to 1 MiB of objects; writes beyond that are dropped (x-maxoperf-vs-state: capacity). Buyer approval is simulated by opening the order or subscription approve link (GET /checkoutnow). Webhook signatures are not certificate-signed; the mock's verify-webhook-signature endpoint confirms the transmissions it emitted.
MaxoPerf is not affiliated with, endorsed by, or sponsored by PayPal Holdings, Inc. PayPal is a trademark of its owner.