{
  "openapi": "3.0.0",
  "info": {
    "contact": {
      "email": "support@trustap.com"
    },
    "description": "The Trustap API is a REST-based API for managing user data and\ntransactions for Trustap users.\n\nNote that, like Stripe, all API `price` and `charge` fields expect\namounts to be provided in a currency's smallest unit. See [the Stripe\ndocumentation](https://stripe.com/docs/currencies#zero-decimal) for more\ndetails.\n\nAPI Keys\n--------\n\nSome endpoints such as `/charge` endpoints can be accessed directly\nusing an API key. API keys are provided as the \"username\" portion of a\nbasic auth authentication. For example, the Trustap fee for a \ntransaction can be determined using the following cURL request with an\nAPI key:\n\n``` bash\ncurl -i -X GET -u '<API_KEY>:'​ 'https://api.test.trustap.com/v2/fees?currency=usd&amount=896'\n```\n\nDeprecation\n-----------\n\nDeprecated endpoints are tagged with the word `DEPRECATED` at the start\nof their description. The deprecation message will describe what\nendpoints/approach should be used instead.\n\nNote that deprecated endpoints will not be removed from the current\nversion of the API, but their use is discouraged. Furthermore, migrating\nto later major versions of the API will be made easier by avoiding\ndeprecated endpoints.\n\nProduction\n----------\n\nThis documentation references the staging environment of the Trustap\nAPI, which is available at `https://api.test.trustap.com` and uses the\n`trustap-stage` realm during authentication. This environment can be\nused for implementing and testing features using test credit cards, bank\naccounts, etc.\n\nWhen all features using Trustap have been implemented and tested\nsufficiently, the production environment of the Trustap API can be used\nto process actual currency. This environment is available at\n`https://api.trustap.com` and uses the `trustap` realm during\nauthentication.\n\nNote that only your client ID will be the same in the staging and\nproduction Trustap API environments; your client secret and API key will\nbe different in the two environments.\n",
    "title": "Trustap API",
    "version": "2.0.1"
  },
  "paths": {
    "/v2/carriers": {
      "get": {
        "description": "This returns the carriers that are currently supported for\nautomated tracking. The carrier `name`\nshould be shown to users but the `code` should be submitted to\nthe `/track` endpoint when submitting tracking details.\nLikewise, when showing a transaction to the user, the `carrier`\nfield stored with the transaction should be used to index these\ncarriers and show the human-readable name of the carrier to the\nuser, if this index is found.\n",
        "operationId": "v2_transactions.getSupportedCarriers",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "items": {
                    "$ref": "#/components/schemas/v2_transactions.Carrier"
                  },
                  "type": "array"
                }
              }
            }
          }
        },
        "summary": "Get the supported carriers",
        "tags": [
          "Shipping"
        ],
        "x-toc-endpoint": {
          "context": "v2_carriers",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      }
    },
    "/v2/experiences": {
      "get": {
        "operationId": "experiences.getExperiences",
        "parameters": [
          {
            "description": "Filter experiences by activity. \nFiltering is case sensitive.\n",
            "in": "query",
            "name": "activity",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filter experiences by category. \nFiltering is case sensitive.\n",
            "in": "query",
            "name": "category",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filter experiences by title. \nFiltering is case insensitive and can contain partial titles.\n",
            "in": "query",
            "name": "title",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filter experiences on and after this date.\n",
            "in": "query",
            "name": "start_date",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filter experiences on and before this date.\n",
            "in": "query",
            "name": "end_date",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filter experiences by country. \nFiltering is case insensitive.\n",
            "in": "query",
            "name": "country",
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Page number.\n",
            "in": "query",
            "name": "page",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "description": "Items per page (max 100)\n",
            "in": "query",
            "name": "page_size",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a paginated list of supported experiences",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/experiences.PaginatedExperiences"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKey": []
          }
        ],
        "summary": "Get supported experiences",
        "x-toc-endpoint": {
          "context": "experiences"
        }
      }
    },
    "/v2/fees": {
      "get": {
        "description": "This returns the Trustap fee, in the `currency`'s smallest unit,\nfor a transaction involving goods with the supplied `amount`. See\n[the Stripe\ndocumentation](https://stripe.com/docs/currencies#zero-decimal)\nfor more details.\n",
        "operationId": "v2_transactions.getFees",
        "parameters": [
          {
            "description": "The currency that the `amount` is specified in.\n",
            "in": "query",
            "name": "currency",
            "required": true,
            "schema": {
              "type": "string",
              "format": "currency"
            }
          },
          {
            "description": "The price of the goods being sold in this transaction, in\nthe `currency`'s smallest unit. For example, if a trading\ncard is being sold for $12.34 (with `currency` as `usd`),\nthen the request for the fees for this transaction would\nbe `/v2/fees?amount=1234&currency=usd`.\n",
            "in": "query",
            "name": "amount",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "description": "Represents an additional charge to be paid by the buyer added\nto the transaction total. Use this field to include costs like\nprocessing fees or local taxes.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD). Defaults to 0 if not provided.\n",
            "in": "query",
            "name": "amount_extra",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "description": "Represents an additional charge to be paid by the buyer, seller or client.\nUse this field to include costs like shipping surcharges.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD).\n",
            "in": "query",
            "name": "amount_postage",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "description": "The payment method that will be used to pay for the\ntransaction. This is necessary because different payment\nmethods may result in different fees.\nSupports `card` and `bank_transfer`.\n\nThe default value is `card`.\n",
            "in": "query",
            "name": "payment_method",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "The fee config for which the fees are computed.\n",
            "in": "query",
            "name": "fees_config",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Fees"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "example": {
                    "code": "negative_amount",
                    "message": "`amount` cannot be negative"
                  },
                  "properties": {
                    "code": {
                      "description": "* `unsupported_combination`: The provided payment method,\nfee config and currency combination isn't supported.\n",
                      "enum": [
                        "currency_missing",
                        "invalid_amount",
                        "negative_amount",
                        "amount_too_low",
                        "unsupported_currency",
                        "invalid_fee_config",
                        "unsupported_combination"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Get the Trustap fee for a transaction",
        "tags": [
          "Payment"
        ],
        "x-toc-endpoint": {
          "context": "p2p_optional_user",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      }
    },
    "/v2/guest_users": {
      "post": {
        "description": "This endpoint creates a new guest user which can be used as the buyer or\nthe seller in a transaction. Guest users can be used to create transactions\nfor users that don't yet have login details, or who choose not to use the\nlogged-in user for creating the new transaction. Emails are sent to guest\nusers which will contain details for adding guest transactions to their\nlogged-in profile.\n",
        "operationId": "v2_users.createGuestUser",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "example": {
                  "country_code": "IE",
                  "email": "guest@test.com",
                  "first_name": "Test",
                  "last_name": "User",
                  "tos_acceptance": {
                    "ip": "192.168.1.2",
                    "unix_timestamp": 1672531200
                  }
                },
                "properties": {
                  "country_code": {
                    "type": "string"
                  },
                  "email": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "first_name": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "last_name": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "tos_acceptance": {
                    "$ref": "#/components/schemas/v2_users.TosAcceptance"
                  }
                },
                "required": [
                  "email",
                  "country_code",
                  "tos_acceptance"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_users.User"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "invalid_email",
                        "missing_country_code",
                        "missing_tos_acceptance",
                        "invalid_tos_acceptance_date",
                        "invalid_country_code"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKey": []
          }
        ],
        "summary": "Create a new guest user",
        "tags": [
          "Buyers and Sellers"
        ],
        "x-toc-endpoint": {
          "context": "users_client_access",
          "meta": {
            "log_req_body": false,
            "log_resp_body": false
          }
        }
      }
    },
    "/v2/transactions": {
      "post": {
        "description": "Offline access is allowed for this endpoint.\n",
        "operationId": "v2_transactions.createTransaction",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "amount": {
                    "description": "The price of the goods being sold in this transaction, in\nthe `currency`'s smallest unit. For example, if a trading\ncard is being sold for $12.34 (with `currency` as `usd`),\nthen the body would contain `{\"amount\": 1234, \"currency\": \"usd\"}`.\n",
                    "format": "int64",
                    "type": "integer"
                  },
                  "amount_extra": {
                    "description": "Represents an additional charge to be paid by the buyer added\nto the transaction total. Use this field to include costs like\nprocessing fees or local taxes.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD). Defaults to 0 if not provided.\n",
                    "format": "int64",
                    "type": "integer"
                  },
                  "amount_postage": {
                    "description": "Represents an additional charge to be paid by the buyer, seller or client.\nUse this field to include costs like shipping surcharges.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD).\n",
                    "format": "int64",
                    "type": "integer"
                  },
                  "buyer_id": {
                    "description": "The ID of the user that will be the buyer in this transaction.\n",
                    "type": "string"
                  },
                  "contains_shipping": {
                    "description": "Specifies if the transactions contains a shippable item and\nthe shipping details should be collected from the buyer.\n",
                    "type": "boolean"
                  },
                  "currency": {
                    "description": "The currency that the `amount` is specified in.\n",
                    "format": "currency",
                    "type": "string",
                    "x-toc-ref": "#/definitions/Currency"
                  },
                  "description": {
                    "description": "A description of the goods being sold.",
                    "type": "string"
                  },
                  "fees_buyer": {
                    "description": "The buyer fees for this transaction, in the `currency`'s smallest\nunit.\n",
                    "format": "int64",
                    "type": "integer"
                  },
                  "fees_config": {
                    "description": "The fee config for which the fees are computed.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "fees_seller": {
                    "description": "The seller fees for this transaction, in the `currency`'s smallest\nunit.\n",
                    "format": "int64",
                    "type": "integer"
                  },
                  "image_url": {
                    "description": "URL of the image displayed on the Trustap payment page to show the buyer\nthe item they are paying for.\nSupports jpg, png, gif, bmp, webp and svg files. Images displayed as a\nsquares. Non-square images are cropped.\n",
                    "format": "absolute_url",
                    "maxLength": 2047,
                    "type": "string"
                  },
                  "payment_method": {
                    "description": "The payment method that will be used to pay for the\ntransaction. This is necessary because different payment\nmethods may result in different fees.\nSupports `card` and `bank_transfer`.\n\nThe default value is `card`.\n",
                    "type": "string"
                  },
                  "role": {
                    "description": "The role of the user creating the transaction.\nSupported values are `buyer` and `seller`.\n",
                    "type": "string",
                    "x-toc-ref": "#/definitions/Role"
                  },
                  "seller_id": {
                    "description": "The ID of the user that will be the seller in this transaction.\n",
                    "type": "string"
                  }
                },
                "required": [
                  "currency",
                  "amount",
                  "fees_buyer",
                  "description"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-def29dfe-8626-48a2-8863-b6fdf2b96ff1",
                        "is_guest": true
                      },
                      "client_id": "5ad5451d-70c7-43c6-86c9-e1d90556856c",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-07-30T15:49:46Z",
                          "joined": "2026-07-30T15:49:46Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-30T15:49:46Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-30T15:49:46Z",
                            "code": "joined"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kysvfb1ff1j8st5akj3vqknf",
                      "metadata": {},
                      "payment_link": "https://actions.stage.trustap.com/transactions/tx_01kysvfb1ff1j8st5akj3vqknf/pay",
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 200,
                        "amount_postage": 500,
                        "currency": "gbp",
                        "fees": {
                          "buyer": 661,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        },
                        "postage_bearer": "buyer"
                      },
                      "seller": {
                        "id": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                        "is_guest": false
                      },
                      "status": "joined"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "example": {
                    "code": "negative_amount",
                    "message": "`price` cannot be negative"
                  },
                  "properties": {
                    "code": {
                      "enum": [
                        "invalid_currency",
                        "missing_user_id",
                        "invalid_user_id",
                        "missing_seller_id",
                        "missing_buyer_id",
                        "invalid_seller_id",
                        "invalid_buyer_id",
                        "incorrect_charge",
                        "negative_amount",
                        "amount_too_low",
                        "invalid_charge_config",
                        "missing_role",
                        "invalid_role",
                        "unsupported_role"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKey": []
          }
        ],
        "summary": "Create a new transaction",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "v2_create_transaction",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}": {
      "get": {
        "operationId": "v2_transactions.getTransaction",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-def29dfe-8626-48a2-8863-b6fdf2b96ff1",
                        "is_guest": true
                      },
                      "client_id": "5ad5451d-70c7-43c6-86c9-e1d90556856c",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-07-30T15:49:46Z",
                          "joined": "2026-07-30T15:49:46Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-30T15:49:46Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-30T15:49:46Z",
                            "code": "joined"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kysvfb1ff1j8st5akj3vqknf",
                      "metadata": {},
                      "payment_link": "https://actions.stage.trustap.com/transactions/tx_01kysvfb1ff1j8st5akj3vqknf/pay",
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 200,
                        "amount_postage": 500,
                        "currency": "gbp",
                        "fees": {
                          "buyer": 661,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        },
                        "postage_bearer": "buyer"
                      },
                      "seller": {
                        "id": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                        "is_guest": false
                      },
                      "status": "joined"
                    }
                  }
                }
              }
            }
          }
        },
        "summary": "Get a transaction by its ID",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p_open",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/accept_complaint": {
      "post": {
        "operationId": "v2_transactions.acceptComplaintForTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "complaint": {
                        "accepted": "2026-07-31T18:34:53Z",
                        "category": "other",
                        "description": "Item arrived damaged"
                      },
                      "deadlines": {
                        "complaints": "2026-07-31T18:38:49Z"
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "complaint_submitted": "2026-07-31T18:34:09Z",
                          "created": "2026-07-31T18:31:13Z",
                          "delivered": "2026-07-31T18:33:49Z",
                          "joined": "2026-07-31T18:31:13Z",
                          "paid": "2026-07-31T18:31:58Z",
                          "payment_accepted": "2026-07-31T18:33:07Z",
                          "refunded": "2026-07-31T18:34:52Z",
                          "tracked": "2026-07-31T18:33:38Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T18:31:13Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T18:31:13Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T18:31:58Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T18:33:07Z",
                            "by": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T18:33:38Z",
                            "code": "tracked"
                          },
                          {
                            "at": "2026-07-31T18:33:49Z",
                            "code": "delivered"
                          },
                          {
                            "at": "2026-07-31T18:34:09Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "complaint_submitted"
                          },
                          {
                            "at": "2026-07-31T18:34:52Z",
                            "code": "refunded"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [
                          {
                            "amount": 20000,
                            "id": "4984"
                          }
                        ],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywq3p00eaf8h40zmtv6mxhz",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                        "is_guest": false
                      },
                      "status": "refunded",
                      "tracking": {
                        "carrier": "ups",
                        "tracking_code": "345345123"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "funds_already_released",
                        "deposit_not_paid",
                        "deposit_already_refunded",
                        "not_complained"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Accept a complaint for this transaction",
        "tags": [
          "Transaction Issues"
        ],
        "x-toc-endpoint": {
          "context": "p2p",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": true,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/accept_payment": {
      "post": {
        "operationId": "v2_transactions.acceptPaymentForTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-def29dfe-8626-48a2-8863-b6fdf2b96ff0",
                        "is_guest": true
                      },
                      "client_id": "5ad5451d-70c7-43c6-86c9-e1d90556856c",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-04-29T11:04:26Z",
                          "joined": "2026-04-29T11:04:26Z",
                          "paid": "2026-04-29T11:05:19Z",
                          "payment_accepted": "2026-04-29T11:06:06Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-04-29T11:04:26Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-04-29T11:04:26Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-04-29T11:05:19Z",
                            "by": "1-def29dfe-8626-48a2-8863-b6fdf2b96ff0",
                            "code": "paid"
                          },
                          {
                            "at": "2026-04-29T11:06:06Z",
                            "by": "1-3f546125-2ec2-4b14-87f6-54a14ae73e98",
                            "code": "payment_accepted"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kq7pz74mffj9x5vsesqkve08",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "gbp",
                        "fees": {
                          "buyer": 640,
                          "buyer_client": 0,
                          "international_payment": 310,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "1-3f546125-2ec2-4b14-87f6-54a14ae73e98",
                        "is_guest": true
                      },
                      "status": "payment_accepted"
                    }
                  }
                }
              }
            }
          }
        },
        "summary": "Accept the payment for a transaction",
        "tags": [
          "Payment"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/bank_transfer_details": {
      "get": {
        "description": "Get the bank transfer details for a transaction with payment method `bank_transfer`.\n",
        "operationId": "v2_transactions.getBankTransferDetails",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.BankTransferDetails"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "payment_method_not_bank_transfer",
                        "paid_with_balance"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Get the bank transfer details for a transaction",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p_open",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/buyer_details": {
      "get": {
        "operationId": "v2_transactions.getBuyerDetailsForTransaction",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.UserDetails"
                }
              }
            }
          }
        },
        "summary": "Get the buyer's contact details for a transaction",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p_open",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/cancel": {
      "post": {
        "operationId": "v2_transactions.cancelTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "description": {
                    "description": "A description of the cancellation reason.\n",
                    "type": "string"
                  }
                },
                "required": [
                  "description"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "cancellation": {
                        "description": "Colour does not match description"
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "cancelled": "2026-07-31T16:14:03Z",
                          "created": "2026-07-31T16:05:12Z",
                          "joined": "2026-07-31T16:05:12Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T16:05:12Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T16:05:12Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T16:14:03Z",
                            "code": "cancelled"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kyweratweaf9kv5kn2yz6966",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                        "is_guest": true
                      },
                      "status": "cancelled"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "already_cancelled",
                        "handover_already_confirmed"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Cancel a transaction",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/claim": {
      "post": {
        "description": "This endpoint enables a client to claim a transaction on behalf of a\nTrustap user as a buyer or seller. This endpoint can only be accessed\nby clients.\n",
        "operationId": "v2_transactions.claimTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "role": {
                    "description": "The role of the user claiming the transaction. Supported values are `buyer` and `seller`.",
                    "type": "string",
                    "x-toc-ref": "#/definitions/Role"
                  }
                },
                "required": [
                  "role"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "claimed_by_seller": "2026-07-31T19:25:29Z",
                          "created": "2026-07-31T19:22:05Z",
                          "joined": "2026-07-31T19:22:05Z",
                          "paid": "2026-07-31T19:22:50Z",
                          "payment_accepted": "2026-07-31T19:23:11Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T19:22:05Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T19:22:05Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T19:22:50Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T19:23:11Z",
                            "by": "9c11d028-252b-4124-bd85-21a650f6a793",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T19:25:29Z",
                            "by": "9c11d028-252b-4124-bd85-21a650f6a793",
                            "code": "claimed_by_seller"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywt0t07eaf8v1abyr7wpank",
                      "metadata": {},
                      "payment_link": "https://actions.stage.trustap.com/transactions/tx_01kywt0t07eaf8v1abyr7wpank/pay",
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "international_payment": 316,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "9c11d028-252b-4124-bd85-21a650f6a793",
                        "is_guest": false
                      },
                      "status": "payment_accepted"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "cannot_claim_own_transaction",
                        "invalid_role",
                        "invalid_user_id",
                        "emails_mismatched",
                        "user_is_not_guest"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKey": []
          }
        ],
        "summary": "Claim a transaction on behalf of a Trustap user",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/confirm_delivery": {
      "post": {
        "description": "This endpoint allows a user to confirm the delivery\nof the item in the case that the state of the transaction was\nnot updated asynchronously by Trustap\n",
        "operationId": "v2_transactions.confirmDeliveryForTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "deadlines": {
                        "complaints": "2026-07-31T18:13:10Z"
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-07-31T17:57:20Z",
                          "delivered": "2026-07-31T18:08:10Z",
                          "joined": "2026-07-31T17:57:20Z",
                          "paid": "2026-07-31T17:58:34Z",
                          "payment_accepted": "2026-07-31T18:02:31Z",
                          "tracked": "2026-07-31T18:03:25Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T17:58:34Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T18:02:31Z",
                            "by": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T18:03:25Z",
                            "code": "tracked"
                          },
                          {
                            "at": "2026-07-31T18:08:10Z",
                            "code": "delivered"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywn5ma0eafbk92b1qvfv1dw",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "international_payment": 316,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                        "is_guest": true
                      },
                      "status": "delivered",
                      "tracking": {
                        "carrier": "ups",
                        "tracking_code": "345345123"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "delivery_not_supported",
                        "delivery_already_set",
                        "invalid_id"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKey": []
          },
          {
            "OAuth2": []
          }
        ],
        "summary": "Confirm delivery for this transaction",
        "tags": [
          "Shipping"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/metadata": {
      "post": {
        "operationId": "v2_transactions.setTransactionMetadata",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-506ec116-f0b3-4ea8-bfd0-ea0e7b9d18aa",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "contains_shipping": true,
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-06-16T09:22:35Z",
                          "joined": "2026-06-16T09:22:35Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-06-16T09:22:35Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-06-16T09:22:35Z",
                            "code": "joined"
                          }
                        ]
                      },
                      "id": "tx_01kv7vtr9vfr5rnttm3n4x17z2",
                      "metadata": {
                        "customer_url": "https://my-bike-parts.com/",
                        "part_number": "98932"
                      },
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                        "is_guest": false
                      },
                      "status": "joined"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "too_many_keys",
                        "value_too_long",
                        "key_too_long",
                        "empty_json",
                        "unsupported_type"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Set metadata for a transaction",
        "tags": [
          "Transactions"
        ],
        "x-toc-endpoint": {
          "context": "p2p_open",
          "meta": {
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/shipping_details": {
      "get": {
        "operationId": "v2_transactions.getShippingDetailsForTransaction",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.ShippingDetails"
                }
              }
            }
          }
        },
        "summary": "Get the shipping details of the buyer for a transaction",
        "tags": [
          "Shipping"
        ],
        "x-toc-endpoint": {
          "context": "p2p",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false
          }
        }
      },
      "post": {
        "operationId": "v2_transactions.setShippingDetailsForTransaction",
        "parameters": [
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "address_line_1": {
                    "type": "string"
                  },
                  "address_line_2": {
                    "type": "string"
                  },
                  "city": {
                    "type": "string"
                  },
                  "country": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "name": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "phone": {
                    "type": "string"
                  },
                  "postal_code": {
                    "type": "string"
                  },
                  "state": {
                    "type": "string"
                  }
                },
                "required": [
                  "name",
                  "country"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.ShippingDetails"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "empty_name",
                        "empty_country"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Post the shipping details of the buyer for a transaction",
        "tags": [
          "Shipping"
        ],
        "x-toc-endpoint": {
          "context": "p2p",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/submit_complaint": {
      "post": {
        "description": "A complaint is submitted for problems with transactions after the order\nhas been shipped or handover has been confirmed. Before that an order\nissue should be submitted instead.\n",
        "operationId": "v2_transactions.submitComplaintForTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "category": {
                    "$ref": "#/components/schemas/v2_transactions.ComplaintCategory"
                  },
                  "description": {
                    "type": "string"
                  }
                },
                "required": [
                  "description"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "complaint": {
                        "category": "other",
                        "description": "Item arrived damaged"
                      },
                      "deadlines": {
                        "complaints": "2026-07-31T18:13:10Z"
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "complaint_submitted": "2026-07-31T18:10:56Z",
                          "created": "2026-07-31T17:57:20Z",
                          "delivered": "2026-07-31T18:08:10Z",
                          "joined": "2026-07-31T17:57:20Z",
                          "paid": "2026-07-31T17:58:34Z",
                          "payment_accepted": "2026-07-31T18:02:31Z",
                          "tracked": "2026-07-31T18:03:25Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T17:58:34Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T18:02:31Z",
                            "by": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T18:03:25Z",
                            "code": "tracked"
                          },
                          {
                            "at": "2026-07-31T18:08:10Z",
                            "code": "delivered"
                          },
                          {
                            "at": "2026-07-31T18:10:56Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "complaint_submitted"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywn5ma0eafbk92b1qvfv1dw",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "international_payment": 316,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                        "is_guest": true
                      },
                      "status": "complaint_submitted",
                      "tracking": {
                        "carrier": "ups",
                        "tracking_code": "345345123"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "remainder_required",
                        "already_complained",
                        "funds_already_released",
                        "complaint_period_expired",
                        "handover_or_delivery_required"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Submit a complaint for this transaction",
        "tags": [
          "Transaction Issues"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/submit_order_issue": {
      "post": {
        "description": "An order issue is submitted for problems with transactions after payment\nconfirmation and before the order has been shipped or handover has been\nconfirmed. After that a complaint should be submitted instead.\n",
        "operationId": "v2_transactions.submitOrderIssueForTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "category": {
                    "$ref": "#/components/schemas/v2_transactions.OrderIssueCategory"
                  },
                  "description": {
                    "minLength": 1,
                    "type": "string"
                  }
                },
                "required": [
                  "description"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-07-31T18:38:12Z",
                          "joined": "2026-07-31T18:38:12Z",
                          "order_issue_submitted": "2026-07-31T18:42:20Z",
                          "paid": "2026-07-31T18:39:02Z",
                          "payment_accepted": "2026-07-31T18:39:24Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T18:38:12Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T18:38:12Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T18:39:02Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T18:39:24Z",
                            "by": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T18:42:20Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "order_issue_submitted"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywqgetdeafageg8d7ntam8f",
                      "metadata": {},
                      "order_issue": {
                        "category": "item_not_received",
                        "description": "No contact from seller"
                      },
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "8e5cbedc-e57b-42e5-a3bd-2f9ced81a2d0",
                        "is_guest": false
                      },
                      "status": "payment_accepted"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "remainder_required",
                        "payment_not_accepted",
                        "handover_already_confirmed",
                        "item_already_delivered",
                        "order_issue_already_submitted"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "not_buyer"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Submit an order issue for this transaction",
        "tags": [
          "Transaction Issues"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": false,
            "log_resp_body": false,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    },
    "/v2/transactions/{transaction_id}/track": {
      "post": {
        "description": "After the tracking information has been submitted then the state\nof the transaction will be updated asynchronously by Trustap\nonce the delivery of the item has been confirmed, at which point\nthe `delivered` field of the transaction will be set.\n",
        "operationId": "v2_transactions.trackTransaction",
        "parameters": [
          {
            "description": "Required in client flows, where you make API calls on behalf of another Trustap user.",
            "in": "header",
            "name": "Trustap-User",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "transaction_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "example": {
                  "carrier": "ups",
                  "tracking_code": "***"
                },
                "properties": {
                  "carrier": {
                    "minLength": 1,
                    "type": "string"
                  },
                  "tracking_code": {
                    "minLength": 1,
                    "type": "string"
                  }
                },
                "required": [
                  "carrier",
                  "tracking_code"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/v2_transactions.Transaction"
                },
                "examples": {
                  "response": {
                    "value": {
                      "buyer": {
                        "id": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                        "is_guest": true
                      },
                      "client_id": "5a3d7990-9f1c-4e11-8d67-3da5b160c50a",
                      "deadlines": {
                        "complaints": null
                      },
                      "description": "Trustap socks",
                      "events": {
                        "by_key": {
                          "created": "2026-07-31T17:57:20Z",
                          "joined": "2026-07-31T17:57:20Z",
                          "paid": "2026-07-31T17:58:34Z",
                          "payment_accepted": "2026-07-31T18:02:31Z",
                          "tracked": "2026-07-31T18:03:25Z"
                        },
                        "by_time": [
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "created"
                          },
                          {
                            "at": "2026-07-31T17:57:20Z",
                            "code": "joined"
                          },
                          {
                            "at": "2026-07-31T17:58:34Z",
                            "by": "1-a5034d6a-1110-4d33-b6dd-c6ff1b3b2e28",
                            "code": "paid"
                          },
                          {
                            "at": "2026-07-31T18:02:31Z",
                            "by": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                            "code": "payment_accepted"
                          },
                          {
                            "at": "2026-07-31T18:03:25Z",
                            "code": "tracked"
                          }
                        ]
                      },
                      "funds_release": {
                        "refunds": [],
                        "released_to_seller": false
                      },
                      "id": "tx_01kywn5ma0eafbk92b1qvfv1dw",
                      "metadata": {},
                      "pricing": {
                        "amount": 20000,
                        "amount_extra": 0,
                        "currency": "eur",
                        "fees": {
                          "buyer": 1050,
                          "buyer_client": 0,
                          "international_payment": 316,
                          "seller": 0,
                          "seller_client": 0
                        }
                      },
                      "seller": {
                        "id": "1-22ad0309-d966-440c-8296-9989ff65eebf",
                        "is_guest": true
                      },
                      "status": "tracked",
                      "tracking": {
                        "carrier": "ups",
                        "tracking_code": "345345123"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "invalid_id",
                        "empty_carrier",
                        "empty_tracking_code",
                        "tracking_already_added",
                        "payment_details_not_added",
                        "tracking_details_deadline_expired",
                        "already_cancelled",
                        "tracking_not_supported"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "not_seller"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "enum": [
                        "missing_payment_intent"
                      ],
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            }
          }
        },
        "summary": "Set postal tracking details for a transaction",
        "tags": [
          "Shipping"
        ],
        "x-toc-endpoint": {
          "context": "p2p_any_user",
          "meta": {
            "allow_guest_user": true,
            "log_req_body": true,
            "log_resp_body": true,
            "require_active_country": false,
            "skip_offline_scope_check": true
          }
        }
      }
    }
  },
  "security": [
    {
      "APIKey": []
    },
    {
      "OAuth2": []
    }
  ],
  "tags": [
    {
      "description": "Users represent users of the platform.\n",
      "name": "Buyers and Sellers"
    },
    {
      "description": "Transaction issues endpoints are used for reporting and managing transaction\nissues.\n",
      "name": "Transaction Issues"
    },
    {
      "description": "Endpoints for creating and managing transactions.\n",
      "name": "Transactions"
    },
    {
      "description": "Payment endpoints for transactions.\n",
      "name": "Payment"
    },
    {
      "description": "Endpoint for confirming handover of goods for transactions.\n",
      "name": "Handover"
    },
    {
      "description": "Shipping endpoints for transactions.\n",
      "name": "Shipping"
    }
  ],
  "x-tagGroups": [
    {
      "name": "Users",
      "tags": [
        "Buyers and Sellers"
      ]
    },
    {
      "name": "Payment",
      "tags": [
        "Payment"
      ]
    },
    {
      "name": "Transactions",
      "tags": [
        "Transactions",
        "Transaction Issues"
      ]
    },
    {
      "name": "Delivery",
      "tags": [
        "Handover",
        "Shipping"
      ]
    }
  ],
  "servers": [
    {
      "url": "https://api.test.trustap.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "APIKey": {
        "type": "http",
        "scheme": "basic"
      },
      "OAuth2": {
        "type": "oauth2",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://sso.trustap.com/auth/realms/trustap-stage/protocol/openid-connect/auth",
            "tokenUrl": "https://sso.trustap.com/auth/realms/trustap-stage/protocol/openid-connect/token",
            "scopes": {}
          }
        }
      }
    },
    "schemas": {
      "experiences.Experience": {
        "properties": {
          "activity": {
            "type": "string"
          },
          "category": {
            "type": "string"
          },
          "date": {
            "type": "string"
          },
          "display_title": {
            "type": "string"
          },
          "id": {
            "type": "integer"
          },
          "image": {
            "type": "string"
          },
          "is_featured": {
            "type": "boolean"
          },
          "location": {
            "type": "string"
          },
          "max_price": {
            "type": "integer"
          },
          "min_price": {
            "type": "integer"
          },
          "open_time": {
            "type": "string"
          },
          "participants": {
            "items": {
              "$ref": "#/components/schemas/experiences.Participant"
            },
            "type": "array"
          },
          "title": {
            "type": "string"
          },
          "total_listings": {
            "type": "integer"
          },
          "type": {
            "type": "string"
          },
          "venue": {
            "$ref": "#/components/schemas/experiences.Venue"
          }
        },
        "required": [
          "id"
        ],
        "type": "object"
      },
      "experiences.PaginatedExperiences": {
        "properties": {
          "experiences": {
            "items": {
              "$ref": "#/components/schemas/experiences.Experience"
            },
            "type": "array"
          },
          "pagination": {
            "properties": {
              "page": {
                "type": "integer"
              },
              "page_size": {
                "type": "integer"
              },
              "total_items": {
                "type": "integer"
              },
              "total_pages": {
                "type": "integer"
              }
            },
            "required": [
              "page",
              "page_size",
              "total_items",
              "total_pages"
            ],
            "type": "object"
          }
        },
        "type": "object"
      },
      "experiences.Participant": {
        "properties": {
          "id": {
            "type": "integer"
          },
          "image": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ],
        "type": "object"
      },
      "experiences.Venue": {
        "properties": {
          "city": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "id": {
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "state": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ],
        "type": "object"
      },
      "v2_transactions.BankTransferDetails": {
        "properties": {
          "processor": {
            "type": "string"
          },
          "stripe": {
            "$ref": "#/components/schemas/v2_transactions.StripeBankTransferDetails"
          }
        },
        "required": [
          "processor"
        ],
        "type": "object"
      },
      "v2_transactions.Carrier": {
        "properties": {
          "code": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "required": [
          "code",
          "name"
        ],
        "type": "object"
      },
      "v2_transactions.ComplaintCategory": {
        "enum": [
          "item_not_received",
          "item_not_as_described",
          "other"
        ],
        "example": "other",
        "type": "string"
      },
      "v2_transactions.Events": {
        "properties": {
          "by_key": {
            "description": "These fields indicate the time that the first instance of the given\nevent occurred. Where events can repeat (such as `refunded`),\nduplicate instances can be retrieved from the `by_time` sibling\nproperty.\n",
            "properties": {
              "buyer_handover_confirmed": {
                "format": "date-time",
                "type": "string"
              },
              "cancelled": {
                "format": "date-time",
                "type": "string"
              },
              "claimed_by_buyer": {
                "format": "date-time",
                "type": "string"
              },
              "claimed_by_seller": {
                "format": "date-time",
                "type": "string"
              },
              "complaint_period_ended": {
                "format": "date-time",
                "type": "string"
              },
              "complaint_submitted": {
                "format": "date-time",
                "type": "string"
              },
              "created": {
                "format": "date-time",
                "type": "string"
              },
              "delivered": {
                "format": "date-time",
                "type": "string"
              },
              "funds_released": {
                "format": "date-time",
                "type": "string"
              },
              "joined": {
                "format": "date-time",
                "type": "string"
              },
              "order_issue_submitted": {
                "format": "date-time",
                "type": "string"
              },
              "paid": {
                "format": "date-time",
                "type": "string"
              },
              "payment_accepted": {
                "format": "date-time",
                "type": "string"
              },
              "refunded": {
                "format": "date-time",
                "type": "string"
              },
              "rejected": {
                "format": "date-time",
                "type": "string"
              },
              "review_flagged": {
                "format": "date-time",
                "type": "string"
              },
              "seller_handover_confirmed": {
                "format": "date-time",
                "type": "string"
              },
              "tracked": {
                "format": "date-time",
                "type": "string"
              }
            },
            "required": [
              "created"
            ],
            "type": "object"
          },
          "by_time": {
            "items": {
              "properties": {
                "at": {
                  "format": "date-time",
                  "type": "string"
                },
                "by": {
                  "description": "This contains the ID of the user that triggered this event. It\nis not present for events that are triggered by the platform,\nsuch as by automated systems.\n",
                  "type": "string"
                },
                "code": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "at"
              ],
              "type": "object"
            },
            "type": "array"
          }
        },
        "required": [
          "by_time",
          "by_key"
        ],
        "type": "object"
      },
      "v2_transactions.Fees": {
        "example": {
          "buyer": 78,
          "config": 1,
          "seller": 0
        },
        "properties": {
          "buyer": {
            "format": "int64",
            "type": "integer"
          },
          "config": {
            "format": "int64",
            "type": "integer"
          },
          "seller": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "buyer",
          "seller",
          "config"
        ],
        "type": "object"
      },
      "v2_transactions.OrderIssueCategory": {
        "enum": [
          "item_not_received",
          "other"
        ],
        "example": "other",
        "type": "string"
      },
      "v2_transactions.Pricing": {
        "properties": {
          "amount": {
            "format": "int64",
            "type": "integer"
          },
          "amount_extra": {
            "description": "Represents an additional charge to be paid by the buyer added\nto the transaction total. Use this field to include costs like\nprocessing fees or local taxes.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD). Defaults to 0 if not provided.\n",
            "format": "int64",
            "type": "integer"
          },
          "amount_postage": {
            "description": "Represents an additional charge to be paid by the buyer, seller or client.\nUse this field to include costs like shipping surcharges.\nMust be an integer provided in the smallest unit of the currency\n(for example, 500 for $5.00 USD).\n",
            "format": "int64",
            "type": "integer"
          },
          "currency": {
            "description": "The currency of the transaction. Note that, at present, the\nbuyer must pay using the transaction's currency and the\nseller will be paid in the transaction's currency. Conversion to this\ncurrency will happen automatically during payment if the buyer pays\nwith a different currency.\n",
            "format": "currency",
            "type": "string"
          },
          "fees": {
            "properties": {
              "buyer": {
                "format": "int64",
                "type": "integer"
              },
              "buyer_client": {
                "format": "int64",
                "type": "integer"
              },
              "international_payment": {
                "format": "int64",
                "type": "integer"
              },
              "seller": {
                "format": "int64",
                "type": "integer"
              },
              "seller_client": {
                "format": "int64",
                "type": "integer"
              }
            },
            "required": [
              "buyer",
              "seller",
              "buyer_client",
              "seller_client"
            ],
            "type": "object"
          },
          "postage_bearer": {
            "description": "Indicates who is responsible for paying the postage amount.\nOnly present if `amount_postage` is provided.\n",
            "enum": [
              "buyer",
              "seller",
              "client"
            ],
            "type": "string"
          }
        },
        "required": [
          "amount",
          "amount_extra",
          "currency",
          "fees"
        ],
        "type": "object"
      },
      "v2_transactions.ShippingDetails": {
        "properties": {
          "address": {
            "$ref": "#/components/schemas/v2_transactions.ShippingDetailsAddress"
          },
          "name": {
            "type": "string"
          },
          "phone": {
            "type": "string"
          }
        },
        "required": [
          "address",
          "name",
          "phone"
        ],
        "type": "object"
      },
      "v2_transactions.ShippingDetailsAddress": {
        "properties": {
          "city": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "line1": {
            "type": "string"
          },
          "line2": {
            "type": "string"
          },
          "postal_code": {
            "type": "string"
          },
          "state": {
            "type": "string"
          }
        },
        "required": [
          "city",
          "country",
          "line1",
          "line2",
          "state",
          "postal_code"
        ],
        "type": "object"
      },
      "v2_transactions.Status": {
        "enum": [
          "created",
          "joined",
          "rejected",
          "cancelled",
          "paid",
          "review_flagged",
          "payment_accepted",
          "complaint_submitted",
          "complaint_period_ended",
          "refunded",
          "tracked",
          "delivered",
          "funds_released",
          "claimed_by_buyer",
          "claimed_by_seller"
        ],
        "type": "string"
      },
      "v2_transactions.StripeAba": {
        "properties": {
          "account_number": {
            "type": "string"
          },
          "bank_name": {
            "type": "string"
          },
          "routing_number": {
            "type": "string"
          }
        },
        "required": [
          "account_number",
          "bank_name",
          "routing_number"
        ],
        "type": "object"
      },
      "v2_transactions.StripeBankTransferDetails": {
        "properties": {
          "amount": {
            "format": "int64",
            "type": "integer"
          },
          "currency": {
            "type": "string"
          },
          "financial_address": {
            "$ref": "#/components/schemas/v2_transactions.StripeFinancialAddress"
          },
          "hosted_instructions_url": {
            "type": "string"
          },
          "reference": {
            "type": "string"
          }
        },
        "required": [
          "amount",
          "currency",
          "hosted_instructions_url",
          "reference",
          "financial_address"
        ],
        "type": "object"
      },
      "v2_transactions.StripeFinancialAddress": {
        "properties": {
          "aba": {
            "$ref": "#/components/schemas/v2_transactions.StripeAba"
          },
          "iban": {
            "$ref": "#/components/schemas/v2_transactions.StripeIban"
          },
          "sort_code": {
            "$ref": "#/components/schemas/v2_transactions.StripeSortCode"
          },
          "swift": {
            "$ref": "#/components/schemas/v2_transactions.StripeSwift"
          }
        },
        "type": "object"
      },
      "v2_transactions.StripeIban": {
        "properties": {
          "account_holder_name": {
            "type": "string"
          },
          "bic": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "iban": {
            "type": "string"
          }
        },
        "required": [
          "account_holder_name",
          "bic",
          "country",
          "iban"
        ],
        "type": "object"
      },
      "v2_transactions.StripeSortCode": {
        "properties": {
          "account_holder_name": {
            "type": "string"
          },
          "account_number": {
            "type": "string"
          },
          "sort_code": {
            "type": "string"
          }
        },
        "required": [
          "account_holder_name",
          "account_number",
          "sort_code"
        ],
        "type": "object"
      },
      "v2_transactions.StripeSwift": {
        "properties": {
          "account_number": {
            "type": "string"
          },
          "bank_name": {
            "type": "string"
          },
          "swift_code": {
            "type": "string"
          }
        },
        "required": [
          "account_number",
          "bank_name",
          "swift_code"
        ],
        "type": "object"
      },
      "v2_transactions.Tracking": {
        "properties": {
          "carrier": {
            "type": "string"
          },
          "tracking_code": {
            "type": "string"
          }
        },
        "required": [
          "carrier",
          "tracking_code"
        ],
        "type": "object"
      },
      "v2_transactions.Transaction": {
        "example": {
          "buyer": {
            "id": "9097",
            "is_guest": false
          },
          "client_id": "1234",
          "deadlines": {
            "complaints": "2019-12-25T15:00:00Z"
          },
          "description": "Soccer ticket",
          "events": {
            "by_key": {
              "created": "2019-12-25T09:00:00Z",
              "delivered": "2019-12-25T16:00:00Z",
              "funds_released": "2019-12-25T17:00:00Z",
              "joined": "2019-12-25T10:00:00Z",
              "paid": "2019-12-25T11:00:00Z",
              "payment_accepted": "2019-12-25T12:00:00Z"
            },
            "by_time": []
          },
          "funds_release": {
            "refunds": [],
            "released_to_seller": false
          },
          "id": "tx_21066",
          "pricing": {
            "amount": 1000,
            "amount_extra": 0,
            "currency": "eur",
            "fees": {
              "buyer": 110,
              "buyer_client": 10,
              "international_payment": 20,
              "seller": 0,
              "seller_client": 5
            }
          },
          "review": {
            "approved": true,
            "outcome_reason": "Not fraudulent."
          },
          "seller": {
            "id": "9790",
            "is_guest": false
          },
          "status": "funds_released"
        },
        "properties": {
          "buyer": {
            "$ref": "#/components/schemas/v2_transactions.User"
          },
          "cancellation": {
            "properties": {
              "description": {
                "type": "string"
              }
            },
            "required": [
              "description"
            ],
            "type": "object"
          },
          "client_id": {
            "type": "string"
          },
          "complaint": {
            "properties": {
              "accepted": {
                "format": "date-time",
                "type": "string"
              },
              "category": {
                "$ref": "#/components/schemas/v2_transactions.ComplaintCategory"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "description",
              "category"
            ],
            "type": "object"
          },
          "contains_shipping": {
            "type": "boolean"
          },
          "deadlines": {
            "description": "This property contains all possible actions that have associated\ndeadlines for completion. Actions with `null` do not have deadlines\ncurrently pending.\n",
            "properties": {
              "complaints": {
                "format": "date-time",
                "type": "string",
                "nullable": true
              }
            },
            "type": "object"
          },
          "description": {
            "type": "string"
          },
          "events": {
            "$ref": "#/components/schemas/v2_transactions.Events"
          },
          "funds_release": {
            "properties": {
              "payout_id": {
                "type": "string"
              },
              "refunds": {
                "items": {
                  "properties": {
                    "amount": {
                      "format": "int64",
                      "type": "integer"
                    },
                    "id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "amount"
                  ],
                  "type": "object"
                },
                "type": "array"
              },
              "released_to_seller": {
                "type": "boolean"
              }
            },
            "required": [
              "released_to_seller",
              "refunds"
            ],
            "type": "object"
          },
          "id": {
            "format": "type_id",
            "type": "string"
          },
          "join_code": {
            "type": "string"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Arbitrary key-value string pairs for adding extra information to transactions.",
            "type": "object"
          },
          "order_issue": {
            "properties": {
              "category": {
                "$ref": "#/components/schemas/v2_transactions.OrderIssueCategory"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "description",
              "category"
            ],
            "type": "object"
          },
          "payment_link": {
            "description": "URL to the actions page where the buyer can pay the deposit.\n",
            "type": "string"
          },
          "pricing": {
            "$ref": "#/components/schemas/v2_transactions.Pricing"
          },
          "review": {
            "properties": {
              "approved": {
                "type": "boolean"
              },
              "outcome_reason": {
                "type": "string"
              }
            },
            "required": [
              "approved",
              "outcome_reason"
            ],
            "type": "object"
          },
          "seller": {
            "$ref": "#/components/schemas/v2_transactions.User"
          },
          "status": {
            "$ref": "#/components/schemas/v2_transactions.Status"
          },
          "tracking": {
            "$ref": "#/components/schemas/v2_transactions.Tracking"
          }
        },
        "required": [
          "id",
          "status",
          "client_id",
          "pricing",
          "deadlines",
          "description",
          "events"
        ],
        "type": "object"
      },
      "v2_transactions.User": {
        "example": {
          "id": "9097",
          "is_guest": false
        },
        "properties": {
          "id": {
            "type": "string"
          },
          "is_guest": {
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "is_guest"
        ],
        "type": "object"
      },
      "v2_transactions.UserDetails": {
        "properties": {
          "email": {
            "type": "string"
          },
          "name": {
            "$ref": "#/components/schemas/v2_transactions.UserDetailsName"
          },
          "phone": {
            "type": "string"
          }
        },
        "required": [
          "email"
        ],
        "type": "object"
      },
      "v2_transactions.UserDetailsName": {
        "properties": {
          "first": {
            "type": "string"
          },
          "last": {
            "type": "string"
          }
        },
        "required": [
          "first",
          "last"
        ],
        "type": "object"
      },
      "v2_users.TosAcceptance": {
        "properties": {
          "ip": {
            "minLength": 1,
            "type": "string"
          },
          "unix_timestamp": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "unix_timestamp",
          "ip"
        ],
        "type": "object"
      },
      "v2_users.User": {
        "example": {
          "created_at": "2019-12-25T13:00:00Z",
          "email": "jo@example.com",
          "id": "1-feb33a87-3917-4538-9260-127c8a6b5232"
        },
        "properties": {
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "id": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "email",
          "created_at"
        ],
        "type": "object"
      }
    }
  }
}