{
  "opencollection": "1.0.0",
  "info": {
    "name": "Slope v4 Auth Orders API",
    "version": "1.0.0"
  },
  "items": [
    {
      "info": {
        "name": "Orders",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List orders",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.slopepay.com/v4/orders",
            "params": [
              {
                "name": "status",
                "value": "",
                "type": "query",
                "description": "When specified, only orders with the given status are returned."
              },
              {
                "name": "customerId",
                "value": "",
                "type": "query",
                "description": "When specified, only orders with the given Slope assigned Customer ID or partner assigned Customer ID are returned."
              },
              {
                "name": "limit",
                "value": "",
                "type": "query",
                "description": "The maximum number of objects to list."
              },
              {
                "name": "orderBy",
                "value": "",
                "type": "query",
                "description": "The object attribute(s) to sort by."
              },
              {
                "name": "order",
                "value": "",
                "type": "query",
                "description": "The direction to sort by, one of `asc` or `desc`."
              },
              {
                "name": "beforeCursor",
                "value": "",
                "type": "query",
                "description": "The cursor used to fetch the previous page of objects."
              },
              {
                "name": "afterCursor",
                "value": "",
                "type": "query",
                "description": "The cursor used to fetch the next page of objects."
              }
            ],
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Lists all orders using pagination."
        },
        {
          "info": {
            "name": "Create an order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders",
            "headers": [
              {
                "name": "Slope-Access-Token",
                "value": ""
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Creates a new order for checkout. Returns both a code for Slope.JS widget and full URL for redirect flow"
        },
        {
          "info": {
            "name": "Get an order",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.slopepay.com/v4/orders/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Gets an order by ID."
        },
        {
          "info": {
            "name": "Cancel an order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:id/cancel",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "An API to cancel an order. This is not allowed once order is finalized. You may also cancel on merchant dashboard."
        },
        {
          "info": {
            "name": "Finalize an order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:id/finalize",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Moves an order from the \"open\" state to the \"finalized\" state."
        },
        {
          "info": {
            "name": "Open an order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:id/open",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Optional API call during checkout flow. Only used by developers that utilize the submitted status. Moves an order from the \"submitted\" state to the \"open\" state."
        },
        {
          "info": {
            "name": "Cancel a partial amount of an order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:id/partial-cancel",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Cancel a partial amount of an order.\n  - The cancelled amount will be posted as a credit toward the order balance once the order is finalized. This       will not affect the original `total` amount.\n  - This is supported for orders in approved, pending, submitted, open, opening, and finalizing statuses.\n  - This is not allowed once order is finalized. To update finalized orders, use the adjustments endpoint.\n  - You may also cancel on merchant dashboard."
        },
        {
          "info": {
            "name": "Get repayment estimate",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.slopepay.com/v4/orders/:id/repay-estimate",
            "headers": [
              {
                "name": "Slope-Link-Token",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Gets an order repayment estimate by Order ID.\n\nA `linkToken` is required in the HTTP Header `Slope-Link-Token` in addition to the regular auth headers, see [Link Flow](https://developers.slopepay.com/docs/link-flow)."
        },
        {
          "info": {
            "name": "Repay an order in full",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:id/repay-full",
            "headers": [
              {
                "name": "Slope-Link-Token",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "basic",
              "username": "{{username}}",
              "password": "{{password}}"
            }
          },
          "docs": "Fully repay an order by Order ID.\n\nA `linkToken` is required in the HTTP Header `Slope-Link-Token` in addition to the regular auth headers, see [Link Flow](https://developers.slopepay.com/docs/link-flow)."
        },
        {
          "info": {
            "name": "Create an order adjustment",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.slopepay.com/v4/orders/:orderId/adjustments",
            "params": [
              {
                "name": "orderId",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Create an adjustment (eg. refund) for an order."
        },
        {
          "info": {
            "name": "Get an order adjustment",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.slopepay.com/v4/orders/:orderId/adjustments/:id",
            "params": [
              {
                "name": "orderId",
                "value": "",
                "type": "path",
                "description": "The Slope order ID or the partner external order ID"
              },
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The Slope order adjustment ID or the partner external order adjustment ID"
              }
            ]
          },
          "docs": "Get details about an order adjustment."
        },
        {
          "info": {
            "name": "List order items",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.slopepay.com/v4/orders/:orderId/items",
            "params": [
              {
                "name": "orderId",
                "value": "",
                "type": "path"
              }
            ]
          },
          "docs": "Get all items for a specific order."
        }
      ]
    }
  ],
  "bundled": true
}