{
  "opencollection": "1.0.0",
  "info": {
    "name": "Paypal Subscriptions Authorizations Billing API",
    "version": "1.6"
  },
  "items": [
    {
      "info": {
        "name": "Billing",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List plans",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans",
            "headers": [
              {
                "name": "Prefer",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "product_id",
                "value": "",
                "type": "query",
                "description": "Filters the response by a Product ID."
              },
              {
                "name": "plan_ids",
                "value": "",
                "type": "query",
                "description": "Filters the response by list of plan IDs. Filter supports upto 10 plan IDs."
              },
              {
                "name": "page_size",
                "value": "",
                "type": "query",
                "description": "The number of items to return in the response."
              },
              {
                "name": "page",
                "value": "",
                "type": "query",
                "description": "A non-zero integer which is the start index of the entire list of items to return in the response. The combination of `page=1` and `page_size=20` returns the first 20 items. The combination of `page=2` and `page_size=20` returns the next 20 items."
              },
              {
                "name": "total_required",
                "value": "",
                "type": "query",
                "description": "Indicates whether to show the total count in the response."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Lists billing plans."
        },
        {
          "info": {
            "name": "Create plan",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans",
            "headers": [
              {
                "name": "Prefer",
                "value": ""
              },
              {
                "name": "PayPal-Request-Id",
                "value": ""
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Creates a plan that defines pricing and billing cycle details for subscriptions."
        },
        {
          "info": {
            "name": "Show plan details",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Shows details for a plan, by ID."
        },
        {
          "info": {
            "name": "Update plan",
            "type": "http"
          },
          "http": {
            "method": "PATCH",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Updates a plan with the `CREATED` or `ACTIVE` status. For an `INACTIVE` plan, you can make only status updates.<br/>You can patch these attributes and objects:<table><thead><tr><th>Attribute or object</th><th>Operations</th></tr></thead><tbody><tr><td><code>description</code></td><td>replace</td></tr><tr><td><code>payment_preferences.auto_bill_outstanding</code></td><td>replace</td></tr><tr><td><code>taxes.percentage</code></td><td>replace</td></tr><tr><td><code>payment_preferences.payment_failu"
        },
        {
          "info": {
            "name": "Activate plan",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans/:id/activate",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Activates a plan, by ID."
        },
        {
          "info": {
            "name": "Deactivate plan",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans/:id/deactivate",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Deactivates a plan, by ID."
        },
        {
          "info": {
            "name": "Update pricing",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/plans/:id/update-pricing-schemes",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Updates pricing for a plan. For example, you can update a regular billing cycle from $5 per month to $7 per month."
        },
        {
          "info": {
            "name": "Create subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions",
            "headers": [
              {
                "name": "Prefer",
                "value": ""
              },
              {
                "name": "PayPal-Request-Id",
                "value": ""
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Creates a subscription."
        },
        {
          "info": {
            "name": "Show subscription details",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              },
              {
                "name": "fields",
                "value": "",
                "type": "query",
                "description": "List of fields that are to be returned in the response. Possible value for fields are last_failed_payment and plan."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Shows details for a subscription, by ID."
        },
        {
          "info": {
            "name": "Update subscription",
            "type": "http"
          },
          "http": {
            "method": "PATCH",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Updates a subscription which could be in <code>ACTIVE</code> or <code>SUSPENDED</code> status. You can override plan level default attributes by providing customised values for plan path in the patch request.<br /> <ul> <li>You cannot update attributes that have already completed (Example - trial cycles cant be updated if completed).</li> <li>Once overridden, changes to plan resource will not impact subscription.</li> <li>Any price update will not impact billing cycles within next 10 days (Appli"
        },
        {
          "info": {
            "name": "Revise plan or quantity of subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/revise",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Updates the quantity of the product or service in a subscription. You can also use this method to switch the plan and update the `shipping_amount`, `shipping_address` values for the subscription. This type of update requires the buyer's consent."
        },
        {
          "info": {
            "name": "Suspend subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/suspend",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Suspends the subscription."
        },
        {
          "info": {
            "name": "Cancel subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/cancel",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Cancels the subscription."
        },
        {
          "info": {
            "name": "Activate subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/activate",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Activates the subscription."
        },
        {
          "info": {
            "name": "Capture authorized payment on subscription",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/capture",
            "headers": [
              {
                "name": "PayPal-Request-Id",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Captures an authorized payment from the subscriber on the subscription."
        },
        {
          "info": {
            "name": "List transactions for subscription",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api-m.sandbox.paypal.com/v1/billing/subscriptions/:id/transactions",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The ID of the subscription."
              },
              {
                "name": "start_time",
                "value": "",
                "type": "query",
                "description": "The start time of the range of transactions to list."
              },
              {
                "name": "end_time",
                "value": "",
                "type": "query",
                "description": "The end time of the range of transactions to list."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "client_credentials",
              "accessTokenUrl": "/v1/oauth2/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Lists transactions for a subscription."
        }
      ]
    }
  ],
  "bundled": true
}