{
  "openapi": "3.0.0",
  "paths": {
    "/v1/payins": {
      "post": {
        "description": "Identify the payer with exactly one of `payerId` or an inline `payer` (bank account; an existing payer with the same bank code and account number is reused, otherwise one is created). Returns the payin with `payTo` (incl. `qrPayload`) and `checkoutUrl`; add `?include=paymentImage` for the PNG image. The response may contain `warnings` (e.g. `payer_name_differs`).",
        "operationId": "PayinsController_create",
        "parameters": [
          {
            "name": "include",
            "required": false,
            "in": "query",
            "description": "Comma-separated extra fields. `paymentImage`: add the PNG data URI of the QR code / transfer card. Unknown values are ignored.",
            "schema": {
              "example": "paymentImage",
              "type": "string"
            }
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "description": "Optional, recommended. A unique key (8-255 characters of `A-Z a-z 0-9 _ - : .`) per create request, e.g. a UUID. Retrying with the same key and the same request within 24 hours returns the original response (header `Idempotent-Replayed: true`) instead of creating a second one.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePayinDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayinObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "warnings": {
                      "type": "array",
                      "description": "Non-fatal notices. Only present when there are any.",
                      "items": {
                        "$ref": "#/components/schemas/PartnerWarningObject"
                      }
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Create a payin",
        "tags": [
          "Payins"
        ]
      },
      "get": {
        "description": "Newest first.",
        "operationId": "PayinsController_list",
        "parameters": [
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "schema": {
              "minimum": 1,
              "maximum": 100,
              "default": 20,
              "type": "number"
            }
          },
          {
            "name": "cursor",
            "required": false,
            "in": "query",
            "description": "Opaque cursor from `pagination.nextCursor` of the previous page",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "required": false,
            "in": "query",
            "description": "Comma-separated statuses",
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "pending",
                  "processing",
                  "in_review",
                  "succeeded",
                  "expired",
                  "canceled",
                  "rejected",
                  "failed"
                ]
              }
            }
          },
          {
            "name": "reference",
            "required": false,
            "in": "query",
            "description": "Exact match on your reference",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "payerId",
            "required": false,
            "in": "query",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          },
          {
            "name": "createdFrom",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-01T00:00:00Z",
              "type": "string"
            }
          },
          {
            "name": "createdTo",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-31T23:59:59Z",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/PayinObject"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "pagination": {
                      "$ref": "#/components/schemas/Pagination"
                    }
                  },
                  "required": [
                    "data",
                    "requestId",
                    "pagination"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "List payins",
        "tags": [
          "Payins"
        ]
      }
    },
    "/v1/payins/{id}": {
      "get": {
        "description": "Includes `payTo` (incl. `qrPayload`); add `?include=paymentImage` for the PNG image.",
        "operationId": "PayinsController_retrieve",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "pin_3f2b1c0d9e8f4a7b8c6d5e4f3a2b1c0d",
              "type": "string"
            }
          },
          {
            "name": "include",
            "required": false,
            "in": "query",
            "description": "Comma-separated extra fields. `paymentImage`: add the PNG data URI of the QR code / transfer card. Unknown values are ignored.",
            "schema": {
              "example": "paymentImage",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayinObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Retrieve a payin",
        "tags": [
          "Payins"
        ]
      }
    },
    "/v1/payins/{id}/cancel": {
      "post": {
        "operationId": "PayinsController_cancel",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "pin_3f2b1c0d9e8f4a7b8c6d5e4f3a2b1c0d",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayinObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Cancel a pending or expired payin",
        "tags": [
          "Payins"
        ]
      }
    },
    "/v1/payins/{id}/slip": {
      "post": {
        "description": "multipart/form-data with a single `file` part. The signature body hash is the SHA-256 of the file bytes.",
        "operationId": "PayinsController_uploadSlip",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "pin_3f2b1c0d9e8f4a7b8c6d5e4f3a2b1c0d",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                },
                "required": [
                  "file"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/SlipUploadResult"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Upload a payment slip for a payin",
        "tags": [
          "Payins"
        ]
      }
    },
    "/v1/payouts": {
      "post": {
        "description": "Identify the payer (the destination account) with exactly one of `payerId` or an inline `payer`; an existing payer with the same bank code and account number is reused, otherwise one is created. The response may contain `warnings` (e.g. `payer_name_differs`).",
        "operationId": "PayoutsController_create",
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "description": "Optional, recommended. A unique key (8-255 characters of `A-Z a-z 0-9 _ - : .`) per create request, e.g. a UUID. Retrying with the same key and the same request within 24 hours returns the original response (header `Idempotent-Replayed: true`) instead of creating a second one.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePayoutDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayoutObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "warnings": {
                      "type": "array",
                      "description": "Non-fatal notices. Only present when there are any.",
                      "items": {
                        "$ref": "#/components/schemas/PartnerWarningObject"
                      }
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Create a payout",
        "tags": [
          "Payouts"
        ]
      },
      "get": {
        "description": "Newest first.",
        "operationId": "PayoutsController_list",
        "parameters": [
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "schema": {
              "minimum": 1,
              "maximum": 100,
              "default": 20,
              "type": "number"
            }
          },
          {
            "name": "cursor",
            "required": false,
            "in": "query",
            "description": "Opaque cursor from `pagination.nextCursor` of the previous page",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "required": false,
            "in": "query",
            "description": "Comma-separated statuses",
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "pending",
                  "processing",
                  "in_review",
                  "succeeded",
                  "expired",
                  "canceled",
                  "rejected",
                  "failed"
                ]
              }
            }
          },
          {
            "name": "reference",
            "required": false,
            "in": "query",
            "description": "Exact match on your reference",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "payerId",
            "required": false,
            "in": "query",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          },
          {
            "name": "createdFrom",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-01T00:00:00Z",
              "type": "string"
            }
          },
          {
            "name": "createdTo",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-31T23:59:59Z",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/PayoutObject"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "pagination": {
                      "$ref": "#/components/schemas/Pagination"
                    }
                  },
                  "required": [
                    "data",
                    "requestId",
                    "pagination"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "List payouts",
        "tags": [
          "Payouts"
        ]
      }
    },
    "/v1/payouts/{id}": {
      "get": {
        "operationId": "PayoutsController_retrieve",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "pout_0f1e2d3c4b5a69788796a5b4c3d2e1f0",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayoutObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Retrieve a payout",
        "tags": [
          "Payouts"
        ]
      }
    },
    "/v1/payouts/{id}/cancel": {
      "post": {
        "description": "Possible while pending, failed, queued, or submitted for more than 30 minutes.",
        "operationId": "PayoutsController_cancel",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "pout_0f1e2d3c4b5a69788796a5b4c3d2e1f0",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayoutObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Cancel a payout",
        "tags": [
          "Payouts"
        ]
      }
    },
    "/v1/payers": {
      "post": {
        "operationId": "PayersController_create",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePayerDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayerObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Create a payer",
        "tags": [
          "Payers"
        ]
      },
      "get": {
        "description": "Newest first.",
        "operationId": "PayersController_list",
        "parameters": [
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "schema": {
              "minimum": 1,
              "maximum": 100,
              "default": 20,
              "type": "number"
            }
          },
          {
            "name": "cursor",
            "required": false,
            "in": "query",
            "description": "Opaque cursor from `pagination.nextCursor` of the previous page",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "accountNumber",
            "required": false,
            "in": "query",
            "description": "Contains match",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "accountName",
            "required": false,
            "in": "query",
            "description": "Case-insensitive contains match",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "bankCode",
            "required": false,
            "in": "query",
            "schema": {
              "example": "SCB",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/PayerObject"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "pagination": {
                      "$ref": "#/components/schemas/Pagination"
                    }
                  },
                  "required": [
                    "data",
                    "requestId",
                    "pagination"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "List payers",
        "tags": [
          "Payers"
        ]
      }
    },
    "/v1/payers/{id}": {
      "get": {
        "operationId": "PayersController_retrieve",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayerObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Retrieve a payer",
        "tags": [
          "Payers"
        ]
      },
      "patch": {
        "description": "Omitted fields keep their value.",
        "operationId": "PayersController_update",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdatePayerDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PayerObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Update a payer",
        "tags": [
          "Payers"
        ]
      },
      "delete": {
        "description": "Only payers without payments can be deleted.",
        "operationId": "PayersController_remove",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/DeletedObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Delete a payer",
        "tags": [
          "Payers"
        ]
      }
    },
    "/v1/payers/{id}/payments": {
      "get": {
        "description": "Items are payin or payout objects (see `object`). Newest first.",
        "operationId": "PayersController_listPayments",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          },
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "schema": {
              "minimum": 1,
              "maximum": 100,
              "default": 20,
              "type": "number"
            }
          },
          {
            "name": "cursor",
            "required": false,
            "in": "query",
            "description": "Opaque cursor from `pagination.nextCursor` of the previous page",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "required": false,
            "in": "query",
            "description": "Comma-separated statuses",
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "pending",
                  "processing",
                  "in_review",
                  "succeeded",
                  "expired",
                  "canceled",
                  "rejected",
                  "failed"
                ]
              }
            }
          },
          {
            "name": "reference",
            "required": false,
            "in": "query",
            "description": "Exact match on your reference",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "payerId",
            "required": false,
            "in": "query",
            "schema": {
              "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
              "type": "string"
            }
          },
          {
            "name": "createdFrom",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-01T00:00:00Z",
              "type": "string"
            }
          },
          {
            "name": "createdTo",
            "required": false,
            "in": "query",
            "description": "ISO-8601, inclusive",
            "schema": {
              "example": "2026-01-31T23:59:59Z",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/PayinObject"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    },
                    "pagination": {
                      "$ref": "#/components/schemas/Pagination"
                    }
                  },
                  "required": [
                    "data",
                    "requestId",
                    "pagination"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "404": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "List a payer's payins and payouts",
        "tags": [
          "Payers"
        ]
      }
    },
    "/v1/banks": {
      "get": {
        "operationId": "BanksController_list",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/BankObject"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "List supported banks",
        "tags": [
          "Banks"
        ]
      }
    },
    "/v1/account": {
      "get": {
        "operationId": "AccountController_retrieve",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/AccountObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Retrieve your account, limits and balance",
        "tags": [
          "Account"
        ]
      }
    },
    "/v1/account/balance-history": {
      "get": {
        "description": "`from`/`to` inclusive (YYYY-MM-DD, UTC+7), at most 31 days per request; longer ranges return `400 date_range_too_large`. Entries are in date order.",
        "operationId": "AccountController_balanceHistory",
        "parameters": [
          {
            "name": "from",
            "required": false,
            "in": "query",
            "description": "YYYY-MM-DD (UTC+7), inclusive. Default: 6 days before `to` (a 7-day range). The range may span at most 31 days.",
            "schema": {
              "example": "2026-01-01",
              "type": "string"
            }
          },
          {
            "name": "to",
            "required": false,
            "in": "query",
            "description": "YYYY-MM-DD (UTC+7), inclusive. Default: today.",
            "schema": {
              "example": "2026-01-31",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/BalanceHistoryEntry"
                      }
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "End-of-day balance history",
        "tags": [
          "Account"
        ]
      }
    },
    "/v1/reports/daily-summary": {
      "get": {
        "description": "`from`/`to` inclusive (YYYY-MM-DD, UTC+7), at most 31 days per request; longer ranges return `400 date_range_too_large`.",
        "operationId": "ReportsController_dailySummary",
        "parameters": [
          {
            "name": "from",
            "required": false,
            "in": "query",
            "description": "YYYY-MM-DD (UTC+7), inclusive. Default: 6 days before `to` (a 7-day range). The range may span at most 31 days.",
            "schema": {
              "example": "2026-01-01",
              "type": "string"
            }
          },
          {
            "name": "to",
            "required": false,
            "in": "query",
            "description": "YYYY-MM-DD (UTC+7), inclusive. Default: today.",
            "schema": {
              "example": "2026-01-31",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/DailySummaryObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Totals of succeeded payments for a date range",
        "tags": [
          "Reports"
        ]
      }
    },
    "/v1/withdrawals": {
      "post": {
        "description": "Only the documented fields are accepted; anything else is rejected.",
        "operationId": "WithdrawalsController_create",
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "description": "Optional, recommended. A unique key (8-255 characters of `A-Z a-z 0-9 _ - : .`) per create request, e.g. a UUID. Retrying with the same key and the same request within 24 hours returns the original response (header `Idempotent-Replayed: true`) instead of creating a second one.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWithdrawalDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/WithdrawalObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "409": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Request a withdrawal of your balance",
        "tags": [
          "Withdrawals"
        ]
      }
    },
    "/v1/slips/verify": {
      "post": {
        "description": "Send either JSON `{ \"payload\": \"<QR payload>\" }` or multipart/form-data with a single `file` part (JPG/PNG, max 5 MB). For multipart the signature body hash is the SHA-256 of the file bytes.",
        "operationId": "SlipsController_verify",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifySlipDto"
              }
            },
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary",
                    "description": "JPG or PNG, max 5 MB"
                  }
                },
                "required": [
                  "file"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/SlipVerificationObject"
                    },
                    "requestId": {
                      "type": "string",
                      "example": "req_8f2k3j4h5g6f7d8s9a0q1w2e"
                    }
                  },
                  "required": [
                    "data",
                    "requestId"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "401": {
            "description": "Authentication failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "403": {
            "description": "Partner inactive or IP not allowed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "422": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "429": {
            "description": "Error (see `error.code`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PartnerErrorBody"
                }
              }
            }
          }
        },
        "summary": "Verify a payment slip",
        "tags": [
          "Slips"
        ]
      }
    }
  },
  "info": {
    "title": "FIN Partner API",
    "description": "Server-to-server API for partners. Every request is signed:\n\n`X-Signature = base64(HMAC-SHA256(secret, METHOD + \"\\n\" + PATH?QUERY + \"\\n\" + X-Timestamp + \"\\n\" + X-Nonce + \"\\n\" + sha256_hex(raw_body)))`\n\nFor multipart/form-data requests the body hash is the SHA-256 of the uploaded file bytes.\nSuccess: `{ \"data\", \"pagination\"?, \"requestId\" }`. Errors: `{ \"error\": { \"type\", \"code\", \"message\", \"param\"? }, \"requestId\" }`.",
    "version": "1",
    "contact": {
      "email": "support@example.com"
    }
  },
  "tags": [],
  "servers": [
    {
      "url": "https://api.example.com",
      "description": "Partner API"
    }
  ],
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key"
      },
      "Timestamp": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Timestamp"
      },
      "Nonce": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Nonce"
      },
      "Signature": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Signature"
      }
    },
    "schemas": {
      "PartnerErrorDetail": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "invalid_request_error",
              "authentication_error",
              "permission_error",
              "rate_limit_error",
              "api_error"
            ]
          },
          "code": {
            "type": "string",
            "example": "payer_not_found"
          },
          "message": {
            "type": "string",
            "example": "No such payer."
          },
          "param": {
            "type": "string",
            "example": "payerId"
          }
        },
        "required": [
          "type",
          "code",
          "message"
        ]
      },
      "PartnerErrorBody": {
        "type": "object",
        "properties": {
          "error": {
            "$ref": "#/components/schemas/PartnerErrorDetail"
          },
          "requestId": {
            "type": "string",
            "example": "req_8f2k3j4h5g6f7d8s9a0q"
          }
        },
        "required": [
          "error",
          "requestId"
        ]
      },
      "Pagination": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "number",
            "example": 20
          },
          "hasMore": {
            "type": "boolean",
            "example": true
          },
          "nextCursor": {
            "type": "string",
            "nullable": true,
            "description": "Pass as `cursor` to fetch the next page",
            "example": "eyJvIjoyMH0"
          }
        },
        "required": [
          "limit",
          "hasMore",
          "nextCursor"
        ]
      },
      "PayerObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "payer"
          },
          "id": {
            "type": "string",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d"
          },
          "bankCode": {
            "type": "string",
            "example": "SCB",
            "nullable": true
          },
          "bankName": {
            "type": "string",
            "example": "Siam Commercial Bank",
            "nullable": true
          },
          "accountNumber": {
            "type": "string",
            "example": "1234567890"
          },
          "accountName": {
            "type": "string",
            "example": "สมชาย สบายดี"
          },
          "accountNameEn": {
            "type": "string",
            "example": "Somchai Sabuydee",
            "nullable": true
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "inactive"
            ],
            "example": "active"
          },
          "referralCode": {
            "type": "string",
            "nullable": true,
            "example": null
          },
          "createdAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          }
        },
        "required": [
          "object",
          "id",
          "bankCode",
          "bankName",
          "accountNumber",
          "accountName",
          "accountNameEn",
          "status",
          "referralCode",
          "createdAt"
        ]
      },
      "BankAccountRef": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "example": "SCB",
            "nullable": true
          },
          "accountNumber": {
            "type": "string",
            "example": "1234567890",
            "nullable": true
          },
          "accountName": {
            "type": "string",
            "example": "Somchai Sabuydee",
            "nullable": true
          }
        },
        "required": [
          "bankCode",
          "accountNumber",
          "accountName"
        ]
      },
      "PayTo": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "example": "KBANK",
            "nullable": true
          },
          "bankName": {
            "type": "string",
            "example": "Kasikorn Bank",
            "nullable": true
          },
          "accountNumber": {
            "type": "string",
            "example": "0987654321",
            "nullable": true
          },
          "accountName": {
            "type": "string",
            "example": "Example Co., Ltd.",
            "nullable": true
          },
          "promptpayId": {
            "type": "string",
            "example": "0812345678",
            "nullable": true
          },
          "walletAddress": {
            "type": "string",
            "description": "Crypto payins only",
            "example": "0xabc...",
            "nullable": true
          },
          "network": {
            "type": "string",
            "description": "Crypto payins only",
            "example": "BSC",
            "nullable": true
          },
          "qrPayload": {
            "type": "string",
            "description": "The QR text the payer must scan, so you can render your own QR code: the EMVCo/PromptPay payload (incl. the amount) for `promptpay_qr`, the Lao QR payload for `lao_qr`. `null` for `bank_transfer` and `crypto`.",
            "example": "00020101021229370016A000000677010111011300668123456785802TH53037645406150.3763046572",
            "nullable": true
          }
        },
        "required": [
          "qrPayload"
        ]
      },
      "PayinObject": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "example": "pin_3f2b1c0d9e8f4a7b8c6d5e4f3a2b1c0d"
          },
          "reference": {
            "type": "string",
            "description": "Your own reference (order id)",
            "nullable": true,
            "example": "order-10001"
          },
          "payerId": {
            "type": "string",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
            "nullable": true
          },
          "payer": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/PayerObject"
              }
            ]
          },
          "requestedAmount": {
            "type": "string",
            "description": "Amount requested",
            "example": "150.00"
          },
          "amount": {
            "type": "string",
            "description": "Amount to be transferred. For payins this includes the unique decimals the payer must send.",
            "example": "150.37"
          },
          "fee": {
            "type": "string",
            "example": "2.25"
          },
          "currency": {
            "type": "string",
            "example": "THB"
          },
          "method": {
            "type": "string",
            "enum": [
              "promptpay_qr",
              "bank_transfer",
              "crypto",
              "lao_qr",
              "auto"
            ],
            "nullable": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "processing",
              "in_review",
              "succeeded",
              "expired",
              "canceled",
              "rejected",
              "failed"
            ]
          },
          "failureReason": {
            "type": "string",
            "nullable": true,
            "example": null
          },
          "webhookUrl": {
            "type": "string",
            "nullable": true,
            "example": "https://partner.example.com/webhooks"
          },
          "payerAccount": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/BankAccountRef"
              }
            ]
          },
          "createdAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          },
          "updatedAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          },
          "object": {
            "type": "string",
            "example": "payin"
          },
          "returnUrl": {
            "type": "string",
            "nullable": true,
            "example": "https://partner.example.com/return"
          },
          "checkoutUrl": {
            "type": "string",
            "nullable": true,
            "example": "https://pay.example.com/3f2b1c0d-..."
          },
          "paymentImage": {
            "type": "string",
            "description": "PNG data URI (QR code or transfer card). Only present on create and retrieve when requested with `?include=paymentImage`.",
            "nullable": true
          },
          "payTo": {
            "nullable": true,
            "description": "Where the payer must send money. Returned on create and retrieve only.",
            "allOf": [
              {
                "$ref": "#/components/schemas/PayTo"
              }
            ]
          }
        },
        "required": [
          "id",
          "reference",
          "payerId",
          "requestedAmount",
          "amount",
          "fee",
          "currency",
          "method",
          "status",
          "failureReason",
          "webhookUrl",
          "payerAccount",
          "createdAt",
          "updatedAt",
          "object",
          "returnUrl",
          "checkoutUrl"
        ]
      },
      "PartnerWarningObject": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "example": "payer_name_differs",
            "enum": [
              "payer_name_differs"
            ]
          },
          "message": {
            "type": "string",
            "example": "An existing payer with this bank account was used. Its stored account name differs from the one sent and was kept; it is used for payment matching."
          },
          "param": {
            "type": "string",
            "example": "payer.accountName"
          }
        },
        "required": [
          "code",
          "message"
        ]
      },
      "InlinePayerDto": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "description": "Bank code from GET /v1/banks",
            "example": "SCB"
          },
          "accountNumber": {
            "type": "string",
            "description": "Digits only",
            "example": "1234567890"
          },
          "accountName": {
            "type": "string",
            "example": "สมชาย สบายดี"
          },
          "accountNameEn": {
            "type": "string",
            "example": "Somchai Sabuydee"
          }
        },
        "required": [
          "bankCode",
          "accountNumber",
          "accountName"
        ]
      },
      "CreatePayinDto": {
        "type": "object",
        "properties": {
          "payerId": {
            "type": "string",
            "description": "An existing payer. Send exactly one of `payerId` and `payer`.",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d"
          },
          "payer": {
            "description": "The payer's bank account, instead of `payerId`. Send exactly one of `payerId` and `payer`. If you already have a payer with the same `bankCode` and `accountNumber` it is reused (its stored name is kept; a `payer_name_differs` warning is returned if the name differs), otherwise a new active payer is created as with POST /v1/payers. The response contains its `payerId`.",
            "allOf": [
              {
                "$ref": "#/components/schemas/InlinePayerDto"
              }
            ]
          },
          "amount": {
            "type": "string",
            "description": "Decimal string. Unique decimals may be added; see `amount` in the response.",
            "example": "150.00"
          },
          "currency": {
            "type": "string",
            "enum": [
              "THB",
              "USD",
              "USDT",
              "LAK"
            ],
            "example": "THB"
          },
          "method": {
            "type": "string",
            "enum": [
              "auto",
              "promptpay_qr",
              "bank_transfer",
              "crypto",
              "lao_qr"
            ],
            "default": "auto"
          },
          "reference": {
            "type": "string",
            "description": "Your order id",
            "maxLength": 128,
            "example": "order-10001"
          },
          "webhookUrl": {
            "type": "string",
            "example": "https://partner.example.com/webhooks/payments"
          },
          "returnUrl": {
            "type": "string",
            "description": "Where the checkout page sends the payer afterwards",
            "example": "https://partner.example.com/orders/10001"
          }
        },
        "required": [
          "amount",
          "currency",
          "webhookUrl"
        ]
      },
      "SlipUploadResult": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "slip_upload"
          },
          "matched": {
            "type": "boolean",
            "description": "True if the slip matched and the payin succeeded"
          },
          "slipStatus": {
            "type": "string",
            "example": "matched",
            "nullable": true
          },
          "payin": {
            "$ref": "#/components/schemas/PayinObject"
          }
        },
        "required": [
          "object",
          "matched",
          "slipStatus",
          "payin"
        ]
      },
      "PayoutObject": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "example": "pin_3f2b1c0d9e8f4a7b8c6d5e4f3a2b1c0d"
          },
          "reference": {
            "type": "string",
            "description": "Your own reference (order id)",
            "nullable": true,
            "example": "order-10001"
          },
          "payerId": {
            "type": "string",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d",
            "nullable": true
          },
          "payer": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/PayerObject"
              }
            ]
          },
          "requestedAmount": {
            "type": "string",
            "description": "Amount requested",
            "example": "150.00"
          },
          "amount": {
            "type": "string",
            "description": "Amount to be transferred. For payins this includes the unique decimals the payer must send.",
            "example": "150.37"
          },
          "fee": {
            "type": "string",
            "example": "2.25"
          },
          "currency": {
            "type": "string",
            "example": "THB"
          },
          "method": {
            "type": "string",
            "enum": [
              "promptpay_qr",
              "bank_transfer",
              "crypto",
              "lao_qr",
              "auto"
            ],
            "nullable": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "processing",
              "in_review",
              "succeeded",
              "expired",
              "canceled",
              "rejected",
              "failed"
            ]
          },
          "failureReason": {
            "type": "string",
            "nullable": true,
            "example": null
          },
          "webhookUrl": {
            "type": "string",
            "nullable": true,
            "example": "https://partner.example.com/webhooks"
          },
          "payerAccount": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/BankAccountRef"
              }
            ]
          },
          "createdAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          },
          "updatedAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          },
          "object": {
            "type": "string",
            "example": "payout"
          }
        },
        "required": [
          "id",
          "reference",
          "payerId",
          "requestedAmount",
          "amount",
          "fee",
          "currency",
          "method",
          "status",
          "failureReason",
          "webhookUrl",
          "payerAccount",
          "createdAt",
          "updatedAt",
          "object"
        ]
      },
      "CreatePayoutDto": {
        "type": "object",
        "properties": {
          "payerId": {
            "type": "string",
            "description": "An existing payer. Send exactly one of `payerId` and `payer`.",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d"
          },
          "payer": {
            "description": "The payer's bank account, instead of `payerId`. Send exactly one of `payerId` and `payer`. If you already have a payer with the same `bankCode` and `accountNumber` it is reused (its stored name is kept; a `payer_name_differs` warning is returned if the name differs), otherwise a new active payer is created as with POST /v1/payers. The response contains its `payerId`.",
            "allOf": [
              {
                "$ref": "#/components/schemas/InlinePayerDto"
              }
            ]
          },
          "amount": {
            "type": "string",
            "example": "500.00"
          },
          "currency": {
            "type": "string",
            "enum": [
              "THB",
              "USD",
              "USDT",
              "LAK"
            ],
            "example": "THB"
          },
          "method": {
            "type": "string",
            "enum": [
              "auto",
              "bank_transfer",
              "crypto",
              "lao_qr"
            ],
            "default": "auto"
          },
          "reference": {
            "type": "string",
            "maxLength": 128,
            "example": "withdraw-20001"
          },
          "webhookUrl": {
            "type": "string",
            "example": "https://partner.example.com/webhooks/payments"
          },
          "walletAddress": {
            "type": "string",
            "description": "Crypto payouts: destination wallet"
          },
          "network": {
            "type": "string",
            "description": "Crypto payouts: network, e.g. BSC"
          }
        },
        "required": [
          "amount",
          "currency"
        ]
      },
      "CreatePayerDto": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "description": "Bank code from GET /v1/banks",
            "example": "SCB"
          },
          "accountNumber": {
            "type": "string",
            "description": "Digits only",
            "example": "1234567890"
          },
          "accountName": {
            "type": "string",
            "example": "สมชาย สบายดี"
          },
          "accountNameEn": {
            "type": "string",
            "example": "Somchai Sabuydee"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "inactive"
            ],
            "default": "active"
          },
          "referralCode": {
            "type": "string",
            "description": "Referral code, if any"
          }
        },
        "required": [
          "bankCode",
          "accountNumber",
          "accountName"
        ]
      },
      "UpdatePayerDto": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "description": "Bank code from GET /v1/banks",
            "example": "SCB"
          },
          "accountNumber": {
            "type": "string",
            "description": "Digits only",
            "example": "1234567890"
          },
          "accountName": {
            "type": "string",
            "example": "สมชาย สบายดี"
          },
          "accountNameEn": {
            "type": "string",
            "example": "Somchai Sabuydee"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "inactive"
            ],
            "default": "active"
          },
          "referralCode": {
            "type": "string",
            "description": "Referral code, if any"
          }
        }
      },
      "DeletedObject": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "example": "payer_7c0a4b8e2f3d4a1b9c8d7e6f5a4b3c2d"
          },
          "deleted": {
            "type": "boolean",
            "example": true
          }
        },
        "required": [
          "id",
          "deleted"
        ]
      },
      "BankObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "bank"
          },
          "code": {
            "type": "string",
            "example": "SCB"
          },
          "name": {
            "type": "string",
            "example": "Siam Commercial Bank"
          },
          "localName": {
            "type": "string",
            "example": "ธนาคารไทยพาณิชย์",
            "nullable": true
          }
        },
        "required": [
          "object",
          "code",
          "name",
          "localName"
        ]
      },
      "AccountLimits": {
        "type": "object",
        "properties": {
          "payinMinimum": {
            "type": "string",
            "example": "100.00",
            "nullable": true
          },
          "payinMaximum": {
            "type": "string",
            "example": "50000.00",
            "nullable": true
          },
          "payoutMinimum": {
            "type": "string",
            "example": "100.00",
            "nullable": true
          },
          "payoutMaximum": {
            "type": "string",
            "example": "50000.00",
            "nullable": true
          },
          "dailyWithdrawalLimit": {
            "type": "string",
            "description": "Daily withdrawal limit, 0 means unlimited",
            "example": "0.00",
            "nullable": true
          }
        },
        "required": [
          "payinMinimum",
          "payinMaximum",
          "payoutMinimum",
          "payoutMaximum",
          "dailyWithdrawalLimit"
        ]
      },
      "AccountBalance": {
        "type": "object",
        "properties": {
          "currency": {
            "type": "string",
            "example": "THB"
          },
          "total": {
            "type": "string",
            "example": "125000.00"
          },
          "available": {
            "type": "string",
            "example": "120000.00"
          }
        },
        "required": [
          "currency",
          "total",
          "available"
        ]
      },
      "AccountObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "account"
          },
          "name": {
            "type": "string",
            "example": "Example Partner"
          },
          "status": {
            "type": "string",
            "example": "active"
          },
          "payinsEnabled": {
            "type": "boolean"
          },
          "payoutsEnabled": {
            "type": "boolean"
          },
          "ipAllowListEnabled": {
            "type": "boolean"
          },
          "limits": {
            "$ref": "#/components/schemas/AccountLimits"
          },
          "balance": {
            "$ref": "#/components/schemas/AccountBalance"
          },
          "createdAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          }
        },
        "required": [
          "object",
          "name",
          "status",
          "payinsEnabled",
          "payoutsEnabled",
          "ipAllowListEnabled",
          "limits",
          "balance",
          "createdAt"
        ]
      },
      "BalanceHistoryEntry": {
        "type": "object",
        "properties": {
          "date": {
            "type": "string",
            "example": "2026-01-01",
            "description": "Day (UTC+7)"
          },
          "balance": {
            "type": "string",
            "example": "120000.00",
            "description": "Balance at end of day (THB)"
          }
        },
        "required": [
          "date",
          "balance"
        ]
      },
      "DailySummaryObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "daily_summary"
          },
          "from": {
            "type": "string",
            "example": "2026-01-01"
          },
          "to": {
            "type": "string",
            "example": "2026-01-07"
          },
          "currency": {
            "type": "string",
            "example": "THB"
          },
          "payinsSucceeded": {
            "type": "string",
            "example": "100000.00"
          },
          "payoutsSucceeded": {
            "type": "string",
            "example": "40000.00"
          },
          "withdrawalsSucceeded": {
            "type": "string",
            "example": "20000.00"
          },
          "topupsSucceeded": {
            "type": "string",
            "example": "0.00"
          },
          "fees": {
            "type": "string",
            "example": "1500.00"
          }
        },
        "required": [
          "object",
          "from",
          "to",
          "currency",
          "payinsSucceeded",
          "payoutsSucceeded",
          "withdrawalsSucceeded",
          "topupsSucceeded",
          "fees"
        ]
      },
      "WithdrawalObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "withdrawal"
          },
          "id": {
            "type": "string",
            "example": "wd_0a1b2c3d4e5f60718293a4b5c6d7e8f9"
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "processing",
              "succeeded",
              "rejected"
            ]
          },
          "channel": {
            "type": "string",
            "enum": [
              "bank_transfer",
              "crypto"
            ]
          },
          "requestedAmount": {
            "type": "string",
            "description": "Requested amount (THB)",
            "example": "10000.00"
          },
          "fee": {
            "type": "string",
            "description": "Fee (THB)",
            "example": "50.00"
          },
          "netAmount": {
            "type": "string",
            "description": "Requested amount minus fee (THB)",
            "example": "9950.00"
          },
          "currency": {
            "type": "string",
            "description": "Currency paid out",
            "example": "THB"
          },
          "payoutAmount": {
            "type": "string",
            "description": "Amount paid out in `currency`",
            "example": "9950.00"
          },
          "exchangeRate": {
            "type": "string",
            "example": "1.000000",
            "nullable": true
          },
          "bankAccount": {
            "type": "object",
            "nullable": true,
            "description": "Destination bank account (bank_transfer)",
            "properties": {
              "bankName": {
                "type": "string",
                "nullable": true
              },
              "accountName": {
                "type": "string",
                "nullable": true
              },
              "accountNumber": {
                "type": "string",
                "nullable": true
              }
            }
          },
          "wallet": {
            "type": "object",
            "nullable": true,
            "description": "Destination wallet (crypto)",
            "properties": {
              "address": {
                "type": "string",
                "nullable": true
              },
              "network": {
                "type": "string",
                "nullable": true
              }
            }
          },
          "note": {
            "type": "string",
            "nullable": true
          },
          "createdAt": {
            "type": "string",
            "example": "2026-01-01T00:00:00.000Z"
          }
        },
        "required": [
          "object",
          "id",
          "status",
          "channel",
          "requestedAmount",
          "fee",
          "netAmount",
          "currency",
          "payoutAmount",
          "exchangeRate",
          "bankAccount",
          "wallet",
          "note",
          "createdAt"
        ]
      },
      "CreateWithdrawalDto": {
        "type": "object",
        "properties": {
          "amount": {
            "type": "string",
            "description": "Amount to withdraw from your balance (THB)",
            "example": "10000.00"
          },
          "currency": {
            "type": "string",
            "enum": [
              "THB",
              "USD",
              "USDT"
            ],
            "default": "THB",
            "description": "Currency to be paid out in"
          },
          "channel": {
            "type": "string",
            "enum": [
              "bank_transfer",
              "crypto"
            ]
          },
          "bankName": {
            "type": "string",
            "description": "bank_transfer: bank name",
            "example": "SCB"
          },
          "bankAccountName": {
            "type": "string",
            "description": "bank_transfer: account name"
          },
          "bankAccountNumber": {
            "type": "string",
            "description": "bank_transfer: account number"
          },
          "walletAddress": {
            "type": "string",
            "description": "crypto: wallet address"
          },
          "network": {
            "type": "string",
            "description": "crypto: network, e.g. TRC20"
          },
          "note": {
            "type": "string",
            "maxLength": 500
          }
        },
        "required": [
          "amount",
          "channel"
        ]
      },
      "SlipParty": {
        "type": "object",
        "properties": {
          "bankCode": {
            "type": "string",
            "nullable": true
          },
          "bankName": {
            "type": "string",
            "nullable": true
          },
          "accountNumber": {
            "type": "string",
            "nullable": true
          },
          "accountName": {
            "type": "string",
            "nullable": true
          },
          "accountNameEn": {
            "type": "string",
            "nullable": true
          }
        },
        "required": [
          "bankCode",
          "bankName",
          "accountNumber",
          "accountName",
          "accountNameEn"
        ]
      },
      "SlipVerificationObject": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string",
            "example": "slip_verification"
          },
          "verified": {
            "type": "boolean"
          },
          "failureCode": {
            "type": "string",
            "nullable": true,
            "enum": [
              "slip_not_found",
              "duplicate_slip",
              "amount_mismatch",
              "receiver_mismatch",
              "invalid_image",
              "invalid_payload",
              "verification_unavailable"
            ]
          },
          "payload": {
            "type": "string",
            "nullable": true
          },
          "bankReference": {
            "type": "string",
            "nullable": true,
            "description": "Bank transaction reference"
          },
          "transferredAt": {
            "type": "string",
            "nullable": true
          },
          "amount": {
            "type": "string",
            "nullable": true,
            "example": "100.00"
          },
          "currency": {
            "type": "string",
            "nullable": true,
            "example": "THB"
          },
          "sender": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/SlipParty"
              }
            ]
          },
          "receiver": {
            "nullable": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/SlipParty"
              }
            ]
          }
        },
        "required": [
          "object",
          "verified",
          "failureCode",
          "payload",
          "bankReference",
          "transferredAt",
          "amount",
          "currency",
          "sender",
          "receiver"
        ]
      },
      "VerifySlipDto": {
        "type": "object",
        "properties": {
          "payload": {
            "type": "string",
            "description": "QR payload read from the slip (JSON requests)"
          },
          "checkDuplicate": {
            "type": "boolean",
            "description": "Ask the provider to flag duplicate slips"
          }
        }
      }
    }
  },
  "security": [
    {
      "ApiKey": [],
      "Timestamp": [],
      "Nonce": [],
      "Signature": []
    }
  ]
}
