{
  "openapi": "3.0.0",
  "info": {
    "title": "Gr4vy API",
    "version": "1.1.0-beta",
    "contact": {
      "name": "Gr4vy Support",
      "email": "code@gr4vy.com",
      "url": "https://gr4vy.com"
    },
    "termsOfService": "https://gr4vy.com",
    "license": {
      "name": "MIT",
      "url": "https://raw.githubusercontent.com/gr4vy/gr4vy-openapi/main/LICENSE"
    },
    "description": "Welcome to the Gr4vy API reference documentation.\nOur API is still very much a work in product and subject to change."
  },
  "servers": [
    {
      "url": "https://api.sandbox.{id}.gr4vy.app",
      "x-speakeasy-server-id": "sandbox",
      "variables": {
        "id": {
          "default": "example",
          "description": "The subdomain for your Gr4vy instance."
        }
      }
    },
    {
      "url": "https://api.{id}.gr4vy.app",
      "x-speakeasy-server-id": "production",
      "variables": {
        "id": {
          "default": "example",
          "description": "The subdomain for your Gr4vy instance."
        }
      }
    }
  ],
  "tags": [
    {
      "name": "Account Updater",
      "description": "An Account Updater is a service provided by credit card issuers\n(such as banks and financial institutions) to merchants who accept\nrecurring payments from customers. Its primary purpose is to help\nmerchants maintain accurate and up-to-date payment information for\ntheir customers' credit or debit card accounts.\n\nIn Gr4vy, the Account Updater service is provided in an on-demand\nand asynchronous fashion:\n\n1. A merchant requests an update for a set of stored cards.\n2. A request is submitted to a third-party service.\n3. When results are ready, new card details are stored and left in standby.\n4. Card details are updated when it gets determined that the original card\n   is no longer valid (e.g. has expired)."
    },
    {
      "name": "Anti-Fraud Services",
      "description": "In Gr4vy, an anti-fraud service represents a configured anti-fraud service\nprovider (`Sift`, `CyberSource`, etc). This third-party services will be\nused to screen transactions to determine the risk and prevents chargebacks\nand fraudulent transactions.\n\nThe anti-fraud services API can be used to:\n\n* Provide Gr4vy with the API credentials for an anti-fraud service provider.\n* Set a display name for a anti-fraud provider.\n* Map anti-fraud service decisions to Gr4vy internal decisions.",
      "x-internal": true
    },
    {
      "name": "Anti Fraud Service Definitions",
      "description": "Anti fraud service definitions describe the fields required for a anti fraud\nservice to be configured."
    },
    {
      "name": "API Key Pairs",
      "description": "In Gr4vy, an API key pair is used to sign and validate JSON Web Tokens (JWT).\nJWTs are used as a HTTP `bearer` token to authenticate to the API. For more\ninformation please visit our [in-depth authentication](/guides/authentication)\nguide.",
      "x-internal": true
    },
    {
      "name": "API Logs",
      "description": "API Logs provide an historic of 4XX and 5XX errors that happened in the API\nin the last 24 hours with a 250 result limit.",
      "x-internal": true
    },
    {
      "name": "Apple Pay Certificates",
      "description": "Apple Pay payment processing certificates are used by Apple to encrypt Apple\nPay tokens. You must register and upload an Apple Pay payment processing\ncertificate if you wish to use Apple Pay with Gr4vy's mobile SDKs.\n\nThe Apple Pay certificates API can be used to:\n\n* Start a new Apple Pay certificate registration, providing you with a\nCertificate Signing Request (CSR).\n* Update the Apple Pay certificate record with the certificate received from\nApple after creating a new payment processing certificate on your Apple\nDeveloper console and uploading a CSR.\n* List all Apple Pay certificates.",
      "x-internal": true
    },
    {
      "name": "Audit Logs",
      "description": "Audit Logs provide an historic record of changes made to your Gr4vy instance."
    },
    {
      "name": "Buyers",
      "description": "In Gr4vy, a buyer represents your customer, the shopper who's performing\na checkout and making a purchase.\n\nA buyer can be used by you to:\n\n* Display a human readable name (`display_name`) for a buyer in the Gr4vy\nadmin panel\n* Associate multiple stored payment methods with a single user\n* Initialize **Gr4vy Embed** with the buyer ID, automatically displaying the\n  buyer's previously stored payment methods, allowing for faster checkout."
    },
    {
      "name": "Card Details",
      "description": "Endpoints to retrieve details of a card by utilising a BIN lookup table.",
      "x-internal": true
    },
    {
      "name": "Card Scheme Definitions",
      "description": "Card Scheme definitions provide display information to a card scheme."
    },
    {
      "name": "Connections",
      "description": "Endpoints to retrieve details of configured connections such as payment\nservices, digital wallets, and anti-fraud services.",
      "x-internal": true
    },
    {
      "name": "Connection Definitions",
      "description": "Endpoints to retrieve details of various connections such as payment\nservices, digital wallets, and anti-fraud services.",
      "x-internal": true
    },
    {
      "name": "Checkout Sessions",
      "description": "A Checkout Session represents the session of a user as they progress\nthrough an online checkout."
    },
    {
      "name": "Digital Wallets",
      "description": "In Gr4vy, a digital wallet represents a way for a buyer to pay using\ncard details already stored on their device via a digital wallet service\nsuch as Apple Pay or Google Pay. The buyer will not have to fill in their\ncard details on checkout.\n\nThe digital wallets API can be used to:\n\n* Register with a digital wallet provider.\n* List digital wallets currently registered."
    },
    {
      "name": "Gift Cards",
      "description": "In Gr4vy, a gift card represents a stored value card that can be used to pay for\na transaction."
    },
    {
      "name": "Gift Card Services",
      "description": "In Gr4vy, a gift card service represents a configured provider for processing\ngift cards."
    },
    {
      "name": "Gift Card Service Definitions",
      "description": "Gift card service definitions describe the fields required for a gift\ncard service to be configured."
    },
    {
      "name": "Health Dashboard",
      "description": "Endpoints to retrieve the data used for the Health Dashboard.",
      "x-internal": true
    },
    {
      "name": "Merchant Accounts",
      "description": "In Gr4vy, a merchant account represents an individual merchant in an\ninstance. Each instance has one or more merchant accounts, and each\nmerchant account has its own connections, Flow rules, transactions, and\nmore."
    },
    {
      "name": "Metrics Explorer",
      "description": "Endpoints to retrieve the data used for the Metrics Explorer.",
      "x-internal": true
    },
    {
      "name": "Payment Methods",
      "description": "In Gr4vy, a payment method represents a way in which a payment can be\nprocessed, for example a card, a PayPal account, or a bank account.\n\nThe payment method API can be used to:\n\n* List all the available payment methods\n* Filter the available payment method for a buyer in a specific currency\nand country.\n* Store (also known as vault) a payment method for a buyer.\n* Fetch all previously stored payment methods for a buyer."
    },
    {
      "name": "Payment Method Definitions",
      "description": "Payment Method definitions provide display information to a payment method."
    },
    {
      "name": "Payment Options",
      "description": "In Gr4vy, a payment option represents a list of methods (card, PayPal,\netc) that are available for a given locale.\n\nThe payment options API can be used to:\n\n* Determine what types of payments can be processed in a specific locale.\n* Display a list options to a buyer to choose from."
    },
    {
      "name": "Payment Service Definitions",
      "description": "Payment service definitions describe the fields required for a payment\nservice to be configured."
    },
    {
      "name": "Payment Services",
      "description": "In Gr4vy, a payment service represents a configured payment provider\n(Stripe, PayPal, Adyen, etc) for a specific payment type (card, bitcoin,\netc)\n\nThe payment services API can be used to:\n\n* Provide Gr4vy with the payment credentials for a payment provider.\n* Set a display name for a payment provider."
    },
    {
      "name": "Payouts",
      "description": "Payouts allow a merchant to send money from one of their own accounts to a\nthird party."
    },
    {
      "name": "Payment Links",
      "description": "In Gr4vy, payment links allow a merchant to generate a link, send it to a\ncustomer via email, SMS, etc, and then have the customer pay without the need\nfor the merchant hosting their own checkout."
    },
    {
      "name": "Vault Forward Definitions",
      "description": "Vault Forward definitions describe a third party service that has been vetted\nto receive requests containing PCI data."
    },
    {
      "name": "Vault Forward Configurations",
      "description": "A Vault Forward Configuration represents a third party service that is\ncurrently enabled to send requests containing PCI data."
    },
    {
      "name": "Vault Forward",
      "description": "Vault Forwarding is a way to perform requests where, provided a template,\nGr4vy will evaluate it to inject PCI data and forward it to third party\nservices that have been vetted to receive such data."
    },
    {
      "name": "Reports",
      "description": "In Gr4vy, a report represents the configuration details to extract or\ndump a set of data into a downloadable CSV file. The data extracted\nby a report is configured via the reports API where you can specify:\n\n* Which fields should be in the dataset.\n* How the dataset should be sorted.\n* How the dataset should be filtered.\n\nOnce a report is created, it may be executed on a one-off or recurring\nbasis. One-off reports are executed only once shortly after the report\nis created, while recurring reports are executed periodically based on\nits configured frequency, e.g. weekly or monthly.\n\nDuring a report execution, the data is extracted and loaded into\na CSV file according to the report's configuration. The resulting file\nmay then be downloaded.\n\nThe reports API can be used to:\n\n* Create and configure new reports.\n* List all reports.\n* View the configuration details of a report.\n* List a report's executions.\n* Reconfigure an existing report.\n* Generate a temporary URL to download the result of a report execution\nin CSV format."
    },
    {
      "name": "Sessions",
      "description": "The sessions APIs are used to facilitate user authentication for the Gr4vy\ndashboard.",
      "x-internal": true
    },
    {
      "name": "Transactions",
      "description": "In Gr4vy, a transaction represents a payment in any state, either before it\nis authorized, once it is captured, or after it has been refunded.\n\nThe transactions API can be used to:\n\n- Authorize, capture, and store cards.\n- Authorize, capture, and store alternative payment methods like PayPal.\n- Refund, void, and otherwise cancel existing transactions."
    },
    {
      "name": "Users",
      "description": "In Gr4vy, a user represents an employee of the merchant with access to the\ndashboard.",
      "x-internal": true
    },
    {
      "name": "Webhooks",
      "description": "Endpoints related to webhooks to integrate Gr4vy with payment services\nwebhooks functionality.",
      "x-internal": true
    },
    {
      "name": "Flow",
      "description": "In Gr4vy, a rule can be created that triggers actions anywhere in the payment flow.",
      "x-internal": true
    },
    {
      "name": "Roles",
      "description": "In Gr4vy, users can be granted access to specific types of resources and permissions\nto perform certain actions by being assigned one or more roles."
    },
    {
      "name": "Tokens",
      "description": "Endpoints related to the Gr4vy tokenization service."
    },
    {
      "name": "Webhook subscriptions",
      "description": "Endpoints related to the management of subscriptions for endpoints to receive webhooks."
    }
  ],
  "paths": {
    "/account-updater/jobs": {
      "post": {
        "operationId": "new-account-updater-job",
        "summary": "Create Account Updater job",
        "description": "Creates an Account Updater job.\n\nA request is submitted to a third-party service, containing inquiries for a given\nset of payment methods. The job is not processed right away, but once created, it\nwill store new card details automatically, if there are, when results are ready.\n\nA payment method is considered for the job if the following conditions are met:\n* It exists.\n* It's in a valid state: `status` is either `succeeded` or `processing`.\n* It corresponds to a card: `method` is `card`.\n* Its scheme is supported: `scheme` is `amex`, `discover`, `mastercard` or `visa`.\n* It doesn't have an in-progress inquiry already.\n\nThe endpoint works in a best-efforts basis and it doesn't return any error when a payment\nmethod doesn't qualify for an inquiry. To determine what payment methods were considered\nfor the job, an `inquiries` field, returned in the response body, contains the submitted\ninquiries. If none of the payment methods qualified for an inquiry, the job is not created\nand a `204 No Content` status code is returned.",
        "tags": [
          "Account Updater"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AccountUpdaterJobCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created Account Updater job.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AccountUpdaterJob"
                }
              }
            }
          },
          "204": {
            "description": "Returns an empty response when no Account Updater job is created.\nThis occurs when none of the payment methods qualifies for an inquiry."
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required\nfields or the Account Updater service is not configured properly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/auth/sessions": {
      "post": {
        "operationId": "login",
        "summary": "Login user",
        "description": "Authenticate a user.\n",
        "tags": [
          "Sessions"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "security": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "x-model-name": "SessionRequest",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/SessionRequestEmailAndPassword"
                  },
                  {
                    "$ref": "#/components/schemas/SessionRequestToken"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns a session object.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Session"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if the credentials provided were not valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "403": {
            "description": "Returns an error if the access to the requested resource is forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error403Forbidden"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "refresh-session",
        "summary": "Refresh user session",
        "description": "Re-authenticate a user using a refresh token.\n",
        "tags": [
          "Sessions"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "200": {
            "description": "Returns a session object.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Session"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if the refresh token provided was not valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "logout",
        "summary": "Logout user",
        "description": "Ends a user's session by invalidating the used access token.",
        "tags": [
          "Sessions"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/api-key-pairs": {
      "get": {
        "operationId": "list-api-key-pairs",
        "summary": "List API key",
        "description": "Returns a list of active API key-pairs.",
        "tags": [
          "API Key Pairs"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of active key pairs.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIKeyPairs"
                },
                "examples": {
                  "A list of key pairs": {
                    "value": {
                      "items": [
                        {
                          "type": "api-key-pair",
                          "id": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                          "display_name": "Storefront",
                          "algorithm": "ECDSA",
                          "thumbprint": "SopiN5XU0IWy8Xe9mwx1ICQbKh4-ydCDPx3LIyArkVI",
                          "private_key": null,
                          "creator": {
                            "id": "5162f467-c5be-4673-8aae-6bbff795099b",
                            "name": "Demo User",
                            "email_address": "demo@gr4vy.com"
                          },
                          "merchant_account": {
                            "type": "merchant-account",
                            "id": "default",
                            "display_name": "Default",
                            "created_at": "2012-12-12T10:53:43+00:00",
                            "updated_at": "2012-12-12T10:53:43+00:00"
                          },
                          "created_at": "2012-12-12T10:53:43+00:00",
                          "updated_at": "2012-12-12T10:53:43+00:00"
                        },
                        {
                          "type": "api-key-pair",
                          "id": "c81bdcfd-00c2-4897-b220-06ff0e95685a",
                          "display_name": "Back Office",
                          "algorithm": "ECDSA",
                          "thumbprint": "Wy8Xe9mwx1ICQbKh4SopiN5XU0I-yArkVIydCDPx3LI",
                          "private_key": null,
                          "creator": {
                            "id": "5162f467-c5be-4673-8aae-6bbff795099b",
                            "name": "Demo User",
                            "email_address": "demo@gr4vy.com"
                          },
                          "merchant_account": {
                            "type": "merchant-account",
                            "id": "plantly-uk",
                            "display_name": "Plantly UK",
                            "created_at": "2012-12-12T10:53:43+00:00",
                            "updated_at": "2012-12-12T10:53:43+00:00"
                          },
                          "created_at": "2012-12-12T10:53:12+00:00",
                          "updated_at": "2012-12-12T10:53:12+00:00"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-api-key-pair",
        "summary": "Create API key",
        "description": "Creates a new API key-pair.",
        "tags": [
          "API Key Pairs"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/APIKeyPairCreate"
              },
              "examples": {
                "Create an API Key Pair": {
                  "value": {
                    "display_name": "Back Office",
                    "algorithm": "ECDSA",
                    "role_ids": [
                      "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
                    ],
                    "merchant_account_id": "plantly-uk"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns a newly created key pair.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIKeyPair"
                },
                "examples": {
                  "A newly created API key pair": {
                    "value": {
                      "type": "api-key-pair",
                      "id": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                      "display_name": "Back Office",
                      "algorithm": "ECDSA",
                      "thumbprint": "SopiN5XU0IWy8Xe9mwx1ICQbKh4-ydCDPx3LIyArkVI",
                      "private_key": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----",
                      "creator": null,
                      "merchant_account": {
                        "type": "merchant-account",
                        "id": "plantly-uk",
                        "display_name": "Plantly UK",
                        "created_at": "2012-12-12T10:53:43+00:00",
                        "updated_at": "2012-12-12T10:53:43+00:00"
                      },
                      "created_at": "2012-12-12T10:53:43+00:00",
                      "updated_at": "2012-12-12T10:53:43+00:00"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/api-key-pairs/{api_key_pair_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "gg9ILy"
          },
          "name": "api_key_pair_id",
          "in": "path",
          "required": true,
          "description": "The ID for the API key pair."
        }
      ],
      "put": {
        "operationId": "update-api-key-pair",
        "summary": "Update API key",
        "description": "Updates an API key-pair.",
        "tags": [
          "API Key Pairs"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/APIKeyPairUpdate"
              },
              "examples": {
                "Update an API Key Pair": {
                  "value": {
                    "display_name": "Back Office"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated key pair.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIKeyPair"
                },
                "examples": {
                  "An updated API Key Pair": {
                    "value": {
                      "type": "api-key-pair",
                      "id": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                      "display_name": "Back Office",
                      "algorithm": "ECDSA",
                      "thumbprint": "SopiN5XU0IWy8Xe9mwx1ICQbKh4-ydCDPx3LIyArkVI",
                      "private_key": null,
                      "merchant_account": {
                        "type": "merchant-account",
                        "id": "plantly-uk",
                        "display_name": "Plantly UK",
                        "created_at": "2012-12-12T10:53:43+00:00",
                        "updated_at": "2012-12-12T10:53:43+00:00"
                      },
                      "created_at": "2012-12-12T10:53:43+00:00",
                      "updated_at": "2012-12-15T10:53:43+00:00"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-api-key-pair",
        "summary": "Delete API key",
        "description": "Deletes an API key-pair.",
        "tags": [
          "API Key Pairs"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/api-logs": {
      "get": {
        "operationId": "list-api-logs",
        "summary": "List API error logs",
        "description": "Returns a list of API 4XX and 5XX logs.",
        "tags": [
          "API Logs"
        ],
        "responses": {
          "200": {
            "description": "Returns a list of API logs.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiLogs"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/apple-pay-certificates": {
      "get": {
        "operationId": "list-apple-pay-certificates",
        "summary": "List Apple Pay certificates",
        "description": "Returns a list of Apple Pay certificate records.",
        "tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of Apple Pay certificate records.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApplePayCertificates"
                },
                "examples": {
                  "A list of Apple Pay certificate records": {
                    "value": {
                      "items": [
                        {
                          "type": "apple-pay-certificate",
                          "id": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                          "display_name": "iPad App v2",
                          "status": "active",
                          "apple_merchant_id": "merchant.com.gr4vy.demo",
                          "public_key_hash": "WSOIlV70592m1ah1sm0mcmhJPQsAIWGSg7FSe+uzHtc=",
                          "certificate_signing_request": null,
                          "expires_at": "2024-12-12T10:53:43+00:00",
                          "created_at": "2022-12-12T10:53:43+00:00",
                          "updated_at": "2022-12-12T10:53:43+00:00"
                        },
                        {
                          "type": "apple-pay-certificate",
                          "id": "c81bdcfd-00c2-4897-b220-06ff0e95685a",
                          "display_name": "iPhone App v2",
                          "status": "incomplete",
                          "apple_merchant_id": null,
                          "public_key_hash": null,
                          "certificate_signing_request": "-----BEGIN CERTIFICATE REQUEST-----\\nMIHTMHsCAQAwGTEXMBUG\nA1UEAwwOc3BpZGVyLnNhbmRib3gwWTATBgcqhkjOPQIB\\nBggqhkjOPQM\nBBwNCAAQZgRE56Evtf6f9fD4Hn1zOMwyrgXU4CQXuyPXoIjiMwKXE\\nV/\nHx9NX7vZbOSXhyzPaU/b6HdLMfx2+UP/GZ48jYoAAwCgYIKoZIzj0EAwI\nDSAAw\\nRQIgPhcfepIaX9s8E8WI/T+GEUqwuYIoVUQV+F8KlaYGukACIQ\nCLeLocEFWFYPHN\\n+QsLoyXvbbqmEjSPB4vQKmXQZ8I2DA==\\n-----EN\nD CERTIFICATE REQUEST-----\\n",
                          "expires_at": null,
                          "created_at": "2022-12-12T10:53:43+00:00",
                          "updated_at": "2022-12-12T10:53:43+00:00"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-apple-pay-certificate",
        "summary": "New Apple Pay certificate",
        "description": "Starts a new Apple Pay payment processing certificate registration. The\nApple digital wallet must be registered before you can register an Apple\nPay certificate.\n\nYou will be given a Certificate Signing Request (CSR) value in the response\nto upload to Apple when creating a new payment processing certificate on\nthe Apple Developer console.",
        "tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApplePayCertificateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the Apple Pay certificate record that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApplePayCertificate"
                },
                "examples": {
                  "An Apple Pay certificate record": {
                    "value": {
                      "type": "apple-pay-certificate",
                      "id": "c81bdcfd-00c2-4897-b220-06ff0e95685a",
                      "display_name": "iPad App v2",
                      "status": "incomplete",
                      "apple_merchant_id": null,
                      "public_key_hash": null,
                      "certificate_signing_request": "-----BEGIN CERTIFICATE REQUEST-----\\nMIHTMHsCAQAwGTEXMBUG\nA1UEAwwOc3BpZGVyLnNhbmRib3gwWTATBgcqhkjOPQIB\\nBggqhkjOPQM\nBBwNCAAQZgRE56Evtf6f9fD4Hn1zOMwyrgXU4CQXuyPXoIjiMwKXE\\nV/\nHx9NX7vZbOSXhyzPaU/b6HdLMfx2+UP/GZ48jYoAAwCgYIKoZIzj0EAwI\nDSAAw\\nRQIgPhcfepIaX9s8E8WI/T+GEUqwuYIoVUQV+F8KlaYGukACIQ\nCLeLocEFWFYPHN\\n+QsLoyXvbbqmEjSPB4vQKmXQZ8I2DA==\\n-----EN\nD CERTIFICATE REQUEST-----\\n",
                      "expires_at": null,
                      "created_at": "2022-12-12T10:53:43+00:00",
                      "updated_at": "2022-12-12T10:53:43+00:00"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/apple-pay-certificates/{apple_pay_certificate_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "apple_pay_certificate_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for an Apple Pay certificate record."
        }
      ],
      "put": {
        "operationId": "update-apple-pay-certificate",
        "summary": "Update Apple Pay certificate",
        "description": "Update the Apple Pay certificate record with the payment processing\ncertificate received from Apple.\n",
        "tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary",
                    "description": "The payment processing certificate received from Apple.\nThis file should be associated with the Certificate\nSigning Request of this record, have a valid expiration\ndate, and be DER encoded."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the Apple Pay certificate record that was updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AntiFraudService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-apple-pay-certificate",
        "summary": "Remove Apple Pay certificate",
        "description": "Deletes an Apple Pay certificate record.",
        "tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/audit-logs": {
      "get": {
        "operationId": "list-audit-logs",
        "summary": "List audit logs",
        "description": "Returns a list of audit logs.",
        "tags": [
          "Audit Logs"
        ],
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "user_id",
            "description": "Filters the results to only the items for which the `user` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "created",
              "enum": [
                "created",
                "updated",
                "deleted"
              ]
            },
            "in": "query",
            "name": "action",
            "description": "Filters the results to only the items for which the `audit-log` has an\n`action` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "buyer"
            },
            "in": "query",
            "name": "resource_type",
            "description": "Filters the results to only the items for which the `audit-log` has a\n`resource` that matches this type value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of audit logs.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuditLogs"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/buyers": {
      "get": {
        "operationId": "list-buyers",
        "summary": "List buyers",
        "description": "Returns a list of buyers.",
        "tags": [
          "Buyers"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "John"
            },
            "in": "query",
            "name": "search",
            "deprecated": true,
            "description": "***Please do not use this query parameter in a production application, as this API call is\nvery inefficient and may negatively impact transaction performance.***\n\nFilters the results to only the buyers for which the `display_name`, `email_address`\nor `external_identifier` matches this value. This field allows for a case insensitive\npartial match, matching any buyer for which any of the fields partially or\ncompletely matches."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that exactly matches this value."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of buyers.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Buyers"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-buyer",
        "summary": "New buyer",
        "description": "Adds a buyer, allowing for payment methods and transactions to be associated\nto this buyer.\n",
        "tags": [
          "Buyers"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BuyerRequest"
              },
              "examples": {
                "Create a buyer": {
                  "value": {
                    "external_identifier": "412231123",
                    "display_name": "John L."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the buyer that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Buyer"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/{buyer_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "buyer_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a buyer."
        }
      ],
      "get": {
        "operationId": "get-buyer",
        "summary": "Get buyer",
        "description": "Gets the information about a buyer.",
        "tags": [
          "Buyers"
        ],
        "responses": {
          "200": {
            "description": "Returns the information about a buyer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Buyer"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-buyer",
        "summary": "Update buyer",
        "description": "Updates a buyer's details.\n",
        "tags": [
          "Buyers"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BuyerUpdate"
              },
              "examples": {
                "Update a buyer": {
                  "value": {
                    "external_identifier": "42623266",
                    "display_name": "John D."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated buyer record.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Buyer"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-buyer",
        "summary": "Delete buyer",
        "description": "Deletes a buyer record. Any associated stored payment methods will remain\nin the system but no longer associated to the buyer.",
        "tags": [
          "Buyers"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/{buyer_id}/shipping-details": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "buyer_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a buyer."
        }
      ],
      "get": {
        "operationId": "list-buyer-shipping-details",
        "summary": "List buyer shipping details",
        "description": "Retrieve all shipping details for a buyer.",
        "tags": [
          "Buyers"
        ],
        "responses": {
          "200": {
            "description": "Returns all associated shipping details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ShippingDetails"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-buyer-shipping-detail",
        "summary": "New buyer shipping detail",
        "description": "Adds a buyer shipping detail.",
        "tags": [
          "Buyers"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShippingDetailRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the shipping detail that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ShippingDetail"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/{buyer_id}/shipping-details/{shipping_detail_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "buyer_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a buyer."
        },
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "shipping_detail_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a buyer's shipping detail."
        }
      ],
      "put": {
        "operationId": "update-buyer-shipping-detail",
        "summary": "Update buyer shipping details",
        "description": "Updates shipping detail for a buyer.",
        "tags": [
          "Buyers"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShippingDetailUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated shipping detail.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ShippingDetail"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-buyer-shipping-detail",
        "summary": "Delete buyer shipping detail",
        "description": "Deletes a buyer shipping detail.",
        "tags": [
          "Buyers"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/billing-details": {
      "get": {
        "operationId": "get-buyer-billing-details",
        "summary": "Get buyer billing details",
        "description": "Gets the information about a buyer's billing details. Note that only one\nof either buyer's ID or external identifier may be passed as a\nquery parameter, and not both.",
        "tags": [
          "Buyers"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the information about a buyer's billing details.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingDetails"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-buyer-billing-details",
        "summary": "Update buyer billing details",
        "description": "Updates the billing details of a buyer. Note that only one of either\nbuyer's ID or external identifier may be passed as a query\nparameter, and not both.",
        "tags": [
          "Buyers"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BillingDetailsUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated billing details of the buyer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingDetails"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/gift-cards": {
      "get": {
        "operationId": "list-buyer-gift-cards",
        "summary": "List gift cards for buyer",
        "description": "Returns a list of all stored, not-expired gift cards and\ntheir balances for a buyer in a summarized format. Any\nexpired or empty gift cards will be automatically filtered\nout and removed from the list of returned cards.\n\nIf we were not able to fetch the latest balance then all\nstored gift cards are returned.",
        "tags": [
          "Gift Cards"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of available gift cards for a buyer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCards--Summary"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/buyers/payment-methods": {
      "get": {
        "operationId": "list-buyer-payment-methods",
        "summary": "List payment methods for buyer",
        "description": "Returns a list of stored payment methods for a buyer in a summarized format.\nOnly payment methods that are compatible with at least one active payment\nservice in that region are shown.",
        "tags": [
          "Payment Methods"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "US"
            },
            "in": "query",
            "name": "country",
            "description": "Filters the results to only the items which support this country code. A\ncountry is formatted as 2-letter ISO country code."
          },
          {
            "schema": {
              "type": "string",
              "example": "USD"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to only the items which support this currency code. A\ncurrency is formatted as 3-letter ISO currency code."
          },
          {
            "schema": {
              "type": "string",
              "description": "Set of fields to order results.",
              "example": "last_used_at",
              "enum": [
                "last_used_at",
                "usage_count",
                "cit_last_used_at",
                "cit_usage_count"
              ]
            },
            "in": "query",
            "name": "sort_by",
            "description": "Used by the payment method filter to sort the results by an specific usage field."
          },
          {
            "schema": {
              "type": "string",
              "description": "Ordering direction for the results.",
              "example": "desc",
              "enum": [
                "asc",
                "desc"
              ],
              "default": "desc"
            },
            "in": "query",
            "name": "order_by",
            "description": "Used to show the results ascending or descending order."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of available payment methods for a buyer, filtered by the\ngiven currency and country code.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentMethods--Tokenized"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/card-scheme-definitions": {
      "get": {
        "operationId": "list-card-scheme-definitions",
        "summary": "List card scheme definitions",
        "description": "Returns a list of all available card scheme definitions.",
        "tags": [
          "Card Scheme Definitions"
        ],
        "responses": {
          "200": {
            "description": "Returns a list of card scheme definitions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CardSchemeDefinitions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/connections": {
      "get": {
        "operationId": "list-connections",
        "summary": "List connections",
        "description": "Returns a list of all configured connections.",
        "tags": [
          "Connections"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns a list of connections.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Connections"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/connection-definitions": {
      "get": {
        "operationId": "list-connection-definitions",
        "summary": "List connection definitions",
        "description": "Returns a list of all available connection definitions.",
        "tags": [
          "Connection Definitions"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns a list of connection definitions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ConnectionDefinitions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/checkout/sessions": {
      "post": {
        "operationId": "new-checkout-session",
        "summary": "New checkout session",
        "description": "Creates a new Checkout Session.",
        "tags": [
          "Checkout Sessions"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutSessionCreateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the new Checkout Session.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutSession"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/checkout/sessions/{checkout_session_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "checkout_session_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a Checkout Session."
        }
      ],
      "get": {
        "operationId": "get-checkout-session",
        "summary": "Get checkout session",
        "description": "Gets details about a current Checkout Session.",
        "tags": [
          "Checkout Sessions"
        ],
        "responses": {
          "200": {
            "description": "Returns details about a current Checkout Session.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutSession"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the Checkout Session can not be found or has expired.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-checkout-session",
        "summary": "Delete checkout session",
        "description": "Deletes a Checkout Session.",
        "tags": [
          "Checkout Sessions"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the Checkout Session can not be found or has expired.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-checkout-session",
        "summary": "Update checkout session",
        "description": "Updates a Checkout Session.",
        "tags": [
          "Checkout Sessions"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutSessionUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated Checkout Session.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutSession"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/checkout/sessions/{checkout_session_id}/fields": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "checkout_session_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a Checkout Session."
        }
      ],
      "put": {
        "operationId": "update-checkout-session-fields",
        "summary": "Update fields for checkout session",
        "description": "Updates the Secure Fields of the Checkout Session.",
        "tags": [
          "Checkout Sessions"
        ],
        "security": [],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutSessionSecureFieldsUpdate"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Returns when the Checkout Session was updated."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the Checkout Session can not be found or has expired.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          },
          "429": {
            "description": "Returns an error if the same checkout session is update too often in a minute.\nThe exact rate limit differs per instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error429TooManyRequests"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods": {
      "get": {
        "operationId": "list-payment-methods",
        "summary": "List payment methods",
        "description": "Returns a list of stored payment methods.",
        "tags": [
          "Payment Methods"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          },
          {
            "schema": {
              "type": "array",
              "example": [
                "succeeded",
                "processing"
              ],
              "items": {
                "type": "string",
                "enum": [
                  "processing",
                  "buyer_approval_required",
                  "succeeded",
                  "failed"
                ]
              }
            },
            "in": "query",
            "name": "status",
            "description": "Filters the results to only the payment methods for which the `status`\nmatches with any of the provided status values."
          },
          {
            "schema": {
              "type": "string",
              "example": "xid123"
            },
            "in": "query",
            "name": "external_identifier",
            "description": "Filters the results to only the items for which the resource has an\n`external_identifier` that matches this value."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of payment methods.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentMethods"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-payment-method",
        "summary": "New payment method",
        "description": "Stores and vaults a new payment method.\n\nVaulting a card only stores its information but doesn't validate it against any\nPSP, so ephemeral data like the security code, often referred to as the CVV or\nCVD, won't be used. In order to validate the card data, a CIT (Customer Initiated\nTransaction) must be done, even if it's a zero-value one.\n",
        "tags": [
          "Payment Methods"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "x-model-name": "PaymentMethodRequest",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/CardRequest"
                  },
                  {
                    "$ref": "#/components/schemas/RedirectRequest"
                  },
                  {
                    "$ref": "#/components/schemas/CheckoutSessionRequest"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created payment method.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentMethod"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        }
      ],
      "get": {
        "operationId": "get-payment-method",
        "summary": "Get payment method",
        "description": "Gets the details for a stored payment method.",
        "tags": [
          "Payment Methods"
        ],
        "responses": {
          "200": {
            "description": "Returns a payment method.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentMethod"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-payment-method",
        "summary": "Delete payment method",
        "description": "Removes a stored payment method.",
        "tags": [
          "Payment Methods"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-method-definitions": {
      "get": {
        "operationId": "list-payment-method-definitions",
        "summary": "List payment method definitions",
        "description": "Returns a list of all available payment method definitions.",
        "tags": [
          "Payment Method Definitions"
        ],
        "responses": {
          "200": {
            "description": "Returns a list of payment method definitions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentMethodDefinitions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payment-options": {
      "get": {
        "operationId": "list-payment-options",
        "summary": "List payment options",
        "description": "Returns a list of available payment method options for the combination of\namount, currency, country and metadata.\n\nIf the amount is zero, payment options which do not support zero amounts,\nwill be omitted in the response.\n\nCheckout flow rules are used to limit these result.",
        "tags": [
          "Payment Options"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "US"
            },
            "in": "query",
            "name": "country",
            "description": "Filters the results to only the items which support this country code. A\ncountry is formatted as 2-letter ISO country code."
          },
          {
            "schema": {
              "type": "string",
              "example": "USD"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to only the items which support this currency code. A\ncurrency is formatted as 3-letter ISO currency code."
          },
          {
            "schema": {
              "type": "integer",
              "example": 500
            },
            "in": "query",
            "name": "amount",
            "description": "Used by the Flow engine to filter the results based on the transaction amount."
          },
          {
            "schema": {
              "type": "string",
              "example": "{\"restricted_items\": \"True\"}"
            },
            "in": "query",
            "name": "metadata",
            "description": "Used by the Flow engine to filter available options based on various\nclient-defined parameters. If present, this must be a string representing\na valid JSON dictionary."
          },
          {
            "schema": {
              "type": "string",
              "example": "en-US",
              "pattern": "^[a-z]{2}(?:-[A-Z]{2})?$",
              "default": "en"
            },
            "in": "query",
            "name": "locale",
            "description": "An ISO 639-1 Language Code and optional ISO 3166 Country Code. This locale\ndetermines the language for the labels returned for every payment option."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of available payment options for the given query\nparameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentOptions"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if  any of the query parameters are not recognized.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "post-list-payment-options",
        "summary": "List payment options with POST",
        "description": "Returns a list of available payment method options for the combination of\namount, currency, country, metadata and list of cart items.\n\nIf the amount is zero, payment options which do not support zero amounts,\nwill be omitted in the response.\n\nCheckout flow rules are used to limit these result.",
        "tags": [
          "Payment Options"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentOptionsRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns a list of available payment options for the given query\nparameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentOptions"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payment-services": {
      "get": {
        "operationId": "list-payment-services",
        "summary": "List payment services",
        "description": "Lists the currently configured and activated payment services.",
        "tags": [
          "Payment Services"
        ],
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "string",
              "example": "card",
              "enum": [
                "affirm",
                "afterpay",
                "alipay",
                "alipayhk",
                "applepay",
                "bacs",
                "bancontact",
                "banked",
                "becs",
                "bitpay",
                "boleto",
                "boost",
                "card",
                "cashapp",
                "chaseorbital",
                "checkout-session",
                "clearpay",
                "click-to-pay",
                "dana",
                "dcb",
                "dlocal",
                "ebanx",
                "efecty",
                "eps",
                "everydaypay",
                "gcash",
                "gem",
                "gemds",
                "gift-card",
                "giropay",
                "givingblock",
                "gocardless",
                "googlepay",
                "googlepay_pan_only",
                "gopay",
                "grabpay",
                "id",
                "ideal",
                "kakaopay",
                "kcp",
                "klarna",
                "latitude",
                "latitudeds",
                "laybuy",
                "linepay",
                "linkaja",
                "maybankqrpay",
                "mercadopago",
                "multibanco",
                "multipago",
                "netbanking",
                "network-token",
                "oney_3x",
                "oney_4x",
                "oney_6x",
                "oney_10x",
                "oney_12x",
                "ovo",
                "oxxo",
                "payid",
                "paymaya",
                "paypal",
                "paypalpaylater",
                "payto",
                "venmo",
                "pix",
                "pse",
                "rabbitlinepay",
                "razorpay",
                "scalapay",
                "sepa",
                "shopeepay",
                "singteldash",
                "smartpay",
                "sofort",
                "spei",
                "stripedd",
                "thaiqr",
                "touchngo",
                "truemoney",
                "trustly",
                "trustlyeurope",
                "upi",
                "vipps",
                "waave",
                "webpay",
                "wechat",
                "zippay"
              ]
            },
            "in": "query",
            "name": "method",
            "description": "Filters the results to only the items for which the `method` has been set to\nthis value. For example `card`."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true,
              "default": false
            },
            "in": "query",
            "name": "deleted",
            "description": "Filters the results to only show items which have been deleted.\nBy default, deleted items will not be returned."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of payment services.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServices"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "summary": "New payment service",
        "operationId": "new-payment-service",
        "description": "Adds a new payment service by providing a custom name and a value for each of the required fields.",
        "tags": [
          "Payment Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created payment service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentService"
                },
                "examples": {
                  "Stripe": {
                    "value": {
                      "type": "payment-service",
                      "id": "faaad066-30b4-4997-a438-242b0752d7e1",
                      "merchant_account_id": "default",
                      "payment_service_definition_id": "stripe",
                      "method": "card",
                      "display_name": "Stripe",
                      "status": "pending",
                      "accepted_currencies": [
                        "EUR"
                      ],
                      "accepted_countries": [
                        "DE"
                      ]
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payment-services/{payment_service_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
          },
          "name": "payment_service_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment service."
        }
      ],
      "get": {
        "operationId": "get-payment-service",
        "summary": "Get payment service",
        "description": "Retrieves the details of a single configured payment service.",
        "tags": [
          "Payment Services"
        ],
        "responses": {
          "200": {
            "description": "Returns a payment service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentService"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-payment-service",
        "summary": "Update payment service",
        "description": "Updates an existing payment service. Allows all fields to be changed except for the service ID.",
        "tags": [
          "Payment Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceUpdate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the updated payment service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-payment-service",
        "summary": "Delete payment service",
        "description": "Deletes a specific active payment service.",
        "tags": [
          "Payment Services"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-services/{payment_service_id}/sessions": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
          },
          "name": "payment_service_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment service."
        }
      ],
      "post": {
        "operationId": "create-payment-service-session",
        "summary": "Create a session for a payment service by ID",
        "description": "Creates a session for a payment service. This endpoint directly\npasses the request through to the relevant payment service for processing,\nand so the schema will differ based on the service used.\n\n\nIf the downstream service returns an error, this API will return a successful response\nwith the status code in the response.",
        "tags": [
          "Payment Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceSessionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the response from the downstream service used to generate the session.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceSession"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the referenced payment service does not exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-services/verify": {
      "post": {
        "operationId": "verify-payment-service",
        "summary": "Verify payment service credentials",
        "description": "Verifies a set of credentials against a payment service.",
        "tags": [
          "Payment Services"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceVerify"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns 200 OK if credentials successfully verified."
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required fields, or if the provided credentials are invalid and failed verification against the payment service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-service-definitions": {
      "get": {
        "operationId": "list-payment-service-definitions",
        "summary": "List payment service definitions",
        "description": "Returns a list of all available payment service definitions.",
        "tags": [
          "Payment Service Definitions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of payment service definitions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceDefinitions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payment-service-definitions/{payment_service_definition_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "stripe-card"
          },
          "name": "payment_service_definition_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the payment service definition."
        }
      ],
      "get": {
        "operationId": "get-payment-service-definition",
        "summary": "Get payment service definition",
        "description": "Gets the definition for a payment service.",
        "tags": [
          "Payment Service Definitions"
        ],
        "responses": {
          "200": {
            "description": "Returns a payment service definition.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceDefinition"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-service-definitions/{payment_service_definition_id}/sessions": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "stripe-card"
          },
          "name": "payment_service_definition_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the payment service definition."
        }
      ],
      "post": {
        "operationId": "create-payment-service-definition-session",
        "summary": "Create a session for a payment service",
        "description": "Creates a session for a payment service. This endpoint directly\npasses the request through to the relevant payment service for processing,\nand so the schema will differ based on the service used.\n\nIf the downstream service returns an error, this API will return a successful response\nwith the status code in the response.",
        "tags": [
          "Payment Service Definitions"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceSessionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the response from the downstream service used to generate the session.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceSession"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the referenced payment service definition does not exist or there is no active payment service configured for the definition.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets": {
      "post": {
        "operationId": "new-digital-wallet",
        "summary": "Register digital wallet",
        "description": "Register with a digital wallet provider.",
        "tags": [
          "Digital Wallets"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DigitalWalletRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the newly registered digital wallet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DigitalWallet"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "list-digital-wallets",
        "summary": "List digital wallets",
        "description": "Returns a list of all registered digital wallets.",
        "tags": [
          "Digital Wallets"
        ],
        "responses": {
          "200": {
            "description": "Returns a list of registered digital wallets.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DigitalWallets"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets/{digital_wallet_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "digital_wallet_id",
          "in": "path",
          "required": true,
          "description": "The ID of the registered digital wallet."
        }
      ],
      "get": {
        "operationId": "get-digital-wallet",
        "summary": "Get digital wallet",
        "description": "Returns a registered digital wallet.",
        "tags": [
          "Digital Wallets"
        ],
        "responses": {
          "200": {
            "description": "Returns a registered digital wallet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DigitalWallet"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-digital-wallet",
        "summary": "Update digital wallet",
        "description": "Updates the values a digital wallet was registered with.",
        "tags": [
          "Digital Wallets"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DigitalWalletUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated digital wallet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DigitalWallet"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-digital-wallet",
        "summary": "De-register digital wallet",
        "description": "De-registers a digital wallet with a provider. Upon successful\nde-registration, the digital wallet's record is deleted and will no\nlonger be available.\n\nA digital wallet of the Apple provider may only be de-registered if\nthere are no active Apple Pay certificates. When there are only\nincomplete or expired Apple Pay certificates, these certificates\nare deleted alongside the Apple digital wallet's record.",
        "tags": [
          "Digital Wallets"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets/{digital_wallet_id}/domains": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "digital_wallet_id",
          "in": "path",
          "required": true,
          "description": "The ID of the registered digital wallet."
        }
      ],
      "post": {
        "operationId": "add-digital-wallet-domain-name",
        "summary": "Add digital wallet domain name",
        "description": "Adds new domain for given digital wallet.",
        "tags": [
          "Digital Wallets"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DigitalWalletDomain"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-digital-wallet-domain-name",
        "summary": "Remove digital wallet domain name",
        "description": "Removes domain for given digital wallet.",
        "tags": [
          "Digital Wallets"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DigitalWalletDomain"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets/apple/session": {
      "post": {
        "operationId": "new-apple-pay-session",
        "summary": "New Apple Pay session",
        "description": "Initiates a new session with Apple Pay. This can be used when implementing\nApple Pay without our SDK.\n\nThis endpoint returns an opaque object that can be directly passed to the\nApple Pay SDK. The format of this object may change when the format returned by\nthe Apple Pay API changes.",
        "tags": [
          "Digital Wallets"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApplePaySessionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns an opaque Apple Pay session object.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApplePaySession"
                },
                "examples": {
                  "Apple Pay session": {
                    "value": {
                      "status": "200",
                      "statusMessage": {
                        "epochTimestamp": 1683210471377,
                        "expiresAt": 1683214071377,
                        "merchantSessionIdentifier": "SSH5F16FF313BC246698E095440F39D9BAE_7E0DD8CB4E6B9B9FB4C5E36B3EDF9FB0DEA51F9419420173",
                        "nonce": "500a2a26",
                        "merchantIdentifier": "A77873CD368A460BD5D3325AD76B01C16CFFF654F9A993F4B6A9B4098",
                        "domainName": "applepaydemo.apple.com",
                        "displayName": "Apple Pay Demo",
                        "signature": "308006092a864886f70d010702a0803080020101310d348016503040201308006092a864886f70d0107010000a080308203e330820388a00302010202084c304149519d5436300a06082a8648ce3d040302307a312e302c06035504030c254170706c65204170706c69636174696f6e20496e746567726174696f6e204341202d20473331263024060355040b0c1d4170706c652043657274696669636174696f6e20417574686f7269747931133011060355040a0c0a4170706c6520496e632e310b3009060355040613025553301e170d3139303531383031333235375a170d3234303531363031333235375a305f3125302306035504030c1c6563632d736d702d62726f6b65722d7369676e5f5543342d50524f4431143012060355040b0c0b694f532053797374656d7331133011060355040a0c0a4170706c6520496e632e310b30090603550406130255533059301306072a8648ce3d020106082a8648ce3d03010703420004c21577edebd6c7b2218f68dd7090a1218dc7b0bd6f2c283d846095d94af4a5411b83420ed811f3407e83331f1c54c3f7eb3220d6bad5d4eff49289893e7c0f13a38202113082020d300c0603551d130101ff04023000301f0603551d2304183016801423f249c44f93e4ef27e6c4f6286c3fa2bbfd2e4b304506082b0601050507010104393037303506082b060105050730018629687474703a2f2f6f6373702e6170706c652e636f6d2f6f63737030342d6170706c65616963613330323082011d0603551d2004820114308201103082010c06092a864886f7636405013081fe3081c306082b060105050702023081b60c81b352656c69616e6365206f6e207468697320636572746966696361746520627920616e7920706172747920617373756d657320616363657074616e6365206f6620746865207468656e206170706c696361626c65207374616e64617264207465726d7320616e6420636f6e646974696f6e73206f66207573652c20636572746966696361746520706f6c69637920616e642063657274696669636174696f6e2070726163746963652073746174656d656e74732e303606082b06010505070201162a687474703a2f2f7777772e6170706c652e636f6d2f6365727469666963617465617574686f726974792f30340603551d1f042d302b3029a027a0258623687474703a2f2f63726c2e6170706c652e636f6d2f6170706c6561696361332e63726c301d0603551d0e041604149457db6fd57481868989762f7e578507e79b5824300e0603551d0f0101ff040403020780300f06092a864886f76364061d04020500300a06082a8648ce3d0403020349003046022100be09571fe71e1e735b55e5afacb4c72feb445f30185222c7251002b61ebd6f55022100d18b350a5dd6dd6eb1746035b11eb2ce87cfa3e6af6cbd8380890dc82cddaa63308202ee30820275a0030201020208496d2fbf3a98da97300a06082a8648ce3d0403023067311b301906035504030c124170706c6520526f6f74204341202d20473331263024060355040b0c1d4170706c652043657274696669636174696f6e20417574686f7269747931133011060355040a0c0a4170706c6520496e632e310b3009060355040613025553301e170d3134303530363233343633305a170d3239303530363233343633305a307a312e302c06035504030c254170706c65204170706c69636174696f6e20496e746567726174696f6e204341202d20473331263024060355040b0c1d4170706c652043657274696669636174696f6e20417574686f7269747931133011060355040a0c0a4170706c6520496e632e310b30090603550406130255533059301306072a8648ce3d020106082a8648ce3d03010703420004f017118419d76485d51a5e25810776e880a2efde7bae4de08dfc4b93e13356d5665b35ae22d097760d224e7bba08fd7617ce88cb76bb6670bec8e82984ff5445a381f73081f4304606082b06010505070101043a3038303606082b06010505073001862a687474703a2f2f6f6373702e6170706c652e636f6d2f6f63737030342d6170706c65726f6f7463616733301d0603551d0e0416041423f249c44f93e4ef27e6c4f6286c3fa2bbfd2e4b300f0603551d130101ff040530030101ff301f0603551d23041830168014bbb0dea15833889aa48a99debebdebafdacb24ab30370603551d1f0430302e302ca02aa0288626687474703a2f2f63726c2e6170706c652e636f6d2f6170706c65726f6f74636167332e63726c300e0603551d0f0101ff0404030201063010060a2a864886f7636406020e04020500300a06082a8648ce3d040302036700306402303acf7283511699b186fb35c356ca62bff417edd90f754da28ebef19c815e42b789f898f79b599f98d5410d8f9de9c2fe0230322dd54421b0a305776c5df3383b9067fd177c2c216d964fc6726982126f54f87a7d1b99cb9b0989216106990f09921d00003182018830820184020101308186307a312e302c06035504030c254170706c65204170706c69636174696f6e20496e746567726174696f6e204341202d20473331263024060355040b0c1d4170706c652043657274696669636174696f6e20417574686f7269747931133011060355040a0c0a4170706c6520496e632e310b300906035504061302555302084c304149519d5436300b0609608648016503040201a08193301806092a864886f70d010903310b06092a864886f70d010701301c06092a864886f70d010905310f170d3233303530343134323735315a302806092a864886f70d010934311b3019300b0609608648016503040201a10a06082a8648ce3d040302302f06092a864886f70d0109043122042004eaf499fad08381253991505170637816c33797a14caa950ba44eac67a8fe7b300a06082a8648ce3d04030204473045022100fd2af84afe4acadfb7f1ac2bd2ff9c6b4f32bf64a86401b4adbdbd7b750689a0022016cda7918941782c14b60150a40dc88f73b89471df83921d4c98e8de14ada7be000000000000",
                        "operationalAnalyticsIdentifier": "Apple Pay Demo:A77873CD368A460BD01C16BB7F838CFFF654F9A993F4B6A9B4098",
                        "retries": 0,
                        "pspId": "A77873CD368A460BD5D3321C16BB7F838CFFF654F9A993F4B6A9B4098"
                      },
                      "statusCode": 200
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if no active Apple Pay service can be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets/click-to-pay/session": {
      "post": {
        "operationId": "new-click-to-pay-session",
        "summary": "New Click to Pay session",
        "description": "Returns digital payment application ID & name for use with Click to Pay.",
        "tags": [
          "Digital Wallets"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickToPaySessionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns Click to Pay session object.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickToPaySession"
                },
                "examples": {
                  "Click to Pay session": {
                    "value": {
                      "digital_payment_application_id": "DPA ID",
                      "digital_payment_application_name": "DPA name"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if no active Click to Pay service can be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/digital-wallets/google/session": {
      "post": {
        "operationId": "new-google-pay-session",
        "summary": "New Google Pay session",
        "description": "Initiates a new session with Google Pay. This can be used when implementing\nGoogle Pay without our SDK.",
        "tags": [
          "Digital Wallets"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GooglePaySessionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns a JWT used for Google Pay authentication.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GooglePaySession"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if no active Google Pay service can be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions": {
      "get": {
        "operationId": "list-transactions",
        "summary": "List transactions",
        "description": "Lists all transactions for an account. Sorted by last updated at.",
        "tags": [
          "Transactions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 500,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "integer",
              "example": 500
            },
            "in": "query",
            "name": "amount_eq",
            "description": "Filters for transactions that have an `amount` that is\nequal to the provided `amount_eq` value."
          },
          {
            "schema": {
              "type": "integer",
              "example": 500
            },
            "in": "query",
            "name": "amount_gte",
            "description": "Filters for transactions that have an `amount` that is\ngreater than or equal to the `amount_gte` value."
          },
          {
            "schema": {
              "type": "integer",
              "example": 500
            },
            "in": "query",
            "name": "amount_lte",
            "description": "Filters for transactions that have an `amount` that is\nless than or equal to the `amount_lte` value."
          },
          {
            "schema": {
              "type": "string",
              "format": "uuid",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "checkout_session_id",
            "description": "Filters for transactions that are linked to the unique ID for a Checkout Session."
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "created_at_gte",
            "description": "Filters the results to only transactions created after this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "created_at_lte",
            "description": "Filters the results to only transactions created before this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              },
              "example": [
                "USD",
                "GBP"
              ]
            },
            "in": "query",
            "name": "currency",
            "description": "Filters for transactions that have matching `currency` values.\nThe `currency` values provided must be formatted as 3-letter ISO\ncurrency code."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "external_identifier",
            "description": "Filters the results to only the items for which the `external_identifier`\nmatches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "be828248-56de-481e-a580-44b6e1d4df81",
              "format": "uuid"
            },
            "in": "query",
            "name": "gift_card_id",
            "description": "Filters for transactions that have at least one gift card\nredemption with a matching `gift_card_id` value."
          },
          {
            "schema": {
              "type": "string",
              "example": "7890",
              "minLength": 4,
              "maxLength": 4
            },
            "in": "query",
            "name": "gift_card_last4",
            "description": "Filters for transactions that have at least one gift card\nredemption where the last 4 digits of its gift card number\nmatches exactly with the provided value."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "has_gift_card_redemptions",
            "description": "When set to `true`, filters for transactions that have at least one gift\ncard redemption associated with it. When set to `false`, filter for\ntransactions that have no gift card redemptions."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "has_refunds",
            "description": "When set to `true`, filter for transactions that have at least one completed\nrefund (including gift card refunds) associated with it. When set to `false`,\nfilter for transactions that have no completed refunds."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "has_settlements",
            "description": "When set to `true`, filter for transactions that have at least one settlement.\nWhen set to `false`, filter for transactions that have no settlements."
          },
          {
            "schema": {
              "type": "string",
              "example": "be828248-56de-481e-a580-44b6e1d4df81",
              "format": "uuid"
            },
            "in": "query",
            "name": "id",
            "description": "Filters for the transaction that has a matching `id` value."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              },
              "example": [
                "{\"key\": \"value\"}",
                "{\"key_one\": \"value\", \"key_two\": \"value\"}"
              ]
            },
            "explode": true,
            "in": "query",
            "name": "metadata",
            "description": "Filters for transactions where their `metadata` values\ncontain all of the provided `metadata` keys. The value sent\nfor `metadata` must be formatted as a JSON string, and all\nkeys and values must be strings. This value should also be URL\nencoded.\n\nDuplicate keys are not supported. If a key is duplicated, only the\nlast appearing value will be used."
          },
          {
            "schema": {
              "type": "array",
              "example": [
                "card"
              ],
              "items": {
                "type": "string",
                "example": "card",
                "enum": [
                  "affirm",
                  "afterpay",
                  "alipay",
                  "alipayhk",
                  "applepay",
                  "bacs",
                  "bancontact",
                  "banked",
                  "becs",
                  "bitpay",
                  "boleto",
                  "boost",
                  "card",
                  "cashapp",
                  "chaseorbital",
                  "checkout-session",
                  "clearpay",
                  "click-to-pay",
                  "dana",
                  "dcb",
                  "dlocal",
                  "ebanx",
                  "efecty",
                  "eps",
                  "everydaypay",
                  "gcash",
                  "gem",
                  "gemds",
                  "gift-card",
                  "giropay",
                  "givingblock",
                  "gocardless",
                  "googlepay",
                  "googlepay_pan_only",
                  "gopay",
                  "grabpay",
                  "id",
                  "ideal",
                  "kakaopay",
                  "kcp",
                  "klarna",
                  "latitude",
                  "latitudeds",
                  "laybuy",
                  "linepay",
                  "linkaja",
                  "maybankqrpay",
                  "mercadopago",
                  "multibanco",
                  "multipago",
                  "netbanking",
                  "network-token",
                  "oney_3x",
                  "oney_4x",
                  "oney_6x",
                  "oney_10x",
                  "oney_12x",
                  "ovo",
                  "oxxo",
                  "payid",
                  "paymaya",
                  "paypal",
                  "paypalpaylater",
                  "payto",
                  "venmo",
                  "pix",
                  "pse",
                  "rabbitlinepay",
                  "razorpay",
                  "scalapay",
                  "sepa",
                  "shopeepay",
                  "singteldash",
                  "smartpay",
                  "sofort",
                  "spei",
                  "stripedd",
                  "thaiqr",
                  "touchngo",
                  "truemoney",
                  "trustly",
                  "trustlyeurope",
                  "upi",
                  "vipps",
                  "waave",
                  "webpay",
                  "wechat",
                  "zippay"
                ]
              }
            },
            "in": "query",
            "name": "method",
            "description": "Filters the results to only the items for which the `method` has been set to\nthis value."
          },
          {
            "schema": {
              "type": "string",
              "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
              "format": "uuid"
            },
            "in": "query",
            "name": "payment_method_id",
            "description": "Filters for transactions that have a payment method with an ID that matches exactly with the provided value."
          },
          {
            "schema": {
              "type": "string",
              "example": "1234"
            },
            "in": "query",
            "name": "payment_method_label",
            "description": "Filters for transactions that have a payment method with a label\nthat matches exactly with the provided value."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "uuid"
              },
              "example": [
                "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
              ]
            },
            "in": "query",
            "name": "payment_service_id",
            "description": "Filters for transactions that were processed by the provided\n`payment_service_id` values."
          },
          {
            "schema": {
              "type": "string",
              "example": "transaction_123"
            },
            "in": "query",
            "name": "payment_service_transaction_id",
            "description": "Filters for transactions that have a matching\n`payment_service_transaction_id` value. The `payment_service_transaction_id`\nis the identifier of the transaction given by the payment service."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "pending_review",
            "description": "When set to `true`, filter for transactions that have a manual review pending.\nWhen set to `false`, filter for transactions that don't have a manual review pending."
          },
          {
            "schema": {
              "type": "string",
              "format": "string",
              "example": "7EgeeeTX0DS45RBDNt4AEY"
            },
            "in": "query",
            "name": "reconciliation_id",
            "description": "Filters for transactions based on their transaction reconciliation identifier."
          },
          {
            "schema": {
              "type": "string",
              "example": "be828248-56de-481e-a580-44b6e1d4df81"
            },
            "in": "query",
            "name": "search",
            "deprecated": true,
            "description": "Filters for transactions that have one of the following fields\nmatch exactly with the provided `search` value.\n\n* `buyer_external_identifier`\n* `buyer_id`\n* `external_identifier`\n* `id`\n* `payment_service_transaction_id`\n\nThe search will apply against all fields at the same time.\nPlease do not use this query parameter in a production application, as this API call is\nvery inefficient and may negatively impact transaction performance."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "processing",
                  "buyer_approval_pending",
                  "authorization_succeeded",
                  "authorization_failed",
                  "authorization_declined",
                  "capture_pending",
                  "capture_succeeded",
                  "authorization_void_pending",
                  "authorization_voided"
                ]
              },
              "example": [
                "capture_succeeded",
                "processing"
              ]
            },
            "in": "query",
            "name": "status",
            "description": "Filters the results to only the transactions that have a `status`\nthat matches with any of the provided status values."
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "updated_at_gte",
            "description": "Filters the results to only transactions last updated after this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "updated_at_lte",
            "description": "Filters the results to only transactions last updated before this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "is_subsequent_payment",
            "description": "When set to `true`, filter for transactions that are a subsequent payment.\nWhen set to `false`, filter for transactions that are not an initial payment."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "merchant_initiated",
            "description": "When set to `true`, filter for transactions that are merchant initiated.\nWhen set to `false`, filter for transactions that are not merchant initiated."
          },
          {
            "schema": {
              "type": "string",
              "example": "411111"
            },
            "in": "query",
            "name": "payment_method_bin",
            "description": "Filter for transactions that have a card with a BIN that matches exactly with the provided value."
          },
          {
            "schema": {
              "type": "array",
              "example": [
                "ecommerce",
                "recurring"
              ],
              "items": {
                "type": "string",
                "example": "recurring",
                "enum": [
                  "ecommerce",
                  "moto",
                  "recurring",
                  "installment",
                  "card_on_file"
                ]
              }
            },
            "in": "query",
            "name": "payment_source",
            "description": "Filters the results to only the transactions that have a payment source that matches with any of the provided values."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a paginated list of transactions for an account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transactions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        },
        "x-speakeasy-pagination": {
          "type": "cursor",
          "inputs": [
            {
              "name": "cursor",
              "in": "parameters",
              "type": "cursor"
            }
          ],
          "outputs": {
            "nextCursor": "$.next_cursor"
          }
        }
      },
      "post": {
        "summary": "New transaction",
        "tags": [
          "Transactions"
        ],
        "operationId": "new-transaction",
        "description": "Attempts to create an authorization for a payment method. In some cases it is\nnot possible to create the authorization without redirecting the user for\ntheir authorization. In these cases the status is set to\nindicate buyer approval is pending and an approval URL is returned.\n\nDuplicated gift card numbers are not supported. This includes both stored gift\ncards, as well as those directly provided via the request.\n",
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "bffa9ce6-7a8a-449c-889a-65bd2ee86903"
            },
            "in": "header",
            "name": "Idempotency-Key",
            "description": "A unique key that identifies this request. Providing this header will make\nthis an idempotent request. We recommend using V4 UUIDs, or another random\nstring with enough entropy to avoid collisions."
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionRequest"
              },
              "examples": {
                "Authorize a new card": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "payment_method": {
                      "method": "card",
                      "number": "4111111111111111",
                      "expiration_date": "11/25",
                      "security_code": "123",
                      "redirect_url": "https://example.com/callback"
                    }
                  }
                },
                "Authorize and store a card": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "store": true,
                    "payment_method": {
                      "method": "card",
                      "number": "4111111111111111",
                      "expiration_date": "11/25",
                      "security_code": "123",
                      "redirect_url": "https://example.com/callback"
                    }
                  }
                },
                "Authorize, capture, and store a card": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "intent": "capture",
                    "store": true,
                    "payment_method": {
                      "method": "card",
                      "number": "4111111111111111",
                      "expiration_date": "11/25",
                      "security_code": "123",
                      "redirect_url": "https://example.com/callback"
                    }
                  }
                },
                "Authorize and capture a GoCardless transaction": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "intent": "capture",
                    "payment_method": {
                      "method": "gocardless",
                      "redirect_url": "https://example.com/callback",
                      "country": "US",
                      "currency": "USD"
                    }
                  }
                },
                "Authorize and capture using a previously stored card": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "intent": "capture",
                    "payment_method": {
                      "method": "id",
                      "id": "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
                    }
                  }
                },
                "Authorize a new card with connection options and anti-fraud fingerprint": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "payment_method": {
                      "method": "card",
                      "number": "4111111111111111",
                      "expiration_date": "11/25",
                      "security_code": "123",
                      "redirect_url": "https://example.com/callback"
                    },
                    "connection_options": {
                      "cybersource-anti-fraud": {
                        "merchant_defined_data": {
                          "1": "John Doe",
                          "2": "trusted",
                          "99": "recurring"
                        }
                      }
                    },
                    "anti_fraud_fingerprint": "yGeBAFYgFmM="
                  }
                },
                "Authorize and asynchronously capture a card transaction": {
                  "value": {
                    "amount": 1299,
                    "currency": "USD",
                    "intent": "capture",
                    "async_capture": true,
                    "payment_method": {
                      "method": "card",
                      "number": "4111111111111111",
                      "expiration_date": "11/25",
                      "security_code": "123",
                      "redirect_url": "https://example.com/callback"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created transaction.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transaction"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          },
          "429": {
            "description": "Returns an error if the same token is used for too many requests per minute.\nThe exact rate limit differs per instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error429TooManyRequests"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "get-transaction",
        "summary": "Get transaction",
        "description": "Get information about a transaction.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns a transaction resource.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transaction"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found or has not yet been created.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/actions": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "get-transaction-actions",
        "summary": "List actions for transaction",
        "description": "Gets actions for a given transaction.",
        "tags": [
          "Transactions"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns associated actions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Actions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/capture": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "post": {
        "operationId": "capture-transaction",
        "summary": "Capture transaction",
        "description": "Captures a previously authorized transaction.",
        "tags": [
          "Transactions"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionCaptureRequest"
              },
              "examples": {
                "Capture an authorization": {
                  "value": {
                    "amount": 1299
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the captured transaction.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transaction"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found or has not yet been created.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/events": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "get-transaction-events",
        "summary": "List events for transaction",
        "description": "Get a list of events related to processing a transaction.",
        "tags": [
          "Transactions"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "integer",
              "default": 100,
              "example": 1,
              "minimum": 1,
              "maximum": 500,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a collection of transaction history events.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TransactionHistoryEvents"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found or has not yet been created.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/refunds": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "list-transaction-refunds",
        "summary": "List refunds",
        "description": "Lists all refunds associated with a certain transaction.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns a list of refunds.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Refunds"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-refund",
        "summary": "Refund transaction",
        "description": "Refunds a transaction, fully or partially.\n\nIf the transaction was not yet successfully captured, the\nrefund will not be processed. Authorized transactions can be\nvoided instead.",
        "tags": [
          "Transactions"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionRefundRequest"
              },
              "examples": {
                "Request a full refund on a transaction": {
                  "value": {}
                },
                "Request a partial refund on a transaction": {
                  "value": {
                    "amount": 1299
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created refund.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Refund"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/refunds/all": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "post": {
        "operationId": "refund-all",
        "summary": "Refund all instruments in a transaction",
        "description": "Refunds a transaction fully across all instruments.",
        "tags": [
          "Transactions"
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionRefundAllRequest"
              },
              "examples": {
                "Request a full refund on a transaction with a reason": {
                  "value": {
                    "reason": "Refund due to user request"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created refunds. Not all refunds may have succeeded.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Refunds"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/refunds/{refund_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        },
        {
          "schema": {
            "type": "string",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "refund_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the refund."
        }
      ],
      "get": {
        "operationId": "get-refund",
        "summary": "Get refund",
        "description": "Gets information about a refund associated with a certain transaction.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns a refund.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Refund"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/settlements": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "get-transaction-settlements",
        "summary": "List settlements for transaction",
        "description": "Gets settlements for a given transaction.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns associated settlements.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Settlements"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/settlements/{settlement_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        },
        {
          "schema": {
            "type": "string",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "settlement_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the settlement."
        }
      ],
      "get": {
        "operationId": "get-transaction-settlement",
        "summary": "Get settlement",
        "description": "Gets information about a settlement associated with a certain transaction.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns a settlement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Settlement"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/sync": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "post": {
        "operationId": "sync-transaction",
        "summary": "Sync transaction",
        "description": "Sync the transaction with the payment service to get the latest status,\namounts, and some of the identifiers. This is only available for some payment\nservice providers.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns the updated transaction resource.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transaction"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found or has not yet been created.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/refunds/{refund_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "refund_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the refund."
        }
      ],
      "get": {
        "operationId": "get-single-refund",
        "summary": "Get refund",
        "description": "Gets information about a refund.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns a refund.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Refund"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/summary": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "get": {
        "operationId": "get-transaction-summary",
        "summary": "Get transaction summary",
        "description": "Gets summary for a given transaction.",
        "tags": [
          "Transactions"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns associated transaction status summary.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TransactionStatusSummary"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/transactions/{transaction_id}/void": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "transaction_id",
          "in": "path",
          "required": true,
          "description": "The ID for the transaction to get the information for."
        }
      ],
      "post": {
        "operationId": "void-transaction",
        "summary": "Void transaction",
        "description": "Voids a transaction.\n\nIf the transaction was not yet successfully authorized, or was already\ncaptured, the void will not be processed. Captured transactions can be\nrefunded instead.\n\nVoiding zero-amount authorized transactions is not supported.\n\nOnce voided, the status of the transaction will be either `authorization_voided`,\n`authorization_void_pending`, or if the void fails the original status will remain.",
        "tags": [
          "Transactions"
        ],
        "responses": {
          "200": {
            "description": "Returns the voided transaction.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transaction"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/users/me": {
      "get": {
        "operationId": "get-current-user",
        "summary": "Get current user",
        "description": "Get current user information.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "200": {
            "description": "Returns the currently authenticated user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-current-user",
        "summary": "Update current user",
        "description": "Update current user information.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserCurrentUpdate"
              },
              "examples": {
                "Update a user": {
                  "value": {
                    "name": "John D."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the currently authenticated user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/users/{user_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "user_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a user."
        }
      ],
      "get": {
        "operationId": "get-user",
        "summary": "Get user",
        "description": "Gets the information about a user.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "200": {
            "description": "Returns the user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-user",
        "summary": "Update user",
        "description": "Updates a user's details.\n",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserUpdate"
              },
              "examples": {
                "Update a user": {
                  "value": {
                    "name": "John D.",
                    "role_ids": [
                      "462ab2e2-3e29-44bd-b39f-e4d1293affbb"
                    ],
                    "merchant_account_ids": [
                      "default",
                      "plantly-uk"
                    ]
                  }
                },
                "Update a user with merchant account": {
                  "value": {
                    "name": "John D.",
                    "role_ids": [
                      "462ab2e2-3e29-44bd-b39f-e4d1293affbb"
                    ],
                    "merchant_account_ids": [
                      "default",
                      "plantly-uk"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated user record.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-user",
        "summary": "Delete user",
        "description": "Deletes a user record. Any associated sessions will also be deleted.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/users": {
      "get": {
        "operationId": "list-users",
        "summary": "List users",
        "description": "Returns a list of users.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "John"
            },
            "in": "query",
            "name": "search",
            "description": "Filters the results to only the users for which the `name` or\n`email_address` matches this value. This field allows for a partial\nmatch, matching any user for which either of the fields partially or\ncompletely matches."
          },
          {
            "schema": {
              "type": "string",
              "example": "active",
              "enum": [
                "active",
                "pending"
              ]
            },
            "in": "query",
            "name": "status",
            "description": "Filters the results to only the users for which the `status`\nmatches this value."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              },
              "example": [
                "8724fd24-5489-4a5d-90fd-0604df7d3b83"
              ]
            },
            "in": "query",
            "name": "roles",
            "description": "Filters the results to only match the users that have any `roles`\nthat matches with any of the provided role IDs."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of users.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Users"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-user",
        "summary": "New user",
        "description": "Adds a new user.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserRequest"
              },
              "examples": {
                "Create a user": {
                  "value": {
                    "display_name": "John L.",
                    "email_address": "john@example.com",
                    "role_ids": [
                      "462ab2e2-3e29-44bd-b39f-e4d1293affbb"
                    ],
                    "merchant_account_ids": [
                      "default",
                      "plantly-uk"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns new user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/users/set-password": {
      "post": {
        "operationId": "set-password",
        "summary": "Set user password",
        "description": "Sets a user password to allow authentication with the dashboard.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetPasswordRequest"
              },
              "examples": {
                "Create a user": {
                  "value": {
                    "reset_token": "nXyWSHq2r5q_8F1_NXtppEStY7KbBHqwU9T8pdmOQa_LYJxpxxXcjOXL58xpHLy5gh1k6s0Myl3ygA6SnsxIjLXBKO3x1EZX3igq",
                    "password": "this-is-n0t-a-secure-passw0rd"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/users/reset-password": {
      "post": {
        "operationId": "reset-password",
        "summary": "Reset user password",
        "description": "Generates a new reset token for a given user.",
        "tags": [
          "Users"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResetPasswordRequest"
              },
              "examples": {
                "Create a user": {
                  "value": {
                    "email_address": "john@example.com"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the user object.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/User"
                }
              }
            }
          },
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/inbound-webhooks/{hook}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "e4f7797af7cc56edb85cde7f94745a13"
          },
          "name": "hook",
          "in": "path",
          "required": true,
          "description": "Opaque token representing the payment service associated with\nthe webhook endpoint."
        }
      ],
      "post": {
        "operationId": "inbound-webhook-deprecated",
        "summary": "Inbound webhook",
        "description": "Inbound webhook endpoint to connect to payment services.\n\nThe response code and payload will depend on the payment\nservice definition.\n\n**Warning**: this endpoint will be removed eventually, use\n[Inbound webhook](#operation/inbound-webhook).",
        "tags": [
          "Webhooks"
        ],
        "security": [],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the expected content by the payment service to\nindicate that the webhook has been successfully received."
          }
        },
        "deprecated": true
      }
    },
    "/i/{payload}/{signature}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "zian1_7ATUeO-gRKMrCbxmJyYWludHJlZS1jYXJk"
          },
          "name": "payload",
          "in": "path",
          "required": true,
          "description": "Opaque data representing the service information associated with\nthe webhook endpoint."
        },
        {
          "schema": {
            "type": "string",
            "example": "VKJw22zyhitK4UlofhFbktBT1esRVua1tN382mFDtrM"
          },
          "name": "signature",
          "in": "path",
          "required": true,
          "description": "Signature of the opaque data with the service information\nused for the webhook endpoint."
        }
      ],
      "post": {
        "operationId": "inbound-webhook",
        "summary": "Inbound webhook",
        "description": "Inbound webhook endpoint to connect to payment services.\n\nThe response code and payload will depend on the payment\nservice definition.",
        "tags": [
          "Webhooks"
        ],
        "security": [],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the expected content by the payment service to\nindicate that the webhook has been successfully received."
          }
        }
      }
    },
    "/i/{resource}/{payload}/{signature}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "ps",
            "enum": [
              "af",
              "ps"
            ]
          },
          "name": "resource",
          "in": "path",
          "required": true,
          "description": "Resource type identifier to which the webhook data is related."
        },
        {
          "schema": {
            "type": "string",
            "example": "zian1_7ATUeO-gRKMrCbxmJyYWludHJlZS1jYXJk"
          },
          "name": "payload",
          "in": "path",
          "required": true,
          "description": "Opaque data representing the service information associated with\nthe webhook endpoint."
        },
        {
          "schema": {
            "type": "string",
            "example": "VKJw22zyhitK4UlofhFbktBT1esRVua1tN382mFDtrM"
          },
          "name": "signature",
          "in": "path",
          "required": true,
          "description": "Signature of the opaque data with the service information\nused for the webhook endpoint."
        }
      ],
      "post": {
        "operationId": "inbound-webhooks",
        "summary": "Inbound webhook",
        "description": "Inbound webhook endpoint to receive data from external services.\n\nThe response code and payload depends on external service.",
        "tags": [
          "Webhooks"
        ],
        "security": [],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the expected content by the service to\nindicate that the webhook has been successfully received."
          }
        }
      }
    },
    "/card-details": {
      "get": {
        "operationId": "get-card-details",
        "summary": "Get card details",
        "description": "Retrieves details about a card using either that\ncard's BIN or for stored cards the `payment_method_id`.",
        "tags": [
          "Card Details"
        ],
        "x-internal": true,
        "x-speakeasy-ignore": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "USD"
            },
            "in": "query",
            "name": "currency",
            "required": true,
            "description": "Filters the results to only the items which support this currency code. A\ncurrency is formatted as 3-letter ISO currency code."
          },
          {
            "schema": {
              "type": "integer",
              "example": 500
            },
            "in": "query",
            "name": "amount",
            "description": "Used by the Flow engine to filter the results based on the transaction amount."
          },
          {
            "schema": {
              "type": "string",
              "minLength": 8,
              "maxLength": 8,
              "example": "42424242"
            },
            "in": "query",
            "name": "bin",
            "description": "The first 8 digits (the BIN) of the card."
          },
          {
            "schema": {
              "type": "string",
              "example": "US"
            },
            "in": "query",
            "name": "country",
            "description": "Filters the results to only the items which support this country code. A\ncountry is formatted as 2-letter ISO country code."
          },
          {
            "schema": {
              "type": "string",
              "example": "capture",
              "enum": [
                "authorize",
                "capture"
              ]
            },
            "in": "query",
            "name": "intent",
            "description": "The intent of the transaction."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "is_subsequent_payment",
            "description": "Used by the Flow engine to filter available options based on the value\nof the `is_subsequent_payment` flag."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "merchant_initiated",
            "description": "Used by the Flow engine to filter available options based on the value\nof the `merchant_initiated` flag."
          },
          {
            "schema": {
              "type": "string",
              "example": "{\"restricted_items\": \"True\"}"
            },
            "in": "query",
            "name": "metadata",
            "description": "Used by the Flow engine to filter available options based on various\nclient-defined parameters. If present, this must be a string representing\na valid JSON dictionary."
          },
          {
            "schema": {
              "type": "string",
              "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
              "format": "uuid"
            },
            "in": "query",
            "name": "payment_method_id",
            "description": "Filters for transactions that have a payment method with an ID that matches exactly with the provided value."
          },
          {
            "schema": {
              "type": "string",
              "example": "recurring",
              "enum": [
                "ecommerce",
                "moto",
                "recurring",
                "installment",
                "card_on_file"
              ]
            },
            "in": "query",
            "name": "payment_source",
            "description": "Used by the Flow engine to filter available options based on the\npayment source."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns information about a card.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CardDetails"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if any of the query parameters are not recognised.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/flows/{flow}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "name": "flow",
          "in": "path",
          "required": true,
          "description": "The flow name. This can be one of the following.\n\n- `checkout` - Applies during checkout to determine what payment options are shown.\n- `card-transaction` - Applies when processing a card transaction.\n- `non-card-transaction` - Applies when processing a gift card only transaction, or a\nredirect transaction using the `decline-early` action.\n- `redirect-transaction` - Applies when processing any other transaction."
        }
      ],
      "get": {
        "operationId": "list-flow-rules",
        "summary": "List flow rules",
        "description": "Returns a list of rules for a given flow. Each rule has an\nassociated action, conditions, and outcome.",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns a list of rules.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRules"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/flows/{flow}/actions/{action}/rules": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "name": "flow",
          "in": "path",
          "required": true,
          "description": "The flow name. This can be one of the following.\n\n- `checkout` - Applies during checkout to determine what payment options are shown.\n- `card-transaction` - Applies when processing a card transaction.\n- `non-card-transaction` - Applies when processing a gift card only transaction, or a\nredirect transaction using the `decline-early` action.\n- `redirect-transaction` - Applies when processing any other transaction."
        },
        {
          "schema": {
            "type": "string",
            "description": "Action for the given rule. Actions can only be used in\nflows that support them.\n\n* The `checkout` flow only supports the\n`select-payment-options` action.\n* The `card-transaction` supports the `route-transaction`,\n`skip-3ds`, and `decline-early` actions.\n* The `non-card-transaction` flow only supports the\n`decline-early` action.\n* The `redirect-transaction` flow only supports\nthe `route-transaction` action.\n",
            "example": "select-payment-options",
            "enum": [
              "select-payment-options",
              "decline-early",
              "route-transaction",
              "skip-3ds"
            ]
          },
          "name": "action",
          "in": "path",
          "required": true,
          "description": "The flow action."
        }
      ],
      "post": {
        "operationId": "new-flow-rule",
        "summary": "Create flow rule",
        "description": "Adds a rule for a given flow and action.\n",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FlowRuleCreateRequest"
              },
              "examples": {
                "Create Rule": {
                  "value": {
                    "description": "example rule description.",
                    "conditions": [
                      {
                        "name": "currency",
                        "operator": "is_one_of",
                        "value": [
                          "GBP",
                          "USD"
                        ]
                      },
                      {
                        "name": "country",
                        "operator": "is_one_of",
                        "value": [
                          "GB",
                          "US"
                        ]
                      }
                    ],
                    "outcome": {
                      "type": "list",
                      "result": [
                        "card",
                        "gocardless"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the rule that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRule"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields. If `use_additional_scheme` transformation is used with the `network_token` instrument, a bad request is returned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/flows/{flow}/actions/{action}/rules/{rule_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "name": "flow",
          "in": "path",
          "required": true,
          "description": "The flow name. This can be one of the following.\n\n- `checkout` - Applies during checkout to determine what payment options are shown.\n- `card-transaction` - Applies when processing a card transaction.\n- `non-card-transaction` - Applies when processing a gift card only transaction, or a\nredirect transaction using the `decline-early` action.\n- `redirect-transaction` - Applies when processing any other transaction."
        },
        {
          "schema": {
            "type": "string",
            "description": "Action for the given rule. Actions can only be used in\nflows that support them.\n\n* The `checkout` flow only supports the\n`select-payment-options` action.\n* The `card-transaction` supports the `route-transaction`,\n`skip-3ds`, and `decline-early` actions.\n* The `non-card-transaction` flow only supports the\n`decline-early` action.\n* The `redirect-transaction` flow only supports\nthe `route-transaction` action.\n",
            "example": "select-payment-options",
            "enum": [
              "select-payment-options",
              "decline-early",
              "route-transaction",
              "skip-3ds"
            ]
          },
          "name": "action",
          "in": "path",
          "required": true,
          "description": "The flow action."
        },
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "rule_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a rule."
        }
      ],
      "get": {
        "operationId": "get-flow-rule",
        "summary": "Get rule",
        "description": "Returns a configured rule that triggers an action in a flow.",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the flow rule.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRule"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-flow-rule",
        "summary": "Update flow rule",
        "description": "Updates a given flow rule.\n",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FlowRuleUpdateRequest"
              },
              "examples": {
                "Update Rule": {
                  "value": {
                    "description": "example description update.",
                    "position": 1
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated rule record.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRule"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields. If `use_additional_scheme` transformation is used with the `network_token` instrument, a bad request is returned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-flow-rule",
        "summary": "Delete flow rule",
        "description": "Deletes a given rule from the system.",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/flows/{flow}/actions/{action}/outcomes": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "name": "flow",
          "in": "path",
          "required": true,
          "description": "The flow name. This can be one of the following.\n\n- `checkout` - Applies during checkout to determine what payment options are shown.\n- `card-transaction` - Applies when processing a card transaction.\n- `non-card-transaction` - Applies when processing a gift card only transaction, or a\nredirect transaction using the `decline-early` action.\n- `redirect-transaction` - Applies when processing any other transaction."
        },
        {
          "schema": {
            "type": "string",
            "description": "Action for the given rule. Actions can only be used in\nflows that support them.\n\n* The `checkout` flow only supports the\n`select-payment-options` action.\n* The `card-transaction` supports the `route-transaction`,\n`skip-3ds`, and `decline-early` actions.\n* The `non-card-transaction` flow only supports the\n`decline-early` action.\n* The `redirect-transaction` flow only supports\nthe `route-transaction` action.\n",
            "example": "select-payment-options",
            "enum": [
              "select-payment-options",
              "decline-early",
              "route-transaction",
              "skip-3ds"
            ]
          },
          "name": "action",
          "in": "path",
          "required": true,
          "description": "The flow action."
        }
      ],
      "get": {
        "operationId": "list-flow-outcomes",
        "summary": "List flow outcomes",
        "description": "Returns a list of possible outcomes for a given flow action.",
        "tags": [
          "Flow"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "en-US",
              "pattern": "^[a-z]{2}(?:-[A-Z]{2})?$",
              "default": "en"
            },
            "in": "query",
            "name": "locale",
            "description": "An ISO 639-1 Language Code and optional ISO 3166 Country Code. This locale\ndetermines the language for the labels returned for every payment option."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of rule outcomes.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRuleOutcomes"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/gift-cards": {
      "get": {
        "operationId": "list-gift-cards",
        "summary": "List gift cards",
        "description": "Returns all stored gift cards.",
        "tags": [
          "Gift Cards"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
            },
            "in": "query",
            "name": "buyer_id",
            "description": "Filters the results to only the items for which the `buyer` has an\n`id` that matches this value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user-12345"
            },
            "in": "query",
            "name": "buyer_external_identifier",
            "description": "Filters the results to only the items for which the `buyer` has an\n`external_identifier` that matches this value."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of gift cards.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCards"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "store-gift-card",
        "summary": "Store gift card",
        "description": "Stores a gift card.\n\nVaulting a gift card stores and validate it against the active gift card\nservice.\n\nIt is only possible to store a gift card against a buyer if the same card is\nnot already stored on the buyer and the gift card has not expired yet.\n\nBuyers by default can only have a maximum limit of 10 gift cards stored against\nthem. Please contact our team to change this limit. To clear out any expired or\nempty gift cards, you can call the `GET /buyers/gift-cards` endpoint which will\nautomatically archive any of those cards and allow new cards to be stored.\n",
        "tags": [
          "Gift Cards"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GiftCardStoreRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the stored gift card.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCard"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          },
          "429": {
            "description": "Returns an error if the same token is used for too many requests per minute.\nThe exact rate limit differs per instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error429TooManyRequests"
                }
              }
            }
          }
        }
      }
    },
    "/gift-cards/{gift_card_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893"
          },
          "name": "gift_card_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of a stored gift card."
        }
      ],
      "get": {
        "operationId": "get-gift-card",
        "summary": "Get gift card",
        "description": "Retrieves details of a stored gift card.",
        "tags": [
          "Gift Cards"
        ],
        "responses": {
          "200": {
            "description": "Returns a stored gift card.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCard"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-gift-card",
        "summary": "Delete gift card",
        "description": "Removes a stored gift card.",
        "tags": [
          "Gift Cards"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/gift-cards/balances": {
      "post": {
        "summary": "Verify and check gift card balances",
        "operationId": "check-gift-card-balances",
        "description": "Verify gift cards are enrolled and fetch their balances.\n\nThis verifies a list of gift cards are enrolled for your gift card programme,\nif this feature is available via your gift card service. It then also fetches each card's\ncurrent balance.\n\nDuplicated gift card numbers are not supported. This includes both stored gift\ncards, as well as those directly provided via the request.",
        "tags": [
          "Gift Cards"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GiftCardBalancesRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the balances for each of the gift cards. Balances are returned in the same\norder they are requested.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCards--Summary"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "429": {
            "description": "Returns an error if the same token is used for too many requests per minute.\nThe exact rate limit differs per instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error429TooManyRequests"
                }
              }
            }
          }
        }
      }
    },
    "/gift-card-services": {
      "post": {
        "summary": "New gift card service",
        "operationId": "new-gift-card-service",
        "description": "Adds a new gift card service by providing a custom name and a value for each of the required fields.",
        "tags": [
          "Gift Card Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GiftCardServiceCreateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created gift card service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCardService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if there is an attempt to activate multiple gift card services simultaneously.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/gift-card-services/{gift_card_service_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "541b126f-44c5-4c5e-a06b-d0e0d54c7d3f"
          },
          "name": "gift_card_service_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the gift card service."
        }
      ],
      "get": {
        "operationId": "get-gift-card-service",
        "summary": "Get gift card service",
        "description": "Retrieves the details of a single configured gift card service.",
        "tags": [
          "Gift Card Services"
        ],
        "responses": {
          "200": {
            "description": "Returns a gift card service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCardService"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-gift-card-service",
        "summary": "Update gift card service",
        "description": "Updates an existing gift card service. Allows all fields to be changed except for the service ID.",
        "tags": [
          "Gift Card Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GiftCardServiceUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the updated gift card service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCardService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if there is an attempt to activate multiple gift card services simultaneously.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-gift-card-service",
        "summary": "Delete gift card service",
        "description": "Deletes a specific gift card service.",
        "tags": [
          "Gift Card Services"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/gift-card-services/verify": {
      "post": {
        "operationId": "verify-gift-card-service",
        "summary": "Verify gift card service credentials",
        "description": "Verifies a set of credentials against a gift card service.",
        "tags": [
          "Gift Card Services"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GiftCardServiceVerifyRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns 200 OK if credentials successfully verified."
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required fields, or if the provided credentials are invalid and failed verification against the gift card service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/gift-card-service-definitions/{gift_card_service_definition_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "qwikcilver-gift-card"
          },
          "name": "gift_card_service_definition_id",
          "in": "path",
          "required": true,
          "description": "The unique ID of the gift card service definition."
        }
      ],
      "get": {
        "operationId": "get-gift-card-service-definition",
        "summary": "Get gift card service definition",
        "description": "Gets the definition for a gift card service.",
        "tags": [
          "Gift Card Service Definitions"
        ],
        "responses": {
          "200": {
            "description": "Returns a gift card service definition.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GiftCardServiceDefinition"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/anti-fraud-services": {
      "post": {
        "operationId": "new-anti-fraud-service",
        "summary": "New anti-fraud service",
        "description": "Adds an anti-fraud service, enabling merchants to determine risky transactions\nand prevent chargebacks.\n",
        "tags": [
          "Anti-Fraud Services"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AntiFraudServiceCreate"
              },
              "examples": {
                "Create an anti-fraud service": {
                  "value": {
                    "anti_fraud_service_definition_id": "sift-anti-fraud",
                    "display_name": "Sift Anti-Fraud Service.",
                    "active": true,
                    "fields": [
                      {
                        "key": "api_key",
                        "value": "sk_test_26PHem9AhJZvU623DfE1x4sd"
                      },
                      {
                        "key": "account_id",
                        "value": "26PHem9AhJZvU623DfE1x4sd"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the anti-fraud service that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AntiFraudService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/anti-fraud-services/{anti_fraud_service_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "anti_fraud_service_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for an anti-fraud service."
        }
      ],
      "get": {
        "operationId": "get-anti-fraud-service",
        "summary": "Get anti-fraud service",
        "description": "Gets information about an anti-fraud service.",
        "tags": [
          "Anti-Fraud Services"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the information about a anti-fraud service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AntiFraudService"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-anti-fraud-service",
        "summary": "Update anti-fraud service",
        "description": "Update an anti-fraud service, enabling merchants to determine\nrisky transactions and prevent chargebacks.\n",
        "tags": [
          "Anti-Fraud Services"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AntiFraudServiceUpdate"
              },
              "examples": {
                "Update an anti-fraud service": {
                  "value": {
                    "anti_fraud_service_definition_id": "sift-anti-fraud",
                    "display_name": "Sift Anti-Fraud Service.",
                    "active": true,
                    "fields": [
                      {
                        "key": "api_key",
                        "value": "sk_test_26PHem9AhJZvU623DfE1x4sd"
                      },
                      {
                        "key": "account_id",
                        "value": "26PHem9AhJZvU623DfE1x4sd"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the anti-fraud service that was updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AntiFraudService"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if there is an attempt to activate multiple anti-fraud services simultaneously.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-anti-fraud-service",
        "summary": "Delete anti-fraud service",
        "description": "Removes an anti-fraud service. Any associated credentials\nwill also be deleted.",
        "tags": [
          "Anti-Fraud Services"
        ],
        "x-internal": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/anti-fraud-service-definitions/{anti_fraud_service_definition_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "sif-ati-fraud"
          },
          "name": "anti_fraud_service_definition_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for an anti-fraud service definition."
        }
      ],
      "get": {
        "operationId": "get-anti-fraud-service-definition",
        "summary": "Get anti fraud service definition",
        "description": "Gets the definition for an anti fraud service.",
        "tags": [
          "Anti Fraud Service Definitions"
        ],
        "responses": {
          "200": {
            "description": "Returns an anti fraud service definition.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AntiFraudServiceDefinition"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/report-executions": {
      "get": {
        "operationId": "list-all-report-executions",
        "summary": "List all report executions",
        "description": "Returns a list of executions belonging to any report.",
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "string",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "created_at_gte",
            "description": "Filters the results to report executions created after this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "string",
              "format": "string",
              "example": "2022-01-01T12:00:00+08:00"
            },
            "in": "query",
            "name": "created_at_lte",
            "description": "Filters the results to report executions created before this ISO\ndate-time string. The time zone must be included.\n\nEnsure that the date-time string is URL encoded, e.g.\n`2022-01-01T12:00:00+08:00` must be encoded as\n`2022-01-01T12%3A00%3A00%2B08%3A00`."
          },
          {
            "schema": {
              "type": "string",
              "example": "Failed+Authorizations+042022"
            },
            "in": "query",
            "name": "report_name",
            "description": "Filters for executions of reports that have a matching\n`name` value. This filter is case-insensitive.\n\nEnsure that when necessary, the value you pass for this\nfilter is URL encoded."
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "example": "succeeded",
                "enum": [
                  "dispatched",
                  "failed",
                  "pending",
                  "processing",
                  "succeeded"
                ]
              },
              "example": [
                "succeeded",
                "failed"
              ]
            },
            "description": "Filters for report executions that have a matching `status` value.\n\nThis filter accepts multiple values."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "uuid"
              },
              "example": [
                "dba3bc4c-c5f2-477f-bfb0-abd61f89f979"
              ]
            },
            "in": "query",
            "name": "creator_id",
            "description": "Filters the results to only match the reports that their `creator_id`\nmatches with any of the provided creator IDs."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of report executions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportExecutions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/report-executions/{report_execution_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "report_execution_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a report execution."
        }
      ],
      "get": {
        "operationId": "get-report-execution",
        "summary": "Get report execution",
        "description": "Retrieves the details of a single report execution.",
        "tags": [
          "Reports"
        ],
        "responses": {
          "200": {
            "description": "Returns a report execution.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportExecution"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/reports": {
      "post": {
        "operationId": "new-report",
        "summary": "New report",
        "description": "Creates a new report.\n",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the report that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Report"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "list-reports",
        "summary": "List reports",
        "description": "Returns a list of reports.",
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "example": "Failed+Authorizations+042022"
            },
            "in": "query",
            "name": "name",
            "description": "Filters for reports that have a matching `name` value.\nThis filter is case-insensitive.\n\nEnsure that when necessary, the value you pass for this\nfilter is URL encoded."
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "daily",
                  "monthly",
                  "once",
                  "weekly"
                ]
              },
              "example": [
                "once",
                "monthly"
              ]
            },
            "in": "query",
            "name": "schedule",
            "description": "Filters for reports that have matching `schedule` values."
          },
          {
            "schema": {
              "type": "boolean",
              "example": true
            },
            "in": "query",
            "name": "schedule_enabled",
            "description": "Filters for reports that have a matching `schedule_enabled` value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of reports.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Reports"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/reports/{report_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "report_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a report."
        }
      ],
      "get": {
        "operationId": "get-report",
        "summary": "Get report",
        "description": "Retrieves the details of a single report.",
        "tags": [
          "Reports"
        ],
        "responses": {
          "200": {
            "description": "Returns a report.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Report"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-report",
        "summary": "Update report",
        "description": "Updates a report. This is mostly used with scheduled reports.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated report.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Report"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/reports/{report_id}/executions": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "report_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a report."
        }
      ],
      "get": {
        "operationId": "list-report-executions",
        "summary": "List executions for report",
        "description": "Returns a list of executions for a report. For a\none-off report there will only be one, where for scheduled ones\nthere may be more.",
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of executions for a report.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportExecutions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/reports/{report_id}/executions/{report_execution_id}/url": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "report_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a report."
        },
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "name": "report_execution_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a report execution."
        }
      ],
      "post": {
        "operationId": "generate-download-url",
        "summary": "Generate report download URL",
        "description": "Generates a temporary signed URL to download the result of a report\nexecution.",
        "tags": [
          "Reports"
        ],
        "responses": {
          "200": {
            "description": "Returns the signed download URL of a report execution result and its\nexpiration date and time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportExecutionUrl"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/roles": {
      "get": {
        "operationId": "list-roles",
        "summary": "List roles",
        "description": "Returns a list of roles.",
        "tags": [
          "Roles"
        ],
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of roles.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Roles"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/roles/assignments": {
      "get": {
        "operationId": "list-role-assignments",
        "summary": "List role assignments",
        "description": "Returns a list of role assignments.\n\nRole assignments can be filtered for a given role by providing\nthe `role_id` search parameter, or for a given assignee by providing\nboth the `assignee_type` and `assignee_id` parameters.",
        "tags": [
          "Roles"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "be828248-56de-481e-a580-44b6e1d4df81",
              "format": "uuid"
            },
            "in": "query",
            "name": "role_id",
            "description": "Filters for role assignments for the role that has a matching `id` value."
          },
          {
            "schema": {
              "type": "string",
              "example": "user",
              "enum": [
                "user"
              ]
            },
            "in": "query",
            "name": "assignee_type",
            "description": "Filters for role assignments for the assignee of the given type."
          },
          {
            "schema": {
              "type": "string",
              "example": "be828248-56de-481e-a580-44b6e1d4df81",
              "format": "uuid"
            },
            "in": "query",
            "name": "assignee_id",
            "description": "Filters for role assignments for the assignee that has a matching `id` value.\nThe `assignee_type` must also be specified."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of role assignments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RoleAssignments"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-role-assignment",
        "summary": "New role assignment",
        "description": "Adds a role assignment, in effect applying a role to the given assignee.\n",
        "tags": [
          "Roles"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RoleAssignmentRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the role assignment that was added.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RoleAssignment"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/roles/assignments/{role_assignment_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "format": "uuid",
            "example": "1cdac457-400f-4866-8da6-5c193a8db158"
          },
          "name": "role_assignment_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for the role assignment."
        }
      ],
      "delete": {
        "operationId": "delete-role-assignment",
        "summary": "Delete role assignment",
        "description": "Deletes a role assignment. The associated assignee will no longer be\nassigned the role.",
        "tags": [
          "Roles"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/merchant-accounts": {
      "get": {
        "operationId": "list-merchant-accounts",
        "summary": "List merchant accounts",
        "description": "Lists all merchant accounts in an instance.",
        "tags": [
          "Merchant Accounts"
        ],
        "responses": {
          "200": {
            "description": "Returns a paginated list of merchant accounts.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MerchantAccounts"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-merchant-account",
        "summary": "New merchant account",
        "description": "Create a merchant account. Optionally, provide an `outbound_webhook_url`, and\nif HTTP Basic Authentication is required, provide the\n`outbound_webhook_username` and `outbound_webhook_password`. When retrieving\na Merchant Account the `outbound_webhook_password` will be omitted.\n\nOptionally provide Network Tokens configuration per scheme. If done, all\nparameters for the same scheme must be provided.",
        "tags": [
          "Merchant Accounts"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MerchantAccountCreate"
              },
              "examples": {
                "Create a merchant account": {
                  "value": {
                    "id": "plantly-uk",
                    "display_name": "Plantly UK",
                    "outbound_webhook_url": "https://www.example.com/webhook",
                    "outbound_webhook_username": "gr4vy",
                    "outbound_webhook_password": "super-secret-password",
                    "visa_network_tokens_requestor_id": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
                    "visa_network_tokens_app_id": "ca12b3d0-4e23-41a9-906f-e5cbb8e6a731"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created merchant account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MerchantAccount"
                },
                "examples": {
                  "Merchant Account": {
                    "value": {
                      "type": "merchant-account",
                      "id": "plantly-uk",
                      "display_name": "Plantly UK",
                      "outbound_webhook_url": "https://www.example.com/webhook",
                      "outbound_webhook_username": "gr4vy",
                      "visa_network_tokens_requestor_id": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
                      "visa_network_tokens_app_id": "ca12b3d0-4e23-41a9-906f-e5cbb8e6a731",
                      "created_at": "2022-02-01T14:20:00.000+00:00",
                      "updated_at": "2022-02-01T14:20:00.000+00:00"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required fields or configuration doesn't meet uniqueness conditions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if duplicate resource has been found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/merchant-accounts/{merchant_account_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "plantly-uk"
          },
          "name": "merchant_account_id",
          "in": "path",
          "required": true,
          "description": "The unique ID for a merchant account."
        }
      ],
      "get": {
        "operationId": "get-merchant-account",
        "summary": "Get merchant account",
        "description": "Retrieves details of a merchant account.",
        "tags": [
          "Merchant Accounts"
        ],
        "responses": {
          "200": {
            "description": "Returns a merchant account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MerchantAccount"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-merchant-account",
        "summary": "Update merchant account",
        "description": "Update an existing merchant account. Optionally, provide an\n`outbound_webhook_url`, and if HTTP Basic Authentication is required, provide\nthe `outbound_webhook_username` and `outbound_webhook_password`. When\nretrieving a Merchant Account the `outbound_webhook_password` will be omitted.\n\nOptionally provide Network Tokens configuration per scheme. If done, all\nparameters for the same scheme must be provided.",
        "tags": [
          "Merchant Accounts"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MerchantAccountUpdate"
              },
              "examples": {
                "Update a merchant account": {
                  "value": {
                    "display_name": "Plantly UK",
                    "outbound_webhook_url": "https://www.example.com/webhook",
                    "outbound_webhook_username": "gr4vy",
                    "outbound_webhook_password": "super-secret-password",
                    "visa_network_tokens_requestor_id": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
                    "visa_network_tokens_app_id": "ca12b3d0-4e23-41a9-906f-e5cbb8e6a731"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated merchant account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MerchantAccount"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required fields or configuration doesn't meet uniqueness conditions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-merchant-accuont",
        "summary": "Delete merchant account",
        "description": "Deletes a specific merchant account.",
        "tags": [
          "Merchant Accounts"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/payment-service-tokens": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        }
      ],
      "get": {
        "operationId": "get-payment-service-tokens",
        "summary": "Get payment service tokens",
        "description": "Get all payment service tokens for a given payment method and payment service.",
        "tags": [
          "Tokens"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
              "format": "uuid"
            },
            "in": "query",
            "name": "payment_method_id",
            "description": "Filters for transactions that have a payment method with an ID that matches exactly with the provided value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list payment service tokens of the specified\npayment method and payment service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceTokens"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "provision-payment-service-token",
        "summary": "Provision payment service token",
        "description": "Tokenize stored card against a payment service.\n",
        "tags": [
          "Tokens"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentServiceTokenRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created payment service token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentServiceToken"
                }
              }
            }
          },
          "400": {
            "description": "Returns if any of the validations below fails:\n- payment method is not card.\n- payment service doesn't support `payment_method_tokenization`.\n- active token already exists for the `payment_service_id`.\n- invalid request payload.\n- `payment_service_id` is not a `uuid` or is not set.\n- `redirect_url` is not set.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/payment-service-tokens/{payment_service_token_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "7e7ede54-616a-422e-8f58-89a79ae2baea",
            "format": "uuid"
          },
          "name": "payment_service_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment service token."
        }
      ],
      "delete": {
        "operationId": "delete-payment-service-token",
        "summary": "Delete payment service token",
        "description": "Deletes a specific payment service token.",
        "tags": [
          "Tokens"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/payment-service-tokens/{payment_service_token_id}/approve": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "7e7ede54-616a-422e-8f58-89a79ae2baea",
            "format": "uuid"
          },
          "name": "payment_service_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment service token."
        }
      ],
      "get": {
        "operationId": "approve-payment-service-token-get",
        "summary": "Approve payment service token",
        "description": "Approves a specific payment service token.",
        "tags": [
          "Tokens"
        ],
        "x-internal": true,
        "responses": {
          "307": {
            "description": "Redirects to `redirect_url` stored in the token."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "approve-payment-service-token-post",
        "summary": "Approve payment service token",
        "description": "Approves a specific payment service token.",
        "tags": [
          "Tokens"
        ],
        "x-internal": true,
        "responses": {
          "307": {
            "description": "Redirects to `redirect_url` stored in the token."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/network-tokens": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        }
      ],
      "get": {
        "operationId": "get-network-tokens",
        "summary": "Get network tokens",
        "description": "Get stored network tokens for the given payment method.",
        "tags": [
          "Tokens"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
              "format": "uuid"
            },
            "in": "query",
            "name": "payment_method_id",
            "description": "Filters for transactions that have a payment method with an ID that matches exactly with the provided value."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of network tokens (empty list if there aren't any).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkTokens"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "provision-network-token",
        "summary": "Provision network token",
        "description": "Provision a network token for a stored card.\n",
        "tags": [
          "Tokens"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NetworkTokenRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created network token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkToken"
                }
              }
            }
          },
          "400": {
            "description": "Returns if any of the validations below fails:\n- network token already exists for the `payment_method_id`.\n- `merchant_initiated` or `is_subsequent_payment` is not provided.\n- `merchant_initiated` is set to `true` but `is_subsequent_payment` is set to `false`.\n- payment method is not a card.\n- Network token provider responds with an error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/network-tokens/{network_token_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "454f6a32-a572-4dda-b885-3e8674086123",
            "format": "uuid"
          },
          "name": "network_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the network token."
        }
      ],
      "delete": {
        "operationId": "delete-network-token",
        "summary": "Delete network token",
        "description": "Deletes a specific network token.",
        "tags": [
          "Tokens"
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/network-tokens/{network_token_id}/cryptogram": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "454f6a32-a572-4dda-b885-3e8674086123",
            "format": "uuid"
          },
          "name": "network_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the network token."
        }
      ],
      "post": {
        "operationId": "issue-cryptogram",
        "summary": "Issue cryptogram",
        "description": "Issue a cryptogram for a stored network token of a stored card.",
        "tags": [
          "Tokens"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/IssueCryptogramRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created network token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Cryptogram"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields. It also returns an error if the requested network token has a status other than `active`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "403": {
            "description": "Returns an error if the access to the requested resource is forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error403Forbidden"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/network-tokens/{network_token_id}/suspend": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "454f6a32-a572-4dda-b885-3e8674086123",
            "format": "uuid"
          },
          "name": "network_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the network token."
        }
      ],
      "post": {
        "operationId": "suspend-network-token",
        "summary": "Suspend network token",
        "description": "Suspends a specific network token.",
        "tags": [
          "Tokens"
        ],
        "responses": {
          "200": {
            "description": "Returns suspended network token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkToken"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if:\n- network token's status is not `active`.\n- network tokens feature is not enabled.\n- if payment method's scheme is not `Visa`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-methods/{payment_method_id}/network-tokens/{network_token_id}/resume": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "payment_method_id",
          "in": "path",
          "required": true,
          "description": "The ID of the payment method."
        },
        {
          "schema": {
            "type": "string",
            "example": "454f6a32-a572-4dda-b885-3e8674086123",
            "format": "uuid"
          },
          "name": "network_token_id",
          "in": "path",
          "required": true,
          "description": "The ID of the network token."
        }
      ],
      "post": {
        "operationId": "resume-network-token",
        "summary": "Resume network token",
        "description": "Resumes a specific network token.",
        "tags": [
          "Tokens"
        ],
        "responses": {
          "200": {
            "description": "Returns resumed network token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkToken"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if:\n- network token's status is not `suspended`.\n- network tokens feature is not enabled.\n- if payment method's scheme is not `Visa`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward/definitions": {
      "get": {
        "operationId": "list-vault-forward-definitions",
        "summary": "List Vault Forward definitions",
        "description": "Returns a list of definitions of the available endpoints that PCI data\ncan be forwarded to.",
        "tags": [
          "Vault Forward Definitions"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns a list of Vault Forward definitions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardDefinitions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward/configs": {
      "get": {
        "operationId": "list-vault-forward-config",
        "summary": "List configured Vault Forward endpoints",
        "description": "Lists the currently configured Vault Forward endpoints that can be used to forward\nPCI data to.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of Vault Forward configurations.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfigs"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "summary": "Enable new Vault Forward endpoint",
        "operationId": "new-vault-forward-config",
        "description": "Enables a new Vault Forward endpoint. This allows this endpoint\nto be used to forward PCI data to. Only 1 configuration may\nexist at a time for a given definition.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PCIForwardConfigRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created Vault Forward configuration.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfig"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "409": {
            "description": "Returns an error if there is an attempt to create multiple configurations for the same definition.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error409DuplicateRecord"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward/configs/{config_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "config_id",
          "in": "path",
          "required": true,
          "description": "The ID of the Vault Forward configuration."
        }
      ],
      "get": {
        "operationId": "get-vault-forward-config",
        "summary": "Get configured Vault Forward endpoints",
        "description": "Gets a configured Vault Forward endpoints that can be used to forward\nPCI data to.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the Vault Forward configuration.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfig"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-vault-forward-config",
        "summary": "Remove a configured Vault Forward endpoint",
        "description": "Removes a previously configured Vault Forward endpoint, effectively disallowing\ndata to be sent to this endpoint.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward/configs/{config_id}/authentications": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "config_id",
          "in": "path",
          "required": true,
          "description": "The ID of the Vault Forward configuration."
        }
      ],
      "get": {
        "operationId": "list-vault-forward-config-authentication",
        "summary": "List configured Vault Forward authentication methods",
        "description": "Lists the configured Vault Forward authentication methods that can\nbe applied in Vault Forward requests for the given configuration.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns a list of Vault Forward authentication methods.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfigAuthentications"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "add-vault-forward-config-authentication",
        "summary": "Adds new Vault Forward authentication method",
        "description": "Configures a new Vault Forward authentication method. This allows the\nauthentication method to be be applied in Vault Forward requests.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PCIForwardConfigAuthenticationRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created Vault Forward authentication method.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfigAuthentication"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward/configs/{config_id}/authentications/{authentication_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "config_id",
          "in": "path",
          "required": true,
          "description": "The ID of the Vault Forward configuration."
        },
        {
          "schema": {
            "type": "string",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "format": "uuid"
          },
          "name": "authentication_id",
          "in": "path",
          "required": true,
          "description": "The ID of the Vault Forward authentication method."
        }
      ],
      "get": {
        "operationId": "get-vault-forward-config-authentication",
        "summary": "Get Vault Forward authentication method",
        "description": "Gets a configured Vault Forward authentication method.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the Vault Forward authentication.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfigAuthentication"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-vault-forward-config-authentication",
        "summary": "Update Vault Forward authentication method",
        "description": "Updates an existing Vault Forward authentication method.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PCIForwardConfigAuthenticationUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated Vault Forward authentication method.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PCIForwardConfigAuthentication"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-vault-forward-config-authentication",
        "summary": "Remove a Vault Forward authentication method",
        "description": "Removes a configured Vault Forward authentication method,\ndisallowing it from being applied in Vault Forward requests.",
        "tags": [
          "Vault Forward Configurations"
        ],
        "x-internal": true,
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/vault-forward": {
      "post": {
        "summary": "Forward PCI data",
        "operationId": "make-vault-forward",
        "description": "Forward an API call to a PCI endpoint. The request body is evaluated and any template fields are replaced by the card data before the request is sent to the given destination.",
        "tags": [
          "Vault Forward"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "faaad066-30b4-4997-a438-242b0752d7e1,faaad066-30b4-4997-a438-242b0752d7e2"
            },
            "in": "header",
            "name": "x-vault-forward-payment-methods",
            "required": false,
            "description": "A comma-separated list of Payment Method IDs that can be used to fill in the request template. If a Checkout Session is provided this field is optional and only 1 can be provided. Otherwise, at least 1 must be given, and a maximum of 100 are accepted."
          },
          {
            "schema": {
              "type": "string",
              "example": "faaad066-30b4-4997-a438-242b0752d7e2"
            },
            "in": "header",
            "name": "x-vault-forward-checkout-session",
            "required": false,
            "description": "A Checkout Session ID that can be used to fill in the request template. At most 1 can be provided. Mandatory if no Payment Methods are provided."
          },
          {
            "schema": {
              "type": "string",
              "example": "faaad066-30b4-4997-a438-242b0752d7e1,faaad066-30b4-4997-a438-242b0752d7e2"
            },
            "in": "header",
            "name": "x-vault-forward-authentications",
            "required": false,
            "description": "A comma-separated list of IDs for the authentication methods that will be applied\nto a Vault Forward request."
          },
          {
            "schema": {
              "type": "string",
              "example": "https://api.amadeus.com/booking"
            },
            "in": "header",
            "name": "x-vault-forward-url",
            "required": true,
            "description": "The URL to forward card data to."
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "POST",
                "PUT",
                "PATCH"
              ],
              "example": "POST"
            },
            "in": "header",
            "name": "x-vault-forward-http-method",
            "required": true,
            "description": "The HTTP method that is used when forwarding the request to the `x-vault-forward-url`."
          },
          {
            "schema": {
              "type": "string",
              "example": "x-vault-forward-header-x-frame-options"
            },
            "in": "header",
            "name": "x-vault-forward-header-{HEADER_NAME}",
            "description": "A header that is forwarded to the `x-vault-forward-url`. The header will be\nforwarded without the `x-vault-forward-header` part. For example,\n`x-vault-forward-header-x-frame-options: SAMEORIGIN` is forwarded as\n`x-frame-options: SAMEORIGIN`."
          },
          {
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 30,
              "example": 10
            },
            "in": "header",
            "name": "x-vault-forward-timeout",
            "description": "The number of seconds to wait before timing out when forwarding the\nrequest."
          }
        ],
        "requestBody": {
          "description": "Payload to forward in the request.",
          "content": {
            "*/*": {
              "schema": {
                "type": "string"
              },
              "examples": {
                "Make a JSON request": {
                  "value": "{\n  \"number\":\"{{CARD_NUMBER_1}}\",\n  \"expiry\":\"{{CARD_EXPIRATION_DATE_1}}\"\n}\n"
                },
                "Make an XML request": {
                  "value": "<card>\n  <number>{{CARD_NUMBER_1}}</number>\n  <expiry>{{CARD_EXPIRATION_DATE_1}}</expiry>\n</card>\n"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the payload received from the forwarded request. If the request timed\nout or there was a network error, the payload will be empty instead.",
            "content": {
              "*/*": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/health-dashboard/connections": {
      "get": {
        "operationId": "get-health-dashboard-connections",
        "summary": "Get Health Dashboard connections",
        "description": "Retrieves the Health Dashboard connections (payment services) table data.",
        "tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          },
          {
            "schema": {
              "type": "boolean",
              "example": true,
              "default": false
            },
            "in": "query",
            "name": "exclude_idle",
            "description": "Filters the results to exclude idle connections.\nA connection is considered idle if it has not\nprocessed any transaction in the specified period.\nBy default, all results are returned."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the Health Dashboard connections table data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthDashboardConnections"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/health-dashboard/connections-volume": {
      "get": {
        "operationId": "get-health-dashboard-connections-volume",
        "summary": "Get Health Dashboard connections volume",
        "description": "Retrieves the Health Dashboard connections (payment services) volume table data.",
        "tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "example": "USD"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to the set of data aggregated by the currency.\nA currency is formatted as 3-letter ISO currency code.",
            "required": true
          },
          {
            "schema": {
              "type": "boolean",
              "example": true,
              "default": false
            },
            "in": "query",
            "name": "exclude_idle",
            "description": "Filters the results to exclude idle connections.\nA connection is considered idle if it has not\nprocessed any transaction in the specified period.\nBy default, all results are returned."
          },
          {
            "schema": {
              "type": "integer",
              "default": 20,
              "example": 1,
              "minimum": 1,
              "maximum": 100,
              "format": "int32"
            },
            "in": "query",
            "name": "limit",
            "description": "Defines the maximum number of items to return for this request."
          },
          {
            "schema": {
              "type": "string",
              "format": "",
              "example": "ZXhhbXBsZTE"
            },
            "in": "query",
            "name": "cursor",
            "description": "A cursor that identifies the page of results to return. This is used to\npaginate the results of this API.\n\nFor the first page of results, this parameter can be left out.\nFor additional pages, use the value returned by the API in\nthe `next_cursor` field. Similarly the `previous_cursor` can be used to\nreverse backwards in the list."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the Health Dashboard connections volume table data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthDashboardConnections"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/health-dashboard/status": {
      "get": {
        "operationId": "get-health-dashboard-status",
        "summary": "Get Health Dashboard status",
        "description": "Retrieves the Health Dashboard status summary.",
        "tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "responses": {
          "200": {
            "description": "Returns the Health Dashboard status summary.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthDashboardStatus"
                }
              }
            }
          }
        }
      }
    },
    "/health-dashboard/total": {
      "get": {
        "operationId": "get-health-dashboard-total",
        "summary": "Get Health Dashboard total",
        "description": "Retrieves the Health Dashboard line chart data.",
        "tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the Health Dashboard line chart data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthDashboardTotal"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/health-dashboard/total-volume": {
      "get": {
        "operationId": "get-health-dashboard-total-volume",
        "summary": "Get Health Dashboard total volume",
        "description": "Retrieves the Health Dashboard volume line chart data.",
        "tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "example": "USD"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to the set of data aggregated by the currency.\nA currency is formatted as 3-letter ISO currency code.",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the Health Dashboard volume line chart data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthDashboardTotalVolume"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payouts": {
      "get": {
        "operationId": "list-payouts",
        "summary": "List payouts",
        "description": "Lists all payouts for an account. Sorted by last updated at.",
        "tags": [
          "Payouts"
        ],
        "responses": {
          "200": {
            "description": "Returns a paginated list of payouts for an account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Payouts"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        },
        "x-speakeasy-pagination": {
          "type": "cursor",
          "inputs": [
            {
              "name": "cursor",
              "in": "parameters",
              "type": "cursor"
            }
          ],
          "outputs": {
            "nextCursor": "$.next_cursor"
          }
        }
      },
      "post": {
        "operationId": "new-payout",
        "summary": "Create payout",
        "description": "Creates a new payout.",
        "tags": [
          "Payouts"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PayoutRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created payout.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Payout"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payouts/{payout_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "payout_id",
          "in": "path",
          "required": true,
          "description": "The ID for the payout to get the information for."
        }
      ],
      "get": {
        "operationId": "get-single-payout",
        "summary": "Get payout",
        "description": "Gets information about a payout.",
        "tags": [
          "Payouts"
        ],
        "responses": {
          "200": {
            "description": "Returns a payout.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Payout"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-links": {
      "get": {
        "operationId": "list-payment-links",
        "summary": "List payment links",
        "description": "Lists all payment links for an account. Sorted by last updated at.",
        "tags": [
          "Payment Links"
        ],
        "responses": {
          "200": {
            "description": "Returns a paginated list of payment links for an account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentLinks"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-payment-link",
        "summary": "Create payment link",
        "description": "Creates a new payment link.",
        "tags": [
          "Payment Links"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PaymentLinkRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returns the created payment link.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentLink"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required\nfields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/payment-links/{payment_link_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "1b2e1e3d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "payment_link_id",
          "in": "path",
          "required": true,
          "description": "The ID for the payment link to get the information for."
        }
      ],
      "get": {
        "operationId": "get-payment-link",
        "summary": "Get payment link",
        "description": "Gets information about a payment link.",
        "tags": [
          "Payment Links"
        ],
        "responses": {
          "200": {
            "description": "Returns a payment link.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentLink"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/payment-links/{payment_link_id}/expire": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "1b2e1e3d-ec3e-4884-9553-f7356683f7f9"
          },
          "name": "payment_link_id",
          "in": "path",
          "required": true,
          "description": "The ID for the payment link to get the information for."
        }
      ],
      "post": {
        "operationId": "expire-payment-link",
        "summary": "Expire payment link",
        "description": "Expires a payment link.",
        "tags": [
          "Payment Links"
        ],
        "parameters": [
          {
            "name": "payment_link_id",
            "in": "path",
            "required": true,
            "description": "The ID of the payment link to expire.",
            "schema": {
              "type": "string",
              "format": "uuid",
              "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response if the payment link was successfully expired."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/webhook-subscriptions": {
      "get": {
        "operationId": "list-webhook-subscriptions",
        "summary": "List webhook subscriptions",
        "description": "Returns a list of endpoints that we will send webhooks to.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of webhook subscriptions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookSubscriptions"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "new-webhook-subscription",
        "summary": "New webhook subscription",
        "description": "Adds a new endpoint to send webhooks to.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookSubscriptionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the new webhook subscription.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookSubscription"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/webhook-subscriptions/{webhook_subscription_id}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "8fd77b13-a5e3-43de-bd54-26a8a714ac18"
          },
          "name": "webhook_subscription_id",
          "in": "path",
          "required": true,
          "description": "The ID for the webhook subscription."
        }
      ],
      "get": {
        "operationId": "get-webhook-subscription",
        "summary": "Get webhook subscription",
        "description": "Returns a single endpoint that we will send webhooks to.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a webhook subscription.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookSubscription"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "put": {
        "operationId": "update-webhook-subscription",
        "summary": "Update webhook subscription",
        "description": "Updates a webhook subscription.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookSubscriptionUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated webhook subscription.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookSubscription"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      },
      "delete": {
        "operationId": "delete-webhook-subscription",
        "summary": "Delete a webhook subscription",
        "description": "Deletes a webhook subscription, removing any delivery of webhooks\nto the associated endpoint.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "responses": {
          "204": {
            "description": "Returns an empty response."
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/webhook-subscriptions/{webhook_subscription_id}/rotate-secret": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "example": "8fd77b13-a5e3-43de-bd54-26a8a714ac18"
          },
          "name": "webhook_subscription_id",
          "in": "path",
          "required": true,
          "description": "The ID for the webhook subscription."
        }
      ],
      "post": {
        "operationId": "rotate-webhook-subscription-secret",
        "summary": "Rotate the webhook subscription secret.",
        "description": "Rotate the webhook subscription secret.",
        "tags": [
          "Webhook subscriptions"
        ],
        "parameters": [
          {
            "schema": {
              "type": "string",
              "maxLength": 255,
              "example": "default"
            },
            "in": "header",
            "name": "X-Gr4vy-Merchant-Account-ID",
            "description": "The ID of the merchant account to act upon. When not  or provided, this value\nwill default to the first merchant account a user has access to. This value\ncan be set to `*` on some APIs to fetch resources from all merchant accounts."
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookSubscriptionRotateSecretRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returns the updated webhook subscription with the new secret.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookSubscription"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted, missing required fields or the webhook subscription already has a secret being rotated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Returns an error if the resource can not be found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error404NotFound"
                }
              }
            }
          }
        }
      }
    },
    "/metrics-explorer/{source}/metrics/{metric}/modules/{module}": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "enum": [
              "authentication",
              "authorization"
            ],
            "example": "authorization"
          },
          "in": "path",
          "name": "source",
          "description": "The set of transactions used as a source to calculate metrics.\nThe source names are related to the Insights tab in the dashboard.",
          "required": true
        },
        {
          "schema": {
            "type": "string",
            "enum": [
              "auth_rate",
              "transactions",
              "volume"
            ],
            "example": "transactions"
          },
          "in": "path",
          "name": "metric",
          "description": "The metric to be calculated.",
          "required": true
        },
        {
          "schema": {
            "type": "string",
            "enum": [
              "authentication_outcome",
              "authorized",
              "country",
              "currency",
              "error_code",
              "instrument_type",
              "is_subsequent_payment",
              "liability_shifted",
              "merchant_initiated",
              "metadata",
              "method",
              "payment_method_bin",
              "payment_method_card_issuer_name",
              "payment_method_card_type",
              "payment_method_country",
              "payment_method_scheme",
              "payment_service",
              "payment_source",
              "raw_response_code",
              "rule_route_transaction",
              "rule_skip_3ds",
              "three_d_secure_auth_resp",
              "three_d_secure_eci",
              "three_d_secure_method"
            ],
            "example": "payment_service"
          },
          "in": "path",
          "name": "module",
          "description": "The module to be calculated.",
          "required": true
        }
      ],
      "get": {
        "operationId": "get-metrics-explorer-module",
        "summary": "Get Metrics Explorer module data",
        "description": "Retrieves the data for a module in the Metrics Explorer. <br/>**Important:** The currency filter query parameter is **required** when the `metric` is set to `volume`.",
        "tags": [
          "Metrics Explorer"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "succeeded",
                "failed",
                "abandoned"
              ],
              "example": "abandoned"
            },
            "in": "query",
            "name": "authentication_outcome",
            "description": "Filters the results to only include transactions whose authentication process ended with the specified outcome.\nThis parameter also accepts the null character `\\0` to include transactions that didn't undergo an authentication process.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "authorized",
            "description": "Filters the results to only include transactions that were authorized (1) or declined (0).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GB"
            },
            "in": "query",
            "name": "country",
            "description": "Filters the results to only include transactions that were processed in the specified country. The country code should be in the ISO 3166-1 two letter format.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GBP"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to only include transactions that were processed in the specified currency. The currency code should be in the ISO 4217 format. <br/>**Important:** This query parameter is **required** when the `metric` is set to `volume`.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "invalid_credentials"
            },
            "in": "query",
            "name": "error_code",
            "description": "Filters the results to only include transactions that failed with the specified error code. The error code is a string that describes the reason for the failure.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "description": "The name of the instrument used to process the transaction.\n",
              "enum": [
                "applepay",
                "card_token",
                "googlepay",
                "network_token",
                "pan",
                "redirect",
                "redirect_token"
              ],
              "example": "network_token"
            },
            "in": "query",
            "name": "instrument_type",
            "description": "Filters the results to only include transactions that used the specified instrument type.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "is_subsequent_payment",
            "description": "Filters the results to only include transactions that are subsequent payments. A subsequent payment is a payment that is made after an initial payment, typically in a subscription or recurring payment scenario.\nThe value should be either \"0\" (false) or \"1\" (true).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "liability_shifted",
            "description": "Filters the results to only include transactions where liability was shifted (1) or was not shifted (0).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "merchant_initiated",
            "description": "Filters the results to only include transactions that were initiated by the merchant.\nThe value should be either \"0\" (false) or \"1\" (true).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "{\"key\": \"value\"}"
            },
            "in": "query",
            "name": "metadata",
            "description": "Filters the results to only include transactions that have the specified metadata. The metadata should be in JSON format and contain a single key-value pair.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "card",
              "enum": [
                "affirm",
                "afterpay",
                "alipay",
                "alipayhk",
                "applepay",
                "bacs",
                "bancontact",
                "banked",
                "becs",
                "bitpay",
                "boleto",
                "boost",
                "card",
                "cashapp",
                "chaseorbital",
                "checkout-session",
                "clearpay",
                "click-to-pay",
                "dana",
                "dcb",
                "dlocal",
                "ebanx",
                "efecty",
                "eps",
                "everydaypay",
                "gcash",
                "gem",
                "gemds",
                "gift-card",
                "giropay",
                "givingblock",
                "gocardless",
                "googlepay",
                "googlepay_pan_only",
                "gopay",
                "grabpay",
                "id",
                "ideal",
                "kakaopay",
                "kcp",
                "klarna",
                "latitude",
                "latitudeds",
                "laybuy",
                "linepay",
                "linkaja",
                "maybankqrpay",
                "mercadopago",
                "multibanco",
                "multipago",
                "netbanking",
                "network-token",
                "oney_3x",
                "oney_4x",
                "oney_6x",
                "oney_10x",
                "oney_12x",
                "ovo",
                "oxxo",
                "payid",
                "paymaya",
                "paypal",
                "paypalpaylater",
                "payto",
                "venmo",
                "pix",
                "pse",
                "rabbitlinepay",
                "razorpay",
                "scalapay",
                "sepa",
                "shopeepay",
                "singteldash",
                "smartpay",
                "sofort",
                "spei",
                "stripedd",
                "thaiqr",
                "touchngo",
                "truemoney",
                "trustly",
                "trustlyeurope",
                "upi",
                "vipps",
                "waave",
                "webpay",
                "wechat",
                "zippay"
              ]
            },
            "in": "query",
            "name": "method",
            "description": "Filters the results to only include transactions that were processed using the specified payment method.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "123456"
            },
            "in": "query",
            "name": "payment_method_bin",
            "description": "Filters the results to only include transactions that used the specified payment method bin.\nThe payment method bin is the first 6 digits of the card number.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "Barclays"
            },
            "in": "query",
            "name": "payment_method_card_issuer_name",
            "description": "Filters the results to only include transactions that were processed with the specified card issuer name.\nThe card issuer name is the name of the bank or financial institution that issued the card used for the transaction.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "credit",
              "enum": [
                "credit",
                "debit",
                "prepaid"
              ]
            },
            "in": "query",
            "name": "payment_method_card_type",
            "description": "Filters the results to only include transactions that used the specified card type.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GB"
            },
            "in": "query",
            "name": "payment_method_country",
            "description": "Filters the results to only include transactions that were processed with a card issued in the specified country.\nThe country code should be in the ISO 3166-1 two letter format.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "in": "query",
            "name": "payment_method_scheme",
            "description": "Filters the results to only include transactions that were processed with the specified payment method scheme.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "06319aec-2c0f-4c7b-8af1-047ca037fc021"
            },
            "in": "query",
            "name": "payment_service_id",
            "description": "Filters the results to only include transactions that were processed with the specified payment service ID.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "recurring",
              "enum": [
                "ecommerce",
                "moto",
                "recurring",
                "installment",
                "card_on_file"
              ]
            },
            "in": "query",
            "name": "payment_source",
            "description": "Filters the results to only include transactions that were processed with the specified payment source.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "COMPLETED"
            },
            "in": "query",
            "name": "raw_response_code",
            "description": "Filters the results to only include transactions that received the specified raw response code from the payment service.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "c2fefd1b-6ed0-4038-bbc8-48ea2fb7e9f7"
            },
            "in": "query",
            "name": "rule_id_route_transaction",
            "description": "Filters the results to only include transactions that were processed with the specified routing rule. The rule ID should be in UUID format.\nThis parameter also accepts the null character `\\0` to include transactions that were not processed by any routing rule.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "c2fefd1b-6ed0-4038-bbc8-48ea2fb7e9f7"
            },
            "in": "query",
            "name": "rule_id_skip_3ds",
            "description": "Filters the results to only include transactions that were processed with the specified 3DS rule. The rule ID should be in UUID format.\nThis parameter also accepts the null character `\\0` to include transactions that were not processed by any 3DS rule.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "Y"
            },
            "in": "query",
            "name": "three_d_secure_auth_resp",
            "description": "Filters the results to only include transactions that received the specified response during 3DS authentication.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "05"
            },
            "in": "query",
            "name": "three_d_secure_eci",
            "description": "Filters the results to only include transactions that received the specified ECI during 3DS authentication.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "challenge",
                "frictionless"
              ],
              "example": "frictionless"
            },
            "in": "query",
            "name": "three_d_secure_method",
            "description": "Filters the results to only include transactions that underwent 3DS authentication with the specified method.\nThis parameter also accepts the null character `\\0` to include transactions that didn't undergo 3DS authentication.",
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the module's data.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MetricsExplorerModule"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "/metrics-explorer/{source}/metrics/{metric}/totals": {
      "parameters": [
        {
          "schema": {
            "type": "string",
            "enum": [
              "authentication",
              "authorization"
            ],
            "example": "authorization"
          },
          "in": "path",
          "name": "source",
          "description": "The set of transactions used as a source to calculate metrics.\nThe source names are related to the Insights tab in the dashboard.",
          "required": true
        },
        {
          "schema": {
            "type": "string",
            "enum": [
              "auth_rate",
              "transactions",
              "volume"
            ],
            "example": "transactions"
          },
          "in": "path",
          "name": "metric",
          "description": "The metric to be calculated.",
          "required": true
        }
      ],
      "get": {
        "operationId": "get-metrics-explorer-totals",
        "summary": "Get Metrics Explorer line chart and summary data",
        "description": "Retrieves the data for the line chart and summary in the Metrics Explorer. <br/>**Important:** The currency filter query parameter is **required** when the `metric` is set to `volume`.",
        "tags": [
          "Metrics Explorer"
        ],
        "x-internal": true,
        "parameters": [
          {
            "schema": {
              "type": "string",
              "enum": [
                "1-day",
                "7-days",
                "30-days"
              ],
              "example": "7-days"
            },
            "in": "query",
            "name": "period",
            "description": "Filters the results to the set of data aggregated over the\nduration of the specified period.",
            "required": true
          },
          {
            "schema": {
              "type": "boolean",
              "default": false,
              "example": false
            },
            "in": "query",
            "name": "exclude_previous",
            "description": "If set to `true`, aggregations and data from the\nprevious period will not be calculated nor returned."
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "succeeded",
                "failed",
                "abandoned"
              ],
              "example": "abandoned"
            },
            "in": "query",
            "name": "authentication_outcome",
            "description": "Filters the results to only include transactions whose authentication process ended with the specified outcome.\nThis parameter also accepts the null character `\\0` to include transactions that didn't undergo an authentication process.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "authorized",
            "description": "Filters the results to only include transactions that were authorized (1) or declined (0).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GB"
            },
            "in": "query",
            "name": "country",
            "description": "Filters the results to only include transactions that were processed in the specified country. The country code should be in the ISO 3166-1 two letter format.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GBP"
            },
            "in": "query",
            "name": "currency",
            "description": "Filters the results to only include transactions that were processed in the specified currency. The currency code should be in the ISO 4217 format. <br/>**Important:** This query parameter is **required** when the `metric` is set to `volume`.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "invalid_credentials"
            },
            "in": "query",
            "name": "error_code",
            "description": "Filters the results to only include transactions that failed with the specified error code. The error code is a string that describes the reason for the failure.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "description": "The name of the instrument used to process the transaction.\n",
              "enum": [
                "applepay",
                "card_token",
                "googlepay",
                "network_token",
                "pan",
                "redirect",
                "redirect_token"
              ],
              "example": "network_token"
            },
            "in": "query",
            "name": "instrument_type",
            "description": "Filters the results to only include transactions that used the specified instrument type.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "is_subsequent_payment",
            "description": "Filters the results to only include transactions that are subsequent payments. A subsequent payment is a payment that is made after an initial payment, typically in a subscription or recurring payment scenario.\nThe value should be either \"0\" (false) or \"1\" (true).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "liability_shifted",
            "description": "Filters the results to only include transactions where liability was shifted (1) or was not shifted (0).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "0",
                "1"
              ],
              "example": "1"
            },
            "in": "query",
            "name": "merchant_initiated",
            "description": "Filters the results to only include transactions that were initiated by the merchant.\nThe value should be either \"0\" (false) or \"1\" (true).",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "{\"key\": \"value\"}"
            },
            "in": "query",
            "name": "metadata",
            "description": "Filters the results to only include transactions that have the specified metadata. The metadata should be in JSON format and contain a single key-value pair.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "card",
              "enum": [
                "affirm",
                "afterpay",
                "alipay",
                "alipayhk",
                "applepay",
                "bacs",
                "bancontact",
                "banked",
                "becs",
                "bitpay",
                "boleto",
                "boost",
                "card",
                "cashapp",
                "chaseorbital",
                "checkout-session",
                "clearpay",
                "click-to-pay",
                "dana",
                "dcb",
                "dlocal",
                "ebanx",
                "efecty",
                "eps",
                "everydaypay",
                "gcash",
                "gem",
                "gemds",
                "gift-card",
                "giropay",
                "givingblock",
                "gocardless",
                "googlepay",
                "googlepay_pan_only",
                "gopay",
                "grabpay",
                "id",
                "ideal",
                "kakaopay",
                "kcp",
                "klarna",
                "latitude",
                "latitudeds",
                "laybuy",
                "linepay",
                "linkaja",
                "maybankqrpay",
                "mercadopago",
                "multibanco",
                "multipago",
                "netbanking",
                "network-token",
                "oney_3x",
                "oney_4x",
                "oney_6x",
                "oney_10x",
                "oney_12x",
                "ovo",
                "oxxo",
                "payid",
                "paymaya",
                "paypal",
                "paypalpaylater",
                "payto",
                "venmo",
                "pix",
                "pse",
                "rabbitlinepay",
                "razorpay",
                "scalapay",
                "sepa",
                "shopeepay",
                "singteldash",
                "smartpay",
                "sofort",
                "spei",
                "stripedd",
                "thaiqr",
                "touchngo",
                "truemoney",
                "trustly",
                "trustlyeurope",
                "upi",
                "vipps",
                "waave",
                "webpay",
                "wechat",
                "zippay"
              ]
            },
            "in": "query",
            "name": "method",
            "description": "Filters the results to only include transactions that were processed using the specified payment method.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "123456"
            },
            "in": "query",
            "name": "payment_method_bin",
            "description": "Filters the results to only include transactions that used the specified payment method bin.\nThe payment method bin is the first 6 digits of the card number.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "Barclays"
            },
            "in": "query",
            "name": "payment_method_card_issuer_name",
            "description": "Filters the results to only include transactions that were processed with the specified card issuer name.\nThe card issuer name is the name of the bank or financial institution that issued the card used for the transaction.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "credit",
              "enum": [
                "credit",
                "debit",
                "prepaid"
              ]
            },
            "in": "query",
            "name": "payment_method_card_type",
            "description": "Filters the results to only include transactions that used the specified card type.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "GB"
            },
            "in": "query",
            "name": "payment_method_country",
            "description": "Filters the results to only include transactions that were processed with a card issued in the specified country.\nThe country code should be in the ISO 3166-1 two letter format.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "in": "query",
            "name": "payment_method_scheme",
            "description": "Filters the results to only include transactions that were processed with the specified payment method scheme.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "06319aec-2c0f-4c7b-8af1-047ca037fc021"
            },
            "in": "query",
            "name": "payment_service_id",
            "description": "Filters the results to only include transactions that were processed with the specified payment service ID.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "recurring",
              "enum": [
                "ecommerce",
                "moto",
                "recurring",
                "installment",
                "card_on_file"
              ]
            },
            "in": "query",
            "name": "payment_source",
            "description": "Filters the results to only include transactions that were processed with the specified payment source.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "COMPLETED"
            },
            "in": "query",
            "name": "raw_response_code",
            "description": "Filters the results to only include transactions that received the specified raw response code from the payment service.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "c2fefd1b-6ed0-4038-bbc8-48ea2fb7e9f7"
            },
            "in": "query",
            "name": "rule_id_route_transaction",
            "description": "Filters the results to only include transactions that were processed with the specified routing rule. The rule ID should be in UUID format.\nThis parameter also accepts the null character `\\0` to include transactions that were not processed by any routing rule.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "c2fefd1b-6ed0-4038-bbc8-48ea2fb7e9f7"
            },
            "in": "query",
            "name": "rule_id_skip_3ds",
            "description": "Filters the results to only include transactions that were processed with the specified 3DS rule. The rule ID should be in UUID format.\nThis parameter also accepts the null character `\\0` to include transactions that were not processed by any 3DS rule.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "Y"
            },
            "in": "query",
            "name": "three_d_secure_auth_resp",
            "description": "Filters the results to only include transactions that received the specified response during 3DS authentication.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "example": "05"
            },
            "in": "query",
            "name": "three_d_secure_eci",
            "description": "Filters the results to only include transactions that received the specified ECI during 3DS authentication.\nThis parameter also accepts the null character `\\0` to include transactions that have a null for this field.",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "enum": [
                "challenge",
                "frictionless"
              ],
              "example": "frictionless"
            },
            "in": "query",
            "name": "three_d_secure_method",
            "description": "Filters the results to only include transactions that underwent 3DS authentication with the specified method.\nThis parameter also accepts the null character `\\0` to include transactions that didn't undergo 3DS authentication.",
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the totals data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MetricsExplorerTotals"
                }
              }
            }
          },
          "400": {
            "description": "Returns an error if the request was badly formatted or missing required fields.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error400BadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Returns an error if no valid authentication was provided.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error401Unauthorized"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "AccountUpdaterInquirySummary": {
        "title": "Account Updater Inquiry Summary",
        "type": "object",
        "description": "An Account Updater inquiry summary.",
        "x-tags": [
          "Account Updater"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `account-updater-inquiry`.",
            "example": "account-updater-inquiry",
            "enum": [
              "account-updater-inquiry"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique identifier for this Account Updater inquiry.",
            "format": "uuid",
            "example": "d038f8bf-f1fd-45b3-9948-e1fbb58e8d62"
          },
          "payment_method_id": {
            "type": "string",
            "description": "The ID of the payment method associated with this Account Updater inquiry.",
            "format": "uuid",
            "example": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
          }
        }
      },
      "AccountUpdaterJob": {
        "title": "Account Updater Job",
        "type": "object",
        "description": "An Account Updater job.",
        "x-tags": [
          "Account Updater"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `account-updater-job`.",
            "example": "account-updater-job",
            "enum": [
              "account-updater-job"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique identifier for this Account Updater job.",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this Account Updater job was created.",
            "format": "date-time",
            "example": "2023-07-26T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this Account Updater job was last updated.",
            "format": "date-time",
            "example": "2023-07-26T19:23:00.000+00:00"
          },
          "inquiries": {
            "type": "array",
            "description": "A list of inquiries associated with this Account Updater job.",
            "items": {
              "$ref": "#/components/schemas/AccountUpdaterInquirySummary"
            }
          }
        }
      },
      "AccountUpdaterJobCreate": {
        "title": "Account Updater Job (Create)",
        "type": "object",
        "description": "A request to create an Account Updater job.",
        "x-tags": [
          "Account Updater"
        ],
        "required": [
          "payment_method_ids"
        ],
        "properties": {
          "payment_method_ids": {
            "type": "array",
            "description": "A list of unique payment method identifiers used to create the Account Updater job.\nA payment method will be considered only if it qualifies for an inquiry.",
            "minItems": 1,
            "maxItems": 100,
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "example": [
              "497f6eca-6276-4993-bfeb-53cbbbba6f08"
            ]
          }
        }
      },
      "Action": {
        "title": "Action",
        "type": "object",
        "description": "An action taken for a transaction.",
        "x-tags": [
          "Transactions"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `action`.",
            "example": "action",
            "enum": [
              "action"
            ]
          },
          "id": {
            "type": "string",
            "description": "The identifier for the action.",
            "example": "route-transaction",
            "enum": [
              "decline-early",
              "route-transaction",
              "skip-3ds"
            ]
          },
          "flow": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "rule_id": {
            "type": "string",
            "description": "The unique ID of the rule triggered.",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b85",
            "format": "uuid"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this action was created."
          },
          "outcome": {
            "description": "The outcome of the action.",
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/FlowRuleBooleanOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleMethodOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleServiceOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleUUIDsListOutcome"
              }
            ]
          }
        }
      },
      "Actions": {
        "title": "Actions",
        "description": "A list of actions.",
        "type": "object",
        "x-tags": [
          "Transactions"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of actions.",
            "items": {
              "$ref": "#/components/schemas/Action"
            }
          }
        }
      },
      "AdditionalIdentifiers": {
        "title": "Additional transaction identifiers.",
        "type": "object",
        "description": "A list of additional identifiers that we may keep track of to manage this transaction. This\nmay include the authorization ID, capture ID, and processor ID, as well as an undefined list of\nadditional identifiers.",
        "x-tags": [
          "Transactions"
        ],
        "example": {
          "payment_service_authorization_id": "authorization-1234",
          "payment_service_capture_id": null,
          "payment_service_processor_id": null,
          "another_id": "id-1234"
        },
        "properties": {
          "payment_service_authorization_id": {
            "type": "string",
            "example": "authorization-1234",
            "description": "The optional ID for the authorization of this transaction. Availability of this ID will vary per connector used.",
            "nullable": true
          },
          "payment_service_capture_id": {
            "type": "string",
            "example": "capture-1234",
            "description": "The optional ID for the capture of this transaction. Availability of this ID will vary per connector used.",
            "nullable": true
          },
          "payment_service_processor_id": {
            "type": "string",
            "example": "processor-1234",
            "description": "The optional ID provided by the processor for this transaction. Availability of this ID will vary per connector used.",
            "nullable": true
          }
        },
        "additionalProperties": {
          "type": "string"
        }
      },
      "Address": {
        "title": "Address",
        "type": "object",
        "description": "An address for the buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "city": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "The city for the address.",
            "example": "London",
            "nullable": true
          },
          "country": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "The country for the address in ISO 3166 format.",
            "example": "GB",
            "nullable": true
          },
          "postal_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The postal code or zip code for the address.",
            "example": "789123",
            "nullable": true
          },
          "state": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The state, county, or province for the address.",
            "example": "Greater London",
            "nullable": true
          },
          "state_code": {
            "type": "string",
            "minLength": 4,
            "maxLength": 6,
            "description": "The code of state, county, or province for the address in\nISO 3166-2 format.",
            "example": "GB-LND",
            "nullable": true
          },
          "house_number_or_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The house number or name for the address. Not all payment\nservices use this field but some do.",
            "example": "10",
            "nullable": true
          },
          "line1": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first line of the address.",
            "example": "10 Oxford Street",
            "nullable": true
          },
          "line2": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The second line of the address.",
            "example": "New Oxford Court",
            "nullable": true
          },
          "organization": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The optional name of the company or organisation to add\nto the address.",
            "example": "Gr4vy",
            "nullable": true
          }
        }
      },
      "Airline": {
        "title": "Airline Addendum",
        "type": "object",
        "description": "Information about an airline travel.",
        "properties": {
          "passenger_name_record": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The Passenger Name Record (PNR) in the airline reservation system.",
            "example": "JOHN L",
            "nullable": true
          },
          "booking_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The unique identifier of the reservation in the global distribution system.",
            "example": "X36Q9C",
            "nullable": true
          },
          "ticket_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The airline's unique ticket number.",
            "example": "123-1234-151555",
            "nullable": true
          },
          "ticket_delivery_method": {
            "type": "string",
            "enum": [
              "electronic",
              "other"
            ],
            "default": "electronic",
            "description": "The delivery method of the ticket.",
            "example": "other",
            "nullable": true
          },
          "issued_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date that the ticket was last issued in the airline reservation\nsystem.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "issued_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The address of the place/agency that issued the ticket.",
            "example": "123 Broadway, New York",
            "nullable": true
          },
          "travel_agency_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The IATA travel agency code.",
            "example": "12345",
            "nullable": true
          },
          "travel_agency_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "The name of the travel agency.",
            "example": "Agency name",
            "nullable": true
          },
          "travel_agency_invoice_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The reference number of the invoice that was issued by the\ntravel agency.",
            "example": "EG15555155",
            "nullable": true
          },
          "travel_agency_plan_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "The name of the travel agency plan.",
            "example": "B733",
            "nullable": true
          },
          "restricted_ticket": {
            "type": "boolean",
            "description": "Indicates whether the ticket is restricted (refundable).",
            "example": false,
            "nullable": true
          },
          "issuing_carrier_code": {
            "type": "string",
            "minLength": 2,
            "maxLength": 3,
            "description": "For airline aggregators, two-character IATA code of the airline issuing\nthe ticket.",
            "example": "A3",
            "nullable": true
          },
          "issuing_carrier_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "The name of the airline issuing the ticket.",
            "example": "Aegean Airlines",
            "nullable": true
          },
          "issuing_iata_designator": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "2 character IATA code of the airline issuing the ticket.",
            "example": "A3",
            "nullable": true
          },
          "issuing_icao_code": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "3 character ICAO code of the airline issuing the ticket.",
            "example": "AEE",
            "nullable": true
          },
          "reservation_system": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "The name of the reservation system.",
            "example": "Amadeus",
            "nullable": true
          },
          "is_cardholder_traveling": {
            "type": "boolean",
            "description": "Indicates whether the cardholder is present in the flight.",
            "example": false,
            "nullable": true
          },
          "passengers": {
            "description": "An array of the travelling passengers.",
            "items": {
              "$ref": "#/components/schemas/AirlinePassenger"
            },
            "maxLength": 20,
            "type": "array",
            "nullable": true
          },
          "legs": {
            "description": "An array of separate trip segments. Each leg contains detailed\nitinerary information.",
            "items": {
              "$ref": "#/components/schemas/AirlineLeg"
            },
            "maxLength": 20,
            "type": "array",
            "nullable": true
          }
        }
      },
      "AirlineLeg": {
        "title": "Airline Addendum Leg",
        "type": "object",
        "description": "Each of the separate trip segment, contains detailed itinerary information.",
        "properties": {
          "carrier_code": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "2 character airline code as set by IATA.",
            "example": "LY",
            "nullable": true
          },
          "carrier_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "The name of the airline.",
            "example": "El Al Israel Airlines",
            "nullable": true
          },
          "iata_designator": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "2 character IATA code of the airline.",
            "example": "LY",
            "nullable": true
          },
          "icao_code": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "3 character ICAO code of the airline.",
            "example": "ELY",
            "nullable": true
          },
          "flight_number": {
            "type": "string",
            "minLength": 3,
            "maxLength": 6,
            "description": "Unique identifier of the flight number.",
            "example": "BA98",
            "nullable": true
          },
          "departure_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time of travel in local time at the departure airport.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "departure_country": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "Departure country code in ISO 3166 format.",
            "example": "UK",
            "nullable": true
          },
          "departure_city": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Departure city name.",
            "example": "London",
            "nullable": true
          },
          "departure_airport": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "Departure airport code of leg. 3-letter ISO code according to IATA\nofficial directory.",
            "example": "LHR",
            "nullable": true
          },
          "arrival_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time of travel in local time at the arrival airport.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "arrival_country": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2,
            "description": "Arrival country code in ISO 3166 format.",
            "example": "UK",
            "nullable": true
          },
          "arrival_city": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Arrival city name.",
            "example": "London",
            "nullable": true
          },
          "arrival_airport": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "Arrival airport code of leg. 3-letter ISO code according to IATA\nofficial directory.",
            "example": "LHR",
            "nullable": true
          },
          "fare_basis_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 8,
            "description": "The alphanumeric code for the \"booking class\" of a ticket.",
            "example": "WH7LNR",
            "nullable": true
          },
          "flight_class": {
            "type": "string",
            "minLength": 1,
            "maxLength": 5,
            "description": "Indicates service class (first class, business class, etc.).",
            "example": "E",
            "nullable": true
          },
          "stop_over": {
            "type": "boolean",
            "description": "Indicates whether a stopover is allowed on this ticket.",
            "example": false,
            "nullable": true
          },
          "route_type": {
            "type": "string",
            "description": "The route type of the flight.",
            "enum": [
              "round_trip",
              "one_way"
            ],
            "example": "round_trip",
            "nullable": false
          },
          "coupon_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "Coupon number associated with the leg.",
            "example": "15885566",
            "nullable": true
          },
          "fare_amount": {
            "type": "integer",
            "description": "Amount of the ticket, for current leg of the trip, excluding taxes and fees.",
            "minimum": 0,
            "maximum": 99999999,
            "example": 100,
            "nullable": true
          },
          "fee_amount": {
            "type": "integer",
            "description": "Fee amount for current leg of the trip.",
            "minimum": 0,
            "maximum": 99999999,
            "example": 100,
            "nullable": true
          },
          "tax_amount": {
            "type": "integer",
            "description": "Amount of the taxes for current leg of the trip.",
            "minimum": 0,
            "maximum": 99999999,
            "example": 100,
            "nullable": true
          },
          "departure_tax_amount": {
            "type": "integer",
            "description": "Departure tax amount charged by a country when a person is leaving the\ncountry.",
            "minimum": 0,
            "maximum": 99999999,
            "example": 100,
            "nullable": true
          },
          "seat_class": {
            "type": "string",
            "minLength": 1,
            "maxLength": 5,
            "description": "Indicates seat class (first class, business class, etc.).",
            "example": "F",
            "nullable": true
          }
        }
      },
      "AirlinePassenger": {
        "title": "Airline Addendum Passenger",
        "type": "object",
        "description": "Information of the travelling passenger.",
        "properties": {
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "Title of the passenger.",
            "example": "Mr.",
            "nullable": true
          },
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name of the passenger.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The last name, or family name, of the passenger.",
            "example": "Lunn",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address of the passenger.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number of the passenger. This number is formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "passport_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The passenger's unique passport number.",
            "example": "7700225",
            "nullable": true
          },
          "ticket_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The ticket number for a flight.",
            "example": "LH1236699999",
            "nullable": true
          },
          "frequent_flyer_number": {
            "type": "string",
            "minLength": 5,
            "maxLength": 50,
            "description": "The passenger's frequent flyer number.",
            "example": "15885566",
            "nullable": true
          },
          "date_of_birth": {
            "type": "string",
            "description": "The passenger's date of birth.",
            "format": "date",
            "example": "2013-07-16",
            "nullable": true
          },
          "age_group": {
            "type": "string",
            "enum": [
              "adult",
              "infant"
            ],
            "example": "adult",
            "nullable": true
          }
        }
      },
      "AntiFraudDecisionEvent": {
        "title": "Anti-fraud - Decision",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to an anti-fraud provider.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-decision`.",
            "example": "anti-fraud-decision",
            "enum": [
              "anti-fraud-decision"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "anti_fraud_service_check_id": {
                "type": "string",
                "description": "The external ID of the decision.",
                "example": "decision-1234"
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to fetch a decision."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the anti-fraud provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the anti-fraud provider."
              },
              "decision": {
                "type": "string",
                "description": "The parsed decision response from the anti-fraud provider response.",
                "example": "ACCEPT"
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudDecisionErrorEvent": {
        "title": "Anti-fraud - Error",
        "type": "object",
        "description": "This event logs the reason why we were unable to get an anti-fraud decision.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-decision-error`.",
            "example": "anti-fraud-decision-error",
            "enum": [
              "anti-fraud-decision-error"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "status_code": {
                "type": "number",
                "description": "The HTTP response status code from the anti-fraud provider, if we received any."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not get the anti-fraud decision.",
                "example": "Network Error"
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudDecisionSkippedEvent": {
        "title": "Anti-fraud - Skipped",
        "type": "object",
        "description": "This event logs the reason why we skipped getting an anti-fraud decision.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-decision-skipped`.",
            "example": "anti-fraud-decision-skipped",
            "enum": [
              "anti-fraud-decision-skipped"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not get the anti-fraud decision.",
                "example": "Missing billing address"
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudDecisionUpdateEvent": {
        "title": "Anti-fraud - Decision update sent",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to an anti-fraud provider to update a pending decision. For example, when an anti-fraud review has been rejected.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-decision-update`.",
            "example": "anti-fraud-decision-update",
            "enum": [
              "anti-fraud-decision-update"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "anti_fraud_service_check_id": {
                "type": "string",
                "description": "The external ID of the decision.",
                "example": "decision-1234"
              },
              "decision": {
                "type": "string",
                "description": "The updated decision sent to the anti-fraud provider.",
                "example": "ACCEPT"
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to fetch a decision."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the anti-fraud provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the anti-fraud provider."
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudDecisionUpdateErrorEvent": {
        "title": "Anti-fraud - Decision update failed",
        "type": "object",
        "description": "This event logs the failure reason when attempting to update the decision on the anti-fraud provider.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-decision-update-error`.",
            "example": "anti-fraud-decision-update-error",
            "enum": [
              "anti-fraud-decision-update-error"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "anti_fraud_service_check_id": {
                "type": "string",
                "description": "The external ID of the decision.",
                "example": "decision-1234"
              },
              "decision": {
                "type": "string",
                "description": "The updated decision sent to the anti-fraud provider.",
                "example": "ACCEPT"
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not update the anti-fraud decision.",
                "example": "Network Error"
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudTransactionStatusUpdateEvent": {
        "title": "Anti-fraud - Transaction update sent",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to an anti-fraud provider to update on a transaction status.  For example, when a capture is successful.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-transaction-status-update`.",
            "example": "anti-fraud-transaction-status-update",
            "enum": [
              "anti-fraud-transaction-status-update"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to fetch a decision."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the anti-fraud provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the anti-fraud provider."
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudTransactionStatusUpdateErrorEvent": {
        "title": "Anti-fraud - Transaction update failed",
        "type": "object",
        "description": "This event logs the reason why we were unable to update an anti-fraud transaction.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-transaction-status-update-error`.",
            "example": "anti-fraud-transaction-status-update-error",
            "enum": [
              "anti-fraud-transaction-status-update-error"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not get the anti-fraud decision.",
                "example": "Network Error"
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body sent to fetch a decision."
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body received from the anti-fraud provider."
              },
              "response_status_code": {
                "type": "number",
                "nullable": true,
                "description": "The HTTP response status code from the anti-fraud provider."
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudWebhookEvent": {
        "title": "Anti-fraud - Webhook",
        "type": "object",
        "description": "This event logs the webhook received when an anti-fraud decision is updated.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `anti-fraud-webhook`.",
            "example": "anti-fraud-webhook",
            "enum": [
              "anti-fraud-webhook"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "anti_fraud_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the anti-fraud service used."
              },
              "anti_fraud_service_name": {
                "type": "string",
                "description": "The name of the anti-fraud service used."
              },
              "anti_fraud_service_definition_id": {
                "type": "string",
                "description": "The anti-fraud service definition used."
              },
              "anti_fraud_service_check_id": {
                "type": "string",
                "description": "The external ID of the decision that's being updated.",
                "example": "decision-1234"
              },
              "content": {
                "type": "string",
                "description": "The raw payload sent as a webhook.",
                "example": "{ \"decision\": \"ACCEPT\", \"id\": \"decision-1234\", \"reason\": \"Manually verified\" }"
              },
              "content_type": {
                "type": "string",
                "description": "The content type of the payload sent as a webhook.",
                "example": "application/json"
              },
              "decision": {
                "type": "string",
                "description": "The parsed decision response from the anti-fraud provider webhook.",
                "example": "ACCEPT"
              },
              "comment": {
                "type": "string",
                "description": "Any comment that may have come with the webhook event.",
                "example": "Manually verified"
              },
              "silent": {
                "type": "boolean",
                "example": false,
                "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when\nprocessing a transaction, allowing for warm-up and comparison of new\nservices against the active service."
              }
            }
          }
        }
      },
      "AntiFraudService": {
        "title": "Anti-Fraud Service",
        "type": "object",
        "x-tags": [
          "Anti-Fraud Services"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `anti-fraud-service`.",
            "example": "anti-fraud-service",
            "enum": [
              "anti-fraud-service"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this anti-fraud service.",
            "format": "uuid"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "anti_fraud_service_definition_id": {
            "type": "string",
            "description": "The name of the Anti-Fraud service provider.\nDuring update request, this value is used for validation only but\nthe underlying service can not be changed for an existing service.",
            "example": "sift-anti-fraud",
            "enum": [
              "cybersource-anti-fraud",
              "forter-anti-fraud",
              "sift-anti-fraud"
            ]
          },
          "display_name": {
            "type": "string",
            "description": "A unique name for this anti-fraud service which is used in the Gr4vy admin panel to give a anti-fraud service a human readable name.",
            "example": "Sift Anti-Fraud Service.",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "active": {
            "type": "boolean",
            "example": true,
            "default": true,
            "description": "Defines if this service is currently active or not."
          },
          "silent": {
            "type": "boolean",
            "example": false,
            "default": false,
            "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when processing\na transaction, allowing for warm-up and comparison of new services\nagainst the active service."
          },
          "reviews_enabled": {
            "type": "boolean",
            "example": false,
            "default": false,
            "description": "Defines if this service needs to handle the review status with a proper\nreview workflow. If not, the review status will be treated as any other\none."
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for anti-fraud service decision mapping e.g. for Sift `approve_decision` will be in the response.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this anti-fraud service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "approve_decision",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 1,
                  "maxLength": 10000
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "description": "The date and time\nwhen this anti-fraud service was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time\nwhen this anti-fraud service was last updated in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          }
        }
      },
      "AntiFraudServiceCreate": {
        "title": "Anti-Fraud Service (Create)",
        "type": "object",
        "description": "A request to create an anti-fraud service.",
        "x-tags": [
          "Anti-Fraud Services"
        ],
        "required": [
          "display_name",
          "anti_fraud_service_definition_id",
          "fields"
        ],
        "allOf": [
          {
            "$ref": "#/components/schemas/AntiFraudServiceUpdate"
          }
        ]
      },
      "AntiFraudServiceUpdate": {
        "title": "Anti-Fraud Service (Update)",
        "type": "object",
        "description": "A request to update an anti-fraud service.",
        "x-tags": [
          "Anti-Fraud Services"
        ],
        "required": [
          "anti_fraud_service_definition_id"
        ],
        "properties": {
          "anti_fraud_service_definition_id": {
            "type": "string",
            "description": "The name of the Anti-Fraud service provider.\nDuring update request, this value is used for validation only but\nthe underlying service can not be changed for an existing service.",
            "example": "sift-anti-fraud",
            "enum": [
              "cybersource-anti-fraud",
              "forter-anti-fraud",
              "sift-anti-fraud"
            ]
          },
          "display_name": {
            "type": "string",
            "description": "A unique name for this anti-fraud service which is used in the Gr4vy admin panel to give a anti-fraud Service a human readable name.",
            "example": "Sift Anti-Fraud Service.",
            "minLength": 1,
            "maxLength": 200
          },
          "active": {
            "type": "boolean",
            "example": true,
            "default": true,
            "description": "Defines if this service is currently active or not. There can only\nbe one active service at any time. When updating a service\nto active, the current active service will be deactivated."
          },
          "reviews_enabled": {
            "type": "boolean",
            "example": false,
            "default": false,
            "description": "Defines if this service needs to handle the review status from anti-fraud\nresponses with a proper review workflow. If not, the review status will\nbe treated as any other one."
          },
          "silent": {
            "type": "boolean",
            "example": false,
            "default": false,
            "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when processing\na transaction, allowing for warm-up and comparison of new services\nagainst the active service. A service cannot be silent and active at\nthe same time."
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined\nby the definition for this anti-fraud service e.g. for Sift\n`api_key` must be sent within this field when creating the service.\n\nFor updates, only the fields sent here will be updated,\nexisting ones will not be affected if not present.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this anti-fraud service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "api_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 1,
                  "maxLength": 10000
                }
              }
            }
          }
        }
      },
      "AntiFraudServiceDefinition": {
        "title": "Anti fraud Service Definition",
        "type": "object",
        "description": "An available anti fraud service that can be configured.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the anti fraud service definition.",
            "example": "sift-anti-fraud"
          },
          "type": {
            "type": "string",
            "description": "`anti-fraud-service-definition`.",
            "default": "anti-fraud-service-definition",
            "example": "anti-fraud-service-definition",
            "enum": [
              "anti-fraud-service-definition"
            ]
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this service.",
            "example": "Stripe"
          },
          "fields": {
            "type": "array",
            "description": "A list of fields that need to be submitted when activating the payment. service.",
            "minItems": 1,
            "items": {
              "type": "object",
              "description": "A single field that needs to be submitted for a payment service when it\nis created.",
              "properties": {
                "key": {
                  "type": "string",
                  "example": "private_api_key",
                  "description": "The key of a field that needs to be submitted."
                },
                "display_name": {
                  "type": "string",
                  "example": "Private API key",
                  "description": "The name to display for a field in the dashboard."
                },
                "required": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is required when the service is created."
                },
                "format": {
                  "type": "string",
                  "example": "text",
                  "description": "Defines the type of input that needs to be rendered for this field.",
                  "enum": [
                    "text",
                    "multiline",
                    "number"
                  ]
                },
                "secret": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is secret. When `true` the field is not\nreturned when querying the payment service."
                }
              }
            }
          },
          "icon_url": {
            "type": "string",
            "description": "An icon to display for the payment service.",
            "example": "https://cdn.gr4vy.app/stripe.svg"
          }
        }
      },
      "ApplePayCertificate": {
        "title": "Apple Pay Certificate",
        "type": "object",
        "description": "An Apple Pay certificate record.",
        "x-tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `apple-pay-certificate`.",
            "example": "apple-pay-certificate",
            "enum": [
              "apple-pay-certificate"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this Apple Pay certificate record.",
            "format": "uuid"
          },
          "display_name": {
            "type": "string",
            "example": "iPad App v2",
            "description": "The name for this Apple Pay certificate which is used in the Gr4vy admin\npanel to give the Apple Pay certificate a human readable name."
          },
          "status": {
            "type": "string",
            "description": "The status of this Apple Pay certificate.",
            "example": "active",
            "enum": [
              "active",
              "expired",
              "incomplete"
            ]
          },
          "apple_merchant_id": {
            "type": "string",
            "description": "The unique identifier representing a merchant for Apple Pay. This value is\npopulated after the Apple Pay certificate record has been updated with\nthe payment processing certificate received from Apple.",
            "example": "merchant.com.gr4vy.demo",
            "nullable": true
          },
          "public_key_hash": {
            "type": "string",
            "description": "The hash value of the public key associated with this Apple Pay\ncertificate. This value is populated after the Apple Pay certificate\nrecord has been updated with the payment processing certificate\nreceived from Apple.",
            "example": "WSOIlV70592m1ah1sm0mcmhJPQsAIWGSg7FSe+uzHtc=",
            "nullable": true
          },
          "certificate_signing_request": {
            "type": "string",
            "description": "The Certificate Signing Request to upload to the Apple Developer console\nwhen creating a new payment processing certificate.",
            "example": "-----BEGIN CERTIFICATE REQUEST-----\\nMIHTMHsCAQAwGTEXMBUG\nA1UEAwwOc3BpZGVyLnNhbmRib3gwWTATBgcqhkjOPQIB\\nBggqhkjOPQM\nBBwNCAAQZgRE56Evtf6f9fD4Hn1zOMwyrgXU4CQXuyPXoIjiMwKXE\\nV/\nHx9NX7vZbOSXhyzPaU/b6HdLMfx2+UP/GZ48jYoAAwCgYIKoZIzj0EAwI\nDSAAw\\nRQIgPhcfepIaX9s8E8WI/T+GEUqwuYIoVUQV+F8KlaYGukACIQ\nCLeLocEFWFYPHN\\n+QsLoyXvbbqmEjSPB4vQKmXQZ8I2DA==\\n-----EN\nD CERTIFICATE REQUEST-----\\n",
            "nullable": true
          },
          "expires_at": {
            "type": "string",
            "description": "The date and time this Apple Pay certificate expires. This value is\npopulated after the Apple Pay certificate record has been updated\nwith the payment processing certificate received from Apple.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "created_at": {
            "type": "string",
            "description": "The date and time this Apple Pay certificate record was created in our\nsystem.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time this Apple Pay certificate record was last updated.",
            "example": "2013-07-16T19:23:00.000+00:00"
          }
        }
      },
      "ApplePayCertificates": {
        "title": "A list of Apple Pay certificates",
        "type": "object",
        "description": "A list of Apple Pay certificate records.",
        "x-tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ApplePayCertificate"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "ApplePayCertificateRequest": {
        "title": "Apple Pay certificate (Create)",
        "type": "object",
        "description": "A request to start the registration of a new Apple Pay payment\nprocessing certificate.",
        "x-tags": [
          "Apple Pay Certificates"
        ],
        "x-internal": true,
        "required": [
          "display_name"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A name for this Apple Pay certificate which is used in the Gr4vy\nadmin panel to give the Apple Pay certificate a human readable name.",
            "example": "iPad App v2",
            "minLength": 1,
            "maxLength": 200
          }
        }
      },
      "ApplePayRequest": {
        "title": "Apple Pay payment method request",
        "type": "object",
        "description": "Details for a Apple Pay payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "token"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`applepay`.",
            "example": "applepay",
            "enum": [
              "applepay"
            ]
          },
          "token": {
            "type": "object",
            "description": "The encrypted (opaque) token that was passed to the `onpaymentauthorized`\ncallback by the Apple Pay integration."
          },
          "card_suffix": {
            "type": "string",
            "description": "Last 4 digits of the PAN for identification purposes.",
            "example": "1234",
            "nullable": true
          },
          "card_scheme": {
            "type": "string",
            "description": "The scheme/brand of the card.",
            "nullable": true
          },
          "card_type": {
            "type": "string",
            "description": "The type of card.",
            "nullable": true,
            "example": "credit"
          }
        }
      },
      "ApplePaySessionRequest": {
        "title": "Apple Pay session request",
        "type": "object",
        "description": "Initiates a new session with Apple Pay.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "validation_url",
          "domain_name"
        ],
        "properties": {
          "validation_url": {
            "type": "string",
            "format": "uri",
            "description": "Validation URL obtained from the event passed to a\n`onvalidatemerchant` callback."
          },
          "domain_name": {
            "type": "string",
            "description": "Fully qualified domain name of the merchant."
          }
        }
      },
      "ApplePaySession": {
        "title": "Apple Pay Session",
        "type": "object",
        "x-internal": true,
        "additionalProperties": true
      },
      "APIKeyPairCreate": {
        "title": "API key-pair (Create)",
        "type": "object",
        "description": "A request to create an API key-pair.",
        "x-tags": [
          "API Key Pairs"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A name for this key-pair which is used in the Gr4vy admin panel to give the key-pair a human readable name.",
            "example": "Sandbox",
            "minLength": 1,
            "maxLength": 200
          },
          "algorithm": {
            "type": "string",
            "description": "The algorithm to use for the API Key Pair. The recommended value is `ECDSA`.\nYou should only use the `RSA` algorithm in environments that do not support\n`ECDSA`.",
            "example": "ECDSA",
            "enum": [
              "ECDSA",
              "RSA"
            ],
            "default": "ECDSA"
          },
          "role_ids": {
            "type": "array",
            "minItems": 1,
            "description": "A list of role IDs that will be assigned to the API Key Pair being created.\nOnly the \"Administrator\" and \"Integration\" roles are supported.",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "example": [
              "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
            ],
            "nullable": false
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The optional ID of the merchant account this API Key Pair should be assigned to.\nLeave this unset to create an API key that works across all merchant accounts.",
            "example": "plantly-uk",
            "nullable": true,
            "maxLength": 22
          }
        }
      },
      "APIKeyPairUpdate": {
        "title": "API key-pair (Update)",
        "type": "object",
        "description": "A request to update an API key-pair.",
        "x-tags": [
          "API Key Pairs"
        ],
        "required": [
          "display_name"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A name for this key-pair which is used in the Gr4vy admin panel to give the key-pair a human readable name.",
            "example": "Sandbox",
            "minLength": 1,
            "maxLength": 200
          }
        }
      },
      "ApiLog": {
        "title": "API Log",
        "type": "object",
        "description": "A log of an error that happened in the API call.",
        "x-tags": [
          "API Log"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`api-log`.",
            "example": "api-log",
            "enum": [
              "api-log"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the API log entry.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "request_method": {
            "type": "string",
            "description": "The http request method that generated the log entry.",
            "example": "POST"
          },
          "request_url": {
            "type": "string",
            "description": "The http request URL which trigged the error log.",
            "example": "http://api.wpay.gr4vy.app/transactions"
          },
          "request_received_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time that the request was received.",
            "example": "2022-01-01T00:00:00+00:00"
          },
          "response_status_code": {
            "type": "number",
            "description": "The http request status code.",
            "example": 400
          },
          "response_body": {
            "type": "object",
            "description": "The JSON response body for the log entry.",
            "properties": {
              "code": {
                "type": "string",
                "description": "The error code.",
                "example": "bad_request"
              },
              "message": {
                "type": "string",
                "description": "The error message.",
                "example": "Request failed validation"
              },
              "status": {
                "type": "number",
                "description": "The HTTP error code.",
                "example": 400
              },
              "type": {
                "type": "string",
                "description": "Type of the log entry.",
                "example": "error"
              },
              "details": {
                "type": "object",
                "description": "Details of the log entry, stack trace and endpoint.",
                "properties": {
                  "pointer": {
                    "type": "string",
                    "description": "Log's pointer.",
                    "example": "/payment_method/number"
                  },
                  "message": {
                    "type": "string",
                    "description": "Detailed message on the log entry.",
                    "example": "ensure this value has at least 13 characters"
                  },
                  "location": {
                    "type": "string",
                    "description": "Location on where the error happened.",
                    "example": "body"
                  },
                  "type": {
                    "type": "string",
                    "description": "Detailed error type that is specified in the log entry.",
                    "example": "value_error.any_str.min_length"
                  }
                }
              }
            }
          },
          "response_sent_at": {
            "type": "string",
            "format": "date-time",
            "description": "date-time of when the response was sent.",
            "example": "2022-01-01T00:00:10+00:00"
          }
        }
      },
      "ApiLogs": {
        "title": "API Logs",
        "type": "object",
        "description": "A list of API log entries.",
        "x-tags": [
          "API Logs"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of API log entries.",
            "items": {
              "$ref": "#/components/schemas/ApiLog"
            }
          }
        }
      },
      "AuditLog": {
        "title": "Audit Log",
        "type": "object",
        "description": "A log of a change that occurred in the Gr4vy instance.",
        "x-tags": [
          "Audit Logs"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`audit-log`.",
            "example": "audit-log",
            "enum": [
              "audit-log"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the audit log entry.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "timestamp": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time that the action was performed.",
            "example": "2022-01-01T00:00:00+00:00"
          },
          "action": {
            "type": "string",
            "description": "The action that was performed.",
            "example": "created",
            "enum": [
              "created",
              "updated",
              "deleted"
            ]
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The ID of the merchant account this entry was created for.",
            "example": "default",
            "nullable": true
          },
          "user": {
            "type": "object",
            "description": "The user who performed the action.",
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the user.",
                "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
              },
              "name": {
                "type": "string",
                "description": "The name of the user.",
                "example": "John L"
              },
              "email_address": {
                "type": "string",
                "description": "The email address for this user.",
                "example": "john@example.com",
                "nullable": true
              },
              "staff": {
                "type": "boolean",
                "description": "Whether the user is Gr4vy staff.",
                "example": false
              },
              "status": {
                "type": "string",
                "description": "The status of the user.",
                "example": "active",
                "enum": [
                  "active",
                  "pending",
                  "deleted"
                ]
              }
            }
          },
          "resource": {
            "type": "object",
            "description": "The resource that was changed.",
            "properties": {
              "type": {
                "type": "string",
                "description": "The type of the resource.",
                "example": "buyer"
              },
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the resource.",
                "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
              },
              "name": {
                "type": "string",
                "description": "The descriptive name of the resource.",
                "example": "Samuel J"
              }
            }
          }
        }
      },
      "AuditLogs": {
        "title": "Audit Logs",
        "type": "object",
        "description": "A list of audit log entries.",
        "x-tags": [
          "Audit Logs"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of audit log entries.",
            "items": {
              "$ref": "#/components/schemas/AuditLog"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "BillingDetails": {
        "title": "Billing details",
        "type": "object",
        "description": "Billing details associated to a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `billing-details`.",
            "example": "billing-details",
            "enum": [
              "billing-details"
            ]
          },
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name of the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address of the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number of the buyer. This number is formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "description": "The billing address of the buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          },
          "tax_id": {
            "description": "The tax information associated with the billing details.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/TaxId"
              }
            ]
          }
        }
      },
      "BillingDetailsRequest": {
        "title": "Billing details (Create)",
        "type": "object",
        "description": "Billing details to use associated to a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address for the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the buyer which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "type": "object",
            "description": "The billing address for the buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              },
              {
                "required": [
                  "line1",
                  "city",
                  "state",
                  "postal_code",
                  "country"
                ]
              }
            ]
          },
          "tax_id": {
            "type": "object",
            "description": "The tax ID information associated with the billing details.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/TaxId"
              }
            ]
          }
        }
      },
      "BillingDetailsUpdateRequest": {
        "title": "Billing Details (Update)",
        "type": "object",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address for the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the buyer which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "type": "object",
            "description": "The billing address for the buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          },
          "tax_id": {
            "type": "object",
            "description": "The tax ID information associated with the billing details.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/TaxId"
              }
            ]
          }
        }
      },
      "BrowserInfo": {
        "title": "Browser info",
        "type": "object",
        "required": [
          "java_enabled",
          "javascript_enabled",
          "language",
          "color_depth",
          "screen_height",
          "screen_width",
          "time_zone_offset",
          "user_device",
          "user_agent"
        ],
        "properties": {
          "java_enabled": {
            "type": "boolean",
            "description": "Indicates whether the client browser supports Java.",
            "example": true
          },
          "javascript_enabled": {
            "type": "boolean",
            "description": "Indicates whether the client browser supports JavaScript.",
            "example": true
          },
          "language": {
            "type": "string",
            "description": "The preferred language of the buyer,\nusually the language of the browser UI.",
            "example": "en-GB"
          },
          "color_depth": {
            "type": "number",
            "description": "The color depth of the screen.",
            "example": 32
          },
          "screen_height": {
            "type": "number",
            "description": "The height of the screen in pixels.",
            "example": 1080
          },
          "screen_width": {
            "type": "number",
            "description": "The width of the screen in pixels.",
            "example": 1920
          },
          "time_zone_offset": {
            "type": "number",
            "description": "Time-zone offset in minutes between UTC and buyer location.",
            "example": 60
          },
          "user_device": {
            "type": "string",
            "description": "The platform that is being used to access the website.",
            "example": "desktop",
            "enum": [
              "desktop",
              "mobile"
            ]
          },
          "user_agent": {
            "type": "string",
            "description": "The user agent string for the current browser.",
            "example": "Mozilla/5.0 (darwin) AppleWebKit/537.36\n(KHTML, like Gecko) jsdom/16.7.0"
          },
          "accept_header": {
            "type": "string",
            "description": "The `Accept` header of the request from the buyer's browser.",
            "example": "*/*"
          }
        }
      },
      "Buyer": {
        "title": "Buyer",
        "type": "object",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `buyer`.",
            "example": "buyer",
            "enum": [
              "buyer"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this buyer.",
            "format": "uuid"
          },
          "billing_details": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BillingDetails"
              }
            ],
            "description": "The billing details associated with a buyer.",
            "nullable": true
          },
          "created_at": {
            "description": "The date and time\nwhen this buyer was created in our system.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "display_name": {
            "description": "A unique name for this buyer which is used in the Gr4vy admin panel to give a buyer a human readable name.",
            "example": "John L.",
            "maxLength": 200,
            "minLength": 1,
            "nullable": true,
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the buyer against your own records.",
            "example": "user-789123",
            "maxLength": 200,
            "minLength": 1,
            "nullable": true,
            "type": "string"
          },
          "merchant_account_id": {
            "description": "The unique ID for a merchant account.",
            "example": "default",
            "type": "string"
          },
          "updated_at": {
            "description": "The date and time\nwhen this buyer was last updated in our system.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The source account number to perform an account funding transaction.",
            "nullable": true
          }
        }
      },
      "Buyers": {
        "title": "Buyers",
        "type": "object",
        "description": "A list of buyers.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of buyers.",
            "items": {
              "$ref": "#/components/schemas/Buyer"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "Buyer--Snapshot": {
        "title": "Buyer (Snapshot)",
        "type": "object",
        "description": "Snapshot of a buyer, as used when embedded inside other\nresources.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `buyer`.",
            "example": "buyer",
            "enum": [
              "buyer"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this buyer.",
            "format": "uuid",
            "nullable": true
          },
          "billing_details": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BillingDetails"
              }
            ],
            "description": "The billing details associated with the buyer, which include the\naddress and tax ID.",
            "nullable": true
          },
          "display_name": {
            "description": "A unique name for this buyer which is used in the Gr4vy admin panel to give a buyer a human readable name.",
            "example": "John L.",
            "maxLength": 200,
            "minLength": 1,
            "nullable": true,
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the buyer against your own records.",
            "example": "user-789123",
            "maxLength": 200,
            "minLength": 1,
            "nullable": true,
            "type": "string"
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The source account number to perform an account funding transaction.",
            "nullable": true
          }
        }
      },
      "BuyerRequest": {
        "title": "Buyer (Create)",
        "type": "object",
        "description": "A request to create a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the buyer against your own records. This value needs to be unique for all buyers.",
            "example": "user-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "display_name": {
            "type": "string",
            "description": "A unique name for this buyer which is used in the Gr4vy admin panel to give a buyer a human readable name.",
            "example": "John L.",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "billing_details": {
            "type": "object",
            "description": "The optional billing details to associate with a buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/BillingDetailsRequest"
              }
            ]
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The source account number to perform an account funding transaction.",
            "nullable": true
          }
        }
      },
      "BuyerUpdate": {
        "title": "Buyer (Update)",
        "type": "object",
        "description": "A request to update a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the buyer against your own records. This value needs to be unique for all buyers.",
            "example": "user-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "display_name": {
            "type": "string",
            "description": "A unique name for this buyer which is used in the Gr4vy admin panel to give a buyer a human readable name.",
            "example": "John L.",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "billing_details": {
            "type": "object",
            "description": "The billing details of the buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/BillingDetailsUpdateRequest"
              }
            ]
          }
        }
      },
      "BINLookupRequest": {
        "title": "BIN Lookup Request",
        "type": "object",
        "description": "The result and raw data for a card BIN lookup.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `bin-lookup-request`.",
            "example": "bin-lookup-request",
            "enum": [
              "bin-lookup-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "BIN lookup request context.",
            "properties": {
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The response body received from the `url`.",
                "example": "{}"
              },
              "response_status_code": {
                "type": "integer",
                "description": "The response status code received from the `url`.",
                "example": 200
              },
              "success": {
                "type": "boolean",
                "description": "Whether the BIN lookup was successful or not."
              },
              "bin": {
                "type": "string",
                "nullable": true,
                "description": "The value used to lookup BIN details."
              },
              "instrument": {
                "type": "string",
                "nullable": true,
                "description": "The instrument type used to lookup BIN details.",
                "example": "pan"
              },
              "type": {
                "type": "string",
                "nullable": true,
                "description": "The type of card, i.e. credit or debit, from the lookup response."
              },
              "scheme": {
                "nullable": true,
                "description": "The card scheme result from the lookup response.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              },
              "additional_schemes": {
                "type": "array",
                "items": {
                  "type": "string",
                  "example": "visa",
                  "enum": [
                    "accel",
                    "amex",
                    "bancontact",
                    "carte-bancaire",
                    "cirrus",
                    "culiance",
                    "dankort",
                    "diners-club",
                    "discover",
                    "eftpos-australia",
                    "elo",
                    "hipercard",
                    "jcb",
                    "maestro",
                    "mastercard",
                    "mir",
                    "nyce",
                    "other",
                    "pulse",
                    "rupay",
                    "star",
                    "uatp",
                    "unionpay",
                    "visa",
                    null
                  ]
                },
                "nullable": true,
                "description": "The card additional schemes from the lookup response."
              },
              "country_code": {
                "type": "string",
                "nullable": true,
                "description": "The card country code result from the lookup response."
              },
              "supports_network_tokens": {
                "type": "boolean",
                "nullable": true,
                "description": "Whether the issuing bank supports network tokenization for this card."
              }
            }
          }
        }
      },
      "CardDetails": {
        "title": "Card Details",
        "type": "object",
        "description": "Details about a card.",
        "properties": {
          "type": {
            "type": "string",
            "description": "`card-detail`.",
            "example": "card-detail",
            "enum": [
              "card-detail"
            ]
          },
          "id": {
            "type": "string",
            "format": "bin",
            "minLength": 8,
            "maxLength": 8,
            "description": "The 8 digit BIN of the card. When looking up card details using a\n`payment_method_id` this value will be `null`.",
            "example": "42424242"
          },
          "card_type": {
            "type": "string",
            "description": "The type of card.",
            "example": "credit",
            "enum": [
              "credit",
              "debit"
            ]
          },
          "scheme": {
            "description": "The scheme/brand of the card.",
            "nullable": true,
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          },
          "scheme_icon_url": {
            "type": "string",
            "description": "An icon to display for the card scheme.",
            "example": "https://api.sandbox.example.gr4vy.app/assets/card-scheme-definitions/visa.svg"
          },
          "country": {
            "type": "string",
            "description": "The 2-letter ISO code of the issuing country of the card.",
            "example": "US"
          },
          "required_fields": {
            "$ref": "#/components/schemas/RequiredFields"
          }
        }
      },
      "ClickToPaySessionRequest": {
        "title": "Click to Pay session request",
        "type": "object",
        "description": "Return digital payment application details for Click to Pay.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "checkout_session_id"
        ],
        "properties": {
          "checkout_session_id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The identifier for the current checkout session.",
            "format": "uuid"
          }
        }
      },
      "ClickToPaySession": {
        "title": "Click to Pay Session",
        "type": "object",
        "x-internal": true,
        "properties": {
          "digital_payment_application_id": {
            "type": "string",
            "description": "The ID of the Digital Payment Application for Click to Pay.",
            "example": "a0b093e4-028a-4310-93fb-4ed0afc813fb"
          },
          "digital_payment_application_name": {
            "type": "string",
            "description": "The name of the Digital Payment Application for Click to Pay.",
            "example": "Plantly T4JUU1"
          }
        }
      },
      "DigitalWalletApplePayTokenDecrypted": {
        "title": "Digital wallet Apple Pay token decrypted",
        "type": "object",
        "description": "The result after decrypting an Apple Pay token.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `digital-wallet-apple-pay-token-decrypted`.",
            "example": "digital-wallet-apple-pay-token-decrypted",
            "enum": [
              "digital-wallet-apple-pay-token-decrypted"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Apple Pay decrypted token context.",
            "properties": {
              "version": {
                "type": "string",
                "description": "Version information about the payment token.",
                "example": "EC_v1"
              },
              "type": {
                "type": "string",
                "description": "The type of payment instrument.",
                "nullable": true,
                "enum": [
                  "dpan",
                  "fpan",
                  null
                ],
                "example": "dpan"
              },
              "expiration_date": {
                "type": "string",
                "description": "Expiration of the decrypted data."
              },
              "has_cryptogram": {
                "type": "boolean",
                "description": "Online payment cryptogram, as defined by 3D Secure."
              },
              "eci": {
                "type": "string",
                "nullable": true,
                "description": "ECI indicator, as defined by 3D Secure."
              },
              "application_data": {
                "type": "string",
                "nullable": true,
                "description": "Hash of the application data property of the original request."
              },
              "transaction_identifier": {
                "type": "string",
                "description": "The unique identifier from Apple Pay."
              },
              "cardholder_name": {
                "type": "string",
                "nullable": true,
                "description": "The cardholder name."
              },
              "currency_code": {
                "type": "string",
                "description": "ISO 4217 numeric currency code for the transaction.",
                "example": "840"
              },
              "transaction_amount": {
                "type": "integer",
                "description": "The amount for the transaction."
              },
              "device_manufacturer_identifier": {
                "type": "string",
                "description": "Hex-encoded device manufacturer identifier which initiated the transaction."
              },
              "payment_data_type": {
                "type": "string",
                "description": "Either \"3DSecure\" or \"EMV\".",
                "example": "3DSecure"
              },
              "merchant_token_identifier": {
                "type": "string",
                "nullable": true,
                "description": "For a merchant token request, the provisioned merchant token identifier from the payment network."
              },
              "card_expiration_date": {
                "type": "string",
                "nullable": true,
                "description": "Expiration date of card."
              },
              "card_suffix": {
                "type": "string",
                "nullable": true,
                "description": "Last four digits of card PAN."
              }
            }
          }
        }
      },
      "DigitalWalletClickToPayTokenDecrypted": {
        "title": "Digital wallet Click to Pay token decrypted",
        "type": "object",
        "description": "The result after decrypting an Click to Pay token.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `digital-wallet-click-to-pay-token-decrypted`.",
            "example": "digital-wallet-click-to-pay-token-decrypted",
            "enum": [
              "digital-wallet-click-to-pay-token-decrypted"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Click to Pay decrypted token context.",
            "properties": {
              "correlation_id": {
                "type": "string",
                "description": "Correlation ID for transaction.",
                "example": "ba7a2034-3c9e-4d74-b0e9-d77435fd35d7"
              },
              "merchant_transaction_id": {
                "type": "string",
                "description": "Merchant Checkout Transaction Identifier which links the client-side JavaScript calls and server-side API calls for a specific transaction.",
                "example": "0a4e0d3.34f4a04b.47ee82c373dd4fd5398f3980b39eb6d648b9687c"
              },
              "type": {
                "type": "string",
                "description": "The type of payment instrument.",
                "enum": [
                  "dpan",
                  "fpan"
                ],
                "example": "dpan"
              },
              "expiration_date": {
                "type": "string",
                "description": "Expiration of the card/token."
              },
              "has_cryptogram": {
                "type": "boolean",
                "description": "Online payment cryptogram, as defined by 3-D Secure."
              },
              "cardholder_name": {
                "type": "string",
                "nullable": true,
                "description": "The cardholder name."
              },
              "card_bin": {
                "type": "string",
                "description": "First six digits of underlying card.",
                "example": "424242",
                "nullable": true
              },
              "card_last_four": {
                "type": "string",
                "description": "Last four digits of underlying card.",
                "nullable": true
              },
              "card_expiration_date": {
                "type": "string",
                "description": "Expiration date of underlying card.",
                "nullable": true
              },
              "card_type": {
                "type": "string",
                "description": "Card type.",
                "example": "CREDIT",
                "nullable": true
              },
              "billing_line1": {
                "type": "string",
                "nullable": true,
                "description": "Address line 1."
              },
              "billing_line2": {
                "type": "string",
                "nullable": true,
                "description": "Address line 2."
              },
              "billing_city": {
                "type": "string",
                "nullable": true,
                "description": "Address city."
              },
              "billing_state": {
                "type": "string",
                "nullable": true,
                "description": "Address state."
              },
              "billing_zip": {
                "type": "string",
                "nullable": true,
                "description": "Address zip/postal code."
              },
              "billing_country_code": {
                "type": "string",
                "nullable": true,
                "description": "ISO 3166-1 alpha 2 address country code."
              }
            }
          }
        }
      },
      "DigitalWalletGooglePayTokenDecrypted": {
        "title": "Digital wallet Google Pay token decrypted",
        "type": "object",
        "description": "The result after decrypting an Google Pay token.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `digital-wallet-google-pay-token-decrypted`.",
            "example": "digital-wallet-google-pay-token-decrypted",
            "enum": [
              "digital-wallet-google-pay-token-decrypted"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Google Pay decrypted token context.",
            "properties": {
              "version": {
                "type": "string",
                "description": "Version information about the payment token.",
                "example": "ECv2"
              },
              "type": {
                "type": "string",
                "description": "The type of payment instrument.",
                "nullable": true,
                "enum": [
                  "dpan",
                  "fpan",
                  null
                ],
                "example": "dpan"
              },
              "expiration_date": {
                "type": "string",
                "description": "Expiration of the decrypted data."
              },
              "has_cryptogram": {
                "type": "boolean",
                "description": "Online payment cryptogram, as defined by 3D Secure."
              },
              "eci": {
                "type": "string",
                "nullable": true,
                "description": "ECI indicator, as defined by 3D Secure."
              },
              "message_expiration": {
                "type": "string",
                "description": "Date and time at which the message expires as UTC milliseconds since epoch."
              },
              "message_id": {
                "type": "string",
                "description": "A unique ID that identifies the message in case it needs to be revoked or located at a later time."
              },
              "payment_method": {
                "type": "string",
                "description": "The type of the payment credential.",
                "example": "CARD"
              }
            }
          }
        }
      },
      "PaymentOptionCardScheme": {
        "type": "string",
        "title": "The scheme of the transaction"
      },
      "RequiredFields": {
        "title": "Required Fields",
        "type": "object",
        "description": "The fields that are required to process a transaction for this payment option.",
        "properties": {
          "first_name": {
            "type": "boolean",
            "description": "The first (given) name of the buyer.",
            "readOnly": true
          },
          "last_name": {
            "type": "boolean",
            "description": "The last (family) name of the buyer.",
            "readOnly": true
          },
          "email_address": {
            "type": "boolean",
            "description": "The email address of the buyer.",
            "readOnly": true
          },
          "phone_number": {
            "type": "boolean",
            "description": "The phone number of the buyer.",
            "readOnly": true
          },
          "address": {
            "type": "object",
            "description": "The billing address of the buyer.",
            "properties": {
              "city": {
                "type": "boolean",
                "description": "The city for the billing address.",
                "readOnly": true
              },
              "country": {
                "type": "boolean",
                "description": "The country for the billing address.",
                "readOnly": true
              },
              "postal_code": {
                "type": "boolean",
                "description": "The postal code or zip code for the billing address.",
                "readOnly": true
              },
              "state": {
                "type": "boolean",
                "description": "The state, county, or province for the billing address.",
                "readOnly": true
              },
              "house_number_or_name": {
                "type": "boolean",
                "description": "The house number or name for the billing address. Not all payment\nservices use this field but some do.",
                "readOnly": true
              },
              "line1": {
                "type": "boolean",
                "description": "The first line of the billing address.",
                "readOnly": true
              }
            }
          },
          "tax_id": {
            "type": "boolean",
            "description": "The tax id code associated with the billing details.",
            "readOnly": true
          }
        }
      },
      "CardRequest": {
        "title": "Card",
        "type": "object",
        "description": "Details to register a new card payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "number",
          "expiration_date"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`card`.",
            "example": "card",
            "enum": [
              "card"
            ]
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this card as it can be found on the\nfront of the card."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "card-323444",
            "nullable": true
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to associate this payment method to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset."
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to associate this payment method\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.",
            "example": "user-789123"
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction or payment method. This only applies to payment methods that\nrequire buyer approval.",
            "example": "https://example.com/callback",
            "nullable": true
          }
        }
      },
      "Connection": {
        "title": "Connection",
        "type": "object",
        "description": "A configured connection.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the connection.",
            "example": "7b5e02bd-fa53-4ef0-b11e-1609d0f48cc5"
          },
          "type": {
            "type": "string",
            "description": "`connection`.",
            "default": "connection",
            "example": "connection"
          },
          "name": {
            "type": "string",
            "description": "The name of this connection.",
            "example": "My Connection"
          },
          "active": {
            "type": "boolean",
            "example": true,
            "description": "Whether this connection is currently in use. Connections can\nbe deactivated to allow for them to be kept around and\nre-activated at a later date."
          },
          "silent": {
            "type": "boolean",
            "example": false,
            "description": "Defines if this service is currently running in silent mode. In silent\nmode, a service's decisions will be created but ignored when processing\na transaction, allowing for warm-up and comparison of new services\nagainst the active service."
          },
          "definition": {
            "$ref": "#/components/schemas/ConnectionDefinition"
          }
        }
      },
      "Connections": {
        "title": "Connections",
        "type": "object",
        "description": "A list of configured connections.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Connection"
            }
          }
        }
      },
      "ConnectionDefinition": {
        "title": "Connection Definition",
        "type": "object",
        "description": "A connection that can be configured.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the connection.",
            "example": "stripe-card"
          },
          "type": {
            "type": "string",
            "description": "`connection-definition`.",
            "default": "connection-definition",
            "example": "connection-definition"
          },
          "name": {
            "type": "string",
            "description": "The name of this connection.",
            "example": "Stripe"
          },
          "count": {
            "type": "number",
            "description": "The number of configured connections.",
            "example": 1
          },
          "group": {
            "type": "string",
            "example": "payment-service",
            "enum": [
              "anti-fraud-service",
              "digital-wallet",
              "gift-card-service",
              "payment-service"
            ]
          },
          "category": {
            "type": "string",
            "example": "card",
            "enum": [
              "anti-fraud",
              "bank",
              "bnpl",
              "card",
              "cash",
              "stored-credit",
              "wallet"
            ]
          },
          "icon_url": {
            "type": "string",
            "nullable": true,
            "description": "An icon to display for the connection.",
            "example": "https://cdn.gr4vy.app/stripe.svg"
          },
          "provider": {
            "type": "string",
            "nullable": true,
            "description": "The provider for this connection.",
            "example": "Stripe"
          }
        }
      },
      "ConnectionDefinitions": {
        "title": "Connection definitions",
        "type": "object",
        "description": "A list of available connection definitions.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ConnectionDefinition"
            }
          }
        }
      },
      "ConnectionOptions": {
        "title": "Connection Options",
        "type": "object",
        "properties": {
          "cybersource-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Cybersource payment gateway.",
            "properties": {
              "meta_key_merchant_id": {
                "type": "string",
                "description": "An override for the merchant ID configured for the connector,\nused in combination with meta keys.",
                "nullable": true
              },
              "merchant_defined_information": {
                "type": "object",
                "description": "This is a key-value object for merchant defined information. Each key needs to be a\nnumeric string identifying the MDI field to set. For example, for field 1 set\nthe key to \"1\".",
                "maxProperties": 100,
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "1": "John Doe",
                  "2": "trusted",
                  "99": "recurring"
                }
              },
              "ship_to_method": {
                "type": "string",
                "description": "Shipping method for the order.",
                "nullable": true
              }
            }
          },
          "cybersource-kcp": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Cybersource KCP APM.",
            "properties": {
              "meta_key_merchant_id": {
                "type": "string",
                "description": "An override for the merchant ID configured for the connector,\nused in combination with meta keys.",
                "nullable": true
              },
              "merchant_defined_information": {
                "type": "object",
                "description": "This is a key-value object for merchant defined information. Each key needs to be a\nnumeric string identifying the MDI field to set. For example, for field 1 set\nthe key to \"1\".",
                "maxProperties": 100,
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "1": "John Doe",
                  "2": "trusted",
                  "99": "recurring"
                }
              },
              "ship_to_method": {
                "type": "string",
                "description": "Shipping method for the order.",
                "nullable": true
              }
            }
          },
          "cybersource-ideal": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Cybersource iDeal APM.",
            "properties": {
              "meta_key_merchant_id": {
                "type": "string",
                "description": "An override for the merchant ID configured for the connector,\nused in combination with meta keys.",
                "nullable": true
              },
              "merchant_defined_information": {
                "type": "object",
                "description": "This is a key-value object for merchant defined information. Each key needs to be a\nnumeric string identifying the MDI field to set. For example, for field 1 set\nthe key to \"1\".",
                "maxProperties": 100,
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "1": "John Doe",
                  "2": "trusted",
                  "99": "recurring"
                }
              },
              "ship_to_method": {
                "type": "string",
                "description": "Shipping method for the order.",
                "nullable": true
              }
            }
          },
          "cybersource-anti-fraud": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Cybersource Decision Manager (anti-fraud).",
            "properties": {
              "meta_key_merchant_id": {
                "type": "string",
                "description": "An override for the merchant ID configured for the connector,\nused in combination with meta keys.",
                "nullable": true
              },
              "merchant_defined_data": {
                "type": "object",
                "description": "This is a key-value object for merchant defined data. Each key needs to be a\nnumeric string identifying the MDD field to set. For example, for field 1 set\nthe key to \"1\".\n\nPlease avoid fields \"31\", \"48\", \"50\"-\"56\" and \"63\"-\"76\" as these are\nauto-populated based on the transaction profile.",
                "maxProperties": 100,
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "1": "John Doe",
                  "2": "trusted",
                  "99": "recurring"
                }
              },
              "shipping_method": {
                "type": "string",
                "description": "Shipping method for the order.",
                "nullable": true
              }
            }
          },
          "givingblock-givingblock": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Giving Block connector.",
            "properties": {
              "defaultCryptocurrency": {
                "type": "string",
                "description": "The default crypto currency to display on the hosted page\npresented by The Giving Block.",
                "nullable": false,
                "example": "ETH"
              }
            }
          },
          "forter-anti-fraud": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Forter (anti-fraud).",
            "properties": {
              "delivery_type": {
                "type": "string",
                "nullable": true,
                "enum": [
                  "PHYSICAL",
                  "DIGITAL",
                  "HYBRID"
                ],
                "description": "Value to populate the `deliveryType` field in `primaryDeliveryDetails`.\n\nRepresents the type of delivery. This can be set to `PHYSICAL` for any\ntype of shipped goods, `DIGITAL` for non-shipped goods (services,\ngift cards etc.), or `HYBRID` for others."
              },
              "delivery_method": {
                "type": "string",
                "nullable": true,
                "description": "Value to populate the `deliveryMethod` field in `primaryDeliveryDetails`.\n\nRepresents the delivery method chosen by customer such as postal service,\nemail, in game transfer, etc."
              },
              "is_guest_buyer": {
                "type": "boolean",
                "default": false,
                "description": "Defines if this is a guest check-out. This will redact the `accountId` and\n`created` fields from the `accountOwner` details sent to Forter."
              },
              "cart_items": {
                "type": "array",
                "description": "A list of Forter cart item objects. These will be merged into the `cart_items`\npassed to the transaction. Every cart item here will be merged with a cart item\non the transaction with the same index.\n\nTogether, these will augment the `cartItems` values sent to the Forter validation\nAPI.",
                "items": {
                  "type": "object",
                  "properties": {
                    "basic_item_data": {
                      "description": "General data regarding item such as name, price, etc.",
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "maxLength": 12,
                          "example": "TANGIBLE",
                          "enum": [
                            "TANGIBLE",
                            "NON_TANGIBLE"
                          ],
                          "description": "Tangible if physical item, non-tangible if any other product."
                        }
                      }
                    },
                    "delivery_details": {
                      "description": "General data regarding item such as name, price, etc.",
                      "type": "object",
                      "properties": {
                        "delivery_type": {
                          "type": "string",
                          "nullable": true,
                          "example": "PHYSICAL",
                          "enum": [
                            "PHYSICAL",
                            "DIGITAL",
                            "HYBRID"
                          ],
                          "description": "Value to populate the `deliveryType` field for this cart item. This overrides\nthe type set at the wider level.\n\nRepresents the type of delivery. This can be set to `PHYSICAL` for any\ntype of shipped goods, `DIGITAL` for non-shipped goods (services,\ngift cards etc.), or `HYBRID` for others."
                        },
                        "delivery_method": {
                          "type": "string",
                          "example": "USPS - Ground Mail",
                          "description": "Value to populate the `deliveryMethod` field for this cart item. This overrides\nthe method set at the wider level.\n\nRepresents the delivery method chosen by customer such as postal service,\nemail, in game transfer, etc."
                        }
                      }
                    },
                    "beneficiaries": {
                      "type": "array",
                      "description": "List of all entities receiving or using the purchased cart item.",
                      "items": {
                        "type": "object",
                        "required": [
                          "personal_details"
                        ],
                        "properties": {
                          "personal_details": {
                            "description": "Personal details are those which contribute to building up a picture\nof the person as an individual, such as name, title, etc.",
                            "type": "object",
                            "properties": {
                              "first_name": {
                                "description": "First name.",
                                "type": "string",
                                "maxLength": 75,
                                "example": "John"
                              },
                              "last_name": {
                                "description": "Last name.",
                                "type": "string",
                                "maxLength": 75,
                                "example": "Smith"
                              },
                              "email": {
                                "description": "Email address.",
                                "type": "string",
                                "maxLength": 256,
                                "example": "john@example.com"
                              }
                            }
                          },
                          "address": {
                            "description": "Address details for the beneficiary.",
                            "type": "object",
                            "nullable": true,
                            "required": [
                              "country"
                            ],
                            "properties": {
                              "country": {
                                "description": "Country, two-letter ISO 3166-1 alpha 2 country code.",
                                "type": "string",
                                "maxLength": 2,
                                "example": "US"
                              },
                              "address1": {
                                "description": "Street-level address. Required when full address details are available.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 255,
                                "example": "235 Montgomery st."
                              },
                              "address2": {
                                "description": "Unit-level address.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 255,
                                "example": "Ste. 1110"
                              },
                              "zip": {
                                "description": "Zipcode.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 20,
                                "example": "94104"
                              },
                              "region": {
                                "description": "Top-level administrative subdivision - state/province/department/etc.\nCan be either abbreviated format or full name (NY/New York).",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 200,
                                "example": "CA"
                              },
                              "company": {
                                "description": "Company name.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 255,
                                "example": "Generic Corp. ltd."
                              },
                              "city": {
                                "description": "City. Required when full address details are available.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 200,
                                "example": "San Francisco"
                              }
                            }
                          },
                          "phone": {
                            "type": "array",
                            "description": "List of all phone numbers for the beneficiary.",
                            "items": {
                              "type": "object",
                              "required": [
                                "phone"
                              ],
                              "properties": {
                                "phone": {
                                  "description": "Phone number including all country and local access codes.",
                                  "type": "string",
                                  "maxLength": 25,
                                  "example": "15557654321"
                                }
                              }
                            }
                          },
                          "comments": {
                            "description": "Comments to merchant or beneficiary written by customer.",
                            "type": "object",
                            "nullable": true,
                            "properties": {
                              "user_comments_to_merchant": {
                                "description": "Comments the customer left to the merchant.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 600,
                                "example": "Please wrap with care!!"
                              },
                              "message_to_beneficiary": {
                                "description": "Comments the customer left to the beneficiary of the purchase made.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 600,
                                "example": "Enjoy the gift John!"
                              },
                              "merchant_comments": {
                                "description": "Comments by the merchant.",
                                "type": "string",
                                "nullable": true,
                                "maxLength": 600,
                                "example": "Shipping delayed"
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              },
              "total_discount": {
                "description": "The `totalDiscount` object that's sent to Forter's validation API.\nIt represents the discount that was given to the customer.",
                "type": "object",
                "nullable": true,
                "required": [
                  "coupon_code",
                  "discount_type"
                ],
                "properties": {
                  "coupon_code_used": {
                    "type": "string",
                    "maxLength": 150,
                    "example": "FATHERSDAY2015",
                    "description": "The coupon code used."
                  },
                  "discount_type": {
                    "type": "string",
                    "maxLength": 250,
                    "example": "COUPON",
                    "description": "The discount type."
                  },
                  "coupon_discount_amount": {
                    "description": "A monetary amount in USD or local currency.",
                    "type": "object",
                    "nullable": true,
                    "required": [
                      "coupon_code",
                      "discount_type"
                    ],
                    "properties": {
                      "amount_usd": {
                        "type": "string",
                        "maxLength": 12,
                        "example": "99.95",
                        "description": "Transaction amount in USD."
                      },
                      "amount_local_currency": {
                        "type": "string",
                        "maxLength": 20,
                        "example": "105.55",
                        "description": "Transaction amount in currency chosen by the buyer."
                      },
                      "currency": {
                        "type": "string",
                        "maxLength": 3,
                        "example": "CAD",
                        "description": "Transaction currency chosen by the buyer, 3-letter ISO-4217 format currency code."
                      }
                    }
                  },
                  "coupon_discount_percent": {
                    "type": "string",
                    "nullable": true,
                    "example": "20%",
                    "description": "Coupon discount percentage."
                  }
                }
              }
            }
          },
          "adyen-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Adyen when processing\ncard transactions.",
            "properties": {
              "additionalData": {
                "type": "object",
                "description": "A key-value object representing additional data to be passed\nto Adyen.",
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "riskdata.operatorCode": "operatorCode,",
                  "riskdata.operatorCountry": "operatorCountry"
                }
              },
              "autoRescue": {
                "type": "boolean",
                "default": false,
                "description": "Enabled Adyen's auto-rescue feature."
              },
              "maxDaysToRescue": {
                "type": "integer",
                "default": null,
                "nullable": true,
                "description": "Defines the number of days to auto-retry a payment for if `autoRescue`\nis enabled."
              },
              "autoRescueScenario": {
                "type": "string",
                "default": null,
                "nullable": true,
                "description": "Defines the Adyen auto-rescue test scenario to invoke."
              }
            }
          },
          "adyen-sepa": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Adyen when processing\nSEPA transactions.",
            "properties": {
              "autoRescue": {
                "type": "boolean",
                "default": false,
                "description": "Enabled Adyen's auto-rescue feature."
              },
              "maxDaysToRescue": {
                "type": "integer",
                "default": null,
                "nullable": true,
                "description": "Defines the number of days to auto-retry a payment for if `autoRescue`\nis enabled."
              },
              "autoRescueSepaScenario": {
                "type": "string",
                "default": null,
                "nullable": true,
                "description": "Defines the Adyen auto-rescue test scenario to invoke."
              },
              "ownerName": {
                "type": "string",
                "default": null,
                "nullable": true,
                "description": "Defines the type of chargeback that you want to simulate."
              }
            }
          },
          "paypal-paypal": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to PayPal when processing\ntransactions.",
            "properties": {
              "additional_data": {
                "type": "array",
                "description": "An array with key-value objects representing additional\ndata to be passed to PayPal.",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  }
                },
                "example": [
                  {
                    "key": "test",
                    "value": "abc"
                  }
                ]
              }
            }
          },
          "paypal-paypalpaylater": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to PayPal when processing\ntransactions.",
            "properties": {
              "additional_data": {
                "type": "array",
                "description": "An array with key-value objects representing additional\ndata to be passed to PayPal.",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  }
                },
                "example": [
                  {
                    "key": "test",
                    "value": "abc"
                  }
                ]
              }
            }
          },
          "powertranz-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Powertranz when processing\ntransactions.",
            "properties": {
              "skipThreeDSecure": {
                "type": "boolean",
                "default": false,
                "description": "Allows skipping of 3DS. Without this, every transaction will be sent\nvia Powertranz's 3DS server, even though 3DS might not be triggered."
              }
            }
          },
          "stripe-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Stripe when processing\ntransactions.",
            "properties": {
              "error_on_requires_action": {
                "type": "boolean",
                "default": false,
                "description": "Defines if Stripe should automatically fail the payment if it\nrequires two-factor authentication from the user."
              },
              "stripe_connect": {
                "type": "object",
                "nullable": true,
                "description": "Stripe Connect configuration options.",
                "properties": {
                  "stripe_account": {
                    "type": "string",
                    "nullable": true,
                    "description": "The ID of the connected Stripe account to process for."
                  },
                  "application_fee_amount": {
                    "type": "number",
                    "nullable": true,
                    "description": "The application fee to charge when processing for a connected account."
                  },
                  "on_behalf_of": {
                    "type": "string",
                    "nullable": true,
                    "description": "The Stripe account ID that these funds are intended for."
                  },
                  "transfer_data_destination": {
                    "type": "string",
                    "nullable": true,
                    "description": "The Stripe account ID that these funds are to be transferred to."
                  }
                }
              }
            }
          },
          "fiserv-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options for Fiserv IPG payment gateway.",
            "properties": {
              "installmentOptions": {
                "type": "object",
                "nullable": true,
                "description": "Fiserv installment options.",
                "properties": {
                  "numberOfInstallments": {
                    "type": "number",
                    "nullable": true,
                    "description": "Number of installments for a sale transaction if the customer pays the total amount in multiple transactions."
                  },
                  "installmentsInterest": {
                    "type": "boolean",
                    "nullable": true,
                    "description": "Indicates whether the installment interest amount has been applied."
                  },
                  "installmentDelayMonths": {
                    "type": "number",
                    "nullable": true,
                    "description": "The number of months the first installment payment will be delayed."
                  },
                  "merchantAdviceCodeSupported": {
                    "type": "boolean",
                    "nullable": true,
                    "description": "Indicates if the merchant supports merchant advice code (MAC) in order to receive table 55 code for a declined recurring transaction."
                  }
                }
              }
            }
          },
          "latitude-latitude": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Latitude/Gem when processing\ntransactions.",
            "properties": {
              "promotion_reference": {
                "type": "string",
                "nullable": true,
                "description": "The promotion reference."
              }
            }
          },
          "latitude-latitudeds": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Latitude/Gem when processing\ntransactions.",
            "properties": {
              "promotion_reference": {
                "type": "string",
                "nullable": true,
                "description": "The promotion reference."
              }
            }
          },
          "gem-gem": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Latitude/Gem when processing\ntransactions.",
            "properties": {
              "promotion_reference": {
                "type": "string",
                "nullable": true,
                "description": "The promotion reference."
              }
            }
          },
          "gem-gemds": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Latitude/Gem when processing\ntransactions.",
            "properties": {
              "promotion_reference": {
                "type": "string",
                "nullable": true,
                "description": "The promotion reference."
              }
            }
          },
          "nuvei-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Nuvei when processing\ntransactions.",
            "properties": {
              "customData": {
                "type": "string",
                "nullable": true,
                "description": "Custom data that will be returned in a response and displayed in\nNuvei's reporting."
              },
              "airlineData": {
                "type": "object",
                "nullable": true,
                "description": "Custom airline travel information that will be sent to Nuvei in\naddition to the standard airline fields sent in the request.",
                "properties": {
                  "isCardholderTraveling": {
                    "type": "boolean",
                    "nullable": true,
                    "description": "Indicates whether the cardholder is part of the travelling party."
                  },
                  "seatClass": {
                    "type": "string",
                    "nullable": true,
                    "description": "If present, will be sent to Nuvei as the seat class for all legs."
                  }
                }
              }
            }
          },
          "travelhub-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Worldline Travelhub when processing\ntransactions.",
            "properties": {
              "customData": {
                "type": "array",
                "description": "An array with name-value objects representing additional\ndata to be passed to Worldline Travelhub.",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  }
                },
                "example": [
                  {
                    "name": "fraud_data_name1",
                    "value": "aaa"
                  }
                ]
              }
            }
          },
          "affirm-affirm": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Affirm when processing\ntransactions.",
            "properties": {
              "discounts": {
                "type": "array",
                "description": "An array of discount objects.",
                "items": {
                  "type": "object",
                  "nullable": true,
                  "properties": {
                    "discount_code": {
                      "type": "object",
                      "nullable": false,
                      "description": "The name of your discount code is the name of the object that\ndescribes the amount and display name for that discount. For example,\nRETURN5 is the name of the discount code, so it is represented here as\nthe name of the first discount in the discounts object.",
                      "properties": {
                        "discount_amount": {
                          "nullable": false,
                          "type": "number",
                          "description": "The amount of the discount.",
                          "example": 500
                        },
                        "discount_display_name": {
                          "nullable": false,
                          "type": "string",
                          "description": "The display name of the discount.",
                          "example": "Returning customer 5% discount"
                        }
                      }
                    }
                  }
                },
                "example": [
                  {
                    "RETURN5": {
                      "discount_amount": "500,",
                      "discount_display_name": "Returning customer 5% discount"
                    }
                  },
                  {
                    "PRESDAY10": {
                      "discount_amount": "1000,",
                      "discount_display_name": "President's Day 10% off"
                    }
                  }
                ]
              }
            }
          },
          "braintree-card": {
            "type": "object",
            "nullable": true,
            "description": "Additional options to be passed through to Braintree when processing\ntransactions.",
            "properties": {
              "custom_fields": {
                "type": "object",
                "nullable": true,
                "description": "An array with name-value objects representing additional\ndata to be passed to Braintree. Each key is the name sent to Braintree.",
                "additionalProperties": {
                  "type": "string"
                },
                "example": {
                  "key-1": "Value for key1",
                  "key-2": "Value for key2"
                }
              },
              "dynamic_data_fields": {
                "type": "object",
                "nullable": true,
                "description": "Options to dynamically add information to be sent to Braintree.",
                "properties": {
                  "three_ds_auth_status": {
                    "type": "string",
                    "nullable": true,
                    "description": "The name of the custom field to be sent to Braintree.\nThe value will be the 3DS authentication status."
                  }
                },
                "example": {
                  "three_ds_auth_status": "custom-field-key-name"
                }
              }
            }
          }
        }
      },
      "CartItem": {
        "title": "Cart Item",
        "type": "object",
        "description": "A cart item that represents a single cart line item for a transaction.\nNote that some optional properties are required for certain payment\nservice providers. If no value is set for these properties, we will use\ntheir default value.\n\nIf the total due to be paid for the item is required by the payment service\nprovider, generally referred to as the \"total amount\", the formula below\nwill usually be used to calculate this amount:\n\n`(unit_amount * quantity) - discount_amount + tax_amount`\n\nIt's highly recommended that the total amount to pay for all items\nshould match the transaction's amount to reduce the risk of the\ntransaction being declined by the payment service provider.",
        "required": [
          "name",
          "quantity",
          "unit_amount"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The name of the cart item. The value you set for this property may\nbe truncated if the maximum length accepted by a payment service\nprovider is less than 255 characters.",
            "example": "GoPro HERO9 Camcorder",
            "maxLength": 255
          },
          "quantity": {
            "type": "integer",
            "description": "The quantity of this item in the cart. This value cannot be negative\nor zero.",
            "example": 1,
            "minimum": 1,
            "maximum": 99999999
          },
          "unit_amount": {
            "type": "integer",
            "description": "The amount for an individual item represented as a monetary amount\nin the smallest currency unit for the given currency, for example\n`1299` USD cents represents `$12.99`.\nThe amount sent through to the payment processor as unitary amount\nwill be calculated to include the discount and tax values sent\nas part of this cart item.",
            "example": 37999,
            "minimum": 0,
            "maximum": 99999999
          },
          "discount_amount": {
            "type": "integer",
            "description": "The amount discounted for this item represented as a monetary amount\nin the smallest currency unit for the given currency, for example `1299`\nUSD cents represents `$12.99`.\n\nPlease note that this amount is for the total of the cart item and not\nfor an individual item. For example, if the quantity is 5, this value\nshould be the total discount amount for 5 of the cart item.\n\nYou might see unexpected failed transactions if the `discount_amount` can\nnot be equally divided by the `quantity` value. This is due to the fact\nthat some payment services require this amount to be specified per unit.\n\nIn this situation we recommend splitting this item into separate items,\neach with their own specific discount.",
            "example": 0,
            "minimum": 0,
            "maximum": 99999999,
            "nullable": true,
            "default": 0
          },
          "tax_amount": {
            "type": "integer",
            "description": "The tax amount for this item represented as a monetary amount\nin the smallest currency unit for the given currency, for example `1299`\nUSD cents represents `$12.99`.\n\nPlease not that this amount is for the total of the cart item and not\nfor an individual item. For example, if the quantity is 5, this value\nshould be the total tax amount for 5 of the cart item.\n\nYou might see unexpected failed transactions if the `tax_amount` can\nnot be equally divided by the `quantity` value. This is due to the fact\nthat some payment services require this amount to be specified per unit.\n\nIn this situation we recommend splitting this item into separate items,\neach with their own specific tax amount.",
            "example": 0,
            "minimum": 0,
            "maximum": 99999999,
            "nullable": true,
            "default": 0
          },
          "external_identifier": {
            "type": "string",
            "example": "item-789123",
            "description": "An external identifier for the cart item. This can be set to any value and is not sent to the payment service.",
            "nullable": true,
            "maxLength": 200
          },
          "sku": {
            "type": "string",
            "example": "sku-789123",
            "description": "The SKU for the item.",
            "nullable": true,
            "maxLength": 200
          },
          "product_url": {
            "type": "string",
            "format": "url",
            "example": "https://example.com/items/gopro",
            "description": "The product URL for the item.",
            "nullable": true,
            "maxLength": 2083
          },
          "image_url": {
            "type": "string",
            "format": "url",
            "example": "https://example.com/images/items/gopro.png",
            "description": "The URL for the image of the item.",
            "nullable": true,
            "maxLength": 2083
          },
          "categories": {
            "type": "array",
            "description": "A list of strings containing product categories for the item.\nMax length per item: 50.",
            "items": {
              "type": "string",
              "maxLength": 50
            },
            "nullable": true,
            "maxItems": 100
          },
          "product_type": {
            "type": "string",
            "description": "The product type of the cart item.",
            "nullable": true,
            "example": "physical",
            "enum": [
              "physical",
              "discount",
              "shipping_fee",
              "sales_tax",
              "digital",
              "gift_card",
              "store_credit",
              "surcharge",
              null
            ]
          },
          "seller_country": {
            "type": "string",
            "description": "The country code of the seller of the item. For some connectors, if this country code\ndoes not match the `country` then the transaction will be marked to Visa as a foreign\nseller transaction to meet Marketplace reporting requirements.",
            "example": "US",
            "pattern": "^[A-Z]{2}$",
            "nullable": true
          }
        }
      },
      "CardSchemeDefinition": {
        "title": "Card Scheme Definition",
        "type": "object",
        "description": "Definitions of a card scheme including icon, label, etc.",
        "x-tags": [
          "Card Scheme Definitions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`card-scheme-definition`.",
            "example": "card-scheme-definition",
            "enum": [
              "card-scheme-definition"
            ]
          },
          "id": {
            "type": "string",
            "description": "The name of this card scheme.",
            "example": "visa"
          },
          "icon_url": {
            "type": "string",
            "description": "The icon for this card scheme.",
            "example": "https://api.sandbox.example.gr4vy.app/assets/card-scheme-definitions/visa.svg"
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this card scheme.",
            "example": "Visa"
          }
        }
      },
      "CardSchemeDefinitions": {
        "title": "Card Scheme Definitions",
        "type": "object",
        "description": "A list of available card scheme definitions.",
        "x-tags": [
          "Card Scheme Definitions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CardSchemeDefinition"
            }
          }
        }
      },
      "CheckoutSession": {
        "title": "Checkout Session",
        "type": "object",
        "description": "A short-lived checkout session.",
        "x-tags": [
          "Checkout"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`checkout-session`.",
            "example": "checkout-session",
            "enum": [
              "checkout-session"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the Checkout Session.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "expires_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time when the Checkout Session will expire.\nBy default this will be set to 1 hour from the date of creation.",
            "example": "2022-01-01T00:00:00+00:00"
          },
          "cart_items": {
            "type": "array",
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "nullable": true
          },
          "metadata": {
            "description": "Any additional information about the transaction that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "type": "object",
            "maxProperties": 20,
            "nullable": true,
            "additionalProperties": {
              "type": "string"
            },
            "example": {
              "key": "value"
            }
          },
          "airline": {
            "description": "Contains information about an airline travel, if applicable.",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "nullable": true
          },
          "payment_method": {
            "nullable": true,
            "description": "Details about the payment method for card type only.",
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "example": "payment_method"
              },
              "id": {
                "type": "string",
                "nullable": true,
                "description": "Unique ID for the payment method."
              },
              "method": {
                "type": "string",
                "example": "card",
                "description": "Payment method type.",
                "enum": [
                  "card"
                ]
              },
              "scheme": {
                "description": "The scheme/brand of the card.",
                "nullable": true,
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              },
              "label": {
                "type": "string",
                "example": "4242",
                "nullable": true,
                "description": "Last four digits of PAN."
              },
              "details": {
                "type": "object",
                "nullable": true,
                "properties": {
                  "bin": {
                    "type": "string",
                    "example": "411111",
                    "description": "First six digits of PAN.",
                    "nullable": true
                  },
                  "card_type": {
                    "nullable": true,
                    "example": "credit",
                    "type": "string",
                    "enum": [
                      "credit",
                      "debit",
                      "prepaid"
                    ]
                  },
                  "card_country": {
                    "type": "string",
                    "nullable": true,
                    "example": "US",
                    "description": "ISO 3166 two letter country code.",
                    "maxLength": 2,
                    "minLength": 2
                  },
                  "card_issuer_name": {
                    "type": "string",
                    "nullable": true,
                    "example": "Bank",
                    "description": "The name of the card issuer."
                  }
                }
              },
              "fingerprint": {
                "type": "string",
                "description": "The unique hash derived from the payment method identifier (e.g. card number).",
                "example": "20eb353620155d2b5fc864cc46a73ea77cb92c725238650839da1813fa987a17",
                "nullable": true
              }
            }
          }
        }
      },
      "CheckoutSessionSecureFieldsUpdate": {
        "title": "Checkout Session Secure Fields (Update)",
        "type": "object",
        "description": "A request to update the secure fields of a checkout session.",
        "x-tags": [
          "Checkout Sessions"
        ],
        "x-internal": true,
        "properties": {
          "payment_method": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/CheckoutSessionFieldsCardPaymentMethod"
              },
              {
                "$ref": "#/components/schemas/CheckoutSessionFieldsClickToPayPaymentMethod"
              },
              {
                "$ref": "#/components/schemas/CheckoutSessionFieldsIdPaymentMethod"
              }
            ]
          }
        }
      },
      "CheckoutSessionFieldsCardPaymentMethod": {
        "title": "Card Payment Method",
        "type": "object",
        "description": "Details to store a new card payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "x-internal": true,
        "required": [
          "method"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`card`.",
            "example": "card",
            "enum": [
              "card"
            ]
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this card as it can be found on the\nfront of the card."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          }
        }
      },
      "CheckoutSessionFieldsClickToPayPaymentMethod": {
        "title": "Click to Pay Payment Method",
        "type": "object",
        "description": "Details to store a new Click to Pay payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "x-internal": true,
        "required": [
          "method",
          "merchant_transaction_id",
          "src_correlation_id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`click_to_pay`.",
            "example": "click_to_pay",
            "enum": [
              "click_to_pay"
            ]
          },
          "merchant_transaction_id": {
            "type": "string",
            "example": "1a3f0b9.3f334ba9.v094c1c526e0e39c10491a6a947249b5a9200ed6",
            "description": "Merchant checkout transaction identifier which is returned in the checkout\nresponse from Click to Pay JavaScript methods.\n"
          },
          "src_correlation_id": {
            "type": "string",
            "example": "34f4a24c.977cf2c2-3cv1-489e-b024-188a11a07491",
            "description": "Unique identifier generated by an SRC System."
          }
        }
      },
      "CheckoutSessionFieldsIdPaymentMethod": {
        "title": "ID Payment Method",
        "type": "object",
        "description": "Details to use a stored card payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "x-internal": true,
        "required": [
          "method",
          "id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`id`.",
            "example": "id",
            "enum": [
              "id"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          }
        }
      },
      "CheckoutSessionRequest": {
        "title": "Checkout Session",
        "type": "object",
        "description": "Details to register a new Checkout Session payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`checkout-session`.",
            "example": "checkout-session",
            "enum": [
              "checkout-session"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the Checkout Session.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction or payment method. This only applies to payment methods that\nrequire buyer approval.",
            "example": "https://example.com/callback",
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "card-323444",
            "nullable": true
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to associate this payment method to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset."
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to associate this payment method\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.",
            "example": "user-789123"
          }
        }
      },
      "CheckoutSessionCreateRequest": {
        "title": "Checkout Session (Create)",
        "type": "object",
        "description": "A request to create a checkout session.",
        "x-tags": [
          "Checkout"
        ],
        "properties": {
          "expires_in": {
            "type": "integer",
            "minimum": 3600,
            "maximum": 86400,
            "default": 3600,
            "example": 7200,
            "description": "Defines when the checkout session will expire (in seconds). Defaults to an\nhour (3600 seconds)."
          },
          "cart_items": {
            "type": "array",
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "nullable": true
          },
          "metadata": {
            "description": "Any additional information about the transaction that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "type": "object",
            "maxProperties": 20,
            "nullable": true,
            "additionalProperties": {
              "type": "string"
            },
            "example": {
              "key": "value"
            }
          },
          "airline": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "description": "The airline addendum data which describes the airline booking\nassociated with this transaction.",
            "nullable": true
          },
          "buyer": {
            "description": "Provide buyer details for the transaction. No buyer resource will be\ncreated on Gr4vy when used.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/TransactionBuyerRequest"
              }
            ],
            "type": "object",
            "x-model-name": "TransactionBuyerRequest",
            "nullable": true
          }
        }
      },
      "CheckoutSessionUpdateRequest": {
        "title": "Checkout Session (Update)",
        "type": "object",
        "description": "A request to update a checkout session.",
        "x-tags": [
          "Checkout"
        ],
        "properties": {
          "cart_items": {
            "type": "array",
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "nullable": true
          },
          "metadata": {
            "description": "Any additional information about the transaction that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "type": "object",
            "maxProperties": 20,
            "nullable": true,
            "additionalProperties": {
              "type": "string"
            },
            "example": {
              "key": "value"
            }
          },
          "airline": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "description": "The airline addendum data which describes the airline booking\nassociated with this transaction.",
            "nullable": true
          }
        }
      },
      "Cryptogram": {
        "title": "Cryptogram",
        "type": "object",
        "description": "A network token cryptogram.",
        "x-tags": [
          "Tokens"
        ],
        "properties": {
          "cryptogram": {
            "type": "string",
            "description": "The cryptogram of the network token."
          }
        }
      },
      "DetailedSettlementReportSpec": {
        "title": "Detailed Settlement Report Specification",
        "type": "object",
        "description": "The specification of a detailed settlement report.",
        "x-tags": [
          "Reports"
        ],
        "required": [
          "model",
          "params"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "The model (dataset) that the data used for the report is\nretrieved from.",
            "example": "detailed_settlement",
            "enum": [
              "detailed_settlement"
            ]
          },
          "params": {
            "type": "object",
            "description": "Parameters used to configure the report.",
            "properties": {
              "filters": {
                "type": "object",
                "description": "The filters for the report.",
                "example": {
                  "ingested_at": {
                    "start": "day_start",
                    "end": "day_end"
                  }
                },
                "properties": {
                  "ingested_at": {
                    "type": "object",
                    "description": "The time window for when the data was ingested to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the data was ingested\nas a date-time placeholder value.",
                        "example": "day_start",
                        "enum": [
                          "day_start"
                        ]
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the data was ingested\nas a date-time placeholder value.",
                        "example": "day_end",
                        "enum": [
                          "day_end"
                        ]
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "DigitalWallet": {
        "title": "Digital Wallet",
        "type": "object",
        "description": "A digital wallet (e.g. Apple Pay) that has been registered.",
        "x-tags": [
          "Digital Wallets"
        ],
        "properties": {
          "type": {
            "type": "string",
            "example": "digital-wallet",
            "description": "`digital-wallet`.",
            "enum": [
              "digital-wallet"
            ]
          },
          "id": {
            "type": "string",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79",
            "description": "The ID of the registered digital wallet.",
            "format": "uuid"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "provider": {
            "type": "string",
            "example": "apple",
            "description": "The name of the digital wallet provider.",
            "enum": [
              "apple",
              "google"
            ]
          },
          "merchant_name": {
            "type": "string",
            "example": "Gr4vy",
            "description": "The name of the merchant the digital wallet is registered to."
          },
          "merchant_url": {
            "type": "string",
            "example": "https://example.com",
            "description": "The main URL of the merchant.",
            "default": null,
            "nullable": true,
            "format": "url"
          },
          "merchant_display_name": {
            "type": "string",
            "nullable": true,
            "example": "Gr4vy",
            "description": "The consumer facing name of the merchant."
          },
          "merchant_country_code": {
            "type": "string",
            "example": "US",
            "nullable": true,
            "description": "The country code where the merchant is registered.",
            "maxLength": 2,
            "minLength": 2
          },
          "domain_names": {
            "type": "array",
            "minItems": 1,
            "maxItems": 99,
            "items": {
              "type": "string"
            },
            "example": [
              "example.com"
            ],
            "description": "The list of domain names that a digital wallet can be used on. To use a\ndigital wallet on a website, the domain of the site is required to be\nin this list."
          },
          "fields": {
            "description": "Custom attributes for some digital wallets. Currently only used by\nClick to Pay.",
            "nullable": true,
            "$ref": "#/components/schemas/DigitalWalletClickToPayFields"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this digital wallet was registered."
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this digital wallet was last updated."
          },
          "active_certificate_count": {
            "type": "integer",
            "example": 1,
            "description": "The number of active custom certificates registered for this digital wallet (Apple Pay only)."
          },
          "pending_certificate_count": {
            "type": "integer",
            "example": 1,
            "description": "The number of pending custom certificates registered for this digital wallet (Apple Pay only)."
          },
          "expired_certificate_count": {
            "type": "integer",
            "example": 1,
            "description": "The number of expired custom certificates registered for this digital wallet (Apple Pay only)."
          }
        }
      },
      "DigitalWallets": {
        "title": "Digital Wallets",
        "type": "object",
        "description": "A list of registered digital wallets.",
        "x-tags": [
          "Digital Wallets"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of registered digital wallets.",
            "items": {
              "$ref": "#/components/schemas/DigitalWallet"
            }
          }
        }
      },
      "DigitalWalletClickToPayFields": {
        "title": "Click to Pay",
        "type": "object",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "digital_payment_application_id": {
            "type": "string",
            "description": "Unique ID assigned for digital payment application."
          },
          "digital_payment_application_name": {
            "type": "string",
            "description": "Name assigned for digital payment application."
          }
        }
      },
      "DigitalWalletDomain": {
        "title": "Digital Wallet Domain",
        "type": "object",
        "description": "Domain name for a digital wallet.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "domain_name"
        ],
        "properties": {
          "domain_name": {
            "type": "string",
            "example": "example.com",
            "description": "The domain name that a digital wallet can be used on. To use a\ndigital wallet on a website, the domain of the site is required to be\nin this list."
          }
        }
      },
      "DigitalWalletRequest": {
        "title": "Digital Wallet (Register)",
        "type": "object",
        "description": "Merchant details used to register with a digital wallet provider.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "provider",
          "merchant_name",
          "domain_names",
          "accept_terms_and_conditions"
        ],
        "properties": {
          "provider": {
            "type": "string",
            "example": "apple",
            "description": "The name of the digital wallet provider.",
            "enum": [
              "apple",
              "google"
            ]
          },
          "merchant_name": {
            "type": "string",
            "description": "The name of the merchant. This is used to register the merchant with a\ndigital wallet provider and this name is not displayed to the buyer.",
            "example": "Gr4vy"
          },
          "merchant_url": {
            "type": "string",
            "example": "https://example.com",
            "default": null,
            "nullable": true,
            "description": "The main URL of the merchant.",
            "format": "url"
          },
          "merchant_display_name": {
            "type": "string",
            "nullable": true,
            "example": "Gr4vy",
            "description": "The consumer facing name of the merchant."
          },
          "merchant_country_code": {
            "type": "string",
            "example": "US",
            "nullable": true,
            "description": "The country code where the merchant is registered.",
            "maxLength": 2,
            "minLength": 2
          },
          "domain_names": {
            "type": "array",
            "minItems": 1,
            "maxItems": 99,
            "items": {
              "type": "string"
            },
            "example": [
              "example.com"
            ],
            "description": "The list of domain names that a digital wallet can be used on. To use a\ndigital wallet on a website, the domain of the site is required to be\nin this list."
          },
          "accept_terms_and_conditions": {
            "type": "boolean",
            "description": "The explicit acceptance of the digital wallet provider's terms and\nconditions by the merchant. Needs to be `true` to register a new digital\nwallet.",
            "example": true
          }
        }
      },
      "DigitalWalletUpdate": {
        "title": "Digital Wallet (Update)",
        "type": "object",
        "description": "Request body to update a registered digital wallet's details.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "merchant_name": {
            "type": "string",
            "description": "The name of the merchant. This is used to update the value initially\nused to register with a digital wallet provider and this name is not\ndisplayed to the buyer.",
            "example": "Gr4vy"
          },
          "domain_names": {
            "type": "array",
            "minItems": 1,
            "maxItems": 99,
            "items": {
              "type": "string"
            },
            "example": [
              "example.com"
            ],
            "description": "The list of domain names that a digital wallet can be used on. To use a\ndigital wallet on a website, the domain of the site is required to be\nin this list."
          },
          "merchant_display_name": {
            "type": "string",
            "nullable": true,
            "example": "Gr4vy",
            "description": "The consumer facing name of the merchant."
          },
          "merchant_country_code": {
            "type": "string",
            "example": "US",
            "nullable": true,
            "description": "The country code where the merchant is registered.",
            "maxLength": 2,
            "minLength": 2
          },
          "merchant_url": {
            "type": "string",
            "example": "https://example.com",
            "description": "The main URL of the merchant."
          }
        }
      },
      "Error400BadRequest": {
        "title": "Bad Request",
        "type": "object",
        "description": "Bad Request (HTTP 400).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "A short code that describes the reason for the error.",
            "example": "bad_request",
            "enum": [
              "bad_request",
              "incorrect_json",
              "invalid_credentials"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`400`.",
            "example": 400,
            "enum": [
              400
            ]
          },
          "message": {
            "type": "string",
            "description": "A human-readable reason for the error.",
            "example": "Missing '****' field"
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.",
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "Error401Unauthorized": {
        "title": "Unauthorized Error",
        "type": "object",
        "description": "Unauthorized Error (HTTP 401).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "`unauthorized`.",
            "example": "unauthorized",
            "enum": [
              "unauthorized"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`401`.",
            "example": 401,
            "enum": [
              401
            ]
          },
          "message": {
            "type": "string",
            "description": "No valid API authentication found.",
            "example": "No valid API authentication found",
            "enum": [
              "No valid API authentication found"
            ]
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.\nNot every error supports more detail.",
            "example": [],
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "Error403Forbidden": {
        "title": "Forbidden Error",
        "type": "object",
        "description": "Forbidden Error (HTTP 403).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "`forbidden`.",
            "example": "forbidden",
            "enum": [
              "forbidden"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`403`.",
            "example": 403,
            "enum": [
              403
            ]
          },
          "message": {
            "type": "string",
            "description": "Invalid credentials.",
            "example": "Invalid credentials",
            "enum": [
              "Invalid credentials"
            ]
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.\nNot every error supports more detail.",
            "example": [],
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "Error404NotFound": {
        "title": "Not Found Error",
        "type": "object",
        "description": "Not Found Error (HTTP 404).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "The reason code for the error.",
            "example": "not_found",
            "enum": [
              "not_found",
              "pending_creation"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`404`.",
            "example": 404,
            "enum": [
              404
            ]
          },
          "message": {
            "type": "string",
            "description": "The human readable reason for the error.",
            "example": "The resource could not be found"
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.\nNot every error supports more detail.",
            "example": [],
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "Error409DuplicateRecord": {
        "title": "Duplicate Record Error",
        "type": "object",
        "description": "Duplicate Record Error (HTTP 409).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "`duplicate_record`.",
            "example": "duplicate_record",
            "enum": [
              "duplicate_record"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`409`.",
            "example": 409,
            "enum": [
              409
            ]
          },
          "message": {
            "type": "string",
            "description": "Further details on the field that triggered the error.",
            "example": "A duplicate record exists with this external_identifier value"
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.\nNot every error supports more detail.",
            "example": [],
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "Error429TooManyRequests": {
        "title": "Too Many Requests Error",
        "type": "object",
        "description": "Too Many Requests Error (HTTP 429).",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`error`.",
            "enum": [
              "error"
            ],
            "example": "error"
          },
          "code": {
            "type": "string",
            "description": "`too_many_requests`.",
            "example": "too_many_requests",
            "enum": [
              "too_many_requests"
            ]
          },
          "status": {
            "type": "integer",
            "description": "`429`.",
            "example": 429,
            "enum": [
              429
            ]
          },
          "message": {
            "type": "string",
            "description": "Further details on the field that triggered the error.",
            "example": "Too many requests"
          },
          "details": {
            "type": "array",
            "description": "A list of detail objects that further clarify the reason for the error.\nNot every error supports more detail.",
            "example": [],
            "items": {
              "$ref": "#/components/schemas/ErrorDetail"
            }
          }
        }
      },
      "ErrorDetail": {
        "title": "Error details",
        "description": "Additional detail about the part of a request body that caused an issue.",
        "type": "object",
        "x-tags": [
          "Errors"
        ],
        "properties": {
          "location": {
            "type": "string",
            "example": "body",
            "description": "The location where the error caused an issue.",
            "enum": [
              "query",
              "body",
              "path",
              "header"
            ]
          },
          "type": {
            "type": "string",
            "example": "value_error.missing",
            "description": "A unique identifier for the type of error that occurred."
          },
          "pointer": {
            "type": "string",
            "example": "/payment_method/number",
            "description": "The exact item for which the validation did not succeed. This is a JSON\npointer for request bodies, while for query, path, and header parameters\nit is the name of the parameter."
          },
          "message": {
            "type": "string",
            "example": "field required",
            "description": "A human readable message for this error detail."
          }
        }
      },
      "GiftCard": {
        "title": "A gift card",
        "type": "object",
        "description": "A gift card stored for a buyer, or used in a transaction.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card",
            "enum": [
              "gift-card"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this gift card.",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "service": {
            "$ref": "#/components/schemas/GiftCardService"
          },
          "bin": {
            "type": "string",
            "description": "The first 6 digits of the full gift card number.",
            "example": "412345"
          },
          "sub_bin": {
            "type": "string",
            "description": "The 3 digits after the `bin` of the full gift card number.",
            "example": "554"
          },
          "last4": {
            "type": "string",
            "description": "The last 4 digits for the gift card.",
            "example": "1234"
          },
          "expiration_date": {
            "type": "string",
            "description": "The date and time when this gift card expires. This is a full\ndate/time and may be more accurate than the actual expiry date\nreceived by the gift card service.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "buyer": {
            "description": "The optional buyer for which this payment method has been stored.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer"
              }
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this gift card was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this gift card was last updated in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          }
        }
      },
      "GiftCards": {
        "title": "Gift Cards",
        "type": "object",
        "description": "A list of stored gift cards.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of stored gift cards.",
            "items": {
              "$ref": "#/components/schemas/GiftCard"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "GiftCard--Snapshot": {
        "title": "Gift card (Snapshot)",
        "type": "object",
        "description": "A snapshot of a gift card used in a transaction.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card",
            "enum": [
              "gift-card"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "nullable": true,
            "description": "The ID of this gift card. This may be `null` if the gift\ncard is not stored.",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893"
          },
          "bin": {
            "type": "string",
            "description": "The first 6 digits of the full gift card number.",
            "example": "412345"
          },
          "sub_bin": {
            "type": "string",
            "description": "The 3 digits after the `bin` of the full gift card number.",
            "example": "554"
          },
          "last4": {
            "type": "string",
            "description": "The last 4 digits for the gift card.",
            "example": "1234"
          }
        }
      },
      "GiftCard--Summary": {
        "title": "A stored gift card (summary)",
        "type": "object",
        "description": "A gift card stored for a buyer.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card",
            "enum": [
              "gift-card"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "nullable": true,
            "description": "The ID of this gift card.",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "bin": {
            "type": "string",
            "description": "The first 6 digits of the full gift card number.",
            "example": "412345"
          },
          "sub_bin": {
            "type": "string",
            "description": "The 3 digits after the `bin` of the full gift card number.",
            "example": "554"
          },
          "last4": {
            "type": "string",
            "description": "The last 4 digits for the gift card.",
            "example": "1234"
          },
          "expiration_date": {
            "type": "string",
            "description": "The date and time when this gift card expires. This is a full\ndate/time and may be more accurate than the actual expiry date\nreceived by the gift card service.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "balance": {
            "type": "integer",
            "description": "The amount remaining on the balance for this gift card according to the\ngift card service. This may be `null` if the balance could not be fetched.",
            "nullable": true,
            "example": 1299,
            "minimum": 0,
            "maximum": 99999999
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "nullable": true,
            "description": "The ISO-4217 currency code that this gift card has a balance for."
          },
          "balance_error_code": {
            "description": "If the last balance update failed, this will contain the\ninternal code for this error.",
            "example": "incorrect_currency",
            "nullable": true,
            "type": "string",
            "enum": [
              "expired_card",
              "inactive_card",
              "incorrect_currency",
              "insufficient_funds",
              "invalid_amount",
              "invalid_gift_card",
              "invalid_service_configuration",
              "invalid_service_credentials",
              "operation_canceled",
              "service_error",
              "service_network_error",
              "unknown_error"
            ]
          },
          "balance_raw_error_code": {
            "description": "If the last balance update failed, this will contain the\nthe raw error code received from the gift card provider.",
            "example": "10363",
            "type": "string",
            "nullable": true
          },
          "balance_raw_error_message": {
            "description": "If the last balance update failed, this will contain the\nthe raw error message received from the gift card provider.",
            "example": "This currency is not supported by the merchant.",
            "type": "string",
            "nullable": true
          }
        }
      },
      "GiftCards--Summary": {
        "title": "Gift Cards (Summary)",
        "type": "object",
        "description": "A list of gift cards in a short format including the latest balance.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of stored gift cards.",
            "items": {
              "$ref": "#/components/schemas/GiftCard--Summary"
            }
          }
        }
      },
      "GiftCardBalanceRequest": {
        "title": "Gift Card Balance (Request)",
        "type": "object",
        "description": "Check the balance for a stored/new gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893",
            "description": "The ID of the gift card to check a balance for.\nRequired if `number` is not set."
          },
          "number": {
            "type": "string",
            "minLength": 16,
            "maxLength": 19,
            "example": "4123455541234561234",
            "pattern": "^[0-9]{16,19}$",
            "description": "The 16-19 digit number for this gift card.\nRequired if `id` is not set."
          },
          "pin": {
            "type": "string",
            "description": "The PIN for this gift card. Required if `number` is set.",
            "example": "1234"
          }
        }
      },
      "GiftCardBalanceNewRequest": {
        "title": "Gift Card Balance (New)",
        "type": "object",
        "description": "Check the balance for a non-stored gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "number",
          "pin"
        ],
        "properties": {
          "number": {
            "type": "string",
            "minLength": 16,
            "maxLength": 19,
            "example": "4123455541234561234",
            "pattern": "^[0-9]{16,19}$",
            "description": "The 16-19 digit number for this gift card."
          },
          "pin": {
            "type": "string",
            "description": "The PIN for this gift card.",
            "example": "1234"
          }
        }
      },
      "GiftCardBalanceStoredRequest": {
        "title": "Gift Card Balance (Stored)",
        "type": "object",
        "description": "Check the balance for a stored gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893",
            "description": "The ID of the gift card to check a balance for."
          }
        }
      },
      "GiftCardBalancesRequest": {
        "title": "A gift card balance check request",
        "type": "object",
        "description": "A request to check the balance for a set of stored and\nnon-stored gift cards.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "One or more gift cards to check balances for, up to a default limit\nof 10 gift cards. Please contact our team to change this limit.",
            "minItems": 1,
            "items": {
              "x-model-name": "GiftCardBalanceRequest",
              "oneOf": [
                {
                  "$ref": "#/components/schemas/GiftCardBalanceNewRequest"
                },
                {
                  "$ref": "#/components/schemas/GiftCardBalanceStoredRequest"
                }
              ]
            }
          }
        }
      },
      "GiftCardRedemption": {
        "title": "Gift card redemption",
        "type": "object",
        "description": "A redemption of a gift card used in a transaction.",
        "x-tags": [
          "Gift Cards"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card-redemption",
            "enum": [
              "gift-card-redemption"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "nullable": true,
            "description": "The ID of this gift card redemption. This may be `null` if the\nno redemption happened.",
            "example": "bc3f0d5a-3529-4d31-b2b4-848d14926bbc"
          },
          "status": {
            "type": "string",
            "description": "The status of the gift card redemption for the `payment_method`.",
            "example": "succeeded",
            "enum": [
              "created",
              "succeeded",
              "failed",
              "skipped"
            ]
          },
          "amount": {
            "type": "integer",
            "description": "The amount redeemed for this gift card.",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          },
          "refunded_amount": {
            "type": "integer",
            "description": "The amount refunded for this gift card. This can not be larger\nthan `amount`.",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          },
          "gift_card_service_redemption_id": {
            "type": "string",
            "description": "The gift card service's unique ID for the redemption.",
            "example": "xYqd43gySMtori",
            "nullable": true
          },
          "error_code": {
            "description": "If this gift card redemption resulted in an error, this will\ncontain the internal code for the error.",
            "example": "expired_card",
            "nullable": true,
            "type": "string",
            "enum": [
              "expired_card",
              "inactive_card",
              "incorrect_currency",
              "insufficient_funds",
              "invalid_amount",
              "invalid_gift_card",
              "invalid_service_configuration",
              "invalid_service_credentials",
              "operation_canceled",
              "service_error",
              "service_network_error",
              "unknown_error"
            ]
          },
          "raw_error_code": {
            "type": "string",
            "description": "If this gift card redemption resulted in an error, this will\ncontain the raw error code received from the gift card provider.",
            "example": "10001",
            "nullable": true
          },
          "raw_error_message": {
            "type": "string",
            "description": "If this gift card redemption resulted in an error, this will\ncontain the raw error message received from the gift card provider.",
            "example": "Card expired.",
            "nullable": true
          },
          "gift_card": {
            "$ref": "#/components/schemas/GiftCard--Snapshot"
          }
        }
      },
      "GiftCardRedemptionFailed": {
        "title": "Gift Cards Redemption - Failure",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to redeem gift cards, in case the call failed.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `gift-card-redemption-failed`.",
            "example": "gift-card-redemption-failed",
            "enum": [
              "gift-card-redemption-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "gift_card_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the Gift Card service used."
              },
              "gift_card_service_name": {
                "type": "string",
                "description": "The name of the Gift Card service used."
              },
              "gift_card_service_definition_id": {
                "type": "string",
                "description": "The Gift Card service definition used."
              },
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request, if performed."
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body sent to the Gift Card provider, if performed."
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body received from the Gift Card provider, if any."
              },
              "response_status_code": {
                "type": "number",
                "nullable": true,
                "description": "The HTTP response status code from the Gift Card provider, if any."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not redeem the gift cards.",
                "example": "Network Error"
              }
            }
          }
        }
      },
      "GiftCardRedemptionSucceeded": {
        "title": "Gift Cards Redemption - Succeeded",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to redeem gift cards, in case the call succeeded.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `gift-card-redemption-succeeded`.",
            "example": "gift-card-redemption-succeeded",
            "enum": [
              "gift-card-redemption-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "gift_card_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the Gift Card service used."
              },
              "gift_card_service_name": {
                "type": "string",
                "description": "The name of the Gift Card service used."
              },
              "gift_card_service_definition_id": {
                "type": "string",
                "description": "The Gift Card service definition used."
              },
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request."
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to the Gift Card provider."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the Gift Card provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the Gift Card provider."
              }
            }
          }
        }
      },
      "GiftCardRefundFailed": {
        "title": "Gift Cards Refund - Failed",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to refund gift cards, in case the call failed.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `gift-card-refund-failed`.",
            "example": "gift-card-refund-failed",
            "enum": [
              "gift-card-refund-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "gift_card_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the Gift Card service used."
              },
              "gift_card_service_name": {
                "type": "string",
                "description": "The name of the Gift Card service used."
              },
              "gift_card_service_definition_id": {
                "type": "string",
                "description": "The Gift Card service definition used."
              },
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request, if performed."
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body sent to the Gift Card provider, if performed."
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body received from the Gift Card provider, if any."
              },
              "response_status_code": {
                "type": "number",
                "nullable": true,
                "description": "The HTTP response status code from the Gift Card provider, if any."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not refund the gift cards.",
                "example": "Network Error"
              }
            }
          }
        }
      },
      "GiftCardRefundSucceeded": {
        "title": "Gift Cards Refund - Succeeded",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to refund gift cards, in case the call succeeded.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `gift-card-refund-succeeded`.",
            "example": "gift-card-refund-succeeded",
            "enum": [
              "gift-card-refund-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "gift_card_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the Gift Card service used."
              },
              "gift_card_service_name": {
                "type": "string",
                "description": "The name of the Gift Card service used."
              },
              "gift_card_service_definition_id": {
                "type": "string",
                "description": "The Gift Card service definition used."
              },
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request."
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to the Gift Card provider."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the Gift Card provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the Gift Card provider."
              }
            }
          }
        }
      },
      "GiftCardService": {
        "title": "A gift card service",
        "type": "object",
        "description": "An configured gift card service.",
        "x-tags": [
          "Gift Card Services"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card-service",
            "enum": [
              "gift-card-service"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this gift card service.",
            "example": "6c020bf3-179b-4f4f-858d-84e39e196e0f"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "gift_card_service_definition_id": {
            "type": "string",
            "description": "The ID of the gift card service definition used to create this service.\n",
            "example": "qwikcilver-gift-card",
            "minLength": 1,
            "maxLength": 50
          },
          "display_name": {
            "type": "string",
            "description": "The custom name set for this service.",
            "example": "Qwikcilver UK",
            "minLength": 1,
            "maxLength": 200
          },
          "active": {
            "type": "boolean",
            "example": true,
            "description": "Defines if this service is currently active or not."
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field\nconfigured for this gift card service. Fields marked as `secret`\nare not returned.",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 50,
                  "description": "The key of the field.",
                  "example": "secret_key"
                },
                "value": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 5000,
                  "description": "The value of the field.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd"
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this service was created."
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this service was last updated."
          }
        }
      },
      "GiftCardService--Snapshot": {
        "title": "Gift card service (Snapshot)",
        "type": "object",
        "description": "A snapshot of a gift card service used in a transaction.",
        "x-tags": [
          "Gift Card Services"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "gift-card-service",
            "enum": [
              "gift-card-service"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this gift card service.",
            "example": "6c020bf3-179b-4f4f-858d-84e39e196e0f"
          },
          "gift_card_service_definition_id": {
            "type": "string",
            "description": "The ID of the gift card service definition used to create this service.\n",
            "example": "qwikcilver-gift-card",
            "minLength": 1,
            "maxLength": 50
          },
          "display_name": {
            "type": "string",
            "description": "The custom name set for this service.",
            "example": "Qwikcilver UK",
            "minLength": 1,
            "maxLength": 200
          }
        }
      },
      "GiftCardServiceCreateRequest": {
        "title": "Gift Card Service (Create)",
        "type": "object",
        "description": "Request body for activating a gift card service.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "display_name",
          "gift_card_service_definition_id",
          "fields"
        ],
        "properties": {
          "gift_card_service_definition_id": {
            "type": "string",
            "description": "The ID of the gift card service to use.",
            "example": "qwikcilver-gift-card",
            "minLength": 1,
            "maxLength": 50
          },
          "display_name": {
            "type": "string",
            "description": "A custom name for the service. This will be shown in the Admin UI.",
            "example": "Qwikcilver UK",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined\nby the definition for this gift card service.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this gift card service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "pk_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          },
          "active": {
            "type": "boolean",
            "example": true,
            "default": true,
            "description": "Defines if this service is currently active or not."
          }
        }
      },
      "GiftCardServiceUpdateRequest": {
        "title": "Gift Card Service (Update)",
        "type": "object",
        "description": "Request body for updating a gift card service.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A custom name for the gift card service. This will be shown in the Admin UI.",
            "example": "Qwikcilver UK",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined\nby the definition for this gift card service.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this gift card service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set; you can unset optional fields by setting this to an empty string `\"\"`.",
                  "example": "pk_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          },
          "active": {
            "type": "boolean",
            "example": true,
            "description": "Defines if this service is currently active or not."
          }
        }
      },
      "GiftCardServiceVerifyRequest": {
        "title": "Gift Card Service (Verify)",
        "type": "object",
        "description": "Request body for verifying credentials against a gift card service.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "gift_card_service_definition_id",
          "fields"
        ],
        "properties": {
          "gift_card_service_definition_id": {
            "type": "string",
            "description": "The ID of the gift card service to use.",
            "example": "qwikcilver-gift-card",
            "minLength": 1,
            "maxLength": 50
          },
          "gift_card_service_id": {
            "type": "string",
            "format": "uuid",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "description": "The ID of the gift card service. Required if sending a partial set of\ncredentials in the `fields` property. This will merge the provided\nfields with those already on the service."
          },
          "fields": {
            "type": "array",
            "description": "A list of fields where each field is a key-value pair that represents a defined field in the definition of the service. You are not required to send the full list of fields if the credentials for the service are already stored.\nFor example, if your credentials for `qwikcilver-gift-card` are stored and you only provide a `secret_key` in the request, it will override the stored `secret_key` and verify the resulting set of credentials against the service.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "pk_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 1,
                  "maxLength": 5000
                }
              }
            }
          }
        }
      },
      "GiftCardServiceDefinition": {
        "title": "Gift Card Service Definition",
        "type": "object",
        "description": "An available gift card service that can be configured.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the gift card service definition.",
            "example": "qwikcilver-gift-card"
          },
          "type": {
            "type": "string",
            "description": "`gift-card-service-definition`.",
            "default": "gift-card-service-definition",
            "example": "gift-card-service-definition",
            "enum": [
              "gift-card-service-definition"
            ]
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this service.",
            "example": "Stripe"
          },
          "fields": {
            "type": "array",
            "description": "A list of fields that need to be submitted when activating the payment. service.",
            "minItems": 1,
            "items": {
              "type": "object",
              "description": "A single field that needs to be submitted for a payment service when it\nis created.",
              "properties": {
                "key": {
                  "type": "string",
                  "example": "private_api_key",
                  "description": "The key of a field that needs to be submitted."
                },
                "display_name": {
                  "type": "string",
                  "example": "Private API key",
                  "description": "The name to display for a field in the dashboard."
                },
                "required": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is required when the service is created."
                },
                "format": {
                  "type": "string",
                  "example": "text",
                  "description": "Defines the type of input that needs to be rendered for this field.",
                  "enum": [
                    "text",
                    "multiline",
                    "number"
                  ]
                },
                "secret": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is secret. When `true` the field is not\nreturned when querying the payment service."
                }
              }
            }
          },
          "icon_url": {
            "type": "string",
            "description": "An icon to display for the payment service.",
            "example": "https://cdn.gr4vy.app/stripe.svg"
          }
        }
      },
      "GiftCardStoreRequest": {
        "title": "Gift Card (Store)",
        "type": "object",
        "description": "The gift card details to store.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "number",
          "pin"
        ],
        "properties": {
          "number": {
            "type": "string",
            "minLength": 16,
            "maxLength": 19,
            "example": "4123455541234561234",
            "pattern": "^[0-9]{16,19}$",
            "description": "The 16-19 digit number for this gift card."
          },
          "pin": {
            "type": "string",
            "description": "The PIN for this gift card.",
            "example": "1234"
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to associate this gift card to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset."
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to associate this gift card\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.",
            "example": "user-789123"
          }
        }
      },
      "GooglePayRequest": {
        "title": "Google Pay payment method request",
        "type": "object",
        "description": "Details for a Google Pay payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "token"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`googlepay`.",
            "example": "googlepay",
            "enum": [
              "googlepay"
            ]
          },
          "token": {
            "type": "string",
            "description": "The encrypted (opaque) token returned by the Google Pay API that\nrepresents a payment method."
          },
          "card_suffix": {
            "type": "string",
            "description": "Last 4 digits of the PAN for identification purposes.",
            "example": "1234",
            "nullable": true
          },
          "card_scheme": {
            "type": "string",
            "description": "The scheme/brand of the card.",
            "nullable": true
          },
          "card_type": {
            "type": "string",
            "description": "The type of card.",
            "nullable": true,
            "example": "credit"
          },
          "assurance_details": {
            "type": "object",
            "description": "Information about the validation performed on the payment data. (See https://developers.google.com/pay/api/web/reference/response-objects#assurance-details-specifications).",
            "properties": {
              "account_verified": {
                "type": "boolean",
                "example": false,
                "description": "Indicates that card holder possession validation has been performed.",
                "nullable": true
              },
              "card_holder_authenticated": {
                "type": "boolean",
                "example": false,
                "description": "Indicates that identification and verifications was performed.",
                "nullable": true
              }
            },
            "nullable": true
          },
          "cardholder_name": {
            "type": "string",
            "description": "Name of the card holder.",
            "nullable": true
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "We strongly recommend providing a `redirect_url` either when 3-D\nSecure is enabled and `three_d_secure_data` is not provided, or when\nusing connections where 3DS is enabled. This value will be appended\nwith both a transaction ID and status\n(e.g. `https://example.com/callback?gr4vy_transaction_id=123\n&gr4vy_transaction_status=capture_succeeded`) after 3-D Secure has\ncompleted. For those cases, if the value is not present, the\ntransaction will be marked as failed.",
            "example": "https://example.com/callback",
            "nullable": true
          }
        }
      },
      "APIKeyPair": {
        "title": "API Key Pair",
        "type": "object",
        "description": "Details about an API key pair.",
        "x-internal": true,
        "x-tags": [
          "API Key Pairs"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`api-key-pair`.",
            "example": "api-key-pair",
            "enum": [
              "api-key-pair"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this key-pair.",
            "format": "uuid"
          },
          "display_name": {
            "type": "string",
            "description": "A name for this key-pair which is used in the Gr4vy admin panel to give the key-pair a human readable name.",
            "example": "Sandbox",
            "minLength": 1,
            "maxLength": 200
          },
          "algorithm": {
            "type": "string",
            "description": "The algorithm to use for the API Key Pair. The recommended value is `ECDSA`.\nYou should only use the `RSA` algorithm in environments that do not support\n`ECDSA`.",
            "example": "ECDSA",
            "enum": [
              "ECDSA",
              "RSA"
            ],
            "default": "ECDSA"
          },
          "thumbprint": {
            "type": "string",
            "maxLength": 43,
            "minLength": 43,
            "pattern": "^[A-Za-z0-9-_]+$",
            "description": "A unique ID for this key-pair. This ID is the thumbprint of the key.",
            "example": "SopiN5XU0IWy8Xe9mwx1ICQbKh4-ydCDPx3LIyArkVI"
          },
          "private_key": {
            "type": "string",
            "nullable": true,
            "description": "The private key for the key-pair. This is only returned after\nthe key is initially requested. For subsequent API calls this value is\n`null`.",
            "example": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this key pair was created."
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this key pair was last updated."
          },
          "creator": {
            "type": "object",
            "description": "The user who created the API Key Pair.",
            "nullable": true,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the user.",
                "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
              },
              "name": {
                "type": "string",
                "description": "The name of the user.",
                "example": "John L"
              },
              "email_address": {
                "type": "string",
                "description": "The email address for this user.",
                "example": "john@example.com",
                "nullable": true
              }
            }
          },
          "merchant_account": {
            "$ref": "#/components/schemas/MerchantAccount"
          }
        }
      },
      "APIKeyPairs": {
        "title": "A list of active API key pairs",
        "type": "object",
        "description": "A list of the currently active API key pairs.",
        "x-internal": true,
        "x-tags": [
          "API Key Pairs"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/APIKeyPair"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "GooglePaySessionRequest": {
        "title": "Google Pay session request",
        "type": "object",
        "description": "Initiates a new session with Google Pay.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "origin_domain"
        ],
        "properties": {
          "origin_domain": {
            "type": "string",
            "description": "Fully qualified domain name of the merchant."
          }
        }
      },
      "GooglePaySession": {
        "title": "Google Pay Session",
        "type": "object",
        "x-internal": true,
        "properties": {
          "gateway_merchant_id": {
            "type": "string",
            "description": "Your merchant ID.",
            "example": "app.gr4vy.sandbox.spider.default"
          },
          "token": {
            "type": "string",
            "description": "The JWT for the current Google Pay session.",
            "example": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJtZXJjaGFudElkIjoiQkNSMkRONFQ3QzNLWDZEWSIsIm1lcmNoYW50T3JpZ2luIjoiZW1iZWQuc2FuZGJveC5zcGlkZXIuZ3I0dnkuYXBwIiwiaWF0IjoxNjgzMjExMzk5fQ.Qk99p_j96aSxGmxUyyb06rNxIY7nh9-BvHJGWBrLBSFb3HkSbYRgq9YQzscWJtLHVvIJifkzSc8BgtllfAzh9A"
          }
        }
      },
      "HealthDashboardConnection": {
        "title": "Health Dashboard connection",
        "type": "object",
        "description": "Health Dashboard connection table data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "health-dashboard.connection",
            "enum": [
              "health-dashboard.connection"
            ]
          },
          "summary": {
            "type": "object",
            "description": "Summary of the aggregated payment service data.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the payment service.",
                "example": "50f2e61f-caac-4e12-8d79-30eaf8250423"
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition ID.",
                "example": "stripe-card"
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service.",
                "example": "Stripe UK"
              },
              "payment_service_is_active": {
                "type": "boolean",
                "description": "Indicates whether the payment service is currently active.",
                "example": true
              },
              "payment_service_is_deleted": {
                "type": "boolean",
                "description": "Indicates whether the payment service has been deleted.",
                "example": false
              },
              "transactions_authorized": {
                "type": "integer",
                "description": "The total number of transactions authorized by the payment\nservice during the current period.",
                "example": 290
              },
              "transactions_authorized_rate": {
                "type": "integer",
                "description": "The rate of transactions authorized by the payment service\nduring the current period.",
                "nullable": true,
                "example": 85
              },
              "transactions_authorized_rate_delta": {
                "type": "integer",
                "description": "The absolute difference between the rate of transactions authorized by\nthe payment service during the current period and the previous period.",
                "nullable": true,
                "example": 2
              },
              "transactions_declined": {
                "type": "integer",
                "description": "The total number of transactions declined by the payment\nservice during the current period.",
                "example": 30
              },
              "transactions_recovered": {
                "type": "integer",
                "description": "The total number of transactions recovered by the payment service\nduring the current period. A recovered transaction is a transaction\nthat has failed attempts before being successfully processed by\nthis payment service.",
                "example": 70
              }
            }
          }
        }
      },
      "HealthDashboardConnections": {
        "title": "Health Dashboard connections",
        "type": "object",
        "description": "Health Dashboard connections table data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of connection summaries.",
            "items": {
              "$ref": "#/components/schemas/HealthDashboardConnection"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "HealthDashboardConnectionVolume": {
        "title": "Health Dashboard connection volume",
        "type": "object",
        "description": "Health Dashboard connection volume table data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "health-dashboard.connection-volume",
            "enum": [
              "health-dashboard.connection-volume"
            ]
          },
          "summary": {
            "type": "object",
            "description": "Summary of the aggregated payment service volume data.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the payment service.",
                "example": "50f2e61f-caac-4e12-8d79-30eaf8250423"
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition ID.",
                "example": "stripe-card"
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service.",
                "example": "Stripe UK"
              },
              "payment_service_is_active": {
                "type": "boolean",
                "description": "Indicates whether the payment service is currently active.",
                "example": true
              },
              "payment_service_is_deleted": {
                "type": "boolean",
                "description": "Indicates whether the payment service has been deleted.",
                "example": false
              },
              "transactions_authorized": {
                "type": "integer",
                "description": "The total volume of transactions authorized by the payment\nservice during the current period.",
                "example": 3563
              },
              "transactions_authorized_rate": {
                "type": "integer",
                "description": "The rate of transactions authorized by the payment service\nduring the current period.",
                "nullable": true,
                "example": 85
              },
              "transactions_authorized_rate_delta": {
                "type": "integer",
                "description": "The absolute difference between the rate of transactions authorized by\nthe payment service during the current period and the previous period.",
                "nullable": true,
                "example": 2
              },
              "transactions_declined": {
                "type": "integer",
                "description": "The total volume of transactions declined by the payment\nservice during the current period.",
                "example": 172
              },
              "transactions_recovered": {
                "type": "integer",
                "description": "The total volume of transactions recovered by the payment service\nduring the current period. A recovered transaction is a transaction\nthat has failed attempts before being successfully processed by\nthis payment service.",
                "example": 703
              }
            }
          }
        }
      },
      "HealthDashboardConnectionsVolume": {
        "title": "Health Dashboard connections volume",
        "type": "object",
        "description": "Health Dashboard connections volume table data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of connection volume summaries.",
            "items": {
              "$ref": "#/components/schemas/HealthDashboardConnectionVolume"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "HealthDashboardStatus": {
        "title": "Health Dashboard status",
        "type": "object",
        "description": "Health Dashboard status summary.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "health-dashboard.status",
            "enum": [
              "health-dashboard.status"
            ]
          },
          "latest_execution": {
            "type": "object",
            "description": "Information about the latest execution to process data for the Health Dashboard. This value is null if the data has not been fully processed for the first time yet.",
            "nullable": true,
            "properties": {
              "timestamp": {
                "type": "string",
                "format": "date-time",
                "description": "The date and time when the data was last processed.",
                "example": "2023-07-26T19:23:00.000Z"
              }
            }
          },
          "currencies": {
            "type": "array",
            "description": "The list of currencies that were transacted within the last 60+ days in ISO 4217 currency code format. This value is null if the data has not been fully processed for the first time yet.",
            "nullable": true,
            "items": {
              "type": "string"
            },
            "example": [
              "USD",
              "GBP"
            ]
          }
        }
      },
      "HealthDashboardTotal": {
        "title": "Health Dashboard total",
        "type": "object",
        "description": "Health Dashboard transactions and refunds line chart data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "health-dashboard.total",
            "enum": [
              "health-dashboard.total"
            ]
          },
          "summary": {
            "type": "object",
            "description": "Summary of the aggregated data.",
            "properties": {
              "transactions_accepted": {
                "type": "integer",
                "description": "The total number of transactions created during the current period.",
                "example": 7890
              },
              "transactions_accepted_delta_pct": {
                "type": "integer",
                "description": "The percentage difference between the total number of transactions created during the current period and the previous period.",
                "nullable": true,
                "example": -5
              },
              "transactions_authorized_rate": {
                "type": "integer",
                "description": "The rate of authorized transactions created during the current period.",
                "nullable": true,
                "example": 89
              },
              "transactions_authorized_rate_delta": {
                "type": "integer",
                "description": "The absolute difference between the rate of authorized transactions created during the current period and the previous period.",
                "nullable": true,
                "example": 15
              },
              "refunds": {
                "type": "integer",
                "description": "The total number of successful refunds from all sources created during the current period.",
                "example": 590
              },
              "refunds_delta_pct": {
                "type": "integer",
                "description": "The percentage difference between the total number of successful refunds from all sources created during the current period and the previous period.",
                "nullable": true,
                "example": 7
              }
            }
          },
          "series": {
            "type": "object",
            "description": "Contains two series of data points used to build the line chart. Each series contains aggregations of data created over the duration of the specified period (e.g. `7-days`). The `previous` series contains aggregations from the period immediately preceding the `current` series.",
            "properties": {
              "current": {
                "type": "object",
                "description": "Metrics for the transactions and refunds created during the current period aggregated by hour or day.",
                "properties": {
                  "first_interval": {
                    "type": "string",
                    "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                    "example": "2024-05-07T00:00:00Z/P1D"
                  },
                  "transactions_accepted": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The total number of transactions created within the period that the data point corresponds to.",
                    "example": [
                      1919,
                      2194,
                      1920,
                      2184,
                      1328,
                      1868,
                      2001,
                      2082
                    ]
                  },
                  "transactions_authorized_rate": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "nullable": true
                    },
                    "description": "The rate of authorized transactions created within the period that the data point corresponds to.",
                    "example": [
                      66,
                      89,
                      75,
                      98,
                      100,
                      null,
                      95,
                      100
                    ]
                  },
                  "refunds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The total number of successful refunds created within the period that the data point corresponds to.",
                    "example": [
                      119,
                      294,
                      120,
                      184,
                      138,
                      168,
                      201,
                      182
                    ]
                  }
                }
              },
              "previous": {
                "type": "object",
                "description": "Metrics for the transactions and refunds created during the previous period aggregated by hour or day.",
                "properties": {
                  "first_interval": {
                    "type": "string",
                    "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                    "example": "2024-04-29T00:00:00Z/P1D"
                  },
                  "transactions_accepted": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The total number of transactions created within the period that the data point corresponds to.",
                    "example": [
                      1919,
                      2194,
                      1920,
                      2184,
                      1328,
                      1868,
                      2001,
                      2082
                    ]
                  },
                  "transactions_authorized_rate": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "nullable": true
                    },
                    "description": "The rate of authorized transactions created within the period that the data point corresponds to.",
                    "example": [
                      66,
                      89,
                      75,
                      98,
                      100,
                      null,
                      95,
                      100
                    ]
                  },
                  "refunds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The total number of successful refunds created within the period that the data point corresponds to.",
                    "example": [
                      119,
                      294,
                      120,
                      184,
                      138,
                      168,
                      201,
                      182
                    ]
                  }
                }
              }
            }
          }
        }
      },
      "HealthDashboardTotalVolume": {
        "title": "Health Dashboard total volume",
        "type": "object",
        "description": "Health Dashboard transactions and refunds volume line chart data.",
        "x-tags": [
          "Health Dashboard"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "health-dashboard.total-volume",
            "enum": [
              "health-dashboard.total-volume"
            ]
          },
          "summary": {
            "type": "object",
            "description": "Summary of the aggregated data.",
            "properties": {
              "transactions_authorized": {
                "type": "integer",
                "description": "The volume of authorized transactions created during the current period.",
                "example": 7890
              },
              "transactions_authorized_delta_pct": {
                "type": "integer",
                "description": "The percentage difference between the volume of authorized transactions created during the current period and the previous period.",
                "nullable": true,
                "example": -5
              },
              "transactions_authorized_rate": {
                "type": "integer",
                "description": "The rate of authorized transactions created during the current period.",
                "nullable": true,
                "example": 89
              },
              "transactions_authorized_rate_delta": {
                "type": "integer",
                "description": "The absolute difference between the rate of authorized transactions created during the current period and the previous period.",
                "nullable": true,
                "example": 15
              },
              "refunds": {
                "type": "integer",
                "description": "The volume of successful refunds from all sources created during the current period.",
                "example": 590
              },
              "refunds_delta_pct": {
                "type": "integer",
                "description": "The percentage difference between the volume of successful refunds created during the current period and the previous period.",
                "nullable": true,
                "example": 7
              }
            }
          },
          "series": {
            "type": "object",
            "description": "Contains two series of data points used to build the line chart. The `current` series contains aggregations starting from the `first_interval` up to the specified period (e.g. `7-days`). The `previous` series contains aggregations from the period immediately preceding the `current` series.",
            "properties": {
              "current": {
                "type": "object",
                "description": "Metrics for the transactions and refunds created during the current period aggregated by hour or day.",
                "properties": {
                  "first_interval": {
                    "type": "string",
                    "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                    "example": "2024-05-07T00:00:00Z/P1D"
                  },
                  "transactions_authorized": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The volume of authorized transactions created within the period that the data point corresponds to.",
                    "example": [
                      1919,
                      2194,
                      1920,
                      2184,
                      1328,
                      1868,
                      2001,
                      2082
                    ]
                  },
                  "transactions_authorized_rate": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "nullable": true
                    },
                    "description": "The rate of authorized transactions created within the period that the data point corresponds to.",
                    "nullable": true,
                    "example": [
                      66,
                      89,
                      75,
                      98,
                      100,
                      null,
                      95,
                      100
                    ]
                  },
                  "refunds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The volume of successful refunds created within the period that the data point corresponds to.",
                    "example": [
                      119,
                      294,
                      120,
                      184,
                      138,
                      168,
                      201,
                      182
                    ]
                  }
                }
              },
              "previous": {
                "type": "object",
                "description": "Metrics for the transactions and refunds created during the previous period aggregated by hour or day.",
                "properties": {
                  "first_interval": {
                    "type": "string",
                    "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                    "example": "2024-04-29T00:00:00Z/P1D"
                  },
                  "transactions_authorized": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The volume of authorized transactions created within the period that the data point corresponds to.",
                    "example": [
                      1919,
                      2194,
                      1920,
                      2184,
                      1328,
                      1868,
                      2001,
                      2082
                    ]
                  },
                  "transactions_authorized_rate": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "nullable": true
                    },
                    "description": "The rate of authorized transactions created within the period that the data point corresponds to.",
                    "nullable": true,
                    "example": [
                      66,
                      89,
                      75,
                      98,
                      100,
                      null,
                      95,
                      100
                    ]
                  },
                  "refunds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    },
                    "description": "The volume of successful refunds created within the period that the data point corresponds to.",
                    "example": [
                      119,
                      294,
                      120,
                      184,
                      138,
                      168,
                      201,
                      182
                    ]
                  }
                }
              }
            }
          }
        }
      },
      "IssueCryptogramRequest": {
        "title": "Issue cryptogram",
        "type": "object",
        "description": "Request body for issue a cryptogram for a network token.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "merchant_initiated"
        ],
        "properties": {
          "merchant_initiated": {
            "type": "boolean",
            "example": false,
            "default": false,
            "description": "Defines if the request is merchant initiated or not."
          }
        }
      },
      "Merchant": {
        "title": "Merchant",
        "type": "object",
        "x-tags": [
          "Merchant"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `merchant`.",
            "example": "merchant",
            "enum": [
              "merchant"
            ]
          },
          "name": {
            "type": "string",
            "example": "Merchant",
            "description": "The name of the merchant.",
            "maxLength": 255
          },
          "identification_number": {
            "type": "string",
            "maxLength": 200,
            "description": "Unique value which identifies a merchant for processing transactions, also known as a MID."
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the merchant which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890"
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "Merchant website URL."
          },
          "statement_descriptor": {
            "type": "string",
            "minLength": 5,
            "maxLength": 22,
            "description": "Value to explain charges or payments on bank statements."
          },
          "merchant_category_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4,
            "description": "Merchant classification for the type of goods or services it provides."
          },
          "address": {
            "type": "object",
            "description": "The address for the merchant.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          }
        }
      },
      "MerchantAccount": {
        "title": "Merchant Account",
        "type": "object",
        "x-tags": [
          "Merchant Account"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`merchant-account`.",
            "example": "merchant-account",
            "enum": [
              "merchant-account"
            ]
          },
          "id": {
            "type": "string",
            "description": "The ID for this merchant account.",
            "example": "plantly-uk"
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this merchant account.",
            "example": "Plantly UK"
          },
          "outbound_webhook_url": {
            "type": "string",
            "format": "uri",
            "description": "The optional URL where webhooks will be received.",
            "example": "https://www.example.com/webhook",
            "nullable": true
          },
          "outbound_webhook_username": {
            "type": "string",
            "description": "The optional username to use when `outbound_webhook_url` is configured and\nrequires basic authentication.",
            "example": "gr4vy",
            "nullable": true
          },
          "outbound_webhook_password": {
            "type": "string",
            "description": "The optional password to use when `outbound_webhook_url` is configured and\nrequires basic authentication.\n\nIf the field is not `null`, the value is masked to avoid exposing sensitive information.",
            "example": "********",
            "nullable": true
          },
          "visa_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Visa after onboarding to use Network Tokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "visa_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Visa after onboarding to use Network\nTokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "amex_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Amex after onboarding to use Network Tokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "amex_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Amex after onboarding to use Network Tokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "mastercard_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Mastercard after onboarding to use Network\nTokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "mastercard_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Mastercard after onboarding to use\nNetwork Tokens.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true
          },
          "loon_client_key": {
            "type": "string",
            "nullable": true,
            "description": "Client key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.",
            "example": "7DD771287D0024BA418F8F7ECC7DF1CD"
          },
          "loon_secret_key": {
            "type": "string",
            "nullable": true,
            "description": "Secret key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.\n\nIf the field is not `null`, the value is masked to avoid exposing sensitive information.",
            "example": "********"
          },
          "loon_accepted_schemes": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "nullable": true,
            "description": "Card schemes accepted when creating jobs using this set of Loon API keys.\nLoon is the Account Updater service used by Gr4vy.",
            "example": [
              "mastercard",
              "visa"
            ]
          },
          "account_updater_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "description": "Whether the Realtime Account Updater service is enabled for this merchant account.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `false`, the Account Updater service\ndoesn't get called if a payment fails with expired or invalid card details.\n* If the field is set to `true`, the service is called. Please note that for this to work\nthe other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key",
            "description": "The public key used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key-id",
            "description": "The public key ID used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key",
            "description": "The private key used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key-id",
            "description": "The private key ID used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this merchant account was created.",
            "format": "date-time",
            "example": "2022-02-01T14:20:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this merchant account was updated.",
            "format": "date-time",
            "example": "2022-02-01T14:20:00.000+00:00"
          },
          "over_capture_amount": {
            "type": "number",
            "example": 1000,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum monetary amount allowed for over-capture, in the smallest\ncurrency unit, for example `1299` cents to allow for an over-capture of `$12.99`."
          },
          "over_capture_percentage": {
            "type": "number",
            "example": 20,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum percentage allowed for over-capture, for example `25` to allow for an\nover-capture of 25% of the original transaction amount."
          }
        }
      },
      "MerchantAccounts": {
        "title": "Merchant Accounts",
        "type": "object",
        "x-tags": [
          "Merchant Accounts"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of merchant accounts.",
            "items": {
              "$ref": "#/components/schemas/MerchantAccount"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "MerchantAccountCreate": {
        "title": "Merchant Account (Create)",
        "type": "object",
        "description": "A request to create a merchant account.",
        "x-tags": [
          "Merchant Accounts"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique ID for the merchant account.",
            "example": "plantly-uk",
            "nullable": false,
            "minLength": 1,
            "maxLength": 22
          },
          "display_name": {
            "type": "string",
            "description": "The human-readable name of the merchant account.",
            "example": "Plantly UK",
            "nullable": false,
            "minLength": 1,
            "maxLength": 255
          },
          "outbound_webhook_url": {
            "type": "string",
            "description": "The optional URL where webhooks will be received.",
            "example": "https://www.example.com/webhook",
            "nullable": true
          },
          "outbound_webhook_username": {
            "type": "string",
            "description": "The optional username to use when `outbound_webhook_url` is configured and\nrequires basic authentication.",
            "example": "gr4vy",
            "nullable": true
          },
          "outbound_webhook_password": {
            "type": "string",
            "description": "The optional password to use when `outbound_webhook_url` is configured and\nrequires basic authentication.",
            "example": "super-secret-password",
            "nullable": true
          },
          "visa_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Visa after onboarding to use Network Tokens.\nThe requestor ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "visa_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Visa after onboarding to use Network\nTokens. The application ID must be unique across all schemes and merchant\naccounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "amex_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Amex after onboarding to use Network Tokens.\nThe requestor ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "amex_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Amex after onboarding to use Network Tokens. The application ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "mastercard_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Mastercard after onboarding to use Network\nTokens. The requestor ID must be unique across all schemes and merchant\naccounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "mastercard_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Mastercard after onboarding to use\nNetwork Tokens. The application ID must be unique across all schemes and\nmerchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "loon_client_key": {
            "type": "string",
            "nullable": true,
            "minLength": 1,
            "description": "Client key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get configured.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "loon_secret_key": {
            "type": "string",
            "nullable": true,
            "minLength": 1,
            "description": "Secret key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get configured.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "loon_accepted_schemes": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "nullable": true,
            "description": "Card schemes accepted when creating jobs using this set of Loon API keys.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get configured.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "over_capture_amount": {
            "type": "number",
            "example": 1000,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum monetary amount allowed for over-capture, in the smallest\ncurrency unit, for example `1299` cents to allow for an over-capture of `$12.99`."
          },
          "over_capture_percentage": {
            "type": "number",
            "example": 20,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum percentage allowed for over-capture, for example `25` to allow for an\nover-capture of 25% of the original transaction amount."
          },
          "account_updater_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "description": "Whether the Realtime Account Updater service is enabled for this merchant account.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `false`, the Account Updater service\ndoesn't get called if a payment fails with expired or invalid card details.\n* If the field is set to `true`, the service is called. Please note that for this to work\nthe other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key",
            "description": "The public key used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key-id",
            "description": "The public key ID used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key",
            "description": "The private key used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key-id",
            "description": "The private key ID used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          }
        }
      },
      "MerchantAccountUpdate": {
        "title": "Merchant Account (Update)",
        "type": "object",
        "description": "A request to update a merchant account.",
        "x-tags": [
          "Merchant Accounts"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "The human-readable name of the merchant account.",
            "example": "Plantly UK",
            "nullable": false,
            "minLength": 1,
            "maxLength": 255
          },
          "outbound_webhook_url": {
            "type": "string",
            "description": "The optional URL where webhooks will be received.",
            "example": "https://www.example.com/webhook",
            "nullable": true
          },
          "outbound_webhook_username": {
            "type": "string",
            "description": "The optional username to use when `outbound_webhook_url` is configured and\nrequires basic authentication.",
            "example": "gr4vy",
            "nullable": true
          },
          "outbound_webhook_password": {
            "type": "string",
            "description": "The optional password to use when `outbound_webhook_url` is configured and\nrequires basic authentication.",
            "example": "super-secret-password",
            "nullable": true
          },
          "visa_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Visa after onboarding to use Network Tokens.\nThe requestor ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "visa_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Visa after onboarding to use Network\nTokens. The application ID must be unique across all schemes and merchant\naccounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "amex_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Amex after onboarding to use Network Tokens.\nThe requestor ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "amex_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Amex after onboarding to use Network Tokens. The application ID must be unique across all schemes and merchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "mastercard_network_tokens_requestor_id": {
            "type": "string",
            "description": "Requestor ID provided for Mastercard after onboarding to use Network\nTokens. The requestor ID must be unique across all schemes and merchant\naccounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "mastercard_network_tokens_app_id": {
            "type": "string",
            "description": "Application ID provided for Mastercard after onboarding to use\nNetwork Tokens. The application ID must be unique across all schemes and\nmerchant accounts.",
            "example": "e50fa0da-903d-4d54-aacc-4cac57d48df2",
            "nullable": true,
            "maxLength": 300
          },
          "loon_client_key": {
            "type": "string",
            "nullable": true,
            "minLength": 1,
            "description": "Client key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set, the Account Updater service configuration is not updated.\n* If the field is set to `null`, the Account Updater service is disabled.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "loon_secret_key": {
            "type": "string",
            "nullable": true,
            "minLength": 1,
            "description": "Secret key provided by Pagos to authenticate to the Loon API.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set, the Account Updater service configuration is not updated.\n* If the field is set to `null`, the Account Updater service is disabled.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "loon_accepted_schemes": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "nullable": true,
            "description": "Card schemes accepted when creating jobs using this set of Loon API keys.\nLoon is the Account Updater service used by Gr4vy.\n\n* If the field is not set, the Account Updater service configuration is not updated.\n* If the field is set to `null`, the Account Updater service is disabled.\n* If the field is set to `null`, the other `loon_*` fields must be set to `null` as well."
          },
          "over_capture_amount": {
            "type": "number",
            "example": 1000,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum monetary amount allowed for over-capture, in the smallest\ncurrency unit, for example `1299` cents to allow for an over-capture of `$12.99`."
          },
          "over_capture_percentage": {
            "type": "number",
            "example": 20,
            "minimum": 1,
            "maximum": 99999999,
            "nullable": true,
            "description": "The maximum percentage allowed for over-capture, for example `25` to allow for an\nover-capture of 25% of the original transaction amount."
          },
          "account_updater_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "description": "Whether the Realtime Account Updater service is enabled for this merchant account.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `false`, the Account Updater service\ndoesn't get called if a payment fails with expired or invalid card details.\n* If the field is set to `true`, the service is called. Please note that for this to work\nthe other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key",
            "description": "The public key used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_request_encryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-encryption-key-id",
            "description": "The public key ID used to encrypt the request to the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key",
            "description": "The private key used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          },
          "account_updater_response_decryption_key_id": {
            "type": "string",
            "nullable": true,
            "example": "example-decryption-key-id",
            "description": "The private key ID used to decrypt the response from the Realtime Account Updater service.\nThe Account Updater service is used to update card details when cards are\nlost, stolen or expired.\n\n* If the field is not set or if it's set to `null`, the Account Updater service doesn't get called.\n* If the field is set, the other `account_updater_*` fields must be set as well."
          }
        }
      },
      "MerchantProfileScheme": {
        "title": "Merchant Profile (single scheme)",
        "type": "object",
        "description": "Merchant profile for a specific scheme.",
        "properties": {
          "merchant_acquirer_bin": {
            "type": "string",
            "maxLength": 11,
            "description": "Acquirer bin to use when calling 3DS through this scheme."
          },
          "merchant_url": {
            "type": "string",
            "description": "URL to send when calling 3DS through this scheme."
          },
          "merchant_acquirer_id": {
            "type": "string",
            "maxLength": 35,
            "description": "Merchant ID to use when calling 3DS through this scheme."
          },
          "merchant_name": {
            "type": "string",
            "maxLength": 40,
            "description": "Merchant name to use when calling 3DS through this scheme."
          },
          "merchant_country_code": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "Merchant country code to use when calling 3DS through this scheme."
          },
          "merchant_category_code": {
            "type": "string",
            "maxLength": 4,
            "description": "Merchant category code to use when calling 3DS through this scheme."
          }
        }
      },
      "MerchantProfileSchemeSummary": {
        "title": "Merchant Profile (single scheme)",
        "type": "object",
        "description": "Merchant profile for a specific scheme.",
        "properties": {
          "merchant_acquirer_bin": {
            "type": "string",
            "maxLength": 11,
            "description": "Acquirer bin to use when calling 3DS through this scheme."
          },
          "merchant_url": {
            "type": "string",
            "description": "URL to send when calling 3DS through this scheme."
          },
          "merchant_acquirer_id": {
            "type": "string",
            "maxLength": 35,
            "description": "Merchant ID to use when calling 3DS through this scheme."
          },
          "merchant_name": {
            "type": "string",
            "maxLength": 40,
            "description": "Merchant name to use when calling 3DS through this scheme."
          },
          "merchant_country_code": {
            "type": "string",
            "minLength": 3,
            "maxLength": 3,
            "description": "Merchant country code to use when calling 3DS through this scheme."
          },
          "merchant_category_code": {
            "type": "string",
            "maxLength": 4,
            "description": "Merchant category code to use when calling 3DS through this scheme."
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this profile was created.",
            "format": "date-time",
            "example": "2023-07-26T19:23:00.000+00:00"
          }
        }
      },
      "MerchantProfile": {
        "title": "Merchant Profile",
        "type": "object",
        "description": "Merchant profile for the different card schemes.",
        "properties": {
          "amex": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Amex.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "dankort": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Dankort.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "discover": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Discover.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "jcb": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for JCB.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "mastercard": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Mastercard.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "unionpay": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for UnionPay.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          },
          "visa": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Visa.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileScheme"
              }
            ]
          }
        }
      },
      "MerchantProfileSummary": {
        "title": "Merchant Profile",
        "type": "object",
        "description": "Merchant profile for the different card schemes.",
        "properties": {
          "amex": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Amex.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "dankort": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Dankort.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "discover": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Discover.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "jcb": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for JCB.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "mastercard": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Mastercard.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "unionpay": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for UnionPay.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          },
          "visa": {
            "type": "object",
            "nullable": true,
            "description": "Merchant profile for Visa.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSchemeSummary"
              }
            ]
          }
        }
      },
      "MerchantRequest": {
        "title": "Merchant",
        "type": "object",
        "description": "Details of the merchant.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "name",
          "identification_number",
          "phone_number",
          "url",
          "statement_descriptor",
          "merchant_category_code"
        ],
        "properties": {
          "name": {
            "type": "string",
            "example": "Merchant",
            "description": "The name of the merchant.",
            "maxLength": 255
          },
          "identification_number": {
            "type": "string",
            "maxLength": 200,
            "description": "Unique value which identifies a merchant for processing transactions, also known as a MID."
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the merchant which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890"
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "Merchant website URL."
          },
          "statement_descriptor": {
            "type": "string",
            "minLength": 5,
            "maxLength": 22,
            "description": "Value to explain charges or payments on bank statements."
          },
          "merchant_category_code": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4,
            "description": "Merchant classification for the type of goods or services it provides."
          },
          "address": {
            "type": "object",
            "description": "The address for the merchant.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          }
        }
      },
      "MetricsExplorerModule": {
        "title": "Metrics Explorer Module",
        "type": "object",
        "description": "Data for a module in the Metrics Explorer.",
        "x-tags": [
          "Metrics Explorer"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "enum": [
              "metrics-explorer.module"
            ],
            "example": "metrics-explorer.module"
          },
          "key": {
            "type": "string",
            "description": "The key for the module data entry. <br/>This key is the value that should be used as a filter when calling the endpoints. For example, for module `payment_service`, the key will be the id of the payment service (UUID), so it should be used to filter other modules using the `payment_service_id` filter.",
            "example": "d8c3d939-d75d-4598-81c7-a13f8238e624"
          },
          "display_name": {
            "type": "string",
            "description": "The display name for the module data entry.",
            "example": "Stripe (US)"
          },
          "value": {
            "description": "The value associated with the key. The type depends on the metric.",
            "nullable": true,
            "oneOf": [
              {
                "type": "integer",
                "description": "This type is used for \"volume\" and \"transactions\" metrics.",
                "example": 100
              },
              {
                "type": "number",
                "description": "This type is used for \"authorization rate\" metric.",
                "format": "decimal",
                "example": 0.5
              }
            ],
            "example": 100
          },
          "metadata": {
            "type": "object",
            "description": "A dictionary containing metadata as key-value pairs.",
            "nullable": true,
            "additionalProperties": {
              "type": "string"
            },
            "example": {
              "payment_service_definition_id": "stripe-card"
            }
          }
        }
      },
      "MetricsExplorerTotals": {
        "title": "Metrics Explorer Totals",
        "type": "object",
        "description": "Data for totals in the Metrics Explorer.",
        "x-tags": [
          "Metrics Explorer"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "metrics-explorer.totals",
            "enum": [
              "metrics-explorer.totals"
            ]
          },
          "series": {
            "type": "object",
            "description": "Contains two series of data points used to build the line chart. Each series contains aggregations of data created over the duration of the specified period (e.g. `7-days`). The `previous` series contains aggregations from the period immediately preceding the `current` series.",
            "properties": {
              "current": {
                "type": "array",
                "description": "Metrics for the transactions created during the current period aggregated by hour or day. The meaning of the values depends on the metric used to call the endpoint. \"volume\" and \"transactions\" metrics are represented as integers, while \"authorization rate\" metric is represented as decimal numbers. `null`s may be returned when there is no data for authorization rate to indicate that the metric is not applicable for the given time period.",
                "items": {
                  "type": "object",
                  "properties": {
                    "first_interval": {
                      "type": "string",
                      "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                      "example": "2025-03-25T00:00:00Z/P1D"
                    },
                    "values": {
                      "type": "array",
                      "description": "The values associated with the metric for the current period. \"volume\" and \"transactions\" metrics are represented as integers, while \"authorization rate\" metric is represented as decimal numbers.",
                      "items": {
                        "oneOf": [
                          {
                            "type": "integer",
                            "nullable": true,
                            "description": "The values associated with the metric. This type is used for \"volume\" and \"transactions\" metrics.",
                            "example": 10
                          },
                          {
                            "type": "number",
                            "format": "decimal",
                            "nullable": true,
                            "description": "The value associated with the key. This type is used for \"authorization rate\" metric.",
                            "example": 0.5
                          }
                        ]
                      },
                      "example": [
                        0.9,
                        0.99,
                        0.85
                      ]
                    }
                  }
                }
              },
              "previous": {
                "type": "array",
                "nullable": true,
                "description": "Metrics for the transactions created during the period immediately preceding the current period aggregated by hour or day. The meaning of the values depends on the metric used to call the endpoint. \"volume\" and \"transactions\" metrics are represented as integers, while \"authorization rate\" metric is represented as decimal numbers. `null`s may be returned when there is no data for authorization rate to indicate that the metric is not applicable for the given time period.",
                "items": {
                  "type": "object",
                  "properties": {
                    "first_interval": {
                      "type": "string",
                      "description": "The date and time of the first data point, represented with an ISO 8601 interval value indicating whether it is aggregated by one hour (PT1H) or one day (P1D) periods.",
                      "example": "2025-03-25T00:00:00Z/P1D"
                    },
                    "values": {
                      "type": "array",
                      "description": "The values associated with the metric for the previous period. \"volume\" and \"transactions\" metrics are represented as integers, while \"authorization rate\" metric is represented as decimal numbers.",
                      "items": {
                        "oneOf": [
                          {
                            "type": "integer",
                            "nullable": true,
                            "description": "The value associated with the key. This type is used for \"volume\" and \"transactions\" metrics.",
                            "example": 10
                          },
                          {
                            "type": "number",
                            "nullable": true,
                            "description": "The value associated with the key. This type is used for \"authorization rate\" metric.",
                            "format": "decimal",
                            "example": 0.5
                          }
                        ]
                      },
                      "example": [
                        0.9,
                        0.99,
                        0.85
                      ]
                    }
                  }
                }
              }
            },
            "example": {
              "current": [
                {
                  "first_interval": "2025-03-25T00:00:00Z/PT1H",
                  "values": [
                    0.9,
                    0.99,
                    0.85
                  ]
                }
              ],
              "previous": [
                {
                  "first_interval": "2025-03-18T00:00:00Z/PT1H",
                  "values": [
                    0.9,
                    0.99,
                    0.85
                  ]
                }
              ]
            }
          },
          "summary": {
            "type": "object",
            "description": "A summary of the totals data.",
            "properties": {
              "current": {
                "type": "object",
                "description": "The total value for the current period. <br/>For `volume` and `transactions` metrics, the value is the sum of all values in the `current` series. <br/>For `auth_rate` metric, the value is the count of authorized transactions over the count of processed transactions for the current period.",
                "properties": {
                  "value": {
                    "oneOf": [
                      {
                        "type": "integer",
                        "nullable": true,
                        "description": "This type is used for \"volume\" and \"transactions\" metrics."
                      },
                      {
                        "type": "number",
                        "nullable": true,
                        "description": "This type is used for \"authorization rate\" metric.",
                        "format": "decimal"
                      }
                    ]
                  }
                }
              },
              "previous": {
                "type": "object",
                "nullable": true,
                "description": "The total value for the previous period. <br/>For `volume` and `transactions` metrics, the value is the sum of all values in the `previous` series. <br/>For `auth_rate` metric, the value is the count of authorized transactions over the count of processed transactions for the previous period.",
                "properties": {
                  "value": {
                    "oneOf": [
                      {
                        "type": "integer",
                        "nullable": true,
                        "description": "This type is used for \"volume\" and \"transactions\" metrics."
                      },
                      {
                        "type": "number",
                        "nullable": true,
                        "description": "This type is used for \"authorization rate\" metric.",
                        "format": "decimal"
                      }
                    ]
                  }
                }
              },
              "delta": {
                "type": "number",
                "description": "The difference between the current and previous values. Positive values indicate an increase, while negative values indicate a decrease. <br/>For `volume` and `transactions` metrics, the value is the percentage change between the current and previous values, however, for `authorization rate` metric, the value is the absolute difference between the current and previous values.",
                "format": "decimal",
                "nullable": true,
                "example": 0.5
              }
            },
            "example": {
              "current": {
                "value": 90.5
              },
              "previous": {
                "value": 80.5
              },
              "delta": 10
            }
          }
        }
      },
      "NetworkToken": {
        "title": "Network Token",
        "type": "object",
        "description": "A network token generated by an open-loop PSP.",
        "x-tags": [
          "Tokens"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "network-token",
            "enum": [
              "network-token"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the token.",
            "format": "uuid",
            "example": "d6ad71d5-6908-45d6-ab65-39c55475dd08"
          },
          "payment_method_id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "9bdc4bc4-005e-4658-8eee-a309fc43cd4d"
          },
          "status": {
            "type": "string",
            "description": "The state of the network token.\n\n- `active` - The network token is active and ready to be used.\n- `inactive` - The network token is being deactivated.\n- `suspended` - The network token is suspended.\n- `deleted` - The network token is deleted.",
            "example": "active",
            "enum": [
              "active",
              "inactive",
              "suspended",
              "deleted"
            ]
          },
          "token": {
            "type": "string",
            "description": "The value of the network token."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date for the network token.",
            "example": "01/30",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5,
            "nullable": true
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this network token was first created in our\nsystem.",
            "format": "date-time",
            "example": "2021-01-01T12:34:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this network token was last updated in our system.",
            "format": "date-time",
            "example": "2021-01-01T12:34:00.000+00:00"
          }
        }
      },
      "NetworkTokenRequest": {
        "title": "Network Token (Provision)",
        "type": "object",
        "description": "Request body for provision a network token.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "merchant_initiated",
          "is_subsequent_payment"
        ],
        "properties": {
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          },
          "merchant_initiated": {
            "type": "boolean",
            "example": false,
            "description": "Defines if the request is merchant initiated or not."
          },
          "is_subsequent_payment": {
            "type": "boolean",
            "example": true,
            "description": "Defines if the request is a subsequent of another request or not."
          }
        }
      },
      "NetworkTokens": {
        "title": "Network Tokens",
        "type": "object",
        "description": "A list of network tokens.",
        "x-tags": [
          "Tokens"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of network tokens.",
            "items": {
              "$ref": "#/components/schemas/NetworkToken"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "NetworkTokenCryptogramProvisionFailed": {
        "title": "Network Token Cryptogram Provision - Failure",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to provision a cryptogram for a network token, in case the call failed.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `network-token-cryptogram-provision-failed`.",
            "example": "network-token-cryptogram-provision-failed",
            "enum": [
              "network-token-cryptogram-provision-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request, if performed."
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body sent to the Network Token provider, if performed."
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body received from the Network Token provider, if any."
              },
              "response_status_code": {
                "type": "number",
                "nullable": true,
                "description": "The HTTP response status code from the Network Token provider, if any."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not provision the cryptogram.",
                "example": "Network Error"
              }
            }
          }
        }
      },
      "NetworkTokenCryptogramProvisionSucceeded": {
        "title": "Network Token Cryptogram Provision - Succeeded",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to provision a cryptogram for a network token, in case the call succeeded.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `network-token-cryptogram-provision-succeeded`.",
            "example": "network-token-cryptogram-provision-succeeded",
            "enum": [
              "network-token-cryptogram-provision-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The endpoint for the request."
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to the Network Token provider."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the Network Token provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the Network Token provider."
              }
            }
          }
        }
      },
      "NetworkTokenProvisionFailed": {
        "title": "Network Token Provision - Failure",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to provision a network token, in case the call failed.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `network-token-provision-failed`.",
            "example": "network-token-provision-failed",
            "enum": [
              "network-token-provision-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request, if performed."
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body sent to the Network Token provider, if performed."
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP body received from the Network Token provider, if any."
              },
              "response_status_code": {
                "type": "number",
                "nullable": true,
                "description": "The HTTP response status code from the Network Token provider, if any."
              },
              "reason": {
                "type": "string",
                "description": "The reason we could not provision the network token.",
                "example": "Network Error"
              }
            }
          }
        }
      },
      "NetworkTokenProvisionSucceeded": {
        "title": "Network Token Provision - Succeeded",
        "type": "object",
        "description": "This event logs the request and response details of HTTP calls made to provision a network token, in case the call succeeded.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `network-token-provision-succeeded`.",
            "example": "network-token-provision-succeeded",
            "enum": [
              "network-token-provision-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The endpoint for the request."
              },
              "request": {
                "type": "string",
                "description": "The HTTP body sent to the Network Token provider."
              },
              "response": {
                "type": "string",
                "description": "The HTTP body received from the Network Token provider."
              },
              "response_status_code": {
                "type": "number",
                "description": "The HTTP response status code from the Network Token provider."
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionAuthorizationSucceededEvent": {
        "title": "Authorization",
        "type": "object",
        "description": "This event logs the exact details parsed details for a succeeded authorization\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-authorization-succeeded`.",
            "example": "payment-connector-response-transaction-authorization-succeeded",
            "enum": [
              "payment-connector-response-transaction-authorization-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "status": {
                "type": "string",
                "enum": [
                  "authorization_succeeded"
                ],
                "description": "The new status code for the transaction. This is always\nset to `authorization_succeeded`.",
                "example": "authorization_succeeded"
              },
              "instrument_type": {
                "type": "string",
                "example": "pan",
                "enum": [
                  "pan",
                  "card_token",
                  "redirect",
                  "redirect_token",
                  "googlepay",
                  "applepay",
                  "network_token"
                ],
                "description": "The type of instrument used for this transaction."
              },
              "retry_rule": {
                "type": "string",
                "description": "This will always be `null` because the transaction succeeded.",
                "example": null,
                "nullable": true,
                "deprecated": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionAuthorizationFailedEvent": {
        "title": "Authorization - Failed",
        "type": "object",
        "description": "This event logs the exact details parsed details for a failed authorization\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-authorization-failed`.",
            "example": "payment-connector-response-transaction-authorization-failed",
            "enum": [
              "payment-connector-response-transaction-authorization-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "status": {
                "type": "string",
                "enum": [
                  "authorization_failed"
                ],
                "description": "The new status code for the transaction. This is always\nset to `authorization_failed`.",
                "example": "authorization_failed"
              },
              "code": {
                "type": "string",
                "description": "A raw response code returned for the failure.",
                "example": "INVALID DATA",
                "nullable": true
              },
              "instrument_type": {
                "type": "string",
                "example": "pan",
                "enum": [
                  "pan",
                  "card_token",
                  "redirect",
                  "redirect_token",
                  "googlepay",
                  "applepay",
                  "network_token"
                ],
                "description": "The type of instrument used for this transaction."
              },
              "retry_rule": {
                "type": "string",
                "description": "Defines why the transaction might be retried. A retry is not guaranteed because\nthe maximum number of retries might already have been attempted.\n\n* `failure` - the transaction will be retried because of a failure calling\n  the payment service.\n* `retriable_decline` - the transaction will be retried because a decline code\n  was received that can be retried.\n* `payment_method_replacement` - the transaction will be retried because a\n  decline code was received that triggered a payment method replacement.",
                "enum": [
                  "failure",
                  "retriable_decline",
                  "payment_method_replacement"
                ],
                "example": "failure",
                "nullable": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionDeclinedEvent": {
        "title": "Authorization - Declined",
        "type": "object",
        "description": "This event logs the exact details parsed details for a declined transaction\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-declined`.",
            "example": "payment-connector-response-transaction-declined",
            "enum": [
              "payment-connector-response-transaction-declined"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "status": {
                "type": "string",
                "enum": [
                  "authorization_declined"
                ],
                "description": "The new status code for the transaction. This is always\nset to `authorization_declined`.",
                "example": "authorization_declined"
              },
              "code": {
                "type": "string",
                "description": "A raw response code returned for the decline.",
                "example": "INVALID DATA",
                "nullable": true
              },
              "instrument_type": {
                "type": "string",
                "example": "pan",
                "enum": [
                  "pan",
                  "card_token",
                  "redirect",
                  "redirect_token",
                  "googlepay",
                  "applepay",
                  "network_token"
                ],
                "description": "The type of instrument used for this transaction."
              },
              "retry_rule": {
                "type": "string",
                "description": "Defines why the transaction might be retried. A retry is not guaranteed because\nthe maximum number of retries might already have been attempted.\n\n* `failure` - the transaction will be retried because of a failure calling\n  the payment service.\n* `retriable_decline` - the transaction will be retried because a decline code\n  was received that can be retried.\n* `payment_method_replacement` - the transaction will be retried because a\n  decline code was received that triggered a payment method replacement.",
                "enum": [
                  "failure",
                  "retriable_decline",
                  "payment_method_replacement"
                ],
                "example": "failure",
                "nullable": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionCaptureSucceededEvent": {
        "title": "Capture - Succeeded",
        "type": "object",
        "description": "This event logs the exact details parsed details for a succeeded capture\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-capture-succeeded`.",
            "example": "payment-connector-response-transaction-capture-succeeded",
            "enum": [
              "payment-connector-response-transaction-capture-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "status": {
                "type": "string",
                "enum": [
                  "capture_succeeded"
                ],
                "description": "The new status code for the transaction. This is always\nset to `capture_succeeded`.",
                "example": "capture_succeeded"
              },
              "instrument_type": {
                "type": "string",
                "example": "pan",
                "enum": [
                  "pan",
                  "card_token",
                  "redirect",
                  "redirect_token",
                  "googlepay",
                  "applepay",
                  "network_token"
                ],
                "description": "The type of instrument used for this transaction.",
                "nullable": true
              },
              "retry_rule": {
                "type": "string",
                "description": "This will always be `null` because the transaction succeeded.",
                "example": null,
                "nullable": true,
                "deprecated": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionCaptureDeclinedEvent": {
        "title": "Capture - Declined",
        "type": "object",
        "description": "This event logs the exact details parsed details for a declined capture\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-capture-declined`.",
            "example": "payment-connector-response-transaction-capture-declined",
            "enum": [
              "payment-connector-response-transaction-capture-declined"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "code": {
                "type": "string",
                "description": "A raw response code returned for the failure.",
                "example": "INVALID DATA",
                "nullable": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionCaptureFailedEvent": {
        "title": "Capture - Failed",
        "type": "object",
        "description": "This event logs the exact details parsed details for a failed capture\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-capture-failed`.",
            "example": "payment-connector-response-transaction-capture-failed",
            "enum": [
              "payment-connector-response-transaction-capture-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "code": {
                "type": "string",
                "description": "A raw response code returned for the failure.",
                "example": "INVALID DATA",
                "nullable": true
              },
              "raw_response_code": {
                "type": "string",
                "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "incorrect-zip",
                "nullable": true
              },
              "raw_response_description": {
                "type": "string",
                "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
                "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
                "nullable": true
              },
              "auth_response_code": {
                "description": "This is the response description received from the processor.",
                "example": "00",
                "nullable": true,
                "type": "string"
              },
              "avs_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "partial_match_address",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "partial_match_address",
                  "partial_match_postcode",
                  "unavailable"
                ]
              },
              "cvv_response_code": {
                "type": "string",
                "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
                "example": "match",
                "nullable": true,
                "enum": [
                  "no_match",
                  "match",
                  "unavailable"
                ]
              },
              "payment_method_scheme": {
                "nullable": true,
                "description": "The card scheme sent to the connector.",
                "type": "string",
                "example": "visa",
                "enum": [
                  "accel",
                  "amex",
                  "bancontact",
                  "carte-bancaire",
                  "cirrus",
                  "culiance",
                  "dankort",
                  "diners-club",
                  "discover",
                  "eftpos-australia",
                  "elo",
                  "hipercard",
                  "jcb",
                  "maestro",
                  "mastercard",
                  "mir",
                  "nyce",
                  "other",
                  "pulse",
                  "rupay",
                  "star",
                  "uatp",
                  "unionpay",
                  "visa",
                  null
                ]
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionSync": {
        "title": "Transaction Sync",
        "type": "object",
        "description": "This event logs the exact parsed details for a transaction sync / refresh\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `transaction-sync-event`.",
            "example": "transaction-sync-event",
            "enum": [
              "transaction-sync-event"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2025-01-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "amount": {
                "type": "number",
                "description": "The transaction amount.",
                "example": 123
              },
              "captured_amount": {
                "type": "number",
                "description": "The amount captured for the transaction.",
                "example": 123
              },
              "currency": {
                "type": "string",
                "description": "The currency for the transaction.",
                "example": "EUR"
              },
              "status": {
                "type": "string",
                "description": "The latest status code for the transaction.",
                "example": "capture_succeeded"
              },
              "previous_status": {
                "type": "string",
                "description": "The previous status code for the transaction.",
                "example": "capture_succeeded"
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionVoidSucceededEvent": {
        "title": "Void - Succeeded",
        "type": "object",
        "description": "This event logs the exact details parsed details for a succeeded void\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-void-succeeded`.",
            "example": "payment-connector-response-transaction-void-succeeded",
            "enum": [
              "payment-connector-response-transaction-void-succeeded"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "voided_at": {
                "type": "string",
                "description": "The date and time when this transaction was voided.",
                "format": "date-time",
                "example": "2013-07-16T19:23:00.000+00:00"
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionVoidDeclinedEvent": {
        "title": "Void - Declined",
        "type": "object",
        "description": "This event logs the exact details parsed details for a declined void\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-void-declined`.",
            "example": "payment-connector-response-transaction-void-declined",
            "enum": [
              "payment-connector-response-transaction-void-declined"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234",
                "nullable": true
              },
              "code": {
                "type": "string",
                "description": "A raw response code returned for the failure.",
                "example": "INVALID DATA",
                "nullable": true
              }
            }
          }
        }
      },
      "PaymentConnectorResponseTransactionVoidFailedEvent": {
        "title": "Void - Failed",
        "type": "object",
        "description": "This event logs the exact details parsed details for a failed void\nas reported by our connector.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-response-transaction-void-failed`.",
            "example": "payment-connector-response-transaction-void-failed",
            "enum": [
              "payment-connector-response-transaction-void-failed"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "payment_service_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_display_name": {
                "type": "string",
                "description": "The display name of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "description": "The payment service definition used."
              }
            }
          }
        }
      },
      "PaymentConnectorExternalTransactionRequest": {
        "title": "External Transaction Request",
        "type": "object",
        "description": "This event logs the exact details parsed details for an external\ntransaction request.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `payment-connector-external-transaction-request`.",
            "example": "payment-connector-external-transaction-request",
            "enum": [
              "payment-connector-external-transaction-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this event was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for the transaction.",
            "properties": {
              "connector_request_id": {
                "type": "string",
                "description": "The connector request id.",
                "example": "76f5ed52-8675-491f-b52d-731ca894ed80"
              },
              "request": {
                "type": "string",
                "nullable": true,
                "description": "The request.",
                "example": ""
              },
              "response": {
                "type": "string",
                "nullable": true,
                "description": "The response."
              },
              "payment_service_definition_id": {
                "type": "string",
                "nullable": true,
                "description": "The payment service definition id."
              },
              "success": {
                "type": "boolean",
                "nullable": true,
                "description": "Whether the transaction was successful."
              },
              "payment_service_id": {
                "type": "string",
                "nullable": true,
                "description": "The payment service id."
              },
              "response_status_code": {
                "type": "string",
                "nullable": true,
                "description": "The response status code."
              },
              "payment_service_display_name": {
                "type": "string",
                "nullable": true,
                "description": "The payment service display name."
              },
              "method": {
                "type": "string",
                "nullable": true,
                "description": "The HTTP method."
              },
              "url": {
                "type": "string",
                "nullable": true,
                "description": "The endpoint for the request."
              },
              "refund_id": {
                "type": "string",
                "nullable": true,
                "description": "The ID of the refund, in case this links to a refund."
              },
              "refund_xid": {
                "type": "string",
                "nullable": true,
                "description": "The external ID of the refund."
              }
            }
          }
        }
      },
      "PaymentConnectorReportTransactionSettled": {
        "title": "Settlement - Sourced from Connector Report",
        "type": "object",
        "description": "This event logs the exact details for the settlement\nof a transaction as sourced from a connector report.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always\n`payment-connector-report-transaction-settled`.",
            "example": "payment-connector-report-transaction-settled",
            "enum": [
              "payment-connector-report-transaction-settled"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was settled.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Additional context for this event.",
            "properties": {
              "settlement_id": {
                "type": "string",
                "format": "uuid",
                "example": "577b430a-b516-4c96-bba2-7f63604c4d62",
                "description": "The unique ID of this transaction's settlement."
              },
              "posted_at": {
                "type": "string",
                "format": "date-time",
                "example": "2023-07-26T19:23:00.000+00:00",
                "description": "The date and time when this transaction was settled."
              },
              "ingested_at": {
                "type": "string",
                "format": "date-time",
                "example": "2023-07-26T19:23:00.000+00:00",
                "description": "The date and time when information about this transaction's\nsettlement was ingested into our system."
              },
              "currency": {
                "type": "string",
                "example": "USD",
                "description": "The currency of this transaction's settlement in\nISO 4217 three-letter code format."
              },
              "amount": {
                "type": "integer",
                "example": 500,
                "description": "The net amount settled for this transaction."
              },
              "exchange_rate": {
                "type": "number",
                "example": 0.95,
                "nullable": true,
                "description": "The exchange rate used to convert amounts from the\nprocessing currency to the settlement currency."
              },
              "commission": {
                "type": "integer",
                "example": 5,
                "description": "The total commission paid on this transaction, expressed in `currency`."
              },
              "interchange": {
                "type": "integer",
                "example": 5,
                "nullable": true,
                "description": "The interchange fee for this transaction, expressed in `currency`."
              },
              "markup": {
                "type": "integer",
                "example": 10,
                "nullable": true,
                "description": "The markup applied to this transaction by the acquirer, expressed in `currency`."
              },
              "scheme_fee": {
                "type": "integer",
                "example": 5,
                "nullable": true,
                "description": "The scheme fee for this transaction, expressed in `currency`."
              },
              "payment_service_id": {
                "type": "string",
                "example": "5d8fe189-ea36-4a92-b0b2-d0b2f9d8639f",
                "format": "uuid",
                "description": "The unique ID of the payment service used."
              },
              "payment_service_definition_id": {
                "type": "string",
                "example": "stripe-card",
                "description": "The payment service definition used."
              },
              "payment_service_display_name": {
                "type": "string",
                "example": "Stripe",
                "description": "The display name of the payment service used."
              },
              "payment_service_report_id": {
                "type": "string",
                "format": "uuid",
                "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83",
                "description": "The ID of the payment service report containing\nthis transaction's settlement."
              },
              "payment_service_report_file_ids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "format": "uuid"
                },
                "example": [
                  "0302e601-d2c3-42b2-9825-9457145331ae",
                  "7deec061-71a5-435f-beae-40f35820ca67"
                ],
                "description": "The list of payment service report file IDs that make up the\npayment service report containing this transaction's settlement."
              },
              "payment_service_transaction_id": {
                "type": "string",
                "description": "The external ID of the transaction as set by the payment service.",
                "example": "transaction-1234"
              },
              "report_payment_service_id": {
                "type": "string",
                "example": "5d8fe189-ea36-4a92-b0b2-d0b2f9d8639f",
                "format": "uuid",
                "description": "The unique ID of the payment service that reported this transaction's settlement."
              },
              "report_payment_service_definition_id": {
                "type": "string",
                "example": "stripe-card",
                "description": "The definition ID of the payment service that reported this transaction's settlement."
              },
              "report_payment_service_display_name": {
                "type": "string",
                "example": "Stripe",
                "description": "The display name of the payment service that reported this transaction's settlement."
              }
            }
          }
        }
      },
      "PaymentLink": {
        "title": "Payment Link",
        "type": "object",
        "x-tags": [
          "PaymentLink"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of a payment link.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `payment_link`.",
            "example": "payment_link",
            "enum": [
              "payment_link"
            ]
          },
          "amount": {
            "description": "The monetary amount for this payment link, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.",
            "type": "integer",
            "example": 1299
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "A supported ISO-4217 currency code."
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this payment link was created.",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this payment link was created.",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00"
          },
          "expires_at": {
            "type": "string",
            "description": "The date and time when this payment link expires.",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00"
          },
          "status": {
            "type": "string",
            "example": "active",
            "enum": [
              "active",
              "completed",
              "expired",
              "processing"
            ]
          },
          "external_identifier": {
            "type": "string",
            "description": "A value that can be used to match the payment link against your own records.",
            "example": "payment-link-123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "statement_descriptor": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/StatementDescriptor"
              }
            ],
            "nullable": true
          },
          "locale": {
            "type": "string",
            "nullable": true,
            "description": "The locale used to translate text within the payment link.",
            "example": "en",
            "enum": [
              "en",
              "en-GB",
              "es",
              "pt",
              "pt-BR"
            ]
          },
          "merchant_name": {
            "type": "string",
            "description": "The name of the merchant to display on the payment link.",
            "example": "Gr4vy",
            "maxLength": 100,
            "nullable": true
          },
          "merchant_url": {
            "type": "string",
            "description": "The URL of the merchant to display on the payment link.",
            "example": "https://gr4vy.com",
            "nullable": true
          },
          "merchant_banner_url": {
            "type": "string",
            "description": "The URL of the merchant banner to display on the payment link.",
            "example": "https://gr4vy.com/banner.png",
            "nullable": true
          },
          "merchant_color": {
            "type": "string",
            "description": "The color code of the merchant to display on the payment link.",
            "example": "#FF0000",
            "nullable": true
          },
          "merchant_message": {
            "type": "string",
            "description": "The message to display on the payment link.",
            "example": "Thank you for shopping with us!",
            "maxLength": 255,
            "nullable": true
          },
          "merchant_terms_and_conditions_url": {
            "type": "string",
            "description": "The URL of the merchant terms and conditions to display on the payment link.",
            "example": "https://gr4vy.com/terms",
            "nullable": true
          },
          "merchant_favicon_url": {
            "type": "string",
            "description": "The URL of the merchant favicon icon.",
            "example": "https://gr4vy.com/favicon.png",
            "nullable": true
          },
          "country": {
            "description": "The 2-letter ISO code of the country of the transaction.\nThis is used to filter the payment services that is used to process the\ntransaction.\n",
            "example": "US",
            "type": "string",
            "nullable": true
          },
          "intent": {
            "type": "string",
            "description": "The intent of the payment link.",
            "example": "authorize",
            "enum": [
              "authorize",
              "capture"
            ],
            "nullable": true
          },
          "return_url": {
            "type": "string",
            "description": "The URL to redirect the buyer to after payment.",
            "example": "https://gr4vy.com/return",
            "nullable": true
          },
          "cart_items": {
            "description": "An array of cart items that represents the line items of a payment link.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "maxItems": 249,
            "type": "array"
          },
          "metadata": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Any additional information about the payment link that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "example": {
              "key": "value"
            },
            "maxProperties": 20,
            "type": "object",
            "nullable": true
          },
          "payment_source": {
            "type": "string",
            "description": "The source of the payment link. Defaults to `ecommerce`.",
            "nullable": true,
            "example": "recurring",
            "enum": [
              "ecommerce",
              "moto",
              "recurring",
              "installment",
              "card_on_file"
            ]
          },
          "buyer": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer--Snapshot"
              }
            ],
            "description": "The buyer used for this transaction.",
            "nullable": true
          },
          "shipping_details": {
            "description": "Shipping details for the payment link.",
            "allOf": [
              {
                "$ref": "#/components/schemas/ShippingDetail"
              }
            ],
            "type": "object",
            "x-model-name": "ShippingDetail",
            "nullable": true
          }
        }
      },
      "PaymentLinks": {
        "title": "Payment Links",
        "type": "object",
        "description": "A list of payment links.",
        "x-tags": [
          "PaymentLinks"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of payment links.",
            "items": {
              "$ref": "#/components/schemas/PaymentLink"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PaymentLinkRequest": {
        "title": "Payment Link (Create)",
        "type": "object",
        "description": "Request body for creating a new payment link.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "currency",
          "country"
        ],
        "properties": {
          "amount": {
            "type": "number",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999,
            "description": "The amount to request payment for."
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code for the payment."
          },
          "country": {
            "description": "The 2-letter ISO code of the country of the transaction.\nThis is used to filter the payment services that is used to process the\ntransaction.\n",
            "example": "US",
            "type": "string"
          },
          "buyer": {
            "description": "Guest buyer details provided inline. No buyer resource will be created on Gr4vy when used.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/TransactionBuyerRequest"
              }
            ],
            "type": "object",
            "x-model-name": "TransactionBuyerRequest",
            "nullable": true
          },
          "expires_at": {
            "type": "string",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00",
            "description": "The date and time when this payment link expires. Defaults to 24 hours from creation.",
            "nullable": true
          },
          "connection_options": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ConnectionOptions"
              }
            ],
            "description": "Allows for passing optional configuration per connection to take\nadvantage of connection specific features. When provided, the data\nis only passed to the target connection type to prevent sharing\nconfiguration across connections.\n\nPlease note that each of the keys this object are in kebab-case, for\nexample `cybersource-anti-fraud` as they represent the ID of the\nconnector. All the other keys will be snake case, for example\n`merchant_defined_data` or camel case to match an external API that the\nconnector uses.",
            "type": "object",
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "A value that can be used to match the payment link against your own records. This will also be applied to any transaction.",
            "example": "payment-link-123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "statement_descriptor": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/StatementDescriptor"
              }
            ],
            "nullable": true
          },
          "locale": {
            "type": "string",
            "nullable": true,
            "description": "The locale used to translate text within the payment link.",
            "example": "en",
            "enum": [
              "en",
              "en-GB",
              "es",
              "pt",
              "pt-BR"
            ]
          },
          "merchant_name": {
            "type": "string",
            "description": "The name of the merchant to display on the payment link.",
            "example": "Gr4vy",
            "maxLength": 100,
            "nullable": true
          },
          "merchant_url": {
            "type": "string",
            "description": "The URL of the merchant to display on the payment link.",
            "example": "https://gr4vy.com",
            "nullable": true
          },
          "merchant_banner_url": {
            "type": "string",
            "description": "The URL of the merchant banner to display on the payment link.",
            "example": "https://gr4vy.com/banner.png",
            "nullable": true
          },
          "merchant_color": {
            "type": "string",
            "description": "The color code of the merchant to display on the payment link.",
            "example": "#FF0000",
            "nullable": true
          },
          "merchant_message": {
            "type": "string",
            "description": "The message to display on the payment link.",
            "example": "Thank you for shopping with us!",
            "maxLength": 255,
            "nullable": true
          },
          "merchant_terms_and_conditions_url": {
            "type": "string",
            "description": "The URL of the merchant terms and conditions to display on the payment link.",
            "example": "https://gr4vy.com/terms",
            "nullable": true
          },
          "merchant_favicon_url": {
            "type": "string",
            "description": "The URL of the merchant favicon icon.",
            "example": "https://gr4vy.com/favicon.png",
            "nullable": true
          },
          "intent": {
            "type": "string",
            "description": "The intent of the payment link.",
            "example": "authorize",
            "enum": [
              "authorize",
              "capture"
            ],
            "default": "authorize",
            "nullable": true
          },
          "return_url": {
            "type": "string",
            "description": "The URL to redirect the buyer to after payment.",
            "example": "https://gr4vy.com/return",
            "nullable": true
          },
          "cart_items": {
            "description": "An array of cart items that represents the line items of a payment link.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "maxItems": 249,
            "type": "array"
          },
          "metadata": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Any additional information about the payment link that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "example": {
              "key": "value"
            },
            "maxProperties": 20,
            "type": "object",
            "nullable": true
          },
          "payment_source": {
            "type": "string",
            "description": "The source of the payment link.",
            "nullable": true,
            "example": "recurring",
            "enum": [
              "ecommerce",
              "moto",
              "recurring",
              "installment",
              "card_on_file"
            ]
          }
        }
      },
      "PaymentMethod": {
        "title": "Payment method",
        "description": "A generic payment method.",
        "type": "object",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`payment-method`.",
            "example": "payment-method",
            "enum": [
              "payment-method"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
          },
          "additional_schemes": {
            "description": "Additional schemes of the card. Only applies to card payment methods.",
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "nullable": true,
            "type": "array"
          },
          "approval_target": {
            "type": "string",
            "example": "any",
            "nullable": true,
            "description": "The browser target that an approval URL must be opened in. If `any` or `null`, then there is no specific requirement.",
            "enum": [
              "any",
              "new_window"
            ]
          },
          "approval_url": {
            "description": "The optional URL that the buyer needs to be redirected to to further authorize their payment.",
            "example": "https://api.example.app.gr4vy.com/payment-methods/ffc88ec9-e1ee-45ba-993d-b5902c3b2a8c/approve",
            "format": "uri",
            "nullable": true,
            "type": "string"
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer"
              }
            ],
            "description": "The optional buyer for which this payment method has been stored.",
            "nullable": true
          },
          "country": {
            "description": "The 2-letter ISO code of the country this payment method can\nbe used for. If this value is `null` the payment method may be\nused in multiple countries.",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "description": "The date and time when this payment method was first created in our\nsystem.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "currency": {
            "description": "The ISO-4217 currency code that this payment method can be\nused for. If this value is `null` the payment method may be\nused for multiple currencies.",
            "example": "USD",
            "nullable": true,
            "type": "string"
          },
          "details": {
            "$ref": "#/components/schemas/PaymentMethodDetailsCard"
          },
          "expiration_date": {
            "description": "The expiration date for the payment method.",
            "example": "07/24",
            "maxLength": 5,
            "minLength": 5,
            "nullable": true,
            "pattern": "^\\d{2}/\\d{2}$",
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the payment method\nagainst your own records.",
            "example": "user-789123",
            "nullable": true,
            "type": "string"
          },
          "has_replacement": {
            "description": "Whether this card has a pending replacement that hasn't been applied yet.\n\nWhen the Account Updater determines that new card details are available, existing details are not\nchanged immediately, but this field is set to `true`. There are three scenarios in which the actual\nreplacement occurs:\n\n1. When this card has expired.\n2. When only the expiration date changed.\n3. When a transaction using this card is declined with any of the following codes:\n    * `canceled_payment_method`\n    * `expired_payment_method`\n    * `unavailable_payment_method`\n    * `unknown_payment_method`\n\nWhen the replacement is applied, this field is set to `false`.\nFor non-card payment methods, the value of this field is always set to `false`.",
            "example": false,
            "nullable": false,
            "type": "boolean"
          },
          "label": {
            "description": "A label for the card or the account. For a `paypal` payment method this\nis the user's email address. For a card it is the last 4 digits of the\ncard.",
            "example": "john@example.com",
            "nullable": true,
            "type": "string"
          },
          "last_replaced_at": {
            "description": "The date and time when this card was last replaced.\n\nWhen the Account Updater determines that new card details are available, existing details are not\nchanged immediately. There are three scenarios in which the actual replacement occurs:\n\n1. When this card has expired.\n2. When only the expiration date changed.\n3. When a transaction using this card is declined with any of the following codes:\n    * `canceled_payment_method`\n    * `expired_payment_method`\n    * `unavailable_payment_method`\n    * `unknown_payment_method`\n\nWhen the replacement is applied, this field is updated.\nFor non-card payment methods, the value of this field is always set to `null`.",
            "example": "2023-07-26T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "merchant_account_id": {
            "description": "The unique ID for a merchant account.",
            "example": "default",
            "type": "string"
          },
          "method": {
            "description": "The type of this payment method.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "mode": {
            "description": "The mode to use with this payment method.",
            "type": "string",
            "example": "card",
            "enum": [
              "card",
              "redirect",
              "applepay",
              "googlepay",
              "click-to-pay",
              "checkout-session"
            ]
          },
          "scheme": {
            "description": "The scheme of the card. Only applies to card payments.",
            "nullable": true,
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          },
          "status": {
            "description": "The state of the payment method.\n\n- `processing` - The payment method is stored but is not ready to be\n   used yet, as we may be waiting for a notification from a connector\n   to complete the setup.\n- `buyer_approval_required` - Storing the payment method requires\n  the buyer to provide approval. Follow the `approval_url` for next steps.\n- `succeeded` - The payment method is stored and can be used.\n- `failed` - The payment method could not be stored, or failed verification.",
            "enum": [
              "processing",
              "buyer_approval_required",
              "succeeded",
              "failed"
            ],
            "example": "succeeded",
            "type": "string"
          },
          "updated_at": {
            "description": "The date and time when this payment method was last updated in our system.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "fingerprint": {
            "type": "string",
            "description": "The unique hash derived from the payment method identifier (e.g. card number).",
            "example": "20eb353620155d2b5fc864cc46a73ea77cb92c725238650839da1813fa987a17",
            "nullable": true
          },
          "last_used_at": {
            "description": "The timestamp when this payment method was last used in a transaction.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "usage_count": {
            "description": "The number of times this payment method has been used in transactions.",
            "example": 5,
            "type": "integer",
            "nullable": false
          },
          "cit_last_used_at": {
            "description": "The timestamp when this payment method was last used in a transaction\nfor client initiated transactions.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "cit_usage_count": {
            "description": "The number of times this payment method has been used in transactions\nfor client initiated transactions.",
            "example": 2,
            "type": "integer",
            "nullable": false
          }
        }
      },
      "PaymentMethod--Tokenized": {
        "title": "Payment Method (Summary)",
        "description": "A mini format version of a payment method.",
        "type": "object",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`payment-method`.",
            "example": "payment-method",
            "enum": [
              "payment-method"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "method": {
            "description": "The type of this payment method.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "label": {
            "type": "string",
            "description": "A label for the payment method. For a `card` payment method this is the\nlast 4 digits on the card. For others it would be the email address.",
            "example": "1111"
          },
          "scheme": {
            "description": "The type of the card, if the payment method is a card.",
            "nullable": true,
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          },
          "additional_schemes": {
            "type": "array",
            "description": "Additional schemes of the card. Only applies to card payment methods.",
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            },
            "nullable": true
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date for the payment method.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5,
            "nullable": true
          },
          "approval_target": {
            "type": "string",
            "example": "any",
            "nullable": true,
            "description": "The browser target that an approval URL must be opened in. If `any` or `null`, then there is no specific requirement.",
            "enum": [
              "any",
              "new_window"
            ]
          },
          "approval_url": {
            "type": "string",
            "format": "uri",
            "example": "https://api.example.app.gr4vy.com/payment-methods/ffc88ec9-e1ee-45ba-993d-b5902c3b2a8c/approve",
            "description": "The optional URL that the buyer needs to be redirected to to further authorize their payment.",
            "nullable": true
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code that this payment method can be\nused for. If this value is `null` the payment method may be\nused for multiple currencies.",
            "nullable": true
          },
          "country": {
            "type": "string",
            "example": "US",
            "description": "The 2-letter ISO code of the country this payment method can\nbe used for. If this value is `null` the payment method may be\nused in multiple countries.",
            "nullable": true
          },
          "last_replaced_at": {
            "type": "string",
            "nullable": true,
            "description": "The date and time when this card was last replaced.\n\nWhen the Account Updater determines that new card details are available, existing details are not\nchanged immediately. There are three scenarios in which the actual replacement occurs:\n\n1. When this card has expired.\n2. When only the expiration date changed.\n3. When a transaction using this card is declined with any of the following codes:\n    * `canceled_payment_method`\n    * `expired_payment_method`\n    * `unavailable_payment_method`\n    * `unknown_payment_method`\n\nWhen the replacement is applied, this field is updated.\nFor non-card payment methods, the value of this field is always set to `null`.",
            "format": "date-time",
            "example": "2023-07-26T19:23:00.000+00:00"
          },
          "has_replacement": {
            "type": "boolean",
            "nullable": false,
            "description": "Whether this card has a pending replacement that hasn't been applied yet.\n\nWhen the Account Updater determines that new card details are available, existing details are not\nchanged immediately, but this field is set to `true`. There are three scenarios in which the actual\nreplacement occurs:\n\n1. When this card has expired.\n2. When only the expiration date changed.\n3. When a transaction using this card is declined with any of the following codes:\n    * `canceled_payment_method`\n    * `expired_payment_method`\n    * `unavailable_payment_method`\n    * `unknown_payment_method`\n\nWhen the replacement is applied, this field is set to `false`.\nFor non-card payment methods, the value of this field is always set to `false`.",
            "example": false
          },
          "last_used_at": {
            "description": "The timestamp when this payment method was last used in a transaction.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "usage_count": {
            "description": "The number of times this payment method has been used in transactions.",
            "example": 5,
            "type": "integer",
            "nullable": false
          },
          "cit_last_used_at": {
            "description": "The timestamp when this payment method was last used in a transaction\nfor client initiated transactions.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "cit_usage_count": {
            "description": "The number of times this payment method has been used in transactions\nfor client initiated transactions.",
            "example": 2,
            "type": "integer",
            "nullable": false
          }
        }
      },
      "PaymentMethods": {
        "title": "Payment Methods",
        "type": "object",
        "description": "A list of stored payment methods.",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of stored payment methods.",
            "items": {
              "$ref": "#/components/schemas/PaymentMethod"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PaymentMethod--Snapshot": {
        "title": "Payment method (Snapshot)",
        "description": "Snapshot of a payment method, as used when embedded inside other\nresources.",
        "type": "object",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`payment-method`.",
            "example": "payment-method",
            "enum": [
              "payment-method"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5",
            "nullable": true
          },
          "approval_target": {
            "type": "string",
            "example": "any",
            "nullable": true,
            "description": "The browser target that an approval URL must be opened in. If `any` or `null`, then there is no specific requirement.",
            "enum": [
              "any",
              "new_window"
            ]
          },
          "approval_url": {
            "description": "The optional URL that the buyer needs to be redirected to to further authorize their payment.",
            "example": "https://api.example.app.gr4vy.com/payment-methods/ffc88ec9-e1ee-45ba-993d-b5902c3b2a8c/approve",
            "format": "uri",
            "nullable": true,
            "type": "string"
          },
          "country": {
            "description": "The 2-letter ISO code of the country this payment method can\nbe used for. If this value is `null` the payment method may be\nused in multiple countries.",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "currency": {
            "description": "The ISO-4217 currency code that this payment method can be\nused for. If this value is `null` the payment method may be\nused for multiple currencies.",
            "example": "USD",
            "nullable": true,
            "type": "string"
          },
          "details": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentMethodDetailsCard"
              }
            ],
            "nullable": true
          },
          "expiration_date": {
            "description": "The expiration date for this payment method. This is mostly used by cards\nwhere the card might have an expiration date.",
            "example": "11/25",
            "maxLength": 5,
            "minLength": 5,
            "nullable": true,
            "pattern": "^\\d{2}/\\d{2}$",
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the payment method\nagainst your own records.",
            "example": "user-789123",
            "nullable": true,
            "type": "string"
          },
          "label": {
            "description": "A label for the payment method. This can be the last 4 digits for a card,\nor the email address for an alternative payment method.",
            "example": "1111",
            "nullable": true,
            "type": "string"
          },
          "last_replaced_at": {
            "description": "The date and time when this card was last replaced.\n\nWhen the Account Updater determines that new card details are available, existing details are not\nchanged immediately. There are three scenarios in which the actual replacement occurs:\n\n1. When this card has expired.\n2. When only the expiration date changed.\n3. When a transaction using this card is declined with any of the following codes:\n    * `canceled_payment_method`\n    * `expired_payment_method`\n    * `unavailable_payment_method`\n    * `unknown_payment_method`\n\nWhen the replacement is applied, this field is updated.\nFor non-card payment methods, the value of this field is always set to `null`.",
            "example": "2023-07-26T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "method": {
            "description": "The type of this payment method.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "payment_account_reference": {
            "description": "The payment account reference (PAR) returned by the card scheme. This is a unique\nreference to the underlying account that has been used to fund this payment method.\nThis value will be unique if the same underlying account was used, regardless of\nthe actual payment method used. For example, a network token or an Apple Pay device\ntoken will return the same PAR when possible.\n\nThe uniqueness of this value will depend on the card scheme, please refer to their documentation\nfor further details. The availability of the PAR in our API depends on the availability\nof its value in the API of the payment service used for the transaction.",
            "type": "string",
            "example": "V0010014629724763377327521982",
            "nullable": true
          },
          "scheme": {
            "description": "An additional label used to differentiate different sub-types of a payment\nmethod. Most notably this can include the type of card used in a\ntransaction. This field is `null` for the non-card payment methods.\nThis represents the card scheme sent to the connector and it could be different from the\nactual card scheme that is being used by the PSP to process the transaction\nin the following situations: 1. `use_additional_scheme` transformation is used\nwith the `PAN` instrument but we already have a PSP token for the card.\n2. `use_additional_scheme` transformation is used but PSP has fallen back to the\nmain card scheme internally.",
            "nullable": true,
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          },
          "fingerprint": {
            "type": "string",
            "description": "The unique hash derived from the payment method identifier (e.g. card number).",
            "example": "20eb353620155d2b5fc864cc46a73ea77cb92c725238650839da1813fa987a17",
            "nullable": true
          }
        }
      },
      "PaymentMethods--Tokenized": {
        "title": "Payment Methods (Summary)",
        "type": "object",
        "description": "A list of stored payment methods in summarized format.",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of stored payment methods in summarized format.",
            "items": {
              "$ref": "#/components/schemas/PaymentMethod--Tokenized"
            }
          }
        }
      },
      "PaymentMethodDetailsCard": {
        "title": "Card",
        "description": "A credit or debit card payment method.",
        "type": "object",
        "x-tags": [
          "Payment Methods"
        ],
        "properties": {
          "bin": {
            "type": "string",
            "description": "The first 6 digits of the full card number (the BIN).",
            "example": "412345"
          },
          "card_type": {
            "description": "The type of card, one of `credit`, `debit` or `prepaid`.",
            "example": "credit",
            "type": "string",
            "enum": [
              "credit",
              "debit",
              "prepaid"
            ]
          },
          "card_issuer_name": {
            "type": "string",
            "description": "The name of the card issuer.",
            "example": "Bank"
          }
        }
      },
      "PaymentMethodRequest": {
        "title": "Payment method request",
        "type": "object",
        "description": "Payment method details used to register\na new payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "The type of the funding source, e.g. `card`, `paypal`,\nor `checkout-session`.",
            "example": "card"
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of a Checkout Session.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this credit card as it can be found on the\nfront of the card."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`. If a card has been\npreviously stored with us this value is optional.",
            "example": "11/15",
            "pattern": "^\\d\\d/\\d\\d$",
            "minLength": 5,
            "maxLength": 5
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "account-23423423",
            "nullable": true
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to associate this payment method to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset."
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to associate this payment method\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.",
            "example": "user-789123"
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction or payment method. This only applies to payment methods that\nrequire buyer approval.",
            "example": "https://example.com/callback"
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code to store this payment method for. This is\nused to select the payment service to use.\n\nThis only applies to `redirect` mode payment methods like `gocardless`."
          },
          "country": {
            "type": "string",
            "example": "US",
            "description": "The 2-letter ISO code of the country to store this payment method for.\nThis is used to select the payment service to use.\n\nThis only applies to `redirect` mode payment methods like `gocardless`."
          }
        }
      },
      "PaymentMethodDefinition": {
        "title": "Payment Method Definition",
        "type": "object",
        "description": "Definitions of a payment method including icon, label, etc.",
        "x-tags": [
          "Payment Method Definitions"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The mode of this payment method.",
            "example": "bank"
          },
          "icon_url": {
            "type": "string",
            "description": "The icon for this payment method.",
            "example": "https://api.sandbox.example.gr4vy.app/assets/payment-method-definitions/bank.svg"
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this payment method.",
            "example": "Bank"
          },
          "long_display_name": {
            "type": "string",
            "description": "The long display name of this payment method.",
            "example": "Bank (BACS)"
          },
          "method": {
            "type": "string",
            "description": "The method, or type, for this payment method.",
            "example": "BACS"
          }
        }
      },
      "PaymentMethodDefinitions": {
        "title": "Payment Method Definitions",
        "type": "object",
        "description": "A list of available payment method definitions.",
        "x-tags": [
          "Payment Method Definitions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentMethodDefinition"
            }
          }
        }
      },
      "PaymentOptionsRequest": {
        "title": "Payment Options (List)",
        "type": "object",
        "description": "A request to get list of payment options.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "amount": {
            "nullable": true,
            "description": "The monetary amount to create an authorization for, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nIf the `intent` is set to `capture`, an amount greater than zero must\nbe supplied.",
            "type": "integer",
            "example": 1299
          },
          "locale": {
            "type": "string",
            "example": "en-US",
            "pattern": "^[a-z]{2}(?:-[A-Z]{2})?$",
            "default": "en",
            "nullable": true,
            "description": "An ISO 639-1 Language Code and optional ISO 3166 Country Code. This locale\ndetermines the language for the labels returned for every payment option."
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "nullable": true,
            "description": "A supported ISO-4217 currency code.\n\nFor redirect requests, this value must match the one specified for\n`currency` in `payment_method`.\n"
          },
          "country": {
            "type": "string",
            "example": "US",
            "nullable": true,
            "description": "Filters the results to only the items which support this country code. A\ncountry is formatted as 2-letter ISO country code.\n"
          },
          "metadata": {
            "nullable": true,
            "description": "Used by the Flow engine to filter available options based on various\nclient-defined parameters. If present, this must be a string representing\na valid JSON dictionary.",
            "type": "object",
            "maxProperties": 20,
            "additionalProperties": {
              "type": "string"
            },
            "example": {
              "key": "value"
            }
          },
          "cart_items": {
            "type": "array",
            "nullable": true,
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "maxItems": 249
          }
        }
      },
      "PaymentService": {
        "title": "A payment service",
        "type": "object",
        "description": "An active, configured payment service.",
        "x-tags": [
          "Payment Services"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "payment-service",
            "enum": [
              "payment-service"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this payment service.",
            "example": "faaad066-30b4-4997-a438-242b0752d7e1",
            "minLength": 1,
            "maxLength": 200
          },
          "accepted_countries": {
            "description": "A list of countries for which this service is enabled, in ISO two-letter\ncode format.",
            "example": [
              "DE"
            ],
            "items": {
              "maxLength": 2,
              "minLength": 2,
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          },
          "accepted_currencies": {
            "description": "A list of currencies for which this service is enabled, in ISO 4217\nthree-letter code format.",
            "example": [
              "EUR"
            ],
            "items": {
              "maxLength": 3,
              "minLength": 3,
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          },
          "active": {
            "default": true,
            "description": "Defines if this service is currently active or not.",
            "example": true,
            "type": "boolean"
          },
          "created_at": {
            "description": "The date and time when this service was created.",
            "example": "2012-12-12T10:53:43+00:00",
            "format": "date-time",
            "type": "string"
          },
          "display_name": {
            "description": "The custom name set for this service.",
            "example": "Stripe (Main)",
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "fields": {
            "description": "A list of fields, each containing a key-value pair for each field\nconfigured for this payment service. Fields marked as `secret`\n(see Payment Service Definition) are not returned.",
            "items": {
              "properties": {
                "key": {
                  "description": "The key of the field.",
                  "example": "secret_key",
                  "maxLength": 50,
                  "minLength": 1,
                  "type": "string"
                },
                "value": {
                  "description": "The value of the field.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "maxLength": 5000,
                  "minLength": 1,
                  "type": "string"
                }
              },
              "type": "object"
            },
            "type": "array"
          },
          "reporting_fields": {
            "description": "A list of fields, each containing a key-value pair for each field\nconfigured for reporting for this payment service. Fields marked as\n`secret` (see Payment Service Definition) are not returned.",
            "items": {
              "properties": {
                "key": {
                  "description": "The key of the field.",
                  "example": "ssh_username",
                  "maxLength": 50,
                  "minLength": 1,
                  "type": "string"
                },
                "value": {
                  "description": "The value of the field.",
                  "example": "test_ssh_username",
                  "maxLength": 5000,
                  "minLength": 1,
                  "type": "string"
                }
              },
              "type": "object"
            },
            "type": "array"
          },
          "merchant_account_id": {
            "description": "The unique ID for a merchant account.",
            "example": "default",
            "type": "string"
          },
          "merchant_profile": {
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfileSummary"
              }
            ],
            "description": "An object containing a key for each supported card scheme (Amex,\nDiscover, Mastercard and Visa), and for each key an object with\nthe merchant profile for this service and the corresponding scheme.",
            "nullable": true,
            "type": "object"
          },
          "method": {
            "description": "The payment method that this service handles.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "network_tokens_enabled": {
            "description": "Defines if network tokens are enabled for the service. This feature\ncan only be enabled if the payment service is set as `open_loop` and\nthe PSP is set up to accept network tokens.",
            "example": true,
            "type": "boolean"
          },
          "open_loop": {
            "description": "Defines if the service works as an open-loop service. This feature\ncan only be enabled if the PSP is set up to accept previous scheme\ntransaction IDs.",
            "example": true,
            "type": "boolean"
          },
          "payment_method_tokenization_enabled": {
            "default": false,
            "description": "Defines if tokenization is enabled for the service. This feature\ncan only be enabled if the payment service is NOT set as `open_loop`\nand the PSP is set up to tokenize.",
            "example": true,
            "type": "boolean"
          },
          "payment_service_definition_id": {
            "description": "The ID of the payment service definition used to create this service.\n",
            "example": "stripe-card",
            "maxLength": 50,
            "minLength": 1,
            "type": "string"
          },
          "settlement_reporting_enabled": {
            "description": "Defines if settlement reporting is enabled for the service.\nThis feature can only be enabled if the payment service\ndefinition supports the `settlement_reporting` feature.",
            "example": true,
            "type": "boolean"
          },
          "status": {
            "description": "The current status of this service. This will start off as pending, move\nto created, and might eventually move to an error status if and when the\ncredentials are no longer valid.\n",
            "enum": [
              "pending",
              "created",
              "failed"
            ],
            "type": "string"
          },
          "three_d_secure_enabled": {
            "default": false,
            "description": "Defines if 3-D Secure is enabled for the service. This feature\ncan only be enabled if the payment service definition supports\nthe `three_d_secure_hosted` feature.\nThis does not affect pass through 3-D Secure data.",
            "example": true,
            "type": "boolean"
          },
          "updated_at": {
            "description": "The date and time when this service was last updated.",
            "example": "2012-12-12T10:53:43+00:00",
            "format": "date-time",
            "type": "string"
          },
          "webhook_url": {
            "description": "The URL that needs to be configured with this payment service as the\nreceiving endpoint for webhooks from the service to Gr4vy. Currently,\nGr4vy does not yet automatically register webhooks on setup, and\ntherefore webhooks need to be registered manually by the merchant.",
            "example": "https://api.example.app.gr4vy.com/i/ViYUjDkUSoiQ0ColeigGwnN0...",
            "format": "url",
            "nullable": true,
            "type": "string"
          }
        }
      },
      "PaymentService--Snapshot": {
        "title": "A payment service",
        "type": "object",
        "description": "An active, configured payment service.",
        "x-tags": [
          "Payment Services"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "payment-service",
            "enum": [
              "payment-service"
            ]
          },
          "id": {
            "type": "string",
            "description": "The ID of this payment service.",
            "example": "stripe-card-faaad066-30b4-4997-a438-242b0752d7e1",
            "minLength": 1,
            "maxLength": 200
          },
          "display_name": {
            "description": "The custom name set for this service.",
            "example": "Stripe (Main)",
            "maxLength": 50,
            "minLength": 1,
            "type": "string"
          },
          "method": {
            "description": "The payment method that this services handles.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "payment_service_definition_id": {
            "description": "The ID of the payment service definition used to create this service.\n",
            "example": "stripe-card",
            "maxLength": 50,
            "minLength": 1,
            "type": "string"
          }
        }
      },
      "PaymentServices": {
        "title": "A list of active payment services",
        "type": "object",
        "description": "A list of active, configured payment services.",
        "x-tags": [
          "Payment Services"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentService"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PaymentServiceSession": {
        "title": "Payment Service Session",
        "type": "object",
        "description": "A session request for a payment session. This is an opaque object\npassed to the payment service.",
        "x-tags": [
          "Payment Services"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "payment-service-session",
            "enum": [
              "payment-service-session"
            ]
          },
          "status": {
            "type": "string",
            "description": "The status of the response.\n\n- `succeeded` - The session was successfully generated.\n- `failed` - The session could not be generated.",
            "example": "succeeded",
            "enum": [
              "succeeded",
              "failed"
            ]
          },
          "code": {
            "type": "string",
            "example": "UNKNOWN_ERROR",
            "description": "A generic error code that may be returned when the session could not be generated.",
            "nullable": true
          },
          "status_code": {
            "type": "number",
            "nullable": true,
            "example": 200,
            "description": "The HTTP status code received from the payment service."
          },
          "response_body": {
            "type": "object",
            "description": "The parsed JSON received from the payment service.",
            "nullable": true,
            "additionalProperties": true,
            "example": {
              "data": {
                "customerType": "EXISTING",
                "walletManagementUrl": "https://example.com/session"
              },
              "meta": {}
            }
          }
        }
      },
      "PaymentServiceSessionRequest": {
        "title": "Payment Service Session Request",
        "type": "object",
        "description": "A request to generate a session for a payment session.",
        "x-tags": [
          "Payment Services"
        ],
        "additionalProperties": true
      },
      "PaymentServiceRequest": {
        "title": "Payment Service (Create)",
        "type": "object",
        "description": "Request body for activating a payment service.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "display_name",
          "payment_service_definition_id",
          "fields",
          "accepted_currencies",
          "accepted_countries"
        ],
        "properties": {
          "payment_service_definition_id": {
            "type": "string",
            "description": "The ID of the payment service to use.",
            "example": "stripe-card",
            "minLength": 1,
            "maxLength": 50
          },
          "display_name": {
            "type": "string",
            "description": "A custom name for the payment service. This will be shown in the Admin UI.",
            "example": "Stripe (Main)",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined by the definition for this payment service e.g. for stripe-card `secret_key` is required and so must be sent within this field.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this payment service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 1,
                  "maxLength": 5000
                }
              }
            }
          },
          "reporting_fields": {
            "type": "array",
            "description": "The `reporting_fields` field should contain a list of key-value pairs. Each key-value pair represents a reporting field defined by the payment service. For example, when enabling settlement reporting for `nuvei-card`, the `ssh_username` field is required and must be included in `reporting_fields`.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a reporting field defined in the definition for this payment service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "ssh_username",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "test_ssh_user",
                  "minLength": 1,
                  "maxLength": 5000
                }
              }
            }
          },
          "accepted_countries": {
            "type": "array",
            "description": "A list of countries that this payment service needs to support in ISO two-letter code format.",
            "minItems": 1,
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            },
            "example": [
              "US",
              "GB",
              "DE"
            ]
          },
          "accepted_currencies": {
            "type": "array",
            "description": "A list of currencies that this payment service needs to support in ISO 4217 three-letter code format.",
            "minItems": 1,
            "items": {
              "type": "string",
              "minLength": 3,
              "maxLength": 3
            },
            "example": [
              "EUR",
              "USD",
              "GBP"
            ]
          },
          "three_d_secure_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "description": "Defines if 3-D Secure is enabled for the service. This feature\ncan only be enabled if the payment service definition supports\nthe `three_d_secure_hosted` feature.\nThis does not affect pass through 3-D Secure data."
          },
          "merchant_profile": {
            "type": "object",
            "nullable": true,
            "description": "Configuration for each supported card scheme.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfile"
              }
            ]
          },
          "active": {
            "type": "boolean",
            "example": true,
            "default": true,
            "description": "Defines if this service is currently active or not."
          },
          "open_loop": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if the service works as an open-loop service. This feature\ncan only be enabled if the PSP is set up to accept previous scheme\ntransaction IDs.\n\nIf this value is not provided or is set to `null`, it will be set\nto the value of `open_loop` in the payment service definition.\n\nIf `open_loop_toggle` is `false` in the payment service definition,\n`open_loop` should either not be provided or set to `null`, or it\nwill fail with a validation error."
          },
          "payment_method_tokenization_enabled": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if tokenization is enabled for the service. This feature\ncan only be enabled if the payment service is NOT set as `open_loop`\nand the PSP is set up to tokenize."
          },
          "network_tokens_enabled": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if network tokens are enabled for the service. This feature\ncan only be enabled if the payment service is set as `open_loop` and\nthe PSP is set up to accept network tokens.\n\nIf this value is not provided or is set to `null`, it will be set\nto the value of `network_tokens_default` in the payment service\ndefinition.\n\nIf `network_tokens_toggle` is `false` in the payment service definition,\n`network_tokens_enabled` should either not be provided or set to `null`,\nor it will fail with a validation error."
          },
          "settlement_reporting_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "nullable": false,
            "description": "Defines if settlement reporting is enabled for the service.\nThis feature can only be enabled if the payment service\ndefinition supports the `settlement_reporting` feature."
          }
        }
      },
      "PaymentServiceToken": {
        "title": "Payment Service Token",
        "type": "object",
        "description": "A payment service token.",
        "x-tags": [
          "Tokens"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource.",
            "example": "payment-service-token",
            "enum": [
              "payment-service-token"
            ]
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the token.",
            "format": "uuid",
            "example": "d6ad71d5-6908-45d6-ab65-39c55475dd08"
          },
          "payment_method_id": {
            "type": "string",
            "description": "The unique ID of the payment method.",
            "format": "uuid",
            "example": "9bdc4bc4-005e-4658-8eee-a309fc43cd4d"
          },
          "payment_service_id": {
            "type": "string",
            "description": "The unique ID of the payment service.",
            "format": "uuid",
            "example": "50f2e61f-caac-4e12-8d79-30eaf8250423"
          },
          "status": {
            "type": "string",
            "description": "The state of the token.\n\n- `processing` - The payment method is still being stored.\n- `buyer_approval_required` - Storing the payment method requires\n  the buyer to provide approval. Follow the `approval_url` for next steps.\n- `succeeded` - The payment method is approved and stored with all\n  relevant payment services.\n- `failed` - Storing the payment method did not succeed.",
            "example": "succeeded",
            "enum": [
              "processing",
              "buyer_approval_required",
              "succeeded",
              "failed"
            ]
          },
          "approval_url": {
            "type": "string",
            "format": "uri",
            "example": "https://api.example.app.gr4vy.com/payment-methods/f4fb0dd1-4ff9-46fb-965e-11de34aa6806/approve",
            "description": "The optional URL that the buyer needs to be redirected to to further authorize their payment.",
            "nullable": true
          },
          "token": {
            "type": "string",
            "description": "The token value. Will be present if succeeded.",
            "nullable": true
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this token was first created in our\nsystem.",
            "format": "date-time",
            "example": "2021-01-01T12:34:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this token was last updated in our system.",
            "format": "date-time",
            "example": "2021-01-01T12:34:00.000+00:00"
          }
        }
      },
      "PaymentServiceTokenRequest": {
        "title": "Payment Service Token (Provision)",
        "type": "object",
        "description": "Request body for provision a payment service token.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "payment_service_id",
          "redirect_url"
        ],
        "properties": {
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          },
          "payment_service_id": {
            "type": "string",
            "format": "uuid",
            "example": "a7d6b829-aea5-407d-ab7f-138784b5ad2c",
            "description": "The ID of the payment service."
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\npayment method. This only applies to payment methods that require buyer approval.",
            "example": "https://example.com/callback"
          }
        }
      },
      "PaymentServiceTokens": {
        "title": "Payment Service Tokens",
        "type": "object",
        "description": "A list of payment service tokens.",
        "x-tags": [
          "Tokens"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of payment service tokens.",
            "items": {
              "$ref": "#/components/schemas/PaymentServiceToken"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PaymentServiceUpdate": {
        "title": "Payment Service (Update)",
        "type": "object",
        "description": "Request body for updating an active payment service.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A custom name for the payment service. This will be shown in the Admin UI.",
            "example": "Stripe (Main)",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined by the definition for this payment service e.g. for stripe-card `secret_key` is required and so must be sent within this field.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this payment service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set; you can unset optional fields by setting this to an empty string `\"\"`.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          },
          "reporting_fields": {
            "type": "array",
            "description": "The `reporting_fields` field should contain a list of key-value pairs. Each key-value pair represents a reporting field defined by the payment service. For example, when enabling settlement reporting for `nuvei-card`, the `ssh_username` field is required and must be included in `reporting_fields`.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a reporting field defined in the definition for this payment service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "ssh_username",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set; you can unset optional fields by setting this to an empty string `\"\"`.",
                  "example": "test_ssh_user",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          },
          "accepted_countries": {
            "type": "array",
            "description": "A list of countries that this payment service needs to support in ISO two-letter code format.",
            "minItems": 1,
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            },
            "example": [
              "US",
              "GB",
              "DE"
            ]
          },
          "accepted_currencies": {
            "type": "array",
            "description": "A list of currencies that this payment service needs to support in ISO 4217 three-letter code format.",
            "minItems": 1,
            "items": {
              "type": "string",
              "minLength": 3,
              "maxLength": 3
            },
            "example": [
              "EUR",
              "USD",
              "GBP"
            ]
          },
          "three_d_secure_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "description": "Defines if 3-D Secure is enabled for the service. This feature\ncan only be enabled if the payment service definition supports\nthe `three_d_secure_hosted` feature.\nThis does not affect pass through 3-D Secure data."
          },
          "merchant_profile": {
            "type": "object",
            "nullable": true,
            "description": "Configuration for each supported card scheme.\nWhen updating a Payment Service, a key not being present will\nindicate no updates to be done on that scheme, whereas an object being\nsent as Null for a key will empty the configuration for that scheme.",
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantProfile"
              }
            ]
          },
          "active": {
            "type": "boolean",
            "example": true,
            "default": true,
            "description": "Defines if this service is currently active or not."
          },
          "open_loop": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if the service works as an open-loop service. This feature\ncan only be enabled if the PSP is set up to accept previous scheme\ntransaction IDs.\n\nIf this value is set to `null`, it will be set to the value of\n`open_loop` in the payment service definition.\n\nIf `open_loop_toggle` is `false` in the payment service definition,\n`open_loop` should either not be provided or set to `null`, or it\nwill fail with a validation error."
          },
          "payment_method_tokenization_enabled": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if tokenization is enabled for the service. This feature\ncan only be enabled if the payment service is NOT set as `open_loop`\nand the PSP is set up to tokenize."
          },
          "network_tokens_enabled": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if network tokens are enabled for the service. This feature\ncan only be enabled if the payment service is set as `open_loop` and\nthe PSP is set up to accept network tokens.\n\nIf this value is set to `null`, it will be set to the value of\n`network_tokens_default` in the payment service definition.\n\nIf `network_tokens_toggle` is `false` in the payment service definition,\n`network_tokens_enabled` should either not be provided or set to `null`,\nor it will fail with a validation error."
          },
          "settlement_reporting_enabled": {
            "type": "boolean",
            "example": true,
            "default": false,
            "nullable": false,
            "description": "Defines if settlement reporting is enabled for the service.\nThis feature can only be enabled if the payment service\ndefinition supports the `settlement_reporting` feature."
          }
        }
      },
      "PaymentServiceVerify": {
        "title": "Payment Service (Verify)",
        "type": "object",
        "description": "Request body for verifying credentials against a payment service.",
        "x-internal": true,
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "payment_service_definition_id",
          "fields"
        ],
        "properties": {
          "payment_service_definition_id": {
            "type": "string",
            "description": "The ID of the payment service to use.",
            "example": "stripe-card",
            "minLength": 1,
            "maxLength": 50
          },
          "payment_service_id": {
            "type": "string",
            "format": "uuid",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4",
            "description": "The ID of the payment service. Required if sending a partial set of\ncredentials in the `fields` property."
          },
          "fields": {
            "type": "array",
            "description": "A list of fields where each field is a key-value pair that represents a defined field in the definition of the payment service. You are not required to send the full list of fields if the credentials for the payment service are already stored.\nFor example, if your credentials for `stripe-card` are stored and you only provide a `secret_key` in the request, it will override the stored `secret_key` and verify the resulting set of credentials against the payment service.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for this payment service.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 1,
                  "maxLength": 5000
                }
              }
            }
          }
        }
      },
      "PaymentServiceDefinitionConfiguration": {
        "title": "Payment Service Definition Context",
        "type": "object",
        "description": "Configuration items for the payment service.",
        "properties": {
          "approval_ui_height": {
            "type": "string",
            "description": "Height of the approval interface in either pixels or view height (vh).",
            "example": "300px"
          },
          "approval_ui_width": {
            "type": "string",
            "description": "Width of the approval interface in either pixels or view width (vw).",
            "example": "300px"
          },
          "approval_ui_target": {
            "type": "string",
            "example": "any",
            "nullable": true,
            "description": "The browser target that an approval URL must be opened in. If `any` or `null`, then there is no specific requirement.",
            "enum": [
              "any",
              "new_window"
            ]
          }
        }
      },
      "PaymentServiceDefinition": {
        "title": "Payment Service Definition",
        "type": "object",
        "description": "An available payment service that can be configured.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the payment service. This is the underlying provider followed by a dash followed by the payment method ID.",
            "example": "stripe-card"
          },
          "type": {
            "type": "string",
            "description": "`payment-service-definition`.",
            "default": "payment-service-definition",
            "example": "payment-service-definition",
            "enum": [
              "payment-service-definition"
            ]
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this service.",
            "example": "Stripe"
          },
          "method": {
            "description": "The ID of the payment method that this services handles.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "fields": {
            "type": "array",
            "description": "A list of fields that need to be submitted when activating the payment. service.",
            "minItems": 1,
            "items": {
              "type": "object",
              "description": "A single field that needs to be submitted for a payment service when it\nis created.",
              "properties": {
                "key": {
                  "type": "string",
                  "example": "private_api_key",
                  "description": "The key of a field that needs to be submitted."
                },
                "display_name": {
                  "type": "string",
                  "example": "Private API key",
                  "description": "The name to display for a field in the dashboard."
                },
                "required": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is required when the service is created."
                },
                "format": {
                  "type": "string",
                  "example": "text",
                  "description": "Defines the type of input that needs to be rendered for this field.",
                  "enum": [
                    "text",
                    "multiline",
                    "number"
                  ]
                },
                "secret": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is secret. When `true` the field is not\nreturned when querying the payment service."
                }
              }
            }
          },
          "reporting_fields": {
            "type": "array",
            "description": "A list of fields that need to be submitted when enabling the payment service settlement reporting.",
            "minItems": 0,
            "items": {
              "type": "object",
              "description": "A single field that needs to be submitted for a payment service when the\nsettlement reporting is being enabled for it.",
              "properties": {
                "key": {
                  "type": "string",
                  "example": "username",
                  "description": "The key of a field that needs to be submitted."
                },
                "display_name": {
                  "type": "string",
                  "example": "Reporting Username",
                  "description": "The name to display for a field in the dashboard."
                },
                "required": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is required when the reporting is being enabled."
                },
                "format": {
                  "type": "string",
                  "example": "text",
                  "description": "Defines the type of input that needs to be rendered for this field.",
                  "enum": [
                    "text",
                    "multiline",
                    "number"
                  ]
                },
                "secret": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is secret. When `true` the field is not\nreturned when querying the payment service."
                }
              }
            }
          },
          "supported_currencies": {
            "type": "array",
            "description": "A list of three-letter ISO currency codes that this service supports.",
            "items": {
              "type": "string",
              "minLength": 3,
              "maxLength": 3
            },
            "minItems": 1,
            "example": [
              "USD",
              "GBP",
              "EUR"
            ]
          },
          "supported_countries": {
            "type": "array",
            "description": "A list of two-letter ISO country codes that this service supports.",
            "items": {
              "type": "string"
            },
            "minItems": 1,
            "example": [
              "US",
              "GB",
              "DE"
            ]
          },
          "mode": {
            "description": "The mode of this payment service.",
            "type": "string",
            "example": "card",
            "enum": [
              "card",
              "redirect",
              "applepay",
              "googlepay",
              "click-to-pay",
              "checkout-session"
            ]
          },
          "supported_features": {
            "type": "object",
            "description": "Features supported by the payment definition.",
            "properties": {
              "delayed_capture": {
                "type": "boolean",
                "example": false,
                "description": "Supports [capturing](#operation/capture-transaction) authorized\ntransactions."
              },
              "digital_wallets": {
                "type": "boolean",
                "example": false,
                "description": "Supports passing decrypted digital wallet (e.g. Apple Pay)\ntokens to the underlying processor."
              },
              "network_tokens_default": {
                "type": "boolean",
                "example": true,
                "description": "Supports processing network tokens by default."
              },
              "network_tokens_toggle": {
                "type": "boolean",
                "example": false,
                "description": "Supports toggling processing of network tokens on or off."
              },
              "open_loop": {
                "type": "boolean",
                "example": true,
                "description": "Supports processing transactions with either raw PAN details or\nnetwork tokens."
              },
              "open_loop_toggle": {
                "type": "boolean",
                "example": false,
                "description": "Supports toggling processing as open-loop on or off."
              },
              "partial_refunds": {
                "type": "boolean",
                "example": false,
                "description": "Supports [partially refunding](#operation/refund-transaction) captured\ntransactions."
              },
              "payment_method_tokenization": {
                "type": "boolean",
                "example": true,
                "description": "Supports storing a payment method via tokenization."
              },
              "payment_method_tokenization_toggle": {
                "type": "boolean",
                "example": false,
                "description": "Supports toggling tokenization for a payment method on or off\nfrom the dashboard."
              },
              "refunds": {
                "type": "boolean",
                "example": true,
                "description": "Supports [refunding](#operation/refund-transaction) captured\ntransactions."
              },
              "requires_webhook_setup": {
                "type": "boolean",
                "example": true,
                "description": "Requires merchant to set up `webhook_url` manually with provider."
              },
              "three_d_secure_hosted": {
                "type": "boolean",
                "example": true,
                "description": "Supports hosted 3-D Secure with a redirect."
              },
              "three_d_secure_pass_through": {
                "type": "boolean",
                "example": false,
                "description": "Supports passing 3-D Secure data to the underlying processor."
              },
              "verify_credentials": {
                "type": "boolean",
                "example": false,
                "description": "Supports verifying the credentials entered while setting up the\nunderlying processor. This is for internal use only."
              },
              "void": {
                "type": "boolean",
                "example": true,
                "description": "Supports [voiding](#operation/void-transaction) authorized\ntransactions."
              }
            }
          },
          "icon_url": {
            "type": "string",
            "nullable": true,
            "description": "An icon to display for the payment service.",
            "example": "https://cdn.gr4vy.app/stripe.svg"
          },
          "configuration": {
            "$ref": "#/components/schemas/PaymentServiceDefinitionConfiguration"
          }
        }
      },
      "PaymentServiceDefinitions": {
        "title": "Payment service definitions",
        "type": "object",
        "description": "A list of available payment services definitions.",
        "x-tags": [
          "Discovery"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentServiceDefinition"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PaymentOptionApprovalUI": {
        "title": "Payment Option Approval UI",
        "type": "object",
        "description": "Configuration for the approval interface that should be shown to the buyer.",
        "properties": {
          "height": {
            "type": "string",
            "description": "Height of the approval interface in either pixels or view height (vh).",
            "example": "300px"
          },
          "width": {
            "type": "string",
            "description": "Width of the approval interface in either pixels or view width (vw).",
            "example": "300px"
          }
        }
      },
      "PaymentOption": {
        "title": "Payment option",
        "type": "object",
        "description": "An available payment option for a locale.",
        "x-tags": [
          "Payment Option"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`payment-option`.",
            "example": "payment-option",
            "enum": [
              "payment-option"
            ]
          },
          "method": {
            "description": "The type of payment method that is available.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "icon_url": {
            "type": "string",
            "nullable": true,
            "description": "An icon to display for the payment option.",
            "example": "https://cdn.gr4vy.app/card.svg"
          },
          "mode": {
            "description": "The mode to use with this payment option.",
            "type": "string",
            "example": "card",
            "enum": [
              "card",
              "redirect",
              "applepay",
              "googlepay",
              "click-to-pay",
              "checkout-session"
            ]
          },
          "label": {
            "type": "string",
            "description": "A label that describes this payment option. This label is returned in the\nlanguage defined by the `locale` query parameter. The label can be used\nto display a list of payment options to the buyer in their language.",
            "example": "Pay by Card"
          },
          "can_store_payment_method": {
            "type": "boolean",
            "description": "A flag to indicate if storing the payment method is supported."
          },
          "can_delay_capture": {
            "type": "boolean",
            "description": "A flag to indicate if delayed capture is supported."
          },
          "context": {
            "type": "object",
            "description": "Additional context specific to the payment option.\nThis is currently only returned for Apple Pay and Google Pay.",
            "properties": {
              "gateway": {
                "type": "string",
                "description": "Gateway used for Google Pay payments."
              },
              "gateway_merchant_id": {
                "type": "string",
                "description": "Gateway merchant identifier used for Google Pay payments."
              },
              "merchant_name": {
                "type": "string",
                "description": "Display name of the merchant as registered with the digital wallet\nprovider."
              },
              "supported_schemes": {
                "type": "array",
                "description": "Card schemes supported by the digital wallet provider.",
                "items": {
                  "$ref": "#/components/schemas/PaymentOptionCardScheme"
                }
              },
              "approval_ui": {
                "$ref": "#/components/schemas/PaymentOptionApprovalUI"
              },
              "required_fields": {
                "$ref": "#/components/schemas/RequiredFields"
              }
            }
          }
        }
      },
      "PaymentOptions": {
        "title": "A list of payment options",
        "type": "object",
        "description": "A list of payment options.",
        "x-tags": [
          "Payment Options"
        ],
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentOption"
            }
          }
        }
      },
      "Payout": {
        "title": "Payout",
        "type": "object",
        "x-tags": [
          "Payout"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `payout`.",
            "example": "payout",
            "enum": [
              "payout"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of a payout.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The optional ID of the merchant account this payout should be assigned to.",
            "example": "default",
            "nullable": true,
            "maxLength": 22
          },
          "amount": {
            "description": "The monetary amount for this payout, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.",
            "type": "integer",
            "example": 1299
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "A supported ISO-4217 currency code."
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this payout was created.",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this payout was created.",
            "format": "date-time",
            "example": "2022-01-01T12:00:00+00:00"
          },
          "payment_service": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentService--Snapshot"
              }
            ],
            "description": "The payment service used for this payout."
          },
          "payment_service_payout_id": {
            "type": "string",
            "example": "example",
            "description": "The ID of the payout in the underlying payment service.",
            "nullable": true
          },
          "category": {
            "type": "string",
            "description": "The type of payout to process.",
            "example": "online_gambling",
            "enum": [
              "online_gambling"
            ]
          },
          "status": {
            "type": "string",
            "example": "pending",
            "description": "The status of the payout.",
            "enum": [
              "pending",
              "failed",
              "declined",
              "succeeded"
            ]
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the payout against your own records. This value needs to be unique for all buyers.",
            "example": "user-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "merchant": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Merchant"
              }
            ],
            "description": "The merchant details associated to this payout.",
            "nullable": true
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer--Snapshot"
              }
            ],
            "description": "The buyer used for this transaction."
          },
          "payment_method": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentMethod--Snapshot"
              }
            ],
            "description": "The payment method used for this payout."
          }
        }
      },
      "Payouts": {
        "title": "Payouts",
        "type": "object",
        "description": "A list of payouts.",
        "x-tags": [
          "Payouts"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of payouts.",
            "items": {
              "$ref": "#/components/schemas/Payout"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PayoutConnectionOptionsRequest": {
        "title": "Payout",
        "type": "object",
        "x-tags": [
          "Payout"
        ],
        "properties": {
          "checkout-card": {
            "type": "object",
            "description": "Custom options for checkout-card payment service.",
            "nullable": true,
            "properties": {
              "source_id": {
                "type": "string",
                "description": "The ID of the currency account that will fund the payout."
              },
              "processing_channel_id": {
                "type": "string",
                "description": "The processing channel to be used for the payment."
              }
            }
          }
        }
      },
      "PayoutPaymentMethodRequest": {
        "title": "Payout payment method (Request)",
        "type": "object",
        "description": "Payment method details for a payout.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method"
        ],
        "properties": {
          "method": {
            "type": "string",
            "example": "card",
            "description": "The method to use.",
            "enum": [
              "card",
              "id"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the stored payment method.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79",
            "nullable": true
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this card as it can be found on the\nfront of the card.",
            "nullable": true
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5,
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "card-323444",
            "nullable": true
          },
          "scheme": {
            "nullable": true,
            "description": "The card scheme.",
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          }
        }
      },
      "PayoutInlineCardRequest": {
        "title": "Payout card payment method",
        "type": "object",
        "description": "Inline card details.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "number",
          "expiration_date"
        ],
        "properties": {
          "method": {
            "type": "string",
            "example": "card",
            "description": "The method to use.",
            "enum": [
              "card"
            ]
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this card as it can be found on the\nfront of the card."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "card-323444",
            "nullable": true
          },
          "scheme": {
            "nullable": true,
            "description": "The card scheme.",
            "type": "string",
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          }
        }
      },
      "PayoutStoredCardRequest": {
        "title": "Payout card payment method",
        "type": "object",
        "description": "Stored card reference.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "example": "id",
            "description": "The method to use.",
            "enum": [
              "id"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the stored payment method.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          }
        }
      },
      "PayoutRequest": {
        "title": "Payout (Create)",
        "type": "object",
        "description": "Request body for creating new payout.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "currency",
          "payment_method",
          "payment_service_id"
        ],
        "properties": {
          "amount": {
            "type": "number",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999,
            "description": "The amount to payout."
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code for the payout."
          },
          "payment_service_id": {
            "type": "string",
            "format": "uuid",
            "example": "a7d6b829-aea5-407d-ab7f-138784b5ad2c",
            "description": "The ID of the payment service to use for the payout."
          },
          "category": {
            "type": "string",
            "description": "The type of payout to process.",
            "example": "online_gambling",
            "default": "online_gambling",
            "enum": [
              "online_gambling"
            ]
          },
          "external_identifier": {
            "type": "string",
            "description": "A value that can be used to match the payout against your own records.",
            "example": "payout-123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to send the payout.",
            "nullable": true
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to send this payout to.",
            "example": "user-789123",
            "maxLength": 200,
            "nullable": true
          },
          "buyer": {
            "description": "Inline buyer details for the payout.",
            "allOf": [
              {
                "$ref": "#/components/schemas/TransactionBuyerRequest"
              }
            ],
            "type": "object",
            "nullable": true
          },
          "merchant": {
            "type": "object",
            "description": "Merchant information for the source of the payout.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/MerchantRequest"
              }
            ]
          },
          "payment_method": {
            "type": "object",
            "x-model-name": "PayoutPaymentMethodRequest",
            "description": "The type of payment method to send funds too.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/PayoutInlineCardRequest"
              },
              {
                "$ref": "#/components/schemas/PayoutStoredCardRequest"
              }
            ]
          },
          "connection_options": {
            "type": "object",
            "description": "Optional fields for processing payouts on specific payment services.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/PayoutConnectionOptionsRequest"
              }
            ]
          }
        }
      },
      "PCIForwardAuthenticationDefinition": {
        "title": "Vault Forward Authentication Definition",
        "type": "object",
        "x-internal": true,
        "description": "An available Vault Forward authentication definition that can be configured.",
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. It is always\n`vault-forward-authentication-definition`.",
            "default": "vault-forward-authentication-definition",
            "example": "vault-forward-authentication-definition"
          },
          "kind": {
            "type": "string",
            "description": "The kind of authentication to be used in a Vault Forward request.\n",
            "enum": [
              "mle",
              "mtls",
              "signature"
            ],
            "example": "mle"
          },
          "title": {
            "type": "string",
            "description": "The title of this authentication definition.",
            "example": "Message Level Encryption"
          },
          "description": {
            "type": "string",
            "description": "The description of this authentication definition.",
            "example": "A way to set up payload encryption"
          },
          "fields": {
            "type": "array",
            "description": "A list of fields that can to be submitted when activating the\nauthentication method.",
            "minItems": 1,
            "items": {
              "type": "object",
              "description": "A single field that can be submitted for an authentication method when\nit is created.",
              "properties": {
                "key": {
                  "type": "string",
                  "example": "private_api_key",
                  "description": "The key of a field that can be submitted."
                },
                "display_name": {
                  "type": "string",
                  "example": "Private API key",
                  "description": "The name to display for a field in the dashboard."
                },
                "required": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is required when the authentication method\nis created."
                },
                "format": {
                  "type": "string",
                  "example": "text",
                  "description": "Defines the type of input that needs to be rendered for this field.",
                  "enum": [
                    "text",
                    "multiline",
                    "file",
                    "number"
                  ]
                },
                "secret": {
                  "type": "boolean",
                  "example": true,
                  "description": "Defines if this field is secret. When `true` the field is not\nreturned when querying the authentication method."
                }
              }
            }
          }
        }
      },
      "PCIForwardDefinition": {
        "title": "Vault Forward Definition",
        "type": "object",
        "description": "An available Vault Forward definition that can be configured.",
        "x-internal": true,
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the Vault Forward definition.",
            "example": "amadeus"
          },
          "type": {
            "type": "string",
            "description": "The type of this resource. It is always `vault-forward-definition`.",
            "default": "vault-forward-definition",
            "example": "vault-forward-definition"
          },
          "display_name": {
            "type": "string",
            "description": "The display name of this definition.",
            "example": "Amadeus"
          },
          "hosts": {
            "type": "array",
            "description": "The hosts where Vault Forward requests are allowed for this definition.",
            "minItems": 0,
            "items": {
              "type": "string"
            },
            "example": [
              "https://api.amadeus.com",
              "https://test.api.amadeus.com"
            ]
          },
          "authentications": {
            "type": "array",
            "description": "Available authentication methods to be configured for this definition.",
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/PCIForwardAuthenticationDefinition"
            }
          }
        }
      },
      "PCIForwardDefinitions": {
        "title": "Vault Forward definitions",
        "type": "object",
        "description": "A definitions list of all the PCI endpoints that we can send card data to.",
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PCIForwardDefinition"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PCIForwardConfig": {
        "title": "A Vault Forward configuration",
        "type": "object",
        "description": "A configured Vault Forward configuration.",
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. It is always `vault-forward-config`.",
            "default": "vault-forward-config",
            "example": "vault-forward-config"
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this Vault Forward configuration.",
            "example": "faaad066-30b4-4997-a438-242b0752d7e1"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this configuration was created."
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this configuration was last updated."
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "definition_id": {
            "type": "string",
            "description": "The ID of the Vault Forward definition.",
            "example": "amadeus"
          },
          "display_name": {
            "type": "string",
            "description": "The display name for this configuration.",
            "example": "Amadeus"
          },
          "hosts": {
            "type": "array",
            "description": "The hosts where Vault Forward requests are allowed for this definition.",
            "minItems": 1,
            "items": {
              "type": "string"
            },
            "example": [
              "https://api.amadeus.com",
              "https://test.api.amadeus.com"
            ]
          },
          "authentications": {
            "type": "array",
            "description": "Authentication methods that can be applied in Vault Forward requests.",
            "minItems": 0,
            "items": {
              "$ref": "#/components/schemas/PCIForwardConfigAuthentication"
            }
          },
          "creator": {
            "type": "object",
            "description": "The user who created the Vault Forward configuration.",
            "nullable": true,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the user.",
                "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
              },
              "name": {
                "type": "string",
                "description": "The name of the user.",
                "example": "John L"
              },
              "email_address": {
                "type": "string",
                "description": "The email address for this user.",
                "example": "john@example.com"
              }
            }
          }
        }
      },
      "PCIForwardConfigs": {
        "title": "Vault Forward configurations",
        "type": "object",
        "description": "A list of available Vault Forward configurations.",
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PCIForwardConfig"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "PCIForwardConfigAuthentication": {
        "title": "A Vault Forward authentication method",
        "type": "object",
        "description": "A configured Vault Forward authentication method.",
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. It is always `vault-forward-config-authentication`.",
            "default": "vault-forward-config-authentication",
            "example": "vault-forward-config-authentication"
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of this Vault Forward authentication method.",
            "example": "faaad066-30b4-4997-a438-242b0752d7e1"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this configuration was created."
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "example": "2012-12-12T10:53:43+00:00",
            "description": "The date and time when this configuration was last updated."
          },
          "kind": {
            "type": "string",
            "description": "The kind of authentication to be used in a Vault Forward request.\n",
            "enum": [
              "mle",
              "mtls",
              "signature"
            ],
            "example": "mle"
          },
          "label": {
            "type": "string",
            "description": "A label that describes this authentication method.",
            "example": "My MLE"
          },
          "display_name": {
            "type": "string",
            "description": "The display name for this authentication method given when created.",
            "example": "My MLE"
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field\nconfigured for this authentication method. Fields marked as `secret`\nare not returned.",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 50,
                  "description": "The key of the field.",
                  "example": "secret_key"
                },
                "value": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 5000,
                  "description": "The value of the field.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd"
                }
              }
            }
          },
          "creator": {
            "type": "object",
            "description": "The user who created the Vault Forward authentication method.",
            "nullable": true,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the user.",
                "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5"
              },
              "name": {
                "type": "string",
                "description": "The name of the user.",
                "example": "John L"
              },
              "email_address": {
                "type": "string",
                "description": "The email address for this user.",
                "example": "john@example.com"
              }
            }
          }
        }
      },
      "PCIForwardConfigAuthentications": {
        "title": "Vault Forward authentication methods",
        "type": "object",
        "description": "A list of configured Vault Forward authentication methods.",
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PCIForwardConfigAuthentication"
            }
          }
        }
      },
      "PCIForwardConfigAuthenticationRequest": {
        "title": "Vault Forward authentication method (Create)",
        "type": "object",
        "description": "Request body to create a Vault Forward authentication method.",
        "x-internal": true,
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "kind",
          "display_name",
          "fields"
        ],
        "properties": {
          "kind": {
            "type": "string",
            "description": "The kind of authentication to be used in a Vault Forward request.\n",
            "enum": [
              "mle",
              "mtls",
              "signature"
            ],
            "example": "mle"
          },
          "display_name": {
            "type": "string",
            "description": "A custom name for the authentication method. This will be shown in the Admin UI.",
            "example": "My Message Level Encryption",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined\nby the definition for this authentication method.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for\nthis authentication method.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          }
        }
      },
      "PCIForwardConfigAuthenticationUpdate": {
        "title": "Vault Forward authentication method (Update)",
        "type": "object",
        "description": "Request body to update a Vault Forward authentication method.",
        "x-internal": true,
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "display_name": {
            "type": "string",
            "description": "A custom name for the authentication method. This will be shown in the Admin UI.",
            "example": "My Message Level Encryption",
            "minLength": 1,
            "maxLength": 50
          },
          "fields": {
            "type": "array",
            "description": "A list of fields, each containing a key-value pair for each field defined\nby the definition for this authentication method.",
            "items": {
              "type": "object",
              "description": "A key-value pair that represents a field defined in the definition for\nthis authentication method.",
              "required": [
                "key",
                "value"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The key of the field to set a value for.",
                  "example": "private_key",
                  "minLength": 1,
                  "maxLength": 50
                },
                "value": {
                  "type": "string",
                  "description": "The value of a field to set; you can unset optional fields by\nsetting this to an empty string `\"\"`.",
                  "example": "sk_test_26PHem9AhJZvU623DfE1x4sd",
                  "minLength": 0,
                  "maxLength": 5000
                }
              }
            }
          }
        }
      },
      "PCIForwardConfigRequest": {
        "title": "Vault Forward configuration (Create)",
        "type": "object",
        "description": "Request body to create a Vault Forward configuration.",
        "x-internal": true,
        "required": [
          "definition_id"
        ],
        "properties": {
          "definition_id": {
            "type": "string",
            "description": "The ID of the Vault Forward definition to configure.",
            "example": "amadeus"
          }
        }
      },
      "RedirectRequest": {
        "title": "Redirect",
        "type": "object",
        "description": "Details to register a new redirect payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "redirect_url",
          "country",
          "currency"
        ],
        "properties": {
          "method": {
            "description": "The method to use, this can be any of the methods that\nsupport redirect requests.",
            "type": "string",
            "example": "paypal",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "gopay",
              "grabpay",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_10x",
              "oney_12x",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "venmo",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction.",
            "example": "https://example.com/callback"
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code to use this payment method for. This is\nused to select the payment service to use."
          },
          "country": {
            "type": "string",
            "example": "US",
            "description": "The 2-letter ISO code of the country to use this payment method for.\nThis is used to select the payment service to use."
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the account against your own records.",
            "example": "account-23423423",
            "nullable": true
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The ID of the buyer to associate this payment method to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset."
          },
          "buyer_external_identifier": {
            "type": "string",
            "description": "The `external_identifier` of the buyer to associate this payment method\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.",
            "example": "user-789123"
          }
        }
      },
      "Refund": {
        "title": "Refund",
        "type": "object",
        "description": "A refund record.\n\nA refund is always associated with a single transaction, while a transaction\ncan potentially have several refunds.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `refund`.",
            "enum": [
              "refund"
            ],
            "example": "refund"
          },
          "id": {
            "type": "string",
            "description": "The unique ID of the refund.",
            "format": "uuid",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "transaction_id": {
            "type": "string",
            "description": "The ID of the transaction associated with this refund.",
            "format": "uuid",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "payment_service_refund_id": {
            "type": "string",
            "description": "The payment service's unique ID for the refund.",
            "example": "refund_xYqd43gySMtori"
          },
          "status": {
            "type": "string",
            "description": "The status of the refund.\nIt may change over time as asynchronous processing events occur.\n\n- `processing` - The refund is being processed.\n- `succeeded` - The refund was successful.\n- `declined` - The refund was declined by the underlying PSP.\n- `failed` - The refund could not proceed due to a technical issue.",
            "enum": [
              "processing",
              "succeeded",
              "declined",
              "failed"
            ],
            "example": "processing"
          },
          "currency": {
            "type": "string",
            "description": "The currency code for this refund.\nWill always match that of the associated transaction.",
            "example": "USD"
          },
          "amount": {
            "type": "integer",
            "description": "The amount requested for this refund.",
            "minimum": 0,
            "maximum": 99999999,
            "example": 1299
          },
          "reason": {
            "type": "string",
            "maximum": 100,
            "description": "The reason for this refund.\nCould be a multiline string.",
            "example": "Refund due to user request",
            "default": null,
            "nullable": true,
            "maxLength": 100
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this refund was created.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time when this refund was last updated.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "target_type": {
            "type": "string",
            "description": "The type of the instrument that was refunded.",
            "example": "payment-method",
            "enum": [
              "payment-method",
              "gift-card-redemption"
            ]
          },
          "target_id": {
            "type": "string",
            "nullable": true,
            "description": "The optional ID of the instrument that was refunded. This may be `null` if\nthe instrument was not stored.",
            "example": "c23ea83f-1b1c-4584-a0e8-78ef8c041949"
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the refund against your\nown records.",
            "example": "refund-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 300
          },
          "reconciliation_id": {
            "description": "The base62 encoded refund ID. This represents a shorter version\nof this refund's `id` which is sent to payment services, anti-fraud services,\nand other connectors. You can use this ID to reconcile a payment service's\nrefund against our system.",
            "example": "7jZXl4gBUNl0CnaLEnfXbt",
            "type": "string"
          },
          "transaction_external_identifier": {
            "type": "string",
            "description": "The external identifier of the related transaction.",
            "example": "transaction-789123",
            "nullable": true
          },
          "transaction_reconciliation_id": {
            "description": "The base62 encoded transaction ID. This represents a shorter version\nof the related transaction's `id` which is sent to payment services,\nanti-fraud services, and other connectors. You can use this ID to\nreconcile a payment service's transaction against our system.",
            "example": "7jZXl4gBUNl0CnaLEnfXbt",
            "type": "string"
          }
        }
      },
      "Refunds": {
        "title": "Refunds",
        "type": "object",
        "description": "A list of refunds.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of refunds.",
            "items": {
              "$ref": "#/components/schemas/Refund"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "Report": {
        "title": "Report",
        "type": "object",
        "description": "A report record.",
        "x-tags": [
          "Reports"
        ],
        "allOf": [
          {
            "$ref": "#/components/schemas/ReportSummary"
          }
        ],
        "properties": {
          "created_at": {
            "type": "string",
            "description": "The date and time this report was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time this report was last updated.",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "next_execution_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time this report will next be executed, provided\nthat `schedule_enabled` is `true`. This value is null if this\nis a one-off report.",
            "example": "2023-01-01T00:00:00.000+00:00",
            "nullable": true
          },
          "description": {
            "type": "string",
            "maxLength": 1000,
            "description": "The description of this report.",
            "example": "Transactions that failed to authorize in April 2022",
            "nullable": true
          },
          "schedule": {
            "type": "string",
            "description": "Specifies the schedule of this report.\n\nIf this is a one-off report, this value is `once`.\n\nIf this is a recurring report, this value is set to the\nfrequency by which the report will be executed. For example, a\n`monthly` schedule means that this report will be periodically\nexecuted at the start of each month.\n\nNote that a `weekly` schedule means that the report is executed\nat the start of every Monday.",
            "example": "monthly",
            "enum": [
              "daily",
              "monthly",
              "once",
              "weekly"
            ]
          },
          "schedule_enabled": {
            "type": "boolean",
            "description": "Indicates whether this report's scheduling is enabled. This value\ncan only be set to `true` if this is a recurring report.\n\nWhen this value is set to `true`, this report will be executed at\nthe `next_execution_at` date and time.\n\nWhen this value is set to `false`, future executions of this\nreport are paused until this value is set to `true` again.",
            "example": true
          },
          "schedule_timezone": {
            "type": "string",
            "description": "The time zone in which the next execution will be scheduled. This\nvalue is used to calculate this report's `next_execution_at` value\nand is only relevant if this is a recurring report. This time zone\nis also used to calculate the timestamp range for reports that use\ndate-time placeholders. Date-time placeholders are dynamic\ntimestamps that change with every report execution."
          },
          "spec": {
            "type": "object",
            "description": "The specifications of this report.",
            "nullable": false,
            "x-model-name": "ReportSpec",
            "oneOf": [
              {
                "$ref": "#/components/schemas/DetailedSettlementReportSpec"
              },
              {
                "$ref": "#/components/schemas/TransactionRetriesReportSpec"
              },
              {
                "$ref": "#/components/schemas/TransactionsReportSpec"
              }
            ]
          },
          "latest_execution": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ReportExecutionSummary"
              }
            ],
            "description": "Details of the latest execution of this report.",
            "nullable": true
          }
        }
      },
      "ReportCreate": {
        "title": "Report (Create)",
        "type": "object",
        "description": "A request to create a report.",
        "x-tags": [
          "Reports"
        ],
        "required": [
          "name",
          "spec"
        ],
        "properties": {
          "name": {
            "type": "string",
            "maxLength": 100,
            "description": "The name of the report.",
            "example": "Failed Authorizations 042022",
            "nullable": false
          },
          "description": {
            "type": "string",
            "maxLength": 1000,
            "description": "The description of the report.",
            "example": "Transactions that failed to authorize in April 2022",
            "nullable": true
          },
          "schedule": {
            "type": "string",
            "description": "Specifies the schedule of the report.\n\nIf this is a one-off report, set this value to `once`.\n\nIf this is a recurring report, this value should be set to the\nfrequency by which the report will be executed. For example, a\n`monthly` schedule means that the report will be periodically\nexecuted at the start of each month.\n\nNote that a `weekly` schedule means that the report will be\nexecuted at the start of every Monday.",
            "example": "monthly",
            "enum": [
              "daily",
              "monthly",
              "once",
              "weekly"
            ],
            "default": "once",
            "nullable": false
          },
          "schedule_enabled": {
            "type": "boolean",
            "description": "Indicates whether the report's scheduling is enabled. This value\ncan only be set to `true` if this is a recurring report.\n\nIf this value is set to `true`, the report will be executed at\nthe `next_execution_at` date and time.\n\nIf this is a recurring report and this value is set to `false`,\nexecutions of the report will not occur until this value is set\nto `true`.\n\nIf this value is not provided, `schedule_enabled` will\nautomatically be set to `false` if `schedule` is `once` and set to\n`true` otherwise.",
            "example": true,
            "nullable": true
          },
          "schedule_timezone": {
            "type": "string",
            "description": "The time zone in which the report's executions will be scheduled.\nThis value is used to compute the report's `next_execution_at`\nvalue and is only relevant when this is a recurring report. This\ntime zone is also used to calculate the timestamp range for reports\nthat use date-time placeholders. Date-time placeholders are dynamic\ntimestamps that change with every report execution.\n\nThis value must be set to the time zone's name as presented in\nthe IANA time zone database. For example, to schedule reports in\nthe time zone of New York, set this value to `America/New_York`.",
            "example": "Europe/London",
            "default": "Etc/UTC",
            "nullable": false
          },
          "spec": {
            "type": "object",
            "description": "The specifications of the report.",
            "nullable": false,
            "x-model-name": "ReportSpec",
            "oneOf": [
              {
                "$ref": "#/components/schemas/DetailedSettlementReportSpec"
              },
              {
                "$ref": "#/components/schemas/TransactionRetriesReportSpec"
              },
              {
                "$ref": "#/components/schemas/TransactionsReportSpec"
              }
            ]
          }
        }
      },
      "ReportExecution": {
        "title": "Report Execution",
        "type": "object",
        "description": "A report execution.",
        "x-tags": [
          "Reports"
        ],
        "allOf": [
          {
            "$ref": "#/components/schemas/ReportExecutionSummary"
          }
        ],
        "properties": {
          "report": {
            "type": "object",
            "description": "The report associated with this report execution.",
            "allOf": [
              {
                "$ref": "#/components/schemas/ReportSummary"
              }
            ]
          }
        }
      },
      "ReportExecutionSummary": {
        "title": "Report Execution Summary",
        "type": "object",
        "description": "A report execution summary.",
        "x-tags": [
          "Reports"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `report-execution`.",
            "example": "report-execution",
            "enum": [
              "report-execution"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this report execution.",
            "format": "uuid"
          },
          "created_at": {
            "type": "string",
            "description": "The date and time this report execution was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time this report execution was last updated.",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "status": {
            "type": "string",
            "description": "The status of this report execution.",
            "example": "succeeded",
            "enum": [
              "dispatched",
              "failed",
              "pending",
              "processing",
              "succeeded"
            ]
          },
          "context": {
            "type": "object",
            "description": "Contains the context values used to compute the value of date-time\nplaceholders such as `month_start` and `month_end` if present in\nthe report's specification. Date-time placeholders are dynamic\ntimestamps that change with every report execution.",
            "properties": {
              "reference_timestamp": {
                "type": "string",
                "format": "date-time",
                "description": "The date and time used by the system as a reference point to\ncompute date-time placeholders.",
                "example": "2013-07-16T19:23:00.000+00:00"
              },
              "reference_timezone": {
                "type": "string",
                "description": "The time zone used to compute date-time placeholders.",
                "example": "Europe/London"
              }
            }
          }
        }
      },
      "ReportExecutionUrl": {
        "title": "Report Execution URL",
        "type": "object",
        "description": "The temporary signed URL to download the result of a report execution\nand its expiration date and time.",
        "x-tags": [
          "Reports"
        ],
        "properties": {
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The URL to download the report execution.",
            "example": "https://example.com/download"
          },
          "expires_at": {
            "type": "string",
            "description": "The date and time when the download URL expires.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          }
        }
      },
      "ReportExecutions": {
        "title": "Report Executions",
        "type": "object",
        "description": "A list of report executions.",
        "x-tags": [
          "Reports"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of report executions.",
            "items": {
              "$ref": "#/components/schemas/ReportExecution"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "ReportSpec": {
        "title": "Report Specification",
        "type": "object",
        "description": "The specification of a report.",
        "x-tags": [
          "Reports"
        ],
        "required": [
          "model",
          "params"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "The model (dataset) that the data used for the report is retrieved\nfrom.",
            "example": "transactions",
            "enum": [
              "transactions",
              "detailed_settlement",
              "transaction_retries"
            ]
          },
          "params": {
            "type": "object",
            "description": "Parameters used to configure the report. Acceptable values for\nthis property depend on the value specified for `model`."
          }
        }
      },
      "ReportSummary": {
        "title": "Report Summary",
        "type": "object",
        "description": "A report record summary.",
        "x-tags": [
          "Reports"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `report`.",
            "example": "report",
            "enum": [
              "report"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this report.",
            "format": "uuid"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "name": {
            "type": "string",
            "maxLength": 100,
            "description": "The name of this report.",
            "example": "Failed Authorizations 042022"
          },
          "creator_id": {
            "type": "string",
            "example": "bd5d40d1-913b-419c-bd62-84efc46e0026",
            "description": "The unique identifier for the creator of this report.",
            "format": "uuid",
            "nullable": true
          },
          "creator_display_name": {
            "type": "string",
            "maxLength": 1000,
            "description": "The name of the creator of this report.",
            "example": "John Doe",
            "nullable": true
          },
          "creator_type": {
            "type": "string",
            "description": "The type of the creator of this report.",
            "nullable": true,
            "enum": [
              "user",
              "private_key"
            ]
          }
        }
      },
      "ReportUpdate": {
        "title": "Report (Update)",
        "type": "object",
        "description": "Request body to update a report.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "name": {
            "type": "string",
            "maxLength": 100,
            "description": "The name of the report.",
            "example": "Failed Authorizations 042022",
            "nullable": false
          },
          "description": {
            "type": "string",
            "maxLength": 1000,
            "description": "The description of the report.",
            "example": "Transactions that failed to authorize in April 2022",
            "nullable": true
          },
          "schedule_enabled": {
            "type": "boolean",
            "description": "Indicates whether the report's scheduling is enabled. This value\ncan only be set to `true` if this is a recurring report.\n\nWhen this value is set to `true`, the report will be executed at\nthe `next_execution_at` date and time.\n\nWhen this value is set to `false`, future executions of the\nreport are paused until this value is set to `true` again.\n\nIf scheduling is enabled after being disabled, then the\n`next_execution_at` value is updated if and only if its current\nvalue is a past date-time. The `next_execution_at` value is then\nset to the next closest date-time in the future depending on the\nvalues of `schedule` and `schedule_timezone`.",
            "example": true,
            "nullable": false
          }
        }
      },
      "Reports": {
        "title": "Reports",
        "type": "object",
        "description": "A list of reports.",
        "x-tags": [
          "Reports"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of reports.",
            "items": {
              "$ref": "#/components/schemas/Report"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "Role": {
        "title": "Role",
        "type": "object",
        "x-tags": [
          "Roles"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Always `role`.",
            "example": "role",
            "enum": [
              "role"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The unique ID for this role.",
            "example": "462ab2e2-3e29-44bd-b39f-e4d1293affbb"
          },
          "name": {
            "type": "string",
            "description": "The unique name for this role.",
            "example": "Support"
          },
          "description": {
            "type": "string",
            "description": "The description for this role.",
            "example": "Customer support agents"
          },
          "permissions": {
            "$ref": "#/components/schemas/RolePermissions"
          }
        }
      },
      "Roles": {
        "title": "Roles",
        "type": "object",
        "description": "A list of roles.",
        "x-tags": [
          "Roles"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of roles.",
            "items": {
              "$ref": "#/components/schemas/Role"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "RoleAssignment": {
        "title": "Role Assignment",
        "type": "object",
        "x-tags": [
          "Roles"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Always `role-assignment`.",
            "example": "role-assignment",
            "enum": [
              "role-assignment"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The unique ID for this role assignment.",
            "example": "1cdac457-400f-4866-8da6-5c193a8db158"
          },
          "role": {
            "$ref": "#/components/schemas/Role"
          },
          "assignee": {
            "type": "object",
            "description": "The assignee for this role assignment.",
            "properties": {
              "type": {
                "type": "string",
                "description": "The type of the assignee.",
                "example": "user",
                "enum": [
                  "user"
                ]
              },
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique ID of the assignee.",
                "example": "42aae896-8ce2-4a60-b80a-5f6ae1dfbbd4"
              }
            }
          }
        }
      },
      "RoleAssignments": {
        "title": "Role Assignments",
        "type": "object",
        "description": "A list of role assignments.",
        "x-tags": [
          "Roles"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of role assignments.",
            "items": {
              "$ref": "#/components/schemas/RoleAssignment"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "RoleAssignmentRequest": {
        "title": "Role Assignment (Create)",
        "description": "A request to create a role assignment.",
        "type": "object",
        "x-tags": [
          "Roles"
        ],
        "required": [
          "role",
          "assignee"
        ],
        "properties": {
          "role": {
            "type": "object",
            "description": "The role to associate with the role assignment.",
            "required": [
              "id"
            ],
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the role to associate with the role assignment.",
                "example": "462ab2e2-3e29-44bd-b39f-e4d1293affbb"
              }
            }
          },
          "assignee": {
            "type": "object",
            "description": "The assignee to associate with the role assignment.",
            "required": [
              "type",
              "id"
            ],
            "properties": {
              "type": {
                "type": "string",
                "description": "The type of the assignee to associate with the role assignment.",
                "example": "user",
                "enum": [
                  "user"
                ]
              },
              "id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the assignee to associate with the role assignment.",
                "example": "42aae896-8ce2-4a60-b80a-5f6ae1dfbbd4"
              }
            }
          }
        }
      },
      "RolePermissions": {
        "type": "object",
        "title": "Role permissions",
        "description": "The permissions associated with a role.",
        "x-tags": [
          "Roles"
        ],
        "properties": {
          "allow": {
            "type": "array",
            "description": "The list of permissions to allow for a role.",
            "items": {
              "type": "string"
            },
            "example": [
              "buyers.read",
              "payment-methods.read",
              "transactions.read"
            ]
          }
        }
      },
      "Session": {
        "title": "Session",
        "description": "A user session.",
        "type": "object",
        "x-tags": [
          "Authentication"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "example": "auth.session",
            "description": "`auth.session`.",
            "enum": [
              "auth.session"
            ]
          },
          "token_type": {
            "type": "string",
            "enum": [
              "bearer"
            ],
            "example": "bearer",
            "description": "`bearer`."
          },
          "access_token": {
            "type": "string",
            "description": "A server-signed JWT that can be used as the bearer token in any\nAPI calls.",
            "example": "c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ"
          },
          "refresh_token": {
            "type": "string",
            "description": "A server-signed JWT that can be used as the bearer token to refresh the\naccess token.",
            "example": "nJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ3FIOG9vSGV4VHo4QzAyg5T1JvNc"
          },
          "expires_in": {
            "type": "integer",
            "format": "int64",
            "example": 3600,
            "description": "The time in seconds in seconds by which the `access_token` token will\nexpire."
          }
        }
      },
      "SessionRequest": {
        "title": "Generic session request",
        "type": "object",
        "description": "A request to create a session using an email address and password,\nor with a token.",
        "x-internal": true,
        "x-tags": [
          "Authentication"
        ],
        "properties": {
          "email_address": {
            "type": "string",
            "description": "The email address of the user to log in as.",
            "example": "john@example.com"
          },
          "password": {
            "type": "string",
            "description": "The password the user to log in as.",
            "example": "this-is-n0t-a-secure-passw0rd"
          },
          "token": {
            "type": "string",
            "description": "The Google ID token.",
            "example": "XYZ123"
          }
        }
      },
      "SessionRequestEmailAndPassword": {
        "title": "Username/password session",
        "type": "object",
        "description": "A request to create a session using an email address and password.",
        "x-internal": true,
        "x-tags": [
          "Authentication"
        ],
        "required": [
          "email_address",
          "password"
        ],
        "properties": {
          "email_address": {
            "type": "string",
            "description": "The email address of the user to log in as.",
            "example": "john@example.com"
          },
          "password": {
            "type": "string",
            "description": "The password the user to log in as.",
            "example": "this-is-n0t-a-secure-passw0rd"
          }
        }
      },
      "SessionRequestToken": {
        "title": "Token session",
        "type": "object",
        "description": "A request to create a session using an ID token.",
        "x-internal": true,
        "x-tags": [
          "Authentication"
        ],
        "required": [
          "token"
        ],
        "properties": {
          "token": {
            "type": "string",
            "description": "The Google ID token.",
            "example": "XYZ123"
          }
        }
      },
      "Settlement": {
        "title": "Settlement",
        "type": "object",
        "description": "A settlement record.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `settlement`.",
            "example": "settlement",
            "enum": [
              "settlement"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The unique identifier for this settlement.",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The ID of the merchant account to which this settlement belongs to.",
            "example": "default"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time when this settlement was created in our system.",
            "example": "2024-04-01T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time when this settlement was last updated.",
            "example": "2024-04-01T19:23:00.000+00:00"
          },
          "posted_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time when this settlement occurred.",
            "example": "2024-03-30T10:25:00.000+00:00"
          },
          "ingested_at": {
            "type": "string",
            "format": "date-time",
            "description": "The date and time when information about this settlement\nwas ingested into our system.",
            "example": "2013-04-01T01:01:00.000+00:00"
          },
          "currency": {
            "type": "string",
            "description": "The currency code of this settlement in ISO 4217\nthree-letter code format.",
            "example": "USD"
          },
          "amount": {
            "type": "integer",
            "description": "The net amount of this settlement.",
            "example": 1299
          },
          "exchange_rate": {
            "type": "number",
            "nullable": true,
            "description": "The exchange rate used to convert amounts from the\nprocessing currency to the settlement currency.",
            "example": 0.95
          },
          "commission": {
            "type": "integer",
            "description": "The total commission of this settlement, expressed in `currency`.",
            "example": 5
          },
          "interchange": {
            "type": "integer",
            "nullable": true,
            "description": "The interchange fee of this settlement, expressed in `currency`.",
            "example": 5
          },
          "markup": {
            "type": "integer",
            "nullable": true,
            "description": "The markup of this settlement by the acquirer, expressed in `currency`.",
            "example": 10
          },
          "scheme_fee": {
            "type": "integer",
            "nullable": true,
            "description": "The scheme fee of this settlement, expressed in `currency`.",
            "example": 5
          },
          "payment_service_report_id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the payment service report containing\nthis settlement.",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "payment_service_report_file_ids": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The list of payment service report file IDs that make up the\npayment service report containing this settlement.",
            "example": [
              "0302e601-d2c3-42b2-9825-9457145331ae",
              "7deec061-71a5-435f-beae-40f35820ca67"
            ]
          },
          "transaction_id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the transaction associated with this settlement.",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9"
          }
        }
      },
      "Settlements": {
        "title": "Settlements",
        "description": "A list of settlements.",
        "type": "object",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of settlements.",
            "items": {
              "$ref": "#/components/schemas/Settlement"
            }
          }
        }
      },
      "ShippingDetail": {
        "title": "Shipping detail",
        "type": "object",
        "description": "Shipping detail for a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `shipping-details`.",
            "example": "shipping-details",
            "enum": [
              "shipping-details"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The unique ID for a buyer's shipping detail.",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "buyer_id": {
            "type": "string",
            "format": "uuid",
            "description": "The unique ID for a buyer.",
            "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
          },
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name of the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address of the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number of the buyer. This number is formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "type": "object",
            "description": "The physical shipping address associated to this buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          }
        }
      },
      "ShippingDetails": {
        "title": "Shipping details",
        "type": "object",
        "description": "A list of shipping details.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of shipping details.",
            "items": {
              "$ref": "#/components/schemas/ShippingDetail"
            }
          }
        }
      },
      "ShippingDetailRequest": {
        "title": "Shipping detail (Create)",
        "type": "object",
        "description": "Shipping detail associated to a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address for the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the buyer which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "description": "The physical shipping address associated to this buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          }
        }
      },
      "ShippingDetailUpdateRequest": {
        "title": "Shipping detail (Update)",
        "type": "object",
        "x-tags": [
          "Buyers"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the buyer.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the buyer.",
            "nullable": true
          },
          "email_address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 320,
            "description": "The email address for the buyer.",
            "example": "john@example.com",
            "nullable": true
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 1,
            "maxLength": 50,
            "description": "The phone number for the buyer which should be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "address": {
            "description": "The physical shipping address associated to this buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              }
            ]
          }
        }
      },
      "StatementDescriptor": {
        "title": "Statement descriptor",
        "type": "object",
        "description": "The statement descriptor is the text to be shown on the buyer's statements.\n\nThe specific usage of these fields will depend on the capabilities of\nthe underlying PSP and bank. As a typical example, 'name' and\n'description' could be concatenated using '* ' as a separator, and\nthen the resulting descriptor would be truncated to 22 characters by\nthe issuing bank.",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 5,
            "maxLength": 22,
            "description": "Reflects your doing business as (DBA) name.\n\nOther validations:\n\n1. Contains only Latin characters.\n2. Contain at least one letter\n3. Does not contain any of the special characters `< > \\ ' \" *`\n4. Supports:\n  1. Lower case: `a-z`\n  2. Upper case: `A-Z`\n  3. Numbers: `0-9`\n  4. Spaces: ` `\n  5. Special characters: `. , _ - ? + /`.",
            "example": "GR4VY",
            "nullable": true
          },
          "description": {
            "type": "string",
            "minLength": 5,
            "maxLength": 22,
            "example": "Card payment",
            "description": "A short description about the purchase.\n\nOther validations:\n1. Contains only Latin characters.\n2. Contain at least one letter\n3. Does not contain any of the special characters `< > \\ ' \" *`\n4. Supports:\n  1. Lower case: `a-z`\n  2. Upper case: `A-Z`\n  3. Numbers: `0-9`\n  4. Spaces: ` `\n  5. Special characters: `. , _ - ? + /`.",
            "nullable": true
          },
          "city": {
            "type": "string",
            "minLength": 1,
            "maxLength": 13,
            "description": "The merchant's city to be displayed in a statement\ndescriptor.",
            "example": "London",
            "nullable": true
          },
          "country": {
            "description": "The 2-letter ISO country code of the merchant to be displayed in a statement\ndescriptor.\n",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "phone_number": {
            "type": "string",
            "pattern": "^\\+[1-9]\\d{1,14}$",
            "minLength": 5,
            "maxLength": 20,
            "description": "The value in the phone number field of a customer's statement which\nshould be formatted according to the\n[E164 number standard](https://www.twilio.com/docs/glossary/what-e164).",
            "example": "+1234567890",
            "nullable": true
          },
          "url": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The merchant's URL to be displayed in a statement\ndescriptor.",
            "example": "www.gr4vy.com",
            "nullable": true
          }
        }
      },
      "TaxId": {
        "title": "Tax ID",
        "type": "object",
        "description": "The tax ID information associated to a buyer.",
        "x-tags": [
          "Buyers"
        ],
        "required": [
          "kind",
          "value"
        ],
        "properties": {
          "value": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "description": "The tax ID for the buyer.",
            "example": "12345678931"
          },
          "kind": {
            "type": "string",
            "description": "The kind of tax ID.",
            "example": "gb.vat",
            "enum": [
              "ae.trn",
              "au.abn",
              "ar.dni",
              "ar.cuil",
              "ar.cuit",
              "br.cnpj",
              "br.cpf",
              "ca.bn",
              "ca.gst_hst",
              "ca.pst_bc",
              "ca.pst_mb",
              "ca.pst_sk",
              "ca.qst",
              "ch.vat",
              "cl.tin",
              "es.cif",
              "eu.vat",
              "gb.vat",
              "hk.br",
              "id.nik",
              "id.npwp",
              "in.gst",
              "jp.cn",
              "jp.rn",
              "kr.brn",
              "li.uid",
              "mx.curp",
              "my.frp",
              "my.itn",
              "my.nric",
              "my.sst",
              "no.vat",
              "nz.gst",
              "ph.tin",
              "ru.inn",
              "ru.kpp",
              "sa.vat",
              "sg.gst",
              "sg.uen",
              "th.id",
              "th.vat",
              "tw.vat",
              "us.ein",
              "za.vat"
            ]
          }
        }
      },
      "ThreeDSecureData": {
        "title": "3-D Secure Data",
        "type": "object",
        "required": [
          "cavv",
          "eci",
          "version",
          "directory_response"
        ],
        "properties": {
          "cavv": {
            "type": "string",
            "description": "The cardholder authentication value or AAV.",
            "example": "3q2+78r+ur7erb7vyv66vv8="
          },
          "eci": {
            "type": "string",
            "pattern": "^0?\\d$",
            "minLength": 1,
            "maxLength": 2,
            "description": "The ecommerce indicator for the 3DS transaction.",
            "example": "05"
          },
          "version": {
            "type": "string",
            "pattern": "^[1-2].?[\\d+.?]{0,3}$",
            "description": "The version of 3-D Secure that was used."
          },
          "directory_response": {
            "type": "string",
            "maxLength": 1,
            "description": "For 3-D Secure version 1, the enrolment response. For 3-D Secure version , the transaction status from the `ARes`.",
            "example": "C"
          },
          "scheme": {
            "type": "string",
            "description": "The scheme/brand of the card that is used for 3-D Secure.",
            "nullable": true,
            "example": "visa",
            "enum": [
              "accel",
              "amex",
              "bancontact",
              "carte-bancaire",
              "cirrus",
              "culiance",
              "dankort",
              "diners-club",
              "discover",
              "eftpos-australia",
              "elo",
              "hipercard",
              "jcb",
              "maestro",
              "mastercard",
              "mir",
              "nyce",
              "other",
              "pulse",
              "rupay",
              "star",
              "uatp",
              "unionpay",
              "visa",
              null
            ]
          }
        }
      },
      "ThreeDSecureDataV1": {
        "title": "3-D Secure Data Version 1",
        "type": "object",
        "deprecated": true,
        "allOf": [
          {
            "$ref": "#/components/schemas/ThreeDSecureData"
          },
          {
            "required": [
              "authentication_response",
              "cavv_algorithm",
              "xid"
            ],
            "properties": {
              "authentication_response": {
                "type": "string",
                "maxLength": 1,
                "description": "The response for the 3DS authentication call.",
                "example": "Y"
              },
              "cavv_algorithm": {
                "type": "string",
                "maxLength": 1,
                "description": "The CAVV algorithm used."
              },
              "xid": {
                "type": "string",
                "description": "The transaction identifier."
              }
            }
          }
        ]
      },
      "ThreeDSecureDataV2": {
        "title": "3-D Secure Data Version 2",
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/ThreeDSecureData"
          },
          {
            "required": [
              "directory_transaction_id"
            ],
            "properties": {
              "authentication_response": {
                "type": "string",
                "maxLength": 1,
                "description": "The transaction status after a the 3DS challenge. This will\nbe null in case of a frictionless 3DS flow.",
                "example": "Y",
                "nullable": true,
                "enum": [
                  "Y",
                  "A",
                  "N",
                  "R",
                  "U"
                ]
              },
              "directory_response": {
                "type": "string",
                "maxLength": 1,
                "description": "The transaction status received as part of the authentication request.",
                "example": "C",
                "enum": [
                  "C",
                  "Y",
                  "A",
                  "N",
                  "R",
                  "U"
                ]
              },
              "directory_transaction_id": {
                "type": "string",
                "description": "The transaction identifier.",
                "example": "c4e59ceb-a382-4d6a-bc87-385d591fa09d"
              }
            }
          }
        ]
      },
      "ThreeDSecureDataV1V2": {
        "title": "3-D Secure Data Version 1 & 2",
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/ThreeDSecureDataV1"
          },
          {
            "$ref": "#/components/schemas/ThreeDSecureDataV2"
          }
        ]
      },
      "ThreeDSecureV2": {
        "title": "3-D Secure Data Version 2",
        "type": "object",
        "properties": {
          "cavv": {
            "type": "string",
            "description": "The cardholder authentication value or AAV.",
            "example": "3q2+78r+ur7erb7vyv66vv8=",
            "nullable": true
          },
          "eci": {
            "type": "string",
            "pattern": "^0?\\d$",
            "minLength": 1,
            "maxLength": 2,
            "description": "The ecommerce indicator for the 3DS transaction.",
            "example": "05",
            "nullable": true
          },
          "version": {
            "type": "string",
            "pattern": "^[1-2].?[\\d+.?]{0,3}$",
            "description": "The version of 3-D Secure that was used."
          },
          "authentication_response": {
            "type": "string",
            "maxLength": 1,
            "description": "The transaction status after a the 3DS challenge. This will\nbe null in case of a frictionless 3DS flow.",
            "example": "Y",
            "nullable": true,
            "enum": [
              "Y",
              "A",
              "N",
              "R",
              "U"
            ]
          },
          "directory_response": {
            "type": "string",
            "maxLength": 1,
            "description": "The transaction status received as part of the authentication request.",
            "example": "C",
            "enum": [
              "C",
              "Y",
              "A",
              "N",
              "R",
              "U"
            ],
            "nullable": true
          },
          "directory_transaction_id": {
            "type": "string",
            "description": "The transaction identifier.",
            "example": "c4e59ceb-a382-4d6a-bc87-385d591fa09d",
            "nullable": true
          },
          "transaction_reason": {
            "type": "string",
            "description": "The reason identifier for a declined transaction.",
            "nullable": true,
            "example": "05"
          }
        }
      },
      "ThreeDSecureError": {
        "title": "3-D Secure Error Data",
        "type": "object",
        "description": "Details about the error resulting from 3DS processing a Transaction.",
        "x-tags": [
          "Transactions"
        ],
        "required": [
          "description",
          "detail",
          "component",
          "code"
        ],
        "properties": {
          "description": {
            "type": "string",
            "description": "The error description.",
            "example": "Invalid ThreeDSCompInd",
            "maxLength": 2048,
            "nullable": true
          },
          "detail": {
            "type": "string",
            "description": "Detail for the error.",
            "example": "The threeDSCompInd must be 'Y' when successful",
            "maxLength": 2048,
            "nullable": true
          },
          "code": {
            "type": "string",
            "description": "The error code.",
            "example": "305",
            "maxLength": 3,
            "minLength": 3,
            "nullable": true
          },
          "component": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1,
            "description": "Code indicating the 3-D Secure component that identified the error..",
            "example": "C",
            "nullable": true
          }
        }
      },
      "ThreeDSecureAuthenticationRequestEvent": {
        "title": "3DS - Authentication",
        "type": "object",
        "description": "The result and raw data for a 3DS authorization call.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `three-d-secure-authentication-request`.",
            "example": "three-d-secure-authentication-request",
            "enum": [
              "three-d-secure-authentication-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "3DS authentication context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL that was called for this request.",
                "example": "https://3dserver.example/auth"
              },
              "request": {
                "type": "string",
                "description": "The request body sent to the `url`.",
                "example": "{}"
              },
              "response": {
                "type": "string",
                "description": "The response body received from the `url`.",
                "example": "{}"
              },
              "response_status_code": {
                "type": "integer",
                "description": "The response status code received from the `url`.",
                "example": 200
              },
              "cavv": {
                "type": "string",
                "description": "The 3DS CAVV value parsed from the `response`.",
                "example": "+9YDsoSIbiEgO+PFMdgGSF17Uqk="
              },
              "eci": {
                "type": "string",
                "description": "The 3DS ECI value parsed from the `response`.",
                "example": "05"
              },
              "directory_response": {
                "type": "string",
                "description": "The `transStatus` parsed from the `response`.",
                "example": "C"
              },
              "directory_transaction_id": {
                "type": "string",
                "description": "The `dsTransID` parsed from the `response`.",
                "example": "8875884a-ac2f-42cb-b3f0-09b3ea3c0042"
              },
              "version": {
                "type": "string",
                "description": "The version of 3DS used.",
                "example": "2.2.0"
              }
            }
          }
        }
      },
      "ThreeDSecurePreparationRequestEvent": {
        "title": "3DS - Pre-authentication",
        "type": "object",
        "description": "The result and raw data for a 3DS pre-authorization call.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `three-d-secure-preparation-request`.",
            "example": "three-d-secure-preparation-request",
            "enum": [
              "three-d-secure-preparation-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "3DS pre-authentication context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL that was called for this request.",
                "example": "https://3dserver.example/auth"
              },
              "request": {
                "type": "string",
                "description": "The request body sent to the `url`.",
                "example": "{}"
              },
              "response": {
                "type": "string",
                "description": "The response body received from the `url`.",
                "example": "{}"
              },
              "response_status_code": {
                "type": "integer",
                "description": "The response status code received from the `url`.",
                "example": 200
              },
              "is_enrolled": {
                "type": "boolean",
                "description": "If the card is enrolled for 3DS.",
                "example": true
              },
              "version": {
                "type": "string",
                "description": "The version of 3DS extracted from the `response.",
                "example": "2.2.0"
              }
            }
          }
        }
      },
      "ThreeDSecureResultRequestEvent": {
        "title": "3DS - Post-authentication",
        "type": "object",
        "description": "The result and raw data for a 3DS post-authorization call.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `three-d-secure-result-request`.",
            "example": "three-d-secure-result-request",
            "enum": [
              "three-d-secure-result-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "3DS post-authentication context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL that was called for this request.",
                "example": "https://3dserver.example/auth"
              },
              "request": {
                "type": "string",
                "description": "The request body sent to the `url`.",
                "example": "{}"
              },
              "response": {
                "type": "string",
                "description": "The response body received from the `url`.",
                "example": "{}"
              },
              "response_status_code": {
                "type": "integer",
                "description": "The response status code received from the `url`.",
                "example": 200
              },
              "cavv": {
                "type": "string",
                "description": "The 3DS CAVV value parsed from the `response`.",
                "example": "+9YDsoSIbiEgO+PFMdgGSF17Uqk="
              },
              "eci": {
                "type": "string",
                "description": "The 3DS ECI value parsed from the `response`.",
                "example": "05"
              },
              "authentication_response": {
                "type": "string",
                "description": "The `transStatus` parsed from the post-authorization `response`.",
                "example": "C"
              },
              "directory_response": {
                "type": "string",
                "description": "The `transStatus` parsed from the authorization `response`.",
                "example": "C"
              },
              "directory_transaction_id": {
                "type": "string",
                "description": "The `dsTransID` parsed from the `response`.",
                "example": "8875884a-ac2f-42cb-b3f0-09b3ea3c0042"
              },
              "is_challenge_cancelled": {
                "type": "boolean",
                "description": "Flag to indicate whether the buyer cancelled 3DS authentication.",
                "example": false
              }
            }
          }
        }
      },
      "ThreeDSecureRequestErrorEvent": {
        "title": "3DS - Error",
        "type": "object",
        "description": "Error details for a failed 3DS call.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `three-d-secure-request-error`.",
            "example": "three-d-secure-request-error",
            "enum": [
              "three-d-secure-request-error"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "3DS post-authentication context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL that was called for this request.",
                "example": "https://3dserver.example/auth"
              },
              "reason": {
                "type": "string",
                "description": "The reason for the error.",
                "example": "TIMEOUT"
              }
            }
          }
        }
      },
      "ThreeDSecureSuccessEvent": {
        "title": "3DS - Authentication (Deprecated)",
        "type": "object",
        "description": "Details related to 3DS processing.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `three-d-secure-success`.",
            "example": "three-d-secure-success",
            "enum": [
              "three-d-secure-success"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "3DS context.",
            "properties": {
              "eci": {
                "type": "string",
                "pattern": "^0?\\d$",
                "minLength": 1,
                "maxLength": 2,
                "description": "The ecommerce indicator for the 3DS transaction.",
                "example": "05"
              },
              "cavv": {
                "type": "string",
                "description": "The cardholder authentication value or AAV.",
                "example": "3q2+78r+ur7erb7vyv66vv8="
              },
              "version": {
                "type": "string",
                "pattern": "^[1-2].?[\\d+.?]{0,3}$",
                "description": "The version of 3-D Secure that was used."
              },
              "directory_response": {
                "type": "string",
                "maxLength": 1,
                "description": "For 3-D Secure version 1, the enrolment response. For 3-D Secure version , the transaction status from the `ARes`.",
                "example": "C"
              },
              "authentication_response": {
                "type": "string",
                "nullable": true,
                "maxLength": 1,
                "description": "The transaction status from the challenge result (not required for frictionless).",
                "example": "Y"
              },
              "directory_transaction_id": {
                "type": "string",
                "nullable": true,
                "description": "The transaction identifier.",
                "example": "c4e59ceb-a382-4d6a-bc87-385d591fa09d"
              },
              "cavv_algorithm": {
                "type": "string",
                "nullable": true,
                "maxLength": 1,
                "description": "The CAVV Algorithm used."
              },
              "method": {
                "type": "string",
                "nullable": true,
                "description": "The method used for 3DS authentication for this transaction.",
                "enum": [
                  "challenge",
                  "frictionless"
                ]
              }
            }
          }
        }
      },
      "TransactionAPIRequest": {
        "title": "Transaction API Request",
        "type": "object",
        "description": "Details related to transaction API request.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `transaction-api-request`.",
            "example": "transaction-api-request",
            "enum": [
              "transaction-api-request"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Event context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL requested.",
                "example": "https://api.spider.gr4vy.app/transactions"
              },
              "method": {
                "type": "string",
                "description": "The HTTP method.",
                "example": "POST"
              },
              "request": {
                "nullable": true,
                "type": "string",
                "description": "The body of the request.",
                "example": "{'foo': 'bar'}"
              },
              "request_headers": {
                "type": "object",
                "description": "The request headers received.",
                "example": {
                  "idempotency-key": "50e4bb08-b5e1-40b4-ac60-ea5f4df385cf"
                }
              },
              "auth": {
                "type": "object",
                "description": "Details of the JWT used for authentication.",
                "properties": {
                  "token": {
                    "type": "string",
                    "nullable": true,
                    "description": "JWT provided on request without signature."
                  },
                  "header": {
                    "type": "object",
                    "nullable": true,
                    "description": "Claims of JWT.",
                    "example": {
                      "alg": "HS256",
                      "typ": "JWT"
                    }
                  },
                  "payload": {
                    "type": "object",
                    "nullable": true,
                    "description": "Payload of JWT.",
                    "example": {
                      "sub": "1234567890"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "TransactionAPIResponse": {
        "title": "Transaction API Response",
        "type": "object",
        "description": "Details related to transaction API response.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `transaction-api-response`.",
            "example": "transaction-api-response",
            "enum": [
              "transaction-api-response"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Event context.",
            "properties": {
              "url": {
                "type": "string",
                "description": "The URL requested.",
                "example": "https://api.spider.gr4vy.app/transactions"
              },
              "method": {
                "type": "string",
                "description": "The HTTP method.",
                "example": "POST"
              },
              "response": {
                "type": "string",
                "description": "The body of the response.",
                "example": "{'foo': 'bar'}"
              },
              "response_status_code": {
                "type": "number",
                "description": "The request status code.",
                "example": 200
              },
              "latency": {
                "type": "number",
                "description": "The time taken to process the request in milliseconds.",
                "example": 123
              }
            }
          }
        }
      },
      "RealTimeAccountUpdate": {
        "title": "Real time account update",
        "type": "object",
        "description": "The result from a real time account updater request.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource. Is always `real-time-account-update`.",
            "example": "real-time-account-update",
            "enum": [
              "real-time-account-update"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "Real time account updater request context.",
            "properties": {
              "payment_method_id": {
                "type": "string",
                "format": "uuid",
                "description": "The unique identifier for the payment method.",
                "example": "8724fd24-5489-4a5d-90fd-0604df7d3b83"
              },
              "card_bin": {
                "type": "string",
                "description": "The existing card BIN.",
                "example": "424242"
              },
              "card_suffix": {
                "type": "string",
                "description": "The existing last 4 digits for the card.",
                "example": "4242"
              },
              "card_expiration_date": {
                "type": "string",
                "description": "The existing expiration date for the card.",
                "example": "01/30"
              },
              "new_card_bin": {
                "type": "string",
                "nullable": true,
                "description": "The new card BIN.",
                "example": "424242"
              },
              "new_card_suffix": {
                "type": "string",
                "nullable": true,
                "description": "The new last 4 digits for the card.",
                "example": "4242"
              },
              "new_card_expiration_date": {
                "type": "string",
                "nullable": true,
                "description": "The new expiration date for the card.",
                "example": "01/30"
              },
              "latency": {
                "type": "number",
                "nullable": true,
                "description": "The latency in milliseconds of the request.",
                "example": 123
              },
              "response_code": {
                "type": "string",
                "nullable": true,
                "description": "The response code/result for the update request.",
                "example": "updated",
                "enum": [
                  "account_closed",
                  "contact_cardholder",
                  "unchanged",
                  "updated"
                ]
              },
              "error_code": {
                "type": "string",
                "nullable": true,
                "description": "The reason code for a failed request.",
                "example": "client_error",
                "enum": [
                  "client_error",
                  "issuer_error",
                  "request_timeout"
                ]
              }
            }
          }
        }
      },
      "ThreeDSecureSummary": {
        "title": "3-D Secure data",
        "type": "object",
        "description": "The 3-D Secure data that was sent to the payment\nservice for the transaction.",
        "properties": {
          "version": {
            "type": "string",
            "description": "The version of 3DS used for this transaction.",
            "pattern": "^[1-2].?[\\d+.?]{0,3}$",
            "example": "2.1.0"
          },
          "status": {
            "type": "string",
            "description": "The status of the 3DS challenge for this transaction.",
            "enum": [
              "setup_error",
              "error",
              "declined",
              "cancelled",
              "complete"
            ]
          },
          "method": {
            "type": "string",
            "description": "The method used for 3DS authentication for this transaction.",
            "enum": [
              "challenge",
              "frictionless"
            ]
          },
          "error_data": {
            "type": "object",
            "nullable": true,
            "description": "The error data received from our 3DS server. This will not be\npopulated if the customer failed the authentication with a\nstatus code of `N`, `R`, or `U`.  To see full details about\nthe 3DS calls in those situations please use our transaction\nevents API.",
            "allOf": [
              {
                "$ref": "#/components/schemas/ThreeDSecureError"
              }
            ]
          },
          "response_data": {
            "type": "object",
            "nullable": true,
            "description": "The 3DS data sent to the payment service for this transaction.\n\nThis will only be populated if external 3DS data was passed in\ndirectly as part of the transaction API call, or if our 3DS server\nreturned a status code of `Y` or `A`.\n\nIn case of a failure to authenticate (status `N`, `R`, or `U`) this\nfield will not be populated. To see full details about the 3DS calls\nplease use our transaction events API.",
            "x-model-name": "ThreeDSecureDataV1V2",
            "oneOf": [
              {
                "$ref": "#/components/schemas/ThreeDSecureDataV1"
              },
              {
                "$ref": "#/components/schemas/ThreeDSecureV2"
              }
            ]
          }
        }
      },
      "TokenizedRequest": {
        "title": "Stored payment method request",
        "type": "object",
        "description": "Details for a previously stored payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`id`.",
            "example": "id",
            "enum": [
              "id"
            ]
          },
          "id": {
            "type": "string",
            "description": "A ID that represents a previously stored payment method.\nThis ID can represent any type of payment method.",
            "example": "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "This value is mandatory for stored redirect payment methods.\nFor stored cards, we strongly recommend providing a `redirect_url`\neither when 3-D Secure is enabled and `three_d_secure_data`\nis not provided, or when using connections where 3DS is enabled.\nThis value will be appended with both a transaction ID and status\n(e.g. `https://example.com/callback?gr4vy_transaction_id=123\n&gr4vy_transaction_status=capture_succeeded`) after 3-D Secure\nhas completed. For those cases, if the value is not present, the\ntransaction will be marked as failed.",
            "example": "https://example.com/callback"
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.\n\nThe security code can only be set if the stored payment method\nrepresents a card.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          }
        }
      },
      "Transaction": {
        "title": "Transaction",
        "type": "object",
        "description": "A transaction record.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction`.",
            "example": "transaction",
            "enum": [
              "transaction"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this transaction.",
            "format": "uuid"
          },
          "amount": {
            "description": "The total amount for this transaction across all funding sources\nincluding gift cards.",
            "example": 1299,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "additional_identifiers": {
            "description": "A list of additional identifiers that we may keep track of to manage this transaction. This\nmay include the authorization ID, capture ID, and processor ID, as well as an undefined list of\nadditional identifiers.",
            "allOf": [
              {
                "$ref": "#/components/schemas/AdditionalIdentifiers"
              }
            ]
          },
          "auth_response_code": {
            "description": "This is the response description received from the processor.",
            "example": "00",
            "nullable": true,
            "type": "string"
          },
          "authorized_amount": {
            "description": "The amount for this transaction that has been authorized for the `payment_method`.\nThis can be less than the `amount` if gift cards were used.",
            "example": 1299,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "authorized_at": {
            "description": "The date and time when this transaction was authorized in the payment\nservice.\n\nDon't use this field to determine whether the transaction was authorized.\nA `null` value doesn't necessarily imply that the transaction wasn't\nauthorized, it can mean that the payment service doesn't provide this\nvalue, that it didn't provide it at the time the transaction was\nauthorized or that the transaction was authorized before the introduction\nof this field.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "approval_expires_at": {
            "description": "The date and time when this transaction will be marked as failed if it does\nnot successfully gets captured, authorized or otherwise approved before.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "avs_response_code": {
            "description": "The response code received from the payment service for the Address\nVerification Check (AVS). This code is mapped to a standardized Gr4vy\nAVS response code.\n\n- `no_match` - neither address or postal code match\n- `match` - both address and postal code match\n- `partial_match_address` - address matches but postal code does not\n- `partial_match_postcode` - postal code matches but address does not\n- `unavailable ` - AVS is unavailable for card/country\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
            "enum": [
              "no_match",
              "match",
              "partial_match_address",
              "partial_match_postcode",
              "unavailable"
            ],
            "example": "partial_match_address",
            "nullable": true,
            "type": "string"
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer--Snapshot"
              }
            ],
            "description": "The buyer used for this transaction.",
            "nullable": true
          },
          "captured_amount": {
            "description": "The captured amount for this transaction. This can be the full value\nof the `authorized_amount` or less.",
            "example": 999,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "captured_at": {
            "description": "The date and time when this transaction was captured in the payment\nservice.\n\nDon't use this field to determine whether the transaction was captured.\nA `null` value doesn't necessarily imply that the transaction wasn't\ncaptured, it can mean that the payment service doesn't provide this value,\nthat it didn't provide it at the time the transaction was captured or that\nthe transaction was captured before the introduction of this field.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "cart_items": {
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "maxLength": 249,
            "type": "array"
          },
          "checkout_session_id": {
            "description": "The identifier for the checkout session this transaction is associated with.",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "format": "uuid",
            "nullable": true,
            "type": "string"
          },
          "country": {
            "description": "The 2-letter ISO code of the country of the transaction.\nThis is used to filter the payment services that is used to process the\ntransaction.\n",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "description": "The date and time when this transaction was created in our system.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "currency": {
            "description": "The currency code for this transaction.",
            "example": "USD",
            "type": "string"
          },
          "cvv_response_code": {
            "description": "The response code received from the payment service for the Card\nVerification Value (CVV). This code is mapped to a standardized Gr4vy\nCVV response code.\n\n- `no_match` - the CVV does not match the expected value\n- `match` - the CVV matches the expected value\n- `unavailable ` - CVV check unavailable for card our country\n- `not_provided ` - CVV not provided\n\nThe value of this field can be `null` if the payment service did not\nprovide a response.",
            "enum": [
              "no_match",
              "match",
              "unavailable",
              "not_provided"
            ],
            "example": "match",
            "nullable": true,
            "type": "string"
          },
          "error_code": {
            "description": "This is an error code set by Gr4vy.",
            "example": "missing_redirect_url",
            "nullable": true,
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the transaction against your own records.",
            "example": "user-789123",
            "nullable": true,
            "type": "string"
          },
          "gift_card_service": {
            "allOf": [
              {
                "$ref": "#/components/schemas/GiftCardService--Snapshot"
              }
            ],
            "description": "The gift card service used for this transaction."
          },
          "gift_card_redemptions": {
            "description": "The gift cards redeemed for this transaction.",
            "items": {
              "$ref": "#/components/schemas/GiftCardRedemption"
            },
            "type": "array"
          },
          "instrument_type": {
            "nullable": true,
            "type": "string",
            "description": "The name of the instrument used to process the transaction.\n",
            "enum": [
              "applepay",
              "card_token",
              "googlepay",
              "network_token",
              "pan",
              "redirect",
              "redirect_token"
            ],
            "example": "network_token"
          },
          "intent": {
            "description": "The original `intent` used when the transaction was\n[created](#operation/authorize-new-transaction).",
            "enum": [
              "authorize",
              "capture"
            ],
            "example": "authorize",
            "type": "string"
          },
          "intent_outcome": {
            "description": "The outcome of the original intent of a transaction.\n\nThis allows you to understand if the intent of the transaction\n(e.g. `capture` or `authorize`) has been achieved when dealing with multiple\npayment instruments.\n\nIf all payment instruments (`payment_method` and/or `gift_cards`)\nhave succeeded to get an authorization or direct sale **at any point\nin time** then this will return a `succeeded` value.\n\nIf any of the payment instruments fails or declines then this will\nreturn a `failed` value.\n\nIf any payment instruments is still in a `pending` or `processing` state\nthen the result will be `pending`.\n\nPlease note that if any of the payment instruments are voided or refunded\nafter the result reaches a `succeeded` state  then the result will remain\nunchanged.",
            "enum": [
              "pending",
              "succeeded",
              "failed"
            ],
            "example": "pending",
            "type": "string"
          },
          "is_subsequent_payment": {
            "default": false,
            "description": "Indicates whether the transaction represents a subsequent payment\ncoming from a setup recurring payment.\nPlease note there are some restrictions on how this flag may be\nused.\n\nThe flag can only be `false` (or not set) when the transaction meets\none of the following criteria:\n\n* It is not `merchant_initiated`.\n* `payment_source` is set to `card_on_file`.\n\nThe flag can only be set to `true` when the transaction meets one of the\nfollowing criteria:\n\n* It is not `merchant_initiated`.\n* `payment_source` is set to `recurring` or `installment` and\n`merchant_initiated` is set to `true`.\n* `payment_source` is set to `card_on_file`.",
            "example": true,
            "type": "boolean"
          },
          "merchant_account_id": {
            "description": "The ID of the merchant account to which this transaction belongs to.",
            "example": "default",
            "maximum": 22,
            "minimum": 1,
            "type": "string"
          },
          "merchant_initiated": {
            "default": false,
            "description": "Indicates whether the transaction was initiated by the merchant (true)\nor customer (false).",
            "example": true,
            "type": "boolean"
          },
          "metadata": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Additional information about the transaction stored as key-value pairs.",
            "example": {
              "key": "value"
            },
            "type": "object"
          },
          "method": {
            "nullable": true,
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "multi_tender": {
            "description": "Defines if this transaction has been split across multiple payment instruments\nsuch as a `payment_method` and one or more `gift_cards`, or multiple `gift_cards`\nwithout a `payment_method`.",
            "example": true,
            "type": "boolean"
          },
          "payment_method": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentMethod--Snapshot"
              }
            ],
            "description": "The payment method used for this transaction.",
            "nullable": true
          },
          "payment_service": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentService--Snapshot"
              }
            ],
            "description": "The payment service used for this transaction.",
            "nullable": true
          },
          "payment_service_transaction_id": {
            "description": "The payment service's unique ID for the transaction.",
            "example": "charge_xYqd43gySMtori",
            "type": "string"
          },
          "payment_source": {
            "description": "The source of the transaction. Defaults to `ecommerce`.",
            "type": "string",
            "example": "recurring",
            "enum": [
              "ecommerce",
              "moto",
              "recurring",
              "installment",
              "card_on_file"
            ]
          },
          "pending_review": {
            "description": "Whether a manual review is pending.",
            "example": true,
            "nullable": false,
            "type": "boolean"
          },
          "anti_fraud_decision": {
            "description": "The mapped decision received from the anti-fraud service. In case of a\nreview decision this field is not updated once the review is resolved.",
            "nullable": true,
            "type": "string",
            "example": "accept",
            "enum": [
              "accept",
              "error",
              "exception",
              "reject",
              "review",
              "skipped"
            ]
          },
          "raw_response_code": {
            "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
            "example": "incorrect-zip",
            "nullable": true,
            "type": "string"
          },
          "raw_response_description": {
            "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
            "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
            "nullable": true,
            "type": "string"
          },
          "reconciliation_id": {
            "description": "The base62 encoded transaction ID. This represents a shorter version\nof this transaction's `id` which is sent to payment services, anti-fraud services,\nand other connectors. You can use this ID to reconcile a payment service's\ntransaction against our system.\n\nThis ID is sent instead of the transaction ID because not all services\nsupport 36 digit identifiers.",
            "example": "7jZXl4gBUNl0CnaLEnfXbt",
            "type": "string"
          },
          "refunded_amount": {
            "description": "The refunded amount for this transaction. This can be the full value\nof the `captured_amount` or less.",
            "example": 100,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "scheme_transaction_id": {
            "default": null,
            "description": "An identifier for the transaction used by the scheme itself, when\navailable.\n\ne.g. the Visa Transaction Identifier, or Mastercard Trace ID.",
            "example": "123456789012345",
            "nullable": true,
            "type": "string"
          },
          "shipping_details": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ShippingDetail"
              }
            ],
            "description": "The shipping details associated with the transaction.",
            "nullable": true
          },
          "statement_descriptor": {
            "allOf": [
              {
                "$ref": "#/components/schemas/StatementDescriptor"
              }
            ],
            "nullable": true
          },
          "status": {
            "description": "The status of the transaction for the `payment_method`. The status\nmay change over time as asynchronous processing events occur.\n\nPlease note that the possible statuses returned will depend on the\noperation performed. For example, a captured transaction will never\nmove to a `authorization_voided` status.",
            "enum": [
              "processing",
              "buyer_approval_pending",
              "authorization_succeeded",
              "authorization_failed",
              "authorization_declined",
              "capture_pending",
              "capture_succeeded",
              "authorization_void_pending",
              "authorization_voided"
            ],
            "example": "processing",
            "type": "string"
          },
          "three_d_secure": {
            "$ref": "#/components/schemas/ThreeDSecureSummary"
          },
          "airline": {
            "description": "Contains information about an airline travel, if applicable.",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "nullable": true
          },
          "updated_at": {
            "description": "Defines when the transaction was last updated.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "voided_at": {
            "description": "The date and time when this transaction was voided in the payment service.\n\nDon't use this field to determine whether the transaction was voided.\nA `null` value doesn't necessarily imply that the transaction wasn't\nvoided, it can mean that the payment service doesn't provide this value,\nthat it didn't provide it at the time the transaction was voided or that\nthe transaction was voided before the introduction of this field.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "nullable": true,
            "type": "string"
          },
          "settled_currency": {
            "description": "The currency of this transaction's settlement in\nISO 4217 three-letter code format.",
            "example": "GBP",
            "nullable": true,
            "type": "string"
          },
          "settled_amount": {
            "description": "The net amount settled for this transaction.",
            "example": 1000,
            "type": "integer"
          },
          "settled": {
            "description": "Indicates whether this transaction has been settled.",
            "example": true,
            "type": "boolean"
          },
          "account_funding_transaction": {
            "type": "boolean",
            "default": false,
            "description": "Whether or not the transaction is an account funding transaction.",
            "nullable": true,
            "example": true
          },
          "recipient": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Recipient--Snapshot"
              }
            ],
            "description": "The recipient of an account funding transaction.",
            "nullable": true
          },
          "merchant_advice_code": {
            "type": "string",
            "description": "The merchant advice code received from the payment service. This code is\nused to provide additional information about the card used.",
            "nullable": true,
            "example": "01"
          }
        }
      },
      "TransactionHistoryEvent": {
        "title": "Transaction history event",
        "type": "object",
        "description": "A generic transaction history event.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-event`.",
            "example": "transaction-event",
            "enum": [
              "transaction-event"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this event.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of this resource.",
            "example": "anti-fraud-decision",
            "enum": [
              "anti-fraud-decision-error",
              "anti-fraud-decision-skipped",
              "anti-fraud-decision",
              "anti-fraud-decision-update",
              "anti-fraud-decision-update-error",
              "anti-fraud-transaction-status-update",
              "anti-fraud-transaction-status-update-error",
              "anti-fraud-webhook",
              "bin-lookup-request",
              "digital-wallet-apple-pay-token-decrypted",
              "digital-wallet-google-pay-token-decrypted",
              "digital-wallet-click-to-pay-token-decrypted",
              "gift-card-redemption-failed",
              "gift-card-redemption-succeeded",
              "gift-card-refund-failed",
              "gift-card-refund-succeeded",
              "network-token-cryptogram-provision-failed",
              "network-token-cryptogram-provision-succeeded",
              "network-token-provision-failed",
              "network-token-provision-succeeded",
              "payment-connector-response-transaction-authorization-failed",
              "payment-connector-response-transaction-authorization-succeeded",
              "payment-connector-response-transaction-capture-declined",
              "payment-connector-response-transaction-capture-failed",
              "payment-connector-response-transaction-capture-succeeded",
              "payment-connector-response-transaction-declined",
              "payment-connector-response-transaction-void-declined",
              "payment-connector-response-transaction-void-failed",
              "payment-connector-response-transaction-void-succeeded",
              "payment-connector-report-transaction-settled",
              "payment-connector-external-transaction-request",
              "three-d-secure-authentication-request",
              "three-d-secure-preparation-request",
              "three-d-secure-request-error",
              "three-d-secure-result-request",
              "three-d-secure-success",
              "transaction-api-request",
              "transaction-api-response"
            ]
          },
          "created_at": {
            "type": "string",
            "description": "The date and time when this transaction was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "context": {
            "type": "object",
            "description": "A list of key/values with additional data.",
            "additionalProperties": true
          }
        }
      },
      "TransactionHistoryEvents": {
        "title": "Transaction History Events",
        "description": "A list of transaction history events.",
        "type": "object",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of events related to processing a transaction.",
            "items": {
              "x-model-name": "TransactionHistoryEvent",
              "oneOf": [
                {
                  "$ref": "#/components/schemas/BINLookupRequest"
                },
                {
                  "$ref": "#/components/schemas/ThreeDSecureAuthenticationRequestEvent"
                },
                {
                  "$ref": "#/components/schemas/ThreeDSecureSuccessEvent"
                },
                {
                  "$ref": "#/components/schemas/ThreeDSecureRequestErrorEvent"
                },
                {
                  "$ref": "#/components/schemas/ThreeDSecurePreparationRequestEvent"
                },
                {
                  "$ref": "#/components/schemas/ThreeDSecureResultRequestEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudDecisionEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudDecisionErrorEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudDecisionSkippedEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudDecisionUpdateEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudDecisionUpdateErrorEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudTransactionStatusUpdateEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudTransactionStatusUpdateErrorEvent"
                },
                {
                  "$ref": "#/components/schemas/AntiFraudWebhookEvent"
                },
                {
                  "$ref": "#/components/schemas/DigitalWalletApplePayTokenDecrypted"
                },
                {
                  "$ref": "#/components/schemas/DigitalWalletClickToPayTokenDecrypted"
                },
                {
                  "$ref": "#/components/schemas/DigitalWalletGooglePayTokenDecrypted"
                },
                {
                  "$ref": "#/components/schemas/GiftCardRedemptionFailed"
                },
                {
                  "$ref": "#/components/schemas/GiftCardRedemptionSucceeded"
                },
                {
                  "$ref": "#/components/schemas/GiftCardRefundFailed"
                },
                {
                  "$ref": "#/components/schemas/GiftCardRefundSucceeded"
                },
                {
                  "$ref": "#/components/schemas/NetworkTokenCryptogramProvisionFailed"
                },
                {
                  "$ref": "#/components/schemas/NetworkTokenCryptogramProvisionSucceeded"
                },
                {
                  "$ref": "#/components/schemas/NetworkTokenProvisionFailed"
                },
                {
                  "$ref": "#/components/schemas/NetworkTokenProvisionSucceeded"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionAuthorizationSucceededEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionDeclinedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionAuthorizationFailedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionCaptureDeclinedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionCaptureFailedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionCaptureSucceededEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionSync"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionVoidDeclinedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionVoidFailedEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorResponseTransactionVoidSucceededEvent"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorExternalTransactionRequest"
                },
                {
                  "$ref": "#/components/schemas/PaymentConnectorReportTransactionSettled"
                },
                {
                  "$ref": "#/components/schemas/RealTimeAccountUpdate"
                },
                {
                  "$ref": "#/components/schemas/TransactionAPIRequest"
                },
                {
                  "$ref": "#/components/schemas/TransactionAPIResponse"
                }
              ]
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 500,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "TransactionStatusSummary": {
        "title": "Transaction",
        "type": "object",
        "description": "A transaction record.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction`.",
            "example": "transaction",
            "enum": [
              "transaction"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this transaction.",
            "format": "uuid"
          },
          "status": {
            "type": "string",
            "description": "The status of the transaction. The status may change over time as\nasynchronous processing events occur.",
            "example": "processing",
            "enum": [
              "processing",
              "buyer_approval_pending",
              "authorization_succeeded",
              "authorization_failed",
              "authorization_declined",
              "capture_pending",
              "capture_succeeded",
              "authorization_void_pending",
              "authorization_voided"
            ]
          }
        }
      },
      "TransactionSummary": {
        "title": "Transaction",
        "type": "object",
        "description": "A transaction record.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction`.",
            "example": "transaction",
            "enum": [
              "transaction"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique identifier for this transaction.",
            "format": "uuid"
          },
          "amount": {
            "description": "The authorized amount for this transaction. This can be more than the\nactual captured amount and part of this amount may be refunded.",
            "example": 1299,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "authorized_amount": {
            "description": "The amount for this transaction that has been authorized for the `payment_method`.\nThis can be less than the `amount` if gift cards were used.",
            "example": 1299,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Buyer--Snapshot"
              }
            ],
            "description": "The buyer used for this transaction.",
            "nullable": true
          },
          "captured_amount": {
            "description": "The captured amount for this transaction. This can be the full value\nof the `authorized_amount` or less.",
            "example": 999,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "checkout_session_id": {
            "description": "The identifier for the checkout session this transaction is associated with.",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "format": "uuid",
            "type": "string",
            "nullable": true
          },
          "country": {
            "description": "The 2-letter ISO code of the country of the transaction.\nThis is used to filter the payment services that is used to process the\ntransaction.\n",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "description": "The date and time when this transaction was created in our system.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "currency": {
            "description": "The currency code for this transaction.",
            "example": "USD",
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the transaction against your own records.",
            "example": "user-789123",
            "nullable": true,
            "type": "string"
          },
          "gift_card_redemptions": {
            "description": "The gift cards redeemed for this transaction.",
            "items": {
              "$ref": "#/components/schemas/GiftCardRedemption"
            },
            "type": "array"
          },
          "instrument_type": {
            "nullable": true,
            "type": "string",
            "description": "The name of the instrument used to process the transaction.\n",
            "enum": [
              "applepay",
              "card_token",
              "googlepay",
              "network_token",
              "pan",
              "redirect",
              "redirect_token"
            ],
            "example": "network_token"
          },
          "intent": {
            "description": "The original `intent` used when the transaction was\n[created](#operation/authorize-new-transaction).",
            "enum": [
              "authorize",
              "capture"
            ],
            "example": "authorize",
            "type": "string"
          },
          "merchant_account_id": {
            "description": "The ID of the merchant account to which this transaction belongs to.",
            "example": "default",
            "maximum": 22,
            "minimum": 1,
            "type": "string"
          },
          "method": {
            "nullable": true,
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "payment_method": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentMethod--Snapshot"
              }
            ],
            "description": "The payment method used for this transaction.",
            "nullable": true
          },
          "payment_service": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PaymentService--Snapshot"
              }
            ],
            "description": "The payment service used for this transaction.",
            "nullable": true
          },
          "pending_review": {
            "description": "Whether a manual review is pending.",
            "example": true,
            "nullable": false,
            "type": "boolean"
          },
          "raw_response_code": {
            "description": "This is the response code received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
            "example": "incorrect-zip",
            "nullable": true,
            "type": "string"
          },
          "raw_response_description": {
            "description": "This is the response description received from the payment service. This\ncan be set to any value and is not standardized across different\npayment services.",
            "example": "The card's postal code is incorrect. Check the card's postal code or use a\ndifferent card.",
            "nullable": true,
            "type": "string"
          },
          "reconciliation_id": {
            "description": "The base62 encoded transaction ID. This represents a shorter version\nof this transaction's `id` which is sent to payment services, anti-fraud services,\nand other connectors. You can use this ID to reconcile a payment service's\ntransaction against our system.\n\nThis ID is sent instead of the transaction ID because not all services\nsupport 36 digit identifiers.",
            "example": "7jZXl4gBUNl0CnaLEnfXbt",
            "type": "string"
          },
          "refunded_amount": {
            "description": "The refunded amount for this transaction. This can be the full value\nof the `captured_amount` or less.",
            "example": 100,
            "maximum": 99999999,
            "minimum": 0,
            "type": "integer"
          },
          "status": {
            "description": "The status of the transaction. The status may change over time as\nasynchronous processing events occur.",
            "enum": [
              "processing",
              "buyer_approval_pending",
              "authorization_succeeded",
              "authorization_failed",
              "authorization_declined",
              "capture_pending",
              "capture_succeeded",
              "authorization_void_pending",
              "authorization_voided"
            ],
            "example": "processing",
            "type": "string"
          },
          "updated_at": {
            "description": "Defines when the transaction was last updated.",
            "example": "2013-07-16T19:23:00.000+00:00",
            "format": "date-time",
            "type": "string"
          },
          "settled_currency": {
            "description": "The currency of this transaction's settlement in\nISO 4217 three-letter code format.",
            "example": "GBP",
            "nullable": true,
            "type": "string"
          },
          "settled_amount": {
            "description": "The net amount settled for this transaction.",
            "example": 1000,
            "type": "integer"
          },
          "settled": {
            "description": "Indicates whether this transaction has been settled.",
            "example": true,
            "type": "boolean"
          }
        }
      },
      "Transactions": {
        "title": "Transactions",
        "description": "A list of transactions.",
        "type": "object",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of transactions.",
            "items": {
              "$ref": "#/components/schemas/TransactionSummary"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 500,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "TransactionsBatchCaptureRequest": {
        "title": "Batch Capture (Create)",
        "type": "object",
        "description": "A request to capture multiple previously authorized transactions.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "currency",
          "transaction_id"
        ],
        "properties": {
          "amount": {
            "type": "integer",
            "description": "The (partial) amount to capture.\n\nWhen left blank, this will capture the entire amount.",
            "example": 1299,
            "minimum": 0,
            "maximum": 99999999
          },
          "currency": {
            "type": "string",
            "description": "A supported ISO-4217 currency code.\n",
            "example": "USD"
          },
          "external_identifier": {
            "type": "string",
            "example": "user-789123",
            "description": "An external identifier that can be used to match the transaction against your own records."
          },
          "transaction_id": {
            "type": "string",
            "description": "The ID of the transaction to capture."
          }
        }
      },
      "TransactionRequest": {
        "title": "Transaction (Create)",
        "type": "object",
        "description": "A request to create a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "currency"
        ],
        "properties": {
          "amount": {
            "description": "The monetary amount for this transaction, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nIf the `intent` is set to `capture`, an amount greater than zero must\nbe supplied.\n\nAll gift card amounts are subtracted from this amount before the\nremainder is charged to the provided `payment_method`.",
            "type": "integer",
            "example": 1299,
            "minimum": 0,
            "maximum": 99999999
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "A supported ISO-4217 currency code.\n\nFor redirect requests, this value must match the one specified for\n`currency` in `payment_method`.\n"
          },
          "payment_method": {
            "description": "The optional payment method to use for this transaction. This field is required if no `gift_cards` have been added.",
            "nullable": true,
            "oneOf": [
              {
                "$ref": "#/components/schemas/TransactionCardRequest"
              },
              {
                "$ref": "#/components/schemas/TransactionRedirectRequest"
              },
              {
                "$ref": "#/components/schemas/TokenizedRequest"
              },
              {
                "$ref": "#/components/schemas/ApplePayRequest"
              },
              {
                "$ref": "#/components/schemas/GooglePayRequest"
              },
              {
                "$ref": "#/components/schemas/TransactionCheckoutSessionRequest"
              },
              {
                "$ref": "#/components/schemas/TransactionNetworkTokenRequest"
              },
              {
                "$ref": "#/components/schemas/TransactionNetworkTokenApplePayRequest"
              },
              {
                "$ref": "#/components/schemas/TransactionNetworkTokenGooglePayRequest"
              }
            ],
            "type": "object",
            "x-model-name": "TransactionPaymentMethodRequest"
          },
          "anti_fraud_fingerprint": {
            "default": null,
            "description": "This field represents the fingerprint data to be passed to the active\nanti-fraud service.",
            "example": "yGeBAFYgFmM=",
            "nullable": true,
            "type": "string"
          },
          "async_capture": {
            "default": false,
            "description": "Whether to capture the transaction asynchronously.\n\n- When `async_capture` is `false` (default), the transaction is captured\n  in the same request.\n- When `async_capture` is `true`, the transaction is automatically\n  captured at a later time.\n\nRedirect transactions are not affected by this flag.\n\nThis flag can only be set to `true` when `intent` is set to `capture`.",
            "example": true,
            "type": "boolean"
          },
          "browser_info": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BrowserInfo"
              }
            ],
            "description": "Information about the browser used by the buyer.",
            "nullable": true,
            "type": "object"
          },
          "buyer_external_identifier": {
            "description": "The `external_identifier` of the buyer to associate this payment method\nto. If this field is provided then the `buyer_id` field\nneeds to be unset.\n\nIf a stored payment method or gift card is provided, then the buyer for\nthat payment method needs to match the buyer for this field.",
            "example": "user-789123",
            "type": "string"
          },
          "buyer_id": {
            "description": "The ID of the buyer to associate this payment method to. If this field is\nprovided then the `buyer_external_identifier` field needs to be unset.\n\nIf a stored payment method or gift card is provided, then the buyer for\nthat payment method needs to match the buyer for this field.",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "format": "uuid",
            "type": "string"
          },
          "buyer": {
            "description": "Guest buyer details provided inline rather than creating a buyer resource\nbeforehand and using the `buyer_id` or `buyer_external_identifier` keys.\nNo buyer resource will be created on Gr4vy when used.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/TransactionBuyerRequest"
              }
            ],
            "type": "object",
            "x-model-name": "TransactionBuyerRequest",
            "nullable": true
          },
          "cart_items": {
            "description": "An array of cart items that represents the line items of a transaction.",
            "items": {
              "$ref": "#/components/schemas/CartItem"
            },
            "maxItems": 249,
            "type": "array"
          },
          "connection_options": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ConnectionOptions"
              }
            ],
            "description": "Allows for passing optional configuration per connection to take\nadvantage of connection specific features. When provided, the data\nis only passed to the target connection type to prevent sharing\nconfiguration across connections.\n\nPlease note that each of the keys this object are in kebab-case, for\nexample `cybersource-anti-fraud` as they represent the ID of the\nconnector. All the other keys will be snake case, for example\n`merchant_defined_data` or camel case to match an external API that the\nconnector uses.",
            "nullable": true,
            "type": "object"
          },
          "country": {
            "description": "The 2-letter ISO code of the country where the transaction is processed.\nThis is also used to filter the payment services that can process the\ntransaction.\n\nIf this value is provided for redirect requests and it's not `null`, it\nmust match the one specified for `country` in `payment_method`. Otherwise,\nthe value specified for `country` in `payment_method` will be assumed\nimplicitly.\n",
            "example": "US",
            "nullable": true,
            "type": "string"
          },
          "external_identifier": {
            "description": "An external identifier that can be used to match the transaction against your own records.",
            "example": "user-789123",
            "nullable": true,
            "type": "string"
          },
          "gift_cards": {
            "description": "The optional gift card(s) to use for this transaction. At least one gift card is required if no other `payment_method` has been added.\nBy default, only a maximum limit of 10 gift cards may be used in a single transaction. Please contact our team to change this limit.",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/TransactionGiftCardNewRequest"
                },
                {
                  "$ref": "#/components/schemas/TransactionGiftCardStoredRequest"
                }
              ],
              "x-model-name": "TransactionGiftCardRequest"
            },
            "nullable": true,
            "type": "array"
          },
          "intent": {
            "default": "authorize",
            "description": "Defines the intent of this API call. This determines the desired initial\nstate of the transaction.\n\n* `authorize` - (Default) Optionally approves and then authorizes a\ntransaction but does not capture the funds.\n* `capture` - Optionally approves and then authorizes and captures the\nfunds of the transaction.",
            "enum": [
              "authorize",
              "capture"
            ],
            "example": "capture",
            "type": "string"
          },
          "is_subsequent_payment": {
            "default": false,
            "description": "Indicates whether the transaction represents a subsequent payment\ncoming from a setup recurring payment.\nPlease note there are some restrictions on how this flag may be\nused.\n\nThe flag can only be `false` (or not set) when the transaction meets\none of the following criteria:\n\n* It is not `merchant_initiated`.\n* `payment_source` is set to `card_on_file`.\n\nThe flag can only be set to `true` when the transaction meets one of the\nfollowing criteria:\n\n* It is not `merchant_initiated`.\n* `payment_source` is set to `recurring` or `installment` and\n`merchant_initiated` is set to `true`.\n* `payment_source` is set to `card_on_file`.",
            "example": true,
            "type": "boolean"
          },
          "merchant_initiated": {
            "default": false,
            "description": "Indicates whether the transaction was initiated by the merchant (true)\nor customer (false).",
            "example": true,
            "type": "boolean"
          },
          "metadata": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Any additional information about the transaction that you would like to\nstore as key-value pairs. This data is passed to payment service\nproviders that support it.",
            "example": {
              "key": "value"
            },
            "maxProperties": 20,
            "type": "object"
          },
          "payment_source": {
            "description": "The source of the transaction. Defaults to `ecommerce`.",
            "type": "string",
            "example": "recurring",
            "enum": [
              "ecommerce",
              "moto",
              "recurring",
              "installment",
              "card_on_file"
            ]
          },
          "previous_scheme_transaction_id": {
            "default": null,
            "description": "A scheme's transaction identifier to use in connecting a merchant\ninitiated transaction to a previous customer initiated transaction.\n\nIf not provided, and a qualifying customer initiated transaction has been\npreviously made, then Gr4vy will populate this value with the identifier\nreturned for that transaction.\n\ne.g. the Visa Transaction Identifier, or Mastercard Trace ID.",
            "example": "123456789012345",
            "nullable": true,
            "type": "string"
          },
          "shipping_details_id": {
            "default": null,
            "description": "The unique identifier of a set of shipping details stored for the buyer.\n\nIf provided, the created transaction will include a copy of the details\nat the point of transaction creation; i.e. it will not be affected by\nlater changes to the detail in the database.",
            "example": "47da6902-5eae-4b4b-88fd-856802d627d6",
            "format": "uuid",
            "nullable": true,
            "type": "string"
          },
          "statement_descriptor": {
            "allOf": [
              {
                "$ref": "#/components/schemas/StatementDescriptor"
              }
            ],
            "nullable": true,
            "type": "object"
          },
          "store": {
            "default": false,
            "description": "Whether or not to also try and store the payment method with us so that\nit can be used again for future use. This is only supported for payment\nmethods that support this feature. There are also a few restrictions on\nhow the flag may be set:\n\n* The flag has to be set to `true` when the `payment_source` is set to\n`recurring` or `installment`, and `merchant_initiated` is set to `false`.\n\n* The flag has to be set to `false` (or not set) when using a previously\nvaulted payment method.",
            "example": true,
            "type": "boolean"
          },
          "three_d_secure_data": {
            "description": "Pass through 3-D Secure data to support external 3-D Secure authorisation.\nIf using an external 3-D Secure provider, you should not pass\na `redirect_url` in the `payment_method` object for a transaction.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/ThreeDSecureDataV1"
              },
              {
                "$ref": "#/components/schemas/ThreeDSecureDataV2"
              }
            ],
            "type": "object",
            "x-model-name": "ThreeDSecureDataV1V2"
          },
          "payment_service_id": {
            "default": null,
            "description": "The unique identifier of an existing payment service. When\nprovided, the created transaction will be processed by the given\npayment service and any routing rules will be skipped.",
            "example": "47da6902-5eae-4b4b-88fd-856802d627d6",
            "nullable": true,
            "type": "string",
            "format": "uuid"
          },
          "airline": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "description": "The airline addendum data which describes the airline booking\nassociated with this transaction.",
            "nullable": true
          },
          "account_funding_transaction": {
            "type": "boolean",
            "default": false,
            "description": "Whether or not the transaction is an account funding transaction.",
            "nullable": true,
            "example": true
          },
          "recipient": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Recipient"
              }
            ],
            "description": "The recipient of an account funding transaction.",
            "nullable": true
          },
          "allow_partial_authorization": {
            "type": "boolean",
            "default": false,
            "description": "Whether or not to allow partial authorization of the transaction. Support for this will depend\non the connector used. When a connector does not support partial authorization, and the user does not\nhave sufficient funds, the transaction will be declined.",
            "nullable": true,
            "example": true
          }
        }
      },
      "TransactionBuyerRequest": {
        "title": "Buyer",
        "type": "object",
        "description": "Guest buyer details.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the buyer against your own records. This value needs to be unique for all buyers.",
            "example": "user-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "display_name": {
            "type": "string",
            "description": "A unique name for this buyer which is used in the Gr4vy admin panel to give a buyer a human readable name.",
            "example": "John L.",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "billing_details": {
            "type": "object",
            "description": "The optional billing details for the a buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/BillingDetailsRequest"
              }
            ]
          },
          "shipping_details": {
            "type": "object",
            "description": "The optional shipping details for the buyer.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/ShippingDetail"
              }
            ]
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The source account number to perform an account funding transaction.",
            "nullable": true
          }
        }
      },
      "TransactionCaptureRequest": {
        "title": "Capture a transaction",
        "type": "object",
        "description": "A request to capture a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "amount": {
            "type": "integer",
            "description": "The monetary amount to capture an authorization for, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nWhen omitted blank, this will capture the entire amount.",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          },
          "airline": {
            "type": "object",
            "allOf": [
              {
                "$ref": "#/components/schemas/Airline"
              }
            ],
            "description": "The airline addendum data which describes the airline booking\nassociated with this transaction. When provided, this will override any\nairline data provided when authorizing the transaction. Only the data on\nthis request will be passed to the payment service, and none of the\noriginal data will be sent or kept.",
            "nullable": true
          }
        }
      },
      "TransactionRefundRequest": {
        "title": "Transaction Refund Request",
        "type": "object",
        "description": "A request to refund a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "amount": {
            "type": "integer",
            "description": "The amount requested to refund.\n\nIf omitted, a full refund will be requested for the main payment method.\n\nWhen set, the amount must be lower than or equal to the remaining balance\nin the associated transaction. Negative and zero-amount refunds are not\nsupported.",
            "minimum": 1,
            "maximum": 99999999,
            "example": 1299
          },
          "target_type": {
            "type": "string",
            "description": "The target type to refund for. This can be used to target a gift card\nto refund to instead of the main payment method.",
            "example": "gift-card-redemption",
            "default": "payment-method",
            "nullable": true,
            "enum": [
              "payment-method",
              "gift-card-redemption"
            ]
          },
          "target_id": {
            "type": "string",
            "format": "uuid",
            "nullable": true,
            "description": "The optional ID of the instrument to refund for. This is only required when\nthe `target_type` is set to `gift-card-redemption`.",
            "example": "c23ea83f-1b1c-4584-a0e8-78ef8c041949"
          },
          "reason": {
            "type": "string",
            "description": "An optional reason to attach extra context to the refund request.",
            "example": "Refund due to user request",
            "nullable": true,
            "maxLength": 100
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the refund against your\nown records.",
            "example": "refund-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 300
          }
        }
      },
      "TransactionRefundAllRequest": {
        "title": "Transaction Refund All Request",
        "type": "object",
        "description": "A request to fully refund a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "reason": {
            "type": "string",
            "description": "The reason to refund for. This can be used to attach a written reason to the\nrefund request.",
            "example": "Refund due to user request",
            "nullable": true,
            "maxLength": 100
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the refund against your\nown records.",
            "example": "refund-789123",
            "nullable": true,
            "minLength": 1,
            "maxLength": 300
          }
        }
      },
      "TransactionPaymentMethodRequest": {
        "title": "Transaction payment method request",
        "type": "object",
        "description": "Payment method details to use in a transaction or to register\na new payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method"
        ],
        "properties": {
          "method": {
            "description": "The method to use for this request.",
            "type": "string",
            "example": "card",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this credit card as it can be found on the\nfront of the card.",
            "nullable": true
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`. If a card has been\npreviously stored with us this value is optional.",
            "example": "11/15",
            "pattern": "^\\d\\d/\\d\\d$",
            "minLength": 5,
            "maxLength": 5,
            "nullable": true
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records.",
            "example": "user-789123",
            "nullable": true
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction or payment method. This only applies to payment methods that\nrequire buyer approval.",
            "example": "https://example.com/callback",
            "nullable": true
          },
          "id": {
            "type": "string",
            "description": "An identifier for a previously tokenized payment method or checkout-session.\nThis id can represent any type of payment method or checkout-session.",
            "example": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5",
            "nullable": true
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code to use this payment method for. This is\nused to select the payment service to use.",
            "nullable": true
          },
          "country": {
            "type": "string",
            "example": "US",
            "description": "The 2-letter ISO code of the country to use this payment method for.\nThis is used to select the payment service to use.",
            "nullable": true
          },
          "token": {
            "type": "object",
            "description": "The encrypted (opaque) token that was passed to the `onpaymentauthorized`\ncallback by the Apple Pay integration.",
            "nullable": true
          },
          "assurance_details": {
            "type": "object",
            "description": "Information about the validation performed on the payment data. (See https://developers.google.com/pay/api/web/reference/response-objects#assurance-details-specifications).",
            "properties": {
              "account_verified": {
                "type": "boolean",
                "example": false,
                "description": "Indicates that card holder possession validation has been performed.",
                "nullable": true
              },
              "card_holder_authenticated": {
                "type": "boolean",
                "example": false,
                "description": "Indicates that identification and verifications was performed.",
                "nullable": true
              }
            },
            "nullable": true
          },
          "cardholder_name": {
            "type": "string",
            "description": "Name of the card holder.",
            "nullable": true
          },
          "cryptogram": {
            "type": "string",
            "description": "The cryptogram of the network token.",
            "nullable": true
          }
        }
      },
      "TransactionGiftCardRequest": {
        "title": "Transaction gift card (Request)",
        "type": "object",
        "description": "Create a transaction with this gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893",
            "description": "The ID of the gift card to check a balance for.\nRequired if `number` is not set."
          },
          "number": {
            "type": "string",
            "minLength": 16,
            "maxLength": 19,
            "example": "4123455541234561234",
            "pattern": "^[0-9]{16,19}$",
            "description": "The 16-19 digit number for this gift card.\nRequired if `id` is not set."
          },
          "pin": {
            "type": "string",
            "description": "The PIN for this gift card. Required if `number` is set.",
            "example": "1234"
          },
          "amount": {
            "description": "The monetary amount to charge for this gift card, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nAll gift card amounts are subtracted from the total transaction amount. The\nremainder is charged to the provided `payment_method`.",
            "type": "integer",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          }
        }
      },
      "TransactionGiftCardNewRequest": {
        "title": "Transaction gift card request (New)",
        "type": "object",
        "description": "Create a transaction with this gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "number",
          "pin"
        ],
        "properties": {
          "number": {
            "type": "string",
            "minLength": 16,
            "maxLength": 19,
            "example": "4123455541234561234",
            "pattern": "^[0-9]{16,19}$",
            "description": "The 16-19 digit number for this gift card."
          },
          "pin": {
            "type": "string",
            "description": "The PIN for this gift card.",
            "example": "1234"
          },
          "amount": {
            "description": "The monetary amount to charge for this gift card, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nAll gift card amounts are subtracted from the total transaction amount. The\nremainder is charged to the provided `payment_method`.",
            "type": "integer",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          }
        }
      },
      "TransactionGiftCardStoredRequest": {
        "title": "Transaction gift card request (Stored)",
        "type": "object",
        "description": "Create a transaction with a stored gift card.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "amount",
          "id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "e6cdf979-87e2-4796-8ff6-9784d5aed893",
            "description": "The ID of the gift card to check a balance for."
          },
          "amount": {
            "description": "The monetary amount to charge for this gift card, in the smallest\ncurrency unit for the given currency, for example `1299` cents to create\nan authorization for `$12.99`.\n\nAll gift card amounts are subtracted from the total transaction amount. The\nremainder is charged to the provided `payment_method`.",
            "type": "integer",
            "example": 1299,
            "minimum": 1,
            "maximum": 99999999
          }
        }
      },
      "TransactionCardRequest": {
        "title": "Card",
        "type": "object",
        "description": "Card payment method details to use in a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "number",
          "expiration_date"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`card`.",
            "example": "card",
            "enum": [
              "card"
            ]
          },
          "number": {
            "type": "string",
            "minLength": 13,
            "maxLength": 19,
            "example": "4111111111111111",
            "pattern": "^[0-9]{13,19}$",
            "description": "The 13-19 digit number for this card as it can be found on the\nfront of the card."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the card, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "security_code": {
            "type": "string",
            "description": "The 3 or 4 digit security code often found on the card. This often\nreferred to as the CVV or CVD.",
            "pattern": "^\\d{3,4}$",
            "minLength": 3,
            "maxLength": 4,
            "example": "123",
            "nullable": true
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records. This can only be set if the `store` flag is set to `true`.",
            "example": "card-323444",
            "nullable": true
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "We strongly recommend providing a `redirect_url` either when 3-D\nSecure is enabled and `three_d_secure_data` is not provided, or when\nusing connections where 3DS is enabled. This value will be appended\nwith both a transaction ID and status\n(e.g. `https://example.com/callback?gr4vy_transaction_id=123\n&gr4vy_transaction_status=capture_succeeded`) after 3-D Secure has\ncompleted. For those cases, if the value is not present, the\ntransaction will be marked as failed.",
            "example": "https://example.com/callback",
            "nullable": true
          }
        }
      },
      "TransactionRedirectRequest": {
        "title": "Redirect",
        "type": "object",
        "description": "Redirect payment method details to use in a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "redirect_url",
          "country",
          "currency"
        ],
        "properties": {
          "method": {
            "description": "The method to use, this can be any of the methods that\nsupport redirect requests.",
            "type": "string",
            "example": "paypal",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "gopay",
              "grabpay",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_10x",
              "oney_12x",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "venmo",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "The redirect URL to redirect a buyer to after they have authorized their\ntransaction.",
            "example": "https://example.com/callback"
          },
          "currency": {
            "type": "string",
            "example": "USD",
            "description": "The ISO-4217 currency code to use this payment method for. This is\nused to select the payment service to use."
          },
          "country": {
            "type": "string",
            "example": "US",
            "description": "The 2-letter ISO code of the country to use this payment method for.\nThis is used to select the payment service to use."
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the account against your own records. This can only be set if the `store` flag is set to `true`.",
            "example": "account-23423423",
            "nullable": true
          }
        }
      },
      "TransactionCheckoutSessionRequest": {
        "title": "Checkout Session",
        "type": "object",
        "description": "Checkout Session payment method details to use in a transaction.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "id"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`checkout-session`.",
            "example": "checkout-session",
            "enum": [
              "checkout-session"
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The ID of the Checkout Session.",
            "example": "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
          },
          "external_identifier": {
            "type": "string",
            "description": "An external identifier that can be used to match the card against your own records. This can only be set if the `store` flag is set to `true`.",
            "example": "card-323444",
            "nullable": true
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "We strongly recommend providing a `redirect_url` either when 3-D\nSecure is enabled and `three_d_secure_data` is not provided, or when\nusing connections where 3DS is enabled. This value will be appended\nwith both a transaction ID and status\n(e.g. `https://example.com/callback?gr4vy_transaction_id=123\n&gr4vy_transaction_status=capture_succeeded`) after 3-D Secure has\ncompleted. For those cases, if the value is not present, the\ntransaction will be marked as failed.",
            "example": "https://example.com/callback",
            "nullable": true
          }
        }
      },
      "TransactionNetworkTokenRequest": {
        "title": "Network Token payment method request",
        "type": "object",
        "description": "Details for a Network Token payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "token",
          "expiration_date"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`network-token`.",
            "example": "network-token",
            "enum": [
              "network-token"
            ]
          },
          "token": {
            "type": "string",
            "description": "The value of the network token."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the network token, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "eci": {
            "type": "string",
            "pattern": "^0?\\d$",
            "minLength": 1,
            "maxLength": 2,
            "description": "The ecommerce indicator.",
            "example": "05"
          },
          "cryptogram": {
            "type": "string",
            "description": "The cryptogram of the network token.",
            "nullable": true
          },
          "redirect_url": {
            "type": "string",
            "format": "uri",
            "description": "We strongly recommend providing a `redirect_url` either when 3-D\nSecure is enabled and `three_d_secure_data` is not provided, or when\nusing connections where 3DS is enabled. This value will be appended\nwith both a transaction ID and status\n(e.g. `https://example.com/callback?gr4vy_transaction_id=123\n&gr4vy_transaction_status=capture_succeeded`) after 3-D Secure has\ncompleted. For those cases, if the value is not present, the\ntransaction will be marked as failed.",
            "example": "https://example.com/callback",
            "nullable": true
          }
        }
      },
      "TransactionNetworkTokenApplePayRequest": {
        "title": "Apple Pay decrypted token",
        "type": "object",
        "description": "Details for an Apple Pay decrypted token payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "token",
          "expiration_date",
          "card_source"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`network-token`.",
            "example": "network-token",
            "enum": [
              "network-token"
            ]
          },
          "token": {
            "type": "string",
            "description": "The value of the decrypted Apple Pay token."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the network token, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "cryptogram": {
            "type": "string",
            "description": "The cryptogram of the network token.",
            "nullable": true
          },
          "eci": {
            "type": "string",
            "pattern": "^0?\\d$",
            "minLength": 1,
            "maxLength": 2,
            "description": "The ecommerce indicator for 3D-Secure.",
            "example": "05"
          },
          "card_source": {
            "type": "string",
            "example": "apple-pay",
            "enum": [
              "apple-pay"
            ]
          },
          "card_suffix": {
            "type": "string",
            "nullable": true,
            "example": "1234",
            "maxLength": 4,
            "description": "Last four digits of card PAN."
          },
          "card_scheme": {
            "type": "string",
            "nullable": true,
            "description": "The scheme/brand of the card."
          },
          "cardholder_name": {
            "type": "string",
            "nullable": true,
            "description": "The cardholder name."
          }
        }
      },
      "TransactionNetworkTokenGooglePayRequest": {
        "title": "Google Pay decrypted token",
        "type": "object",
        "description": "Details for a Google Pay decrypted token payment method.",
        "x-tags": [
          "Request Bodies"
        ],
        "required": [
          "method",
          "token",
          "expiration_date",
          "card_source"
        ],
        "properties": {
          "method": {
            "type": "string",
            "description": "`network-token`.",
            "example": "network-token",
            "enum": [
              "network-token"
            ]
          },
          "token": {
            "type": "string",
            "description": "The value of the decrypted Apple Pay token."
          },
          "expiration_date": {
            "type": "string",
            "description": "The expiration date of the network token, formatted `MM/YY`.",
            "example": "11/25",
            "pattern": "^\\d{2}/\\d{2}$",
            "minLength": 5,
            "maxLength": 5
          },
          "cryptogram": {
            "type": "string",
            "description": "The cryptogram of the network token.",
            "nullable": true
          },
          "eci": {
            "type": "string",
            "pattern": "^0?\\d$",
            "minLength": 1,
            "maxLength": 2,
            "description": "The ecommerce indicator for 3D-Secure.",
            "example": "05"
          },
          "card_source": {
            "type": "string",
            "example": "google-pay",
            "enum": [
              "google-pay"
            ]
          },
          "card_suffix": {
            "type": "string",
            "nullable": true,
            "example": "1234",
            "maxLength": 4,
            "description": "Last four digits of card PAN."
          },
          "card_scheme": {
            "type": "string",
            "nullable": true,
            "description": "The scheme/brand of the card."
          },
          "cardholder_name": {
            "type": "string",
            "nullable": true,
            "description": "The cardholder name."
          }
        }
      },
      "TransactionRetriesReportSpec": {
        "title": "Transaction Retries Report Specification",
        "type": "object",
        "description": "The specification of a transaction retries report.",
        "x-tags": [
          "Reports"
        ],
        "required": [
          "model",
          "params"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "The model (dataset) that the data used for the report is\nretrieved from.",
            "example": "transaction_retries",
            "enum": [
              "transaction_retries"
            ]
          },
          "params": {
            "type": "object",
            "description": "Parameters used to configure the report.",
            "properties": {
              "filters": {
                "type": "object",
                "description": "The filters for the report.",
                "example": {
                  "created_at": {
                    "start": "day_start",
                    "end": "day_end"
                  }
                },
                "properties": {
                  "created_at": {
                    "type": "object",
                    "description": "The time window for when the data was created to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the data was created\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the data was created\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "TransactionsReportSpec": {
        "title": "Transactions Report Specification",
        "type": "object",
        "description": "The specification of a transactions report.",
        "x-tags": [
          "Reports"
        ],
        "required": [
          "model",
          "params"
        ],
        "properties": {
          "model": {
            "type": "string",
            "description": "The model (dataset) that the data used for the report is\nretrieved from.",
            "example": "transactions",
            "enum": [
              "transactions"
            ]
          },
          "params": {
            "type": "object",
            "description": "Parameters used to configure the report.",
            "properties": {
              "fields": {
                "type": "array",
                "description": "A list of fields for the report.",
                "items": {
                  "type": "string",
                  "enum": [
                    "id",
                    "external_identifier",
                    "status",
                    "created_at",
                    "updated_at",
                    "authorized_at",
                    "captured_at",
                    "voided_at",
                    "amount",
                    "currency",
                    "captured_amount",
                    "refunded_amount",
                    "method",
                    "scheme",
                    "payment_service_transaction_id",
                    "payment_service_id",
                    "payment_service_definition_id",
                    "payment_service_display_name",
                    "auth_response_code",
                    "raw_response_code",
                    "raw_response_description",
                    "error_code",
                    "metadata",
                    "payment_source",
                    "is_subsequent_payment",
                    "merchant_initiated",
                    "three_d_secure_status",
                    "three_d_secure_eci",
                    "three_d_secure_auth_resp",
                    "three_d_secure_method",
                    "buyer_external_identifier",
                    "billing_details_first_name",
                    "billing_details_last_name",
                    "billing_details_email_address",
                    "billing_details_phone_number",
                    "billing_details_address_city",
                    "billing_details_address_country",
                    "billing_details_address_postal_code",
                    "billing_details_address_state",
                    "billing_details_address_state_code",
                    "billing_details_address_house_number_or_name",
                    "billing_details_address_line1",
                    "billing_details_address_line2",
                    "billing_details_address_organization",
                    "billing_details_tax_id",
                    "billing_details_tax_id_kind",
                    "authorized_amount",
                    "intent_outcome",
                    "gift_card_redemptions_amount",
                    "gift_card_redemption_refunds_amount",
                    "settled",
                    "settled_currency",
                    "settled_amount"
                  ]
                },
                "example": [
                  "id",
                  "external_identifier"
                ]
              },
              "filters": {
                "type": "object",
                "description": "The filters for the report.",
                "example": {
                  "status": [
                    "authorization_failed"
                  ]
                },
                "properties": {
                  "status": {
                    "type": "array",
                    "description": "A list of statuses to filter by.",
                    "example": [
                      "authorization_failed"
                    ],
                    "items": {
                      "type": "string",
                      "enum": [
                        "processing",
                        "buyer_approval_pending",
                        "authorization_succeeded",
                        "authorization_failed",
                        "authorization_declined",
                        "capture_pending",
                        "capture_succeeded",
                        "authorization_void_pending",
                        "authorization_voided"
                      ]
                    }
                  },
                  "created_at": {
                    "type": "object",
                    "description": "The time window for when the data was created to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the data was created\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the data was created\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  },
                  "updated_at": {
                    "type": "object",
                    "description": "The time window for when the data was last updated to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the data was updated\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the data was updated\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  },
                  "authorized_at": {
                    "type": "object",
                    "description": "The time window for when the transactions were authorized to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the transactions were authorized\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the transactions were authorized\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  },
                  "captured_at": {
                    "type": "object",
                    "description": "The time window for when the transactions were captured to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the transactions were captured\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the transactions were captured\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  },
                  "voided_at": {
                    "type": "object",
                    "description": "The time window for when the transactions were voided to filter by.",
                    "example": {
                      "start": "day_start",
                      "end": "day_end"
                    },
                    "properties": {
                      "start": {
                        "type": "string",
                        "description": "The starting boundary for when the transactions were voided\nas either a date-time or date-time placeholder value.",
                        "example": "day_start"
                      },
                      "end": {
                        "type": "string",
                        "description": "The ending boundary for when the transactions were voided\nas either a date-time or date-time placeholder value.",
                        "example": "day_end"
                      }
                    }
                  },
                  "currency": {
                    "type": "array",
                    "description": "A list of ISO-4217 currency codes to filter by.",
                    "example": [
                      "GBP"
                    ],
                    "items": {
                      "type": "string"
                    }
                  },
                  "method": {
                    "type": "array",
                    "description": "A list of payment methods to filter by.",
                    "example": [
                      "card"
                    ],
                    "items": {
                      "type": "string",
                      "example": "card",
                      "enum": [
                        "affirm",
                        "afterpay",
                        "alipay",
                        "alipayhk",
                        "applepay",
                        "bacs",
                        "bancontact",
                        "banked",
                        "becs",
                        "bitpay",
                        "boleto",
                        "boost",
                        "card",
                        "cashapp",
                        "chaseorbital",
                        "checkout-session",
                        "clearpay",
                        "click-to-pay",
                        "dana",
                        "dcb",
                        "dlocal",
                        "ebanx",
                        "efecty",
                        "eps",
                        "everydaypay",
                        "gcash",
                        "gem",
                        "gemds",
                        "gift-card",
                        "giropay",
                        "givingblock",
                        "gocardless",
                        "googlepay",
                        "googlepay_pan_only",
                        "gopay",
                        "grabpay",
                        "id",
                        "ideal",
                        "kakaopay",
                        "kcp",
                        "klarna",
                        "latitude",
                        "latitudeds",
                        "laybuy",
                        "linepay",
                        "linkaja",
                        "maybankqrpay",
                        "mercadopago",
                        "multibanco",
                        "multipago",
                        "netbanking",
                        "network-token",
                        "oney_3x",
                        "oney_4x",
                        "oney_6x",
                        "oney_10x",
                        "oney_12x",
                        "ovo",
                        "oxxo",
                        "payid",
                        "paymaya",
                        "paypal",
                        "paypalpaylater",
                        "payto",
                        "venmo",
                        "pix",
                        "pse",
                        "rabbitlinepay",
                        "razorpay",
                        "scalapay",
                        "sepa",
                        "shopeepay",
                        "singteldash",
                        "smartpay",
                        "sofort",
                        "spei",
                        "stripedd",
                        "thaiqr",
                        "touchngo",
                        "truemoney",
                        "trustly",
                        "trustlyeurope",
                        "upi",
                        "vipps",
                        "waave",
                        "webpay",
                        "wechat",
                        "zippay"
                      ]
                    }
                  },
                  "scheme": {
                    "type": "array",
                    "description": "A list of card schemes to filter by.",
                    "example": [
                      "visa"
                    ],
                    "items": {
                      "type": "string",
                      "example": "visa",
                      "enum": [
                        "accel",
                        "amex",
                        "bancontact",
                        "carte-bancaire",
                        "cirrus",
                        "culiance",
                        "dankort",
                        "diners-club",
                        "discover",
                        "eftpos-australia",
                        "elo",
                        "hipercard",
                        "jcb",
                        "maestro",
                        "mastercard",
                        "mir",
                        "nyce",
                        "other",
                        "pulse",
                        "rupay",
                        "star",
                        "uatp",
                        "unionpay",
                        "visa",
                        null
                      ]
                    }
                  },
                  "metadata": {
                    "type": "array",
                    "description": "A list of metadata as key-value pairs to filter by.",
                    "example": [
                      {
                        "key": "value"
                      }
                    ],
                    "items": {
                      "type": "object"
                    }
                  },
                  "three_d_secure_status": {
                    "type": "array",
                    "description": "A list of 3DS challenge statuses to filter by.",
                    "items": {
                      "type": "string",
                      "enum": [
                        "setup_error",
                        "error",
                        "declined",
                        "cancelled",
                        "complete"
                      ]
                    }
                  },
                  "three_d_secure_eci": {
                    "type": "array",
                    "description": "A list of electric commerce indicators to filter by.",
                    "example": [
                      "05"
                    ],
                    "items": {
                      "type": "string"
                    }
                  },
                  "three_d_secure_auth_resp": {
                    "type": "array",
                    "description": "A list of 3DS responses to filter by.",
                    "example": [
                      "N"
                    ],
                    "items": {
                      "type": "string"
                    }
                  },
                  "payment_source": {
                    "type": "array",
                    "description": "A list of payment sources to filter by.",
                    "items": {
                      "type": "string",
                      "example": "recurring",
                      "enum": [
                        "ecommerce",
                        "moto",
                        "recurring",
                        "installment",
                        "card_on_file"
                      ]
                    }
                  },
                  "merchant_initiated": {
                    "type": "boolean",
                    "description": "A flag indicating transactions initiated by the merchant to filter by.",
                    "example": true
                  },
                  "is_subsequent_payment": {
                    "type": "boolean",
                    "description": "A flag indicating transactions with subsequent payments to filter by.",
                    "example": true
                  }
                }
              },
              "sort": {
                "type": "array",
                "description": "A list of fields to sort the report.",
                "items": {
                  "type": "object"
                },
                "example": [
                  {
                    "field": "captured_at",
                    "order": "desc"
                  }
                ]
              }
            }
          }
        }
      },
      "User": {
        "title": "User",
        "type": "object",
        "x-tags": [
          "Users"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "`user`.",
            "example": "user",
            "enum": [
              "user"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this user."
          },
          "name": {
            "type": "string",
            "description": "The full name of this user.",
            "example": "John Gravy"
          },
          "email_address": {
            "type": "string",
            "description": "The email address for this user.",
            "example": "john@example.com"
          },
          "has_valid_password": {
            "type": "boolean",
            "description": "The user has set a valid password.",
            "example": true
          },
          "category": {
            "type": "string",
            "enum": [
              "sso",
              "email"
            ],
            "description": "The method by which this user authenticates.",
            "example": "email"
          },
          "is_staff": {
            "type": "boolean",
            "example": false,
            "description": "Denotes whether this user is a Gr4vy staff member."
          },
          "reset_token": {
            "type": "string",
            "description": "The token required when setting a password.",
            "example": "abc",
            "nullable": true
          },
          "reset_token_expires_at": {
            "type": "string",
            "description": "The expiration date for the reset token.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "last_logged_in_at": {
            "type": "string",
            "description": "The date that the user last logged in at.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00",
            "nullable": true
          },
          "status": {
            "type": "string",
            "description": "The current status of this user.",
            "example": "active",
            "enum": [
              "active",
              "pending"
            ]
          },
          "roles": {
            "type": "array",
            "description": "The roles this user has been assigned.",
            "items": {
              "$ref": "#/components/schemas/UserRole"
            }
          },
          "merchant_accounts": {
            "type": "array",
            "description": "A list of merchant accounts that the user is assigned to.",
            "items": {
              "$ref": "#/components/schemas/MerchantAccount"
            }
          }
        }
      },
      "Users": {
        "title": "User",
        "type": "object",
        "x-tags": [
          "Users"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of users.",
            "items": {
              "$ref": "#/components/schemas/User"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "UserCurrentUpdate": {
        "title": "User (Update Current)",
        "type": "object",
        "description": "A request to update the current user.",
        "x-tags": [
          "Users"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The full name of the user which is used in the Gr4vy admin panel to give a user a human readable name.",
            "example": "John L.",
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "UserRequest": {
        "title": "User (Create)",
        "type": "object",
        "description": "A request to create a user.",
        "x-tags": [
          "Users"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The full name of the user which is used in the Gr4vy admin panel to give an user a human readable name.",
            "example": "John L.",
            "nullable": false,
            "minLength": 1,
            "maxLength": 1000
          },
          "email_address": {
            "type": "string",
            "description": "The email address for this user.",
            "example": "john@example.com",
            "nullable": false,
            "minLength": 1,
            "maxLength": 200
          },
          "role_ids": {
            "type": "array",
            "minItems": 1,
            "description": "A list of role ids that will be assigned to the user being created. The creator must have `roles.write` or the role that is being assigned.",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "example": [
              "8d3fe99b-1422-42e6-bbb3-932d95ae5f79"
            ],
            "nullable": false
          },
          "merchant_account_ids": {
            "type": "array",
            "description": "A list of merchant account IDs that the user being created will be assigned to.",
            "items": {
              "type": "string"
            },
            "example": [
              "default",
              "plantly-uk"
            ],
            "nullable": true
          }
        }
      },
      "UserUpdate": {
        "title": "User (Update)",
        "type": "object",
        "description": "A request to update a user.",
        "x-tags": [
          "Users"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The full name of the user which is used in the Gr4vy admin panel to give a user a human readable name.",
            "example": "John L.",
            "minLength": 1,
            "maxLength": 1000
          },
          "role_ids": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "example": [
              "46973e9d-88a7-44a6-abfe-be4ff0134ff4"
            ],
            "description": "The IDs of the roles to assign to the user. Sending an empty list will remove all roles assigned to the user."
          },
          "merchant_account_ids": {
            "type": "array",
            "description": "A list of merchant account IDs that the user is assigned to.",
            "items": {
              "type": "string"
            },
            "example": [
              "default",
              "plantly-uk"
            ],
            "nullable": true
          }
        }
      },
      "UserRole": {
        "title": "User Role",
        "type": "object",
        "x-tags": [
          "Users"
        ],
        "allOf": [
          {
            "$ref": "#/components/schemas/Role"
          }
        ]
      },
      "SetPasswordRequest": {
        "title": "Set Password (Create)",
        "type": "object",
        "description": "A request to set a password for a user.",
        "x-tags": [
          "Users"
        ],
        "properties": {
          "reset_token": {
            "type": "string",
            "description": "Unique reset token valid for 7 days.",
            "example": "nXyWSHq2r5q_8F1_NXtppEStY7KbBHqwU9T8pdmOQa_LYJxpxxXcjOXL58xpHLy5gh1k6s0Myl3ygA6SnsxIjLXBKO3x1EZX3igq",
            "nullable": false,
            "minLength": 100,
            "maxLength": 100
          },
          "password": {
            "type": "string",
            "description": "The password the user to log in with.",
            "example": "this-is-n0t-a-secure-passw0rd"
          }
        }
      },
      "ResetPasswordRequest": {
        "title": "Reset Password (Create)",
        "type": "object",
        "description": "A request to reset a password for a user.",
        "x-tags": [
          "Users"
        ],
        "properties": {
          "email_address": {
            "type": "string",
            "description": "The email address of the user account to reset.",
            "example": "john@example.com"
          }
        }
      },
      "FlowRule": {
        "title": "Flow rule",
        "type": "object",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `rule`.",
            "example": "rule",
            "enum": [
              "rule"
            ]
          },
          "id": {
            "type": "string",
            "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
            "description": "The unique Gr4vy ID for this rule.",
            "format": "uuid"
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default"
          },
          "description": {
            "type": "string",
            "description": "Description of the flow rule.",
            "example": "example rule.",
            "nullable": true,
            "minLength": 1,
            "maxLength": 200
          },
          "flow": {
            "type": "string",
            "description": "The name of the Flow.",
            "example": "checkout",
            "enum": [
              "checkout",
              "card-transaction",
              "non-card-transaction",
              "redirect-transaction"
            ]
          },
          "action": {
            "type": "string",
            "description": "Action for the given rule. Actions can only be used in\nflows that support them.\n\n* The `checkout` flow only supports the\n`select-payment-options` action.\n* The `card-transaction` supports the `route-transaction`,\n`skip-3ds`, and `decline-early` actions.\n* The `non-card-transaction` flow only supports the\n`decline-early` action.\n* The `redirect-transaction` flow only supports\nthe `route-transaction` action.\n",
            "example": "select-payment-options",
            "enum": [
              "select-payment-options",
              "decline-early",
              "route-transaction",
              "skip-3ds"
            ]
          },
          "conditions": {
            "type": "array",
            "description": "One or more conditions that apply for this rule. Each condition\nneeds to match for this rule to go into effect.",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/FlowAmountCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAmountRangeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAmountZeroCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAntiFraudDecisionCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowBINRangeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowBrowserLanguageCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardCountryCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardIssuerNameCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardProductNameCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardSchemeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardSourceCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardTypeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCountryCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCurrencyCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowIsSubsequentPaymentCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMetadataCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMetadataNumericCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMerchantInitiatedCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentMethodCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentMethodsCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentSourceCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowProductCategoriesCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowProductTypesCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowSKUsCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowSplitRoutingCondition"
                }
              ]
            }
          },
          "outcome": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/FlowRuleServiceOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleMethodOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleBooleanOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleUUIDsListOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleThreeDSecureOutcome"
              }
            ]
          },
          "position": {
            "description": "The position of the rule in the flow.",
            "type": "number",
            "example": 2
          },
          "created_at": {
            "type": "string",
            "description": "The date and time\nwhen this buyer was created in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "updated_at": {
            "type": "string",
            "description": "The date and time\nwhen this buyer was last updated in our system.",
            "format": "date-time",
            "example": "2013-07-16T19:23:00.000+00:00"
          },
          "error_code": {
            "type": "string",
            "nullable": true,
            "description": "A custom error code returned when this rule is triggered. This only applies\nto `\"decline-early\"` rule actions. The value must have a `flow_` prefix.",
            "example": "flow_error_code",
            "minLength": 1,
            "maxLength": 255,
            "pattern": "^flow_[a-z_]+$"
          }
        }
      },
      "FlowRules": {
        "title": "Flow rules",
        "type": "object",
        "description": "A list of rule in a flow.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of rules.",
            "items": {
              "$ref": "#/components/schemas/FlowRule"
            }
          }
        }
      },
      "FlowAmountCondition": {
        "title": "Flow amount condition",
        "type": "object",
        "description": "Amount conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "amount",
            "enum": [
              "amount"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the currency code `value`.",
            "example": "less_than",
            "enum": [
              "less_than",
              "greater_than"
            ]
          },
          "value": {
            "type": "object",
            "description": "Amount value compare the transaction to.",
            "properties": {
              "currency": {
                "type": "string",
                "example": "USD",
                "description": "Currency ISO codes to compare the transaction to."
              },
              "value": {
                "type": "number",
                "example": 1,
                "minimum": 0,
                "nullable": false,
                "description": "Amount value to compare transaction value to."
              }
            },
            "example": {
              "Amount condition value": {
                "value": {
                  "description": "example amount value.",
                  "currency": "USD",
                  "value": 100
                }
              }
            }
          }
        }
      },
      "FlowAmountRangeCondition": {
        "title": "Flow amount range condition",
        "type": "object",
        "description": "Amount range conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "amount",
            "enum": [
              "amount"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the currency code `value`.",
            "example": "is_between",
            "enum": [
              "is_between"
            ]
          },
          "value": {
            "type": "object",
            "description": "Amount value compare the transaction to.",
            "properties": {
              "currency": {
                "type": "string",
                "example": "USD",
                "description": "Currency ISO codes to compare the transaction to."
              },
              "min": {
                "type": "number",
                "example": 1,
                "minimum": 0,
                "description": "Minimum value to compare transaction value to."
              },
              "max": {
                "type": "number",
                "example": 200,
                "minimum": 0,
                "description": "Maximum value to compare transaction value to."
              }
            },
            "example": {
              "Amount condition value": {
                "value": {
                  "description": "example amount value.",
                  "currency": "USD",
                  "min": 1,
                  "max": 200
                }
              }
            }
          }
        }
      },
      "FlowAmountZeroCondition": {
        "title": "Flow zero amount condition",
        "type": "object",
        "description": "Amount conditions matching a value of 0 in any currency.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "amount_zero",
            "enum": [
              "amount_zero"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the transaction `value`.",
            "example": "equal_to",
            "enum": [
              "equal_to"
            ]
          },
          "value": {
            "type": "number",
            "description": "The value of the transaction must be 0.",
            "example": 0
          }
        }
      },
      "FlowAntiFraudDecisionCondition": {
        "title": "Flow anti-fraud decision condition",
        "type": "object",
        "description": "Anti-fraud decision condition with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "anti_fraud_decision",
            "enum": [
              "anti_fraud_decision"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "A list of anti-fraud decisions to match.",
            "example": [
              "exception"
            ],
            "items": {
              "type": "string",
              "minLength": 1,
              "enum": [
                "accept",
                "error",
                "reject",
                "review",
                "exception",
                "skipped"
              ]
            }
          }
        }
      },
      "FlowBINRangeCondition": {
        "title": "Flow BIN range condition",
        "type": "object",
        "description": "BIN range conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_bin",
            "enum": [
              "card_bin"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `card_bin` `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "description": "BIN range to compare with the transaction. A card BIN is\n8 characters long at maximum.",
            "example": [
              "41410000-42429999"
            ]
          }
        }
      },
      "FlowBrowserLanguageCondition": {
        "title": "Flow browser language condition",
        "type": "object",
        "description": "Browser language conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "browser_language",
            "enum": [
              "browser_language"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the browser language `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "Browser language two-letter ISO 639-1 codes to compare the transaction to.",
            "example": [
              "en",
              "de",
              "fr"
            ],
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            }
          }
        }
      },
      "FlowCardCountryCondition": {
        "title": "Flow card country condition",
        "type": "object",
        "description": "Card country condition with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_country",
            "enum": [
              "card_country"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "Countries to compare the card originating country to\nin `ISO-3166` 2 character format.",
            "example": [
              "ES",
              "GB"
            ],
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            }
          }
        }
      },
      "FlowCardSchemeCondition": {
        "title": "Flow card scheme condition",
        "type": "object",
        "description": "Card scheme conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_scheme",
            "enum": [
              "card_scheme"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "Card scheme(s) to compare the transaction to.",
            "example": [
              "visa",
              "mastercard"
            ],
            "items": {
              "type": "string",
              "example": "visa",
              "enum": [
                "accel",
                "amex",
                "bancontact",
                "carte-bancaire",
                "cirrus",
                "culiance",
                "dankort",
                "diners-club",
                "discover",
                "eftpos-australia",
                "elo",
                "hipercard",
                "jcb",
                "maestro",
                "mastercard",
                "mir",
                "nyce",
                "other",
                "pulse",
                "rupay",
                "star",
                "uatp",
                "unionpay",
                "visa",
                null
              ]
            }
          }
        }
      },
      "FlowCardIssuerNameCondition": {
        "title": "Flow card issuer name condition",
        "type": "object",
        "description": "Card issuer name condition with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_issuer_name",
            "enum": [
              "card_issuer_name"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "like_one_of",
            "enum": [
              "like_one_of",
              "unlike_any_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Issuer name(s) to compare the card issuer name to.\nValues can be a part of the full card's issuer name.\nThe comparison is case-insensitive.\nFor example, `Hsbc Uk Bank Plc` and `Pt Bank Hsbc Indonesia` will match `HSBC`.",
            "example": [
              "HSBC",
              "Barclays"
            ]
          }
        }
      },
      "FlowCardProductNameCondition": {
        "title": "Flow card product name condition",
        "type": "object",
        "description": "Card product name condition with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_product_name",
            "enum": [
              "card_product_name"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "like_one_of",
            "enum": [
              "like_one_of",
              "unlike_any_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Product name(s) to compare the card product name to.\nValues can be a part of the full card's product name.\nThe comparison is case-insensitive.\nFor example, `Platinum MasterCard` and `Visa Platinum` will match `platinum`.",
            "example": [
              "Electron",
              "MasterCard Black"
            ]
          }
        }
      },
      "FlowCardSourceCondition": {
        "title": "Flow card source condition",
        "type": "object",
        "description": "Card source conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_source",
            "enum": [
              "card_source"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 50,
              "description": "Card sources to compare the transaction to.",
              "enum": [
                "applepay",
                "googlepay",
                "network-token",
                "raw",
                "token"
              ]
            },
            "example": [
              "raw",
              "applepay"
            ]
          }
        }
      },
      "FlowCardTypeCondition": {
        "title": "Flow card type condition",
        "type": "object",
        "description": "Card type condition with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "card_type",
            "enum": [
              "card_type"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "Card type to compare the transaction to.",
            "example": [
              "credit"
            ],
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 50,
              "enum": [
                "credit",
                "debit",
                "prepaid"
              ]
            }
          }
        }
      },
      "FlowCountryCondition": {
        "title": "Flow country condition",
        "type": "object",
        "description": "Country conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "country",
            "enum": [
              "country"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the country code `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "description": "Country two-letter ISO codes to compare the transaction to.",
            "example": [
              "US",
              "DE"
            ],
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            }
          }
        }
      },
      "FlowCurrencyCondition": {
        "title": "Flow currency condition",
        "type": "object",
        "description": "Currency conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "currency",
            "enum": [
              "currency"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the currency code `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "description": "Currency ISO codes to compare the transaction to.",
            "example": [
              "USD",
              "EUR",
              "GBP"
            ]
          }
        }
      },
      "FlowGiftCardBINCondition": {
        "title": "Flow gift card BIN range condition",
        "type": "object",
        "description": "Gift card BIN range conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "gift_card_bin",
            "enum": [
              "gift_card_bin"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `gift_card_bin` `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "description": "Gift card BIN range to compare with gift card numbers used in\nthe transaction to. A gift card BIN is 9 characters long at maximum.",
            "example": [
              "414100000-424299999"
            ]
          }
        }
      },
      "FlowHasGiftCardsCondition": {
        "title": "Flow has gift cards condition",
        "type": "object",
        "description": "`has_gift_cards` flag conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "has_gift_cards",
            "enum": [
              "has_gift_cards"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `has_gift_cards` flag `value`.",
            "example": "equal_to",
            "enum": [
              "equal_to"
            ]
          },
          "value": {
            "type": "boolean",
            "description": "`has_gift_cards` flag value to compare the transaction to.",
            "example": true
          }
        }
      },
      "FlowIsSubsequentPaymentCondition": {
        "title": "Flow is subsequent payment condition",
        "type": "object",
        "description": "`is_subsequent_payment` flag conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "is_subsequent_payment",
            "enum": [
              "is_subsequent_payment"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `is_subsequent_payment` flag `value`.",
            "example": "equal_to",
            "enum": [
              "equal_to"
            ]
          },
          "value": {
            "type": "boolean",
            "description": "`is_subsequent_payment` flag value to compare the transaction to.",
            "example": true
          }
        }
      },
      "FlowMerchantInitiatedCondition": {
        "title": "Flow merchant initiated condition",
        "type": "object",
        "description": "`merchant_initiated` flag conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "merchant_initiated",
            "enum": [
              "merchant_initiated"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `merchant_initiated` flag `value`.",
            "example": "equal_to",
            "enum": [
              "equal_to"
            ]
          },
          "value": {
            "type": "boolean",
            "description": "`merchant_initiated` flag value to compare the transaction to.",
            "example": true
          }
        }
      },
      "FlowMetadataCondition": {
        "title": "Flow metadata condition",
        "type": "object",
        "description": "Metadata conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "metadata",
            "enum": [
              "metadata"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the currency code `value`.",
            "example": "includes",
            "enum": [
              "includes",
              "excludes"
            ]
          },
          "value": {
            "type": "object",
            "description": "The metadata to compare the transaction to.",
            "properties": {
              "key": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255,
                "example": "product",
                "description": "Key to metadata value to compare transaction to."
              },
              "value": {
                "oneOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "minLength": 1,
                    "maxLength": 128,
                    "example": [
                      "value1",
                      "value2"
                    ],
                    "description": "List of metadata values to compare transaction to."
                  },
                  {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "example": "phone",
                    "description": "Value of metadata to compare transaction to."
                  }
                ]
              }
            }
          }
        }
      },
      "FlowMetadataNumericCondition": {
        "title": "Flow metadata numeric condition",
        "type": "object",
        "description": "Metadata conditions with a name, operator, and numeric value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The unique name of this condition.",
            "example": "metadata_numeric",
            "enum": [
              "metadata_numeric"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The numeric comparison to evaluate.",
            "example": "less_than",
            "enum": [
              "less_than",
              "greater_than",
              "equal_to",
              "less_than_or_equal_to",
              "greater_than_or_equal_to"
            ]
          },
          "value": {
            "type": "object",
            "description": "The metadata object to evaluate rules against.",
            "properties": {
              "key": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255,
                "example": "product",
                "description": "The key of the metadata object you wish to compare."
              },
              "value": {
                "type": "number",
                "example": 100,
                "description": "The numeric value to compare against."
              }
            }
          }
        }
      },
      "FlowPaymentMethodCondition": {
        "title": "Flow payment method condition",
        "type": "object",
        "description": "Payment method conditions with a name, operator, and value. This\ncondition is only for use with the `route-transaction` action.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "payment_method",
            "enum": [
              "payment_method"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "equal_to",
            "enum": [
              "equal_to"
            ]
          },
          "value": {
            "description": "The payment method to compare the transaction to.",
            "example": "card",
            "type": "string",
            "enum": [
              "affirm",
              "afterpay",
              "alipay",
              "alipayhk",
              "applepay",
              "bacs",
              "bancontact",
              "banked",
              "becs",
              "bitpay",
              "boleto",
              "boost",
              "card",
              "cashapp",
              "chaseorbital",
              "checkout-session",
              "clearpay",
              "click-to-pay",
              "dana",
              "dcb",
              "dlocal",
              "ebanx",
              "efecty",
              "eps",
              "everydaypay",
              "gcash",
              "gem",
              "gemds",
              "gift-card",
              "giropay",
              "givingblock",
              "gocardless",
              "googlepay",
              "googlepay_pan_only",
              "gopay",
              "grabpay",
              "id",
              "ideal",
              "kakaopay",
              "kcp",
              "klarna",
              "latitude",
              "latitudeds",
              "laybuy",
              "linepay",
              "linkaja",
              "maybankqrpay",
              "mercadopago",
              "multibanco",
              "multipago",
              "netbanking",
              "network-token",
              "oney_3x",
              "oney_4x",
              "oney_6x",
              "oney_10x",
              "oney_12x",
              "ovo",
              "oxxo",
              "payid",
              "paymaya",
              "paypal",
              "paypalpaylater",
              "payto",
              "venmo",
              "pix",
              "pse",
              "rabbitlinepay",
              "razorpay",
              "scalapay",
              "sepa",
              "shopeepay",
              "singteldash",
              "smartpay",
              "sofort",
              "spei",
              "stripedd",
              "thaiqr",
              "touchngo",
              "truemoney",
              "trustly",
              "trustlyeurope",
              "upi",
              "vipps",
              "waave",
              "webpay",
              "wechat",
              "zippay"
            ]
          }
        }
      },
      "FlowPaymentMethodsCondition": {
        "title": "Flow payment methods condition",
        "type": "object",
        "description": "Payment methods condition with a name, operator, and value. This\ncondition is only for use with the `decline-early` action.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "payment_method",
            "enum": [
              "payment_method"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "card",
              "enum": [
                "affirm",
                "afterpay",
                "alipay",
                "alipayhk",
                "applepay",
                "bacs",
                "bancontact",
                "banked",
                "becs",
                "bitpay",
                "boleto",
                "boost",
                "card",
                "cashapp",
                "chaseorbital",
                "checkout-session",
                "clearpay",
                "click-to-pay",
                "dana",
                "dcb",
                "dlocal",
                "ebanx",
                "efecty",
                "eps",
                "everydaypay",
                "gcash",
                "gem",
                "gemds",
                "gift-card",
                "giropay",
                "givingblock",
                "gocardless",
                "googlepay",
                "googlepay_pan_only",
                "gopay",
                "grabpay",
                "id",
                "ideal",
                "kakaopay",
                "kcp",
                "klarna",
                "latitude",
                "latitudeds",
                "laybuy",
                "linepay",
                "linkaja",
                "maybankqrpay",
                "mercadopago",
                "multibanco",
                "multipago",
                "netbanking",
                "network-token",
                "oney_3x",
                "oney_4x",
                "oney_6x",
                "oney_10x",
                "oney_12x",
                "ovo",
                "oxxo",
                "payid",
                "paymaya",
                "paypal",
                "paypalpaylater",
                "payto",
                "venmo",
                "pix",
                "pse",
                "rabbitlinepay",
                "razorpay",
                "scalapay",
                "sepa",
                "shopeepay",
                "singteldash",
                "smartpay",
                "sofort",
                "spei",
                "stripedd",
                "thaiqr",
                "touchngo",
                "truemoney",
                "trustly",
                "trustlyeurope",
                "upi",
                "vipps",
                "waave",
                "webpay",
                "wechat",
                "zippay"
              ]
            },
            "example": [
              "paypal",
              "shopeepay"
            ],
            "description": "Payment method(s) to compare the transaction to."
          }
        }
      },
      "FlowPaymentSourceCondition": {
        "title": "Flow payment source condition",
        "type": "object",
        "description": "Payment source conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "payment_source",
            "enum": [
              "payment_source"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the payment source `value`.",
            "example": "is_one_of",
            "enum": [
              "is_one_of",
              "is_not_one_of"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "recurring",
              "enum": [
                "ecommerce",
                "moto",
                "recurring",
                "installment",
                "card_on_file"
              ]
            },
            "example": [
              "recurring",
              "installment"
            ],
            "description": "Payment sources to compare the transaction to."
          }
        }
      },
      "FlowProductCategoriesCondition": {
        "title": "Flow product categories condition",
        "type": "object",
        "description": "Cart items' product categories conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "product_categories",
            "enum": [
              "product_categories"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "includes_all",
            "enum": [
              "includes_all",
              "includes_at_least_one",
              "includes_none"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "description": "Cart items' product categories to compare the transaction to.",
            "example": [
              "electronics",
              "printers"
            ]
          }
        }
      },
      "FlowProductTypesCondition": {
        "title": "Flow product types condition",
        "type": "object",
        "description": "Cart items' product types conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "product_types",
            "enum": [
              "product_types"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "includes_all",
            "enum": [
              "includes_all",
              "includes_at_least_one",
              "includes_none"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "physical",
              "enum": [
                "physical",
                "discount",
                "shipping_fee",
                "sales_tax",
                "digital",
                "gift_card",
                "store_credit",
                "surcharge",
                null
              ]
            },
            "example": [
              "shipping_fee",
              "sales_tax"
            ],
            "description": "Cart items' product types to compare the transaction to."
          }
        }
      },
      "FlowSKUsCondition": {
        "title": "Flow SKUs condition",
        "type": "object",
        "description": "Cart items' SKUs conditions with a name, operator, and value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The type of match made for this rule.",
            "example": "skus",
            "enum": [
              "skus"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The comparison to make on the `value`.",
            "example": "includes_all",
            "enum": [
              "includes_all",
              "includes_at_least_one",
              "includes_none"
            ]
          },
          "value": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "description": "Cart items' SKU values to compare the transaction to.",
            "example": [
              "YZ1234",
              "AB2345",
              "TU4567"
            ]
          }
        }
      },
      "FlowSplitRoutingCondition": {
        "title": "Flow split routing condition",
        "type": "object",
        "description": "Split routing condition with a name, operator, and numeric value.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "name",
          "operator",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "The unique name of this condition.",
            "example": "split_routing",
            "enum": [
              "split_routing"
            ]
          },
          "operator": {
            "type": "string",
            "description": "The numeric comparison to evaluate.",
            "example": "less_than_or_equal_to",
            "enum": [
              "less_than_or_equal_to"
            ]
          },
          "value": {
            "type": "integer",
            "description": "The probability percentage of this condition to be triggered.",
            "minimum": 1,
            "maximum": 99,
            "example": 50
          }
        }
      },
      "FlowRuleBooleanOutcome": {
        "title": "Boolean outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow where the result\nis a boolean.",
        "x-tags": [
          "Flow"
        ],
        "required": [
          "type",
          "result"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of action outcome for the given rule.",
            "example": "boolean",
            "enum": [
              "boolean"
            ]
          },
          "result": {
            "type": "boolean",
            "description": "Results for a given flow action.",
            "enum": [
              true
            ]
          }
        }
      },
      "FlowRuleMethodOutcome": {
        "title": "Payment method outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow where the result\nis a list of payment types.",
        "x-tags": [
          "Flow"
        ],
        "required": [
          "type",
          "result"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of action outcome for the given rule.",
            "example": "list",
            "enum": [
              "list"
            ]
          },
          "result": {
            "type": "array",
            "description": "Results for a given flow action.",
            "items": {
              "type": "string",
              "example": "card",
              "enum": [
                "affirm",
                "afterpay",
                "alipay",
                "alipayhk",
                "applepay",
                "bacs",
                "bancontact",
                "banked",
                "becs",
                "bitpay",
                "boleto",
                "boost",
                "card",
                "cashapp",
                "chaseorbital",
                "checkout-session",
                "clearpay",
                "click-to-pay",
                "dana",
                "dcb",
                "dlocal",
                "ebanx",
                "efecty",
                "eps",
                "everydaypay",
                "gcash",
                "gem",
                "gemds",
                "gift-card",
                "giropay",
                "givingblock",
                "gocardless",
                "googlepay",
                "googlepay_pan_only",
                "gopay",
                "grabpay",
                "id",
                "ideal",
                "kakaopay",
                "kcp",
                "klarna",
                "latitude",
                "latitudeds",
                "laybuy",
                "linepay",
                "linkaja",
                "maybankqrpay",
                "mercadopago",
                "multibanco",
                "multipago",
                "netbanking",
                "network-token",
                "oney_3x",
                "oney_4x",
                "oney_6x",
                "oney_10x",
                "oney_12x",
                "ovo",
                "oxxo",
                "payid",
                "paymaya",
                "paypal",
                "paypalpaylater",
                "payto",
                "venmo",
                "pix",
                "pse",
                "rabbitlinepay",
                "razorpay",
                "scalapay",
                "sepa",
                "shopeepay",
                "singteldash",
                "smartpay",
                "sofort",
                "spei",
                "stripedd",
                "thaiqr",
                "touchngo",
                "truemoney",
                "trustly",
                "trustlyeurope",
                "upi",
                "vipps",
                "waave",
                "webpay",
                "wechat",
                "zippay"
              ]
            },
            "example": [
              "card",
              "paypal"
            ]
          }
        }
      },
      "FlowRuleServiceOutcome": {
        "title": "Payment service outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow where the result\nis a list of dictionaries that define the payment service,\ninstrument and transformation to be used to process a\ntransaction.",
        "x-tags": [
          "Flow"
        ],
        "required": [
          "type",
          "result",
          "version"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of action outcome for the given rule.",
            "example": "card-routing",
            "enum": [
              "card-routing"
            ]
          },
          "result": {
            "type": "array",
            "description": "Results for a given flow action.",
            "items": {
              "type": "object",
              "properties": {
                "payment_service_id": {
                  "type": "string",
                  "description": "ID of the payment service to be used when processing the transaction.",
                  "nullable": false,
                  "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                  "format": "uuid"
                },
                "instrument": {
                  "type": "string",
                  "description": "The name of the instrument to be used to process the transaction.\nFor `pan`, if a Payment Service token is available, the API will use that\nfor stored payment methods.\n",
                  "enum": [
                    "network_token",
                    "pan"
                  ],
                  "example": "network_token"
                },
                "transformations": {
                  "type": "array",
                  "description": "List of transformations to apply when processing the transaction.",
                  "nullable": false,
                  "items": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "description": "Name of the transformation.",
                        "example": "force_mit",
                        "enum": [
                          "force_mit",
                          "use_additional_scheme"
                        ]
                      }
                    }
                  }
                }
              }
            },
            "example": [
              {
                "payment_service_id": "fe26475d-ec3e-4884-9553-f7356683f7f9",
                "instrument\"": "network_token",
                "transformations": []
              },
              {
                "payment_service_id": "d88aca32-07fb-46cd-a43f-86da02b73c21",
                "instrument": "pan",
                "transformations": [
                  {
                    "name": "force_mit"
                  }
                ]
              }
            ]
          },
          "version": {
            "type": "integer",
            "description": "Version of the rule outcome. Current version is `2`.",
            "example": 2,
            "enum": [
              2
            ]
          }
        }
      },
      "FlowRuleThreeDSecureOutcome": {
        "title": "3DS outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow for 3DS.",
        "x-tags": [
          "Flow"
        ],
        "required": [
          "type",
          "result"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of action outcome for the given rule.",
            "example": "three-d-secure",
            "enum": [
              "three-d-secure"
            ]
          },
          "result": {
            "type": "string",
            "description": "Result for a given flow action.",
            "example": "attempt",
            "enum": [
              "attempt",
              "force",
              "skip"
            ]
          }
        }
      },
      "FlowRuleUUIDsListOutcome": {
        "title": "UUIDs list outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow where the result\nis a list of UUIDs.\n\nDepending on the flow and action where this outcome is used, the UUIDs\nmay have an important meaning like the ID of a payment service to be\nused (this is the case for `redirect-transaction` flow and\n`route-transaction` action).",
        "x-tags": [
          "Flow"
        ],
        "required": [
          "type",
          "result"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of action outcome for the given rule.",
            "example": "list",
            "enum": [
              "list"
            ]
          },
          "result": {
            "type": "array",
            "description": "Results for a given flow action.",
            "items": {
              "type": "string",
              "example": "fe26475d-ec3e-4884-9553-f7356683f7f9",
              "format": "uuid"
            },
            "example": [
              "fe26475d-ec3e-4884-9553-f7356683f7f9",
              "d88aca32-07fb-46cd-a43f-86da02b73c21"
            ]
          }
        }
      },
      "FlowRuleOutcomes": {
        "title": "Flow rule outcome",
        "type": "object",
        "description": "Defines the outcome of a rule in a flow.\nCurrently the outcomes can be a boolean value, or a list of string\nvalues. The meaning of this outcome depends on the `action` this rule\nis triggered for.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of outcomes.",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/FlowPaymentOptionOutcome"
                },
                {
                  "$ref": "#/components/schemas/FlowCardTransactionRoutingOutcome"
                },
                {
                  "$ref": "#/components/schemas/FlowRedirectTransactionRoutingOutcome"
                }
              ]
            }
          }
        }
      },
      "FlowRuleCreateRequest": {
        "title": "Create flow rule",
        "type": "object",
        "description": "A request to create a flow rule.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "description": {
            "type": "string",
            "description": "Description of the flow rule.",
            "example": "example rule.",
            "minLength": 1,
            "maxLength": 200
          },
          "conditions": {
            "type": "array",
            "description": "One or more conditions that apply for this rule. Each condition needs to match for this rule to go into effect.",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/FlowAmountCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAmountRangeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAmountZeroCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowAntiFraudDecisionCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowBINRangeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowBrowserLanguageCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardCountryCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardIssuerNameCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardProductNameCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardSchemeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardSourceCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCardTypeCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCountryCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowCurrencyCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowGiftCardBINCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowHasGiftCardsCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowIsSubsequentPaymentCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMetadataCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMetadataNumericCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowMerchantInitiatedCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentMethodCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentMethodsCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowPaymentSourceCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowProductCategoriesCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowProductTypesCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowSKUsCondition"
                },
                {
                  "$ref": "#/components/schemas/FlowSplitRoutingCondition"
                }
              ]
            }
          },
          "outcome": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/FlowRuleBooleanOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleMethodOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleServiceOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleUUIDsListOutcome"
              },
              {
                "$ref": "#/components/schemas/FlowRuleThreeDSecureOutcome"
              }
            ]
          },
          "error_code": {
            "type": "string",
            "nullable": true,
            "example": "flow_error_code",
            "description": "A custom error code returned when this rule is triggered. This only applies\nto `\"decline-early\"` rule actions. The value must have a `flow_` prefix.",
            "minLength": 1,
            "maxLength": 255,
            "pattern": "^flow_[a-z_]+$"
          }
        }
      },
      "FlowRuleUpdateRequest": {
        "title": "Rule Update",
        "type": "object",
        "description": "A request to update a rule.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "required": [
          "position"
        ],
        "allOf": [
          {
            "$ref": "#/components/schemas/FlowRuleCreateRequest"
          },
          {
            "properties": {
              "position": {
                "description": "The position of the rule in the flow.",
                "type": "number",
                "example": 2
              }
            }
          }
        ]
      },
      "FlowPaymentOptionOutcome": {
        "title": "Checkout/Payment Option Outcome",
        "type": "object",
        "description": "Outcome for checkout flow/select payment options action.\nEach option is a Gr4vy payment option object.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `action`.",
            "example": "action",
            "enum": [
              "action"
            ]
          },
          "id": {
            "type": "string",
            "example": "card",
            "description": "Payment option identifier."
          },
          "label": {
            "type": "string",
            "description": "Verbose payment option name.",
            "example": "Card"
          },
          "active": {
            "type": "boolean",
            "description": "The status of the payment option, true if at least one underlying\nconnection is active, otherwise false."
          },
          "group": {
            "type": "string",
            "nullable": true,
            "description": "Optional group label for a given payment option, e.g. `Bank`.",
            "example": "Bank"
          },
          "icon_url": {
            "type": "string",
            "format": "uri",
            "nullable": false,
            "description": "Payment option icon URL."
          }
        }
      },
      "FlowCardTransactionRoutingOutcome": {
        "title": "Card Transactions/Routing Outcome",
        "type": "object",
        "description": "Outcome for card transactions flow/routing action.\nEach option is a Gr4vy payment service object.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `transaction-route`.",
            "example": "transaction-route",
            "enum": [
              "transaction-route"
            ]
          },
          "id": {
            "type": "string",
            "example": "24c8211d-b9d9-4b06-8aa9-f350fd0ffd15",
            "description": "Payment service identifier."
          },
          "label": {
            "type": "string",
            "description": "The display name of the payment service.",
            "example": "Stripe"
          },
          "active": {
            "type": "boolean",
            "description": "The status of the payment service."
          },
          "icon_url": {
            "type": "string",
            "format": "uri",
            "nullable": true,
            "description": "Payment service icon URL."
          },
          "countries": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Accepted currency ISO codes for the payment service.",
            "example": [
              "US",
              "GB"
            ]
          },
          "currencies": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Accepted country ISO codes for the payment service.",
            "example": [
              "USD",
              "GBP"
            ]
          },
          "instruments": {
            "type": "array",
            "description": "Valid instruments that can be used for the payment service.\n\nOnly instruments supported by the payment service will appear in the list.",
            "items": {
              "type": "string",
              "description": "The name of the instrument to be used to process the transaction.\nFor `pan`, if a Payment Service token is available, the API will use that\nfor stored payment methods.\n",
              "enum": [
                "network_token",
                "pan"
              ],
              "example": "network_token"
            }
          },
          "transformations": {
            "type": "array",
            "description": "Valid transformations that can be used for the payment service.",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/ForceMITTransformationOutcome"
                },
                {
                  "$ref": "#/components/schemas/UseAdditionalSchemeTransformationOutcome"
                }
              ]
            }
          },
          "network_tokens_enabled": {
            "type": "boolean",
            "description": "Indicates if Network Tokens are enabled for the payment service.",
            "example": false
          },
          "network_tokens_setup_for_merchant": {
            "type": "boolean",
            "description": "Indicates if Network Tokens feature is enabled for at least one scheme for the merchant account.",
            "example": true
          },
          "open_loop": {
            "type": "boolean",
            "description": "Indicates if the payment service is open loop or not.",
            "example": true
          }
        }
      },
      "FlowRedirectTransactionRoutingOutcome": {
        "title": "Redirect Transactions/Routing Outcome",
        "type": "object",
        "description": "Outcome for redirect transactions flow/routing action.\nEach option is a Gr4vy payment service object.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "type": {
            "type": "string",
            "description": "The type of this resource. Is always `outcome`.",
            "example": "outcome",
            "enum": [
              "outcome"
            ]
          },
          "id": {
            "type": "string",
            "example": "24c8211d-b9d9-4b06-8aa9-f350fd0ffd15",
            "description": "Payment service identifier."
          },
          "label": {
            "type": "string",
            "description": "The display name of the payment service.",
            "example": "Stripe"
          },
          "active": {
            "type": "boolean",
            "description": "The status of the payment service."
          },
          "icon_url": {
            "type": "string",
            "format": "uri",
            "nullable": true,
            "description": "Payment service icon URL."
          },
          "countries": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Accepted currency ISO codes for the payment service.",
            "example": [
              "US",
              "GB"
            ]
          },
          "currencies": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Accepted country ISO codes for the payment service.",
            "example": [
              "USD",
              "GBP"
            ]
          }
        }
      },
      "ForceMITTransformationOutcome": {
        "title": "Force MIT transformation",
        "type": "object",
        "description": "Transformation to be applied when for card transaction\nflow/routing action outcome.\n\nThis transformation forces the processing of a\ntransaction as an MIT one.\n\nIf the request to create a transaction was for MIT,\ni.e. `merchant_initiated=true`, this transformation\nwon't have any effect.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "name": {
            "type": "string",
            "description": "The name of the transformation. This will always be `force_mit`.",
            "example": "force_mit",
            "enum": [
              "force_mit"
            ]
          }
        }
      },
      "UseAdditionalSchemeTransformationOutcome": {
        "title": "Use additional scheme transformation",
        "type": "object",
        "description": "Transformation to be applied when for card transaction\nflow/routing action outcome.\n\nThis transformation forces the processing of a\ntransaction to use the first additional scheme\nof the card instead of it's main scheme.\n\nIf the card doesn't have any additional schemes,\nthis outcome would be skipped.",
        "x-tags": [
          "Flow"
        ],
        "x-internal": true,
        "properties": {
          "name": {
            "type": "string",
            "description": "The name of the transformation. This will always be `use_additional_scheme`.",
            "example": "use_additional_scheme",
            "enum": [
              "use_additional_scheme"
            ]
          }
        }
      },
      "Recipient": {
        "title": "Recipient",
        "type": "object",
        "description": "The recipient of an account funding transaction.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the recipient.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the recipient.",
            "nullable": true
          },
          "address": {
            "type": "object",
            "description": "The billing address for the recipient.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              },
              {
                "required": [
                  "line1",
                  "city",
                  "state",
                  "postal_code",
                  "country"
                ]
              }
            ]
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The destination account number to receive an account funding transaction.",
            "nullable": true
          },
          "date_of_birth": {
            "type": "string",
            "description": "The recipient's date of birth.",
            "format": "date",
            "example": "1996-08-31",
            "nullable": true
          }
        }
      },
      "Recipient--Snapshot": {
        "title": "Recipient (Snapshot)",
        "type": "object",
        "description": "Snapshot of a recipient of an account funding transaction, as used when embedded inside other\nresources.",
        "x-tags": [
          "Transactions"
        ],
        "properties": {
          "first_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "The first name(s) or given name for the recipient.",
            "example": "John",
            "nullable": true
          },
          "last_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "Lunn",
            "description": "The last name, or family name, of the recipient.",
            "nullable": true
          },
          "address": {
            "type": "object",
            "description": "The billing address for the recipient.",
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/Address"
              },
              {
                "required": [
                  "line1",
                  "city",
                  "state",
                  "postal_code",
                  "country"
                ]
              }
            ]
          },
          "account_number": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "example": "1234567",
            "description": "The destination account number to receive an account funding transaction.",
            "nullable": true
          },
          "date_of_birth": {
            "type": "string",
            "description": "The recipient's date of birth.",
            "format": "date",
            "example": "1996-08-31",
            "nullable": true
          }
        }
      },
      "WebhookSubscription": {
        "title": "Webhook subscription",
        "type": "object",
        "x-tags": [
          "Webhook subscriptions"
        ],
        "properties": {
          "type": {
            "type": "string",
            "description": "`webhook-subscription`.",
            "example": "webhook-subscription",
            "enum": [
              "webhook-subscription"
            ]
          },
          "id": {
            "type": "string",
            "example": "8fd77b13-a5e3-43de-bd54-26a8a714ac18",
            "description": "The unique Gr4vy ID for this webhook subscription."
          },
          "merchant_account_id": {
            "type": "string",
            "description": "The unique ID for a merchant account.",
            "example": "default",
            "nullable": true
          },
          "active": {
            "type": "boolean",
            "example": true,
            "description": "Defines if this subscription is currently active or not. When deactivated,\nwebhook events are not sent to the endpoint configured for this subscription."
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The URL of the endpoint to deliver webhook events to.",
            "example": "https://example.com/webhooks"
          },
          "authentication": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/WebhookSubscriptionAuthentication"
              }
            ]
          },
          "secret": {
            "type": "string",
            "description": "The active secret value.",
            "example": "234567890abcdef1234567890abcdef",
            "nullable": true
          },
          "rotating": {
            "type": "boolean",
            "description": "Flag to determine whether the subscription has a secret rotation in progress or not.",
            "example": false
          }
        }
      },
      "WebhookSubscriptions": {
        "title": "Webhook subscriptions",
        "type": "object",
        "x-tags": [
          "Webhook subscriptions"
        ],
        "properties": {
          "items": {
            "type": "array",
            "description": "A list of webhook subscriptions.",
            "items": {
              "$ref": "#/components/schemas/WebhookSubscription"
            }
          },
          "limit": {
            "type": "integer",
            "description": "The limit applied to request. This represents the number of items that are at\nmaximum returned by this request.",
            "format": "int32",
            "minimum": 1,
            "maximum": 100,
            "example": 1,
            "default": 20
          },
          "next_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": "ZXhhbXBsZTE",
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          },
          "previous_cursor": {
            "type": "string",
            "description": "The cursor that represents the next page of results. Use the `cursor` query\nparameter to fetch this page of items.",
            "example": null,
            "nullable": true,
            "minLength": 1,
            "maxLength": 1000
          }
        }
      },
      "WebhookSubscriptionAuthentication": {
        "title": "Webhook subscription authentication",
        "type": "object",
        "x-tags": [
          "Webhook subscriptions"
        ],
        "properties": {
          "kind": {
            "type": "string",
            "description": "Only `basic`` is currently supported.",
            "example": "basic",
            "enum": [
              "basic"
            ]
          },
          "username": {
            "type": "string",
            "example": "username",
            "description": "The basic authentication username to use for authentication.",
            "nullable": true
          },
          "password": {
            "type": "string",
            "example": "password",
            "description": "The basic authentication password to use for authentication.",
            "nullable": true
          }
        }
      },
      "WebhookSubscriptionRequest": {
        "title": "Webhook subscription (Create)",
        "type": "object",
        "x-tags": [
          "Webhook subscriptions"
        ],
        "properties": {
          "active": {
            "type": "boolean",
            "example": true,
            "description": "Defines if this subscription is currently active or not. When deactivated,\nwebhook events are not sent to the endpoint configured for this subscription."
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The URL of the endpoint to deliver webhook events to.",
            "example": "https://example.com/webhooks"
          },
          "authentication": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/WebhookSubscriptionAuthentication"
              }
            ]
          }
        }
      },
      "WebhookSubscriptionUpdateRequest": {
        "title": "Webhook subscription (Update)",
        "type": "object",
        "x-tags": [
          "Webhook subscriptions"
        ],
        "properties": {
          "active": {
            "type": "boolean",
            "example": true,
            "nullable": true,
            "description": "Defines if this subscription is currently active or not. When deactivated,\nwebhook events are not sent to the endpoint configured for this subscription."
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The URL of the endpoint to deliver webhook events to.",
            "example": "https://example.com/webhooks",
            "nullable": true
          },
          "authentication": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/WebhookSubscriptionAuthentication"
              }
            ]
          }
        }
      },
      "WebhookSubscriptionRotateSecretRequest": {
        "title": "Rotate secret of a webhook subscription.",
        "type": "object",
        "description": "A request to rotate the secret of a webhook subscription.",
        "x-tags": [
          "Request Bodies"
        ],
        "properties": {
          "delta": {
            "type": "integer",
            "description": "Delta time in minutes to expire existing secret if any.\nIf not set or set to zero it will expire immediately.",
            "example": 1440,
            "nullable": true,
            "minimum": 0,
            "maximum": 99999999
          }
        }
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ]
}