basePath: /api/v1 consumes: - application/json definitions: Carrier: properties: code: type: string name: type: string required: - code - name type: object CarrierName: enum: - fedex - ups - usps - posta_hr example: fedex type: string Complaint: example: description: Item was fake properties: description: type: string required: - description type: object Currency: enum: - aud - eur - gbp - myr - pln - sek - usd - huf example: eur type: string DocumentVerification: example: previously_submitted: true status: verifying properties: previously_submitted: type: boolean status: description: | Verification status of the document could be one of the following: `due`, `not_due`, `verifying`, `verified` type: string required: - status - previously_submitted type: object Error: example: code: negative_price error: '`price` cannot be negative' properties: code: type: string error: description: | A contextual description of the error that occurred. When handling errors the `code` field should be used to determine the type of error that occurred, as the text in the `error` field may change unexpectedly. type: string required: - code - error type: object ListingType: enum: - single_use - multi_use example: single_use type: string OrderIssue: example: description: Delivery delayed properties: description: type: string required: - description type: object P2PMultiUseListing: example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 deposit_pricing: charge: 150 price: 5000 description: "" id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false properties: allows_multi_use: type: boolean created: type: string creator_id: type: string creator_role: type: string currency: type: string deposit_pricing: $ref: '#/definitions/basic.Pricing' description: type: string id: format: int64 type: integer skip_remainder: type: boolean required: - id type: object P2PSingleUseListing: example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 deposit_pricing: charge: 150 price: 5000 description: "" id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false properties: allows_multi_use: type: boolean created: type: string creator_id: type: string creator_role: type: string currency: type: string deposit_pricing: $ref: '#/definitions/basic.Pricing' description: type: string disabled: type: string id: format: int64 type: integer skip_remainder: type: boolean required: - id type: object PostaHrTracking: example: barcode: ABC123456 barcode_generated: 2019-12-26T14:00:00Z properties: barcode: type: string barcode_generated: format: date-time type: string required: - barcode - barcode_generated type: object ProfilePayoutStatus: example: status: verifying properties: status: description: | Payout status will be one of the following: - `complete`: The user has completed their profile and payment information, and can accept payouts. - `verifying`: The user has submitted profile and payment information, which is currently being verified. - `due`: The user has not adequately filled out their payment information, or may need to update or ammend the provided information before they can accept payouts. enum: - complete - verifying - due type: string required: - status type: object ShippingDetails: properties: address: $ref: '#/definitions/ShippingDetailsAddress' name: type: string phone: type: string required: - address - name - phone type: object 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 ShippoLabelDetails: properties: label_url: type: string qr_code_url: format: uri type: string tracking_code: type: string tracking_url: type: string required: - label_url - tracking_url - tracking_code type: object Tracking: example: carrier: ups tracking_code: '***' properties: carrier: type: string tracking_code: type: string required: - carrier - tracking_code type: object UserDetails: properties: email: type: string name: $ref: '#/definitions/basic.UserDetailsName' phone: type: string required: - email type: object app_notifs.Notification: example: created: 2019-12-25T10:00:00Z description: Buyer has joined transaction for 'Soccer ticket' id: 1990 target: basic/1309 user_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 properties: created: format: date-time type: string description: type: string id: format: int64 type: integer read: format: date-time type: string target: type: string user_id: type: string required: - id - created - user_id - description - target type: object basic.Aba: properties: account_number: type: string bank_name: type: string routing_number: type: string required: - account_number - bank_name - routing_number type: object basic.BankTransferDetails: properties: amount: format: int64 type: integer currency: type: string financial_address: $ref: '#/definitions/basic.FinancialAddress' hosted_instructions_url: type: string reference: type: string required: - amount - currency - hosted_instructions_url - reference - financial_address type: object basic.BillingDetails: properties: email: type: string name: type: string phone: type: string required: - email type: object basic.CarrierFacility: properties: address: type: string city: type: string code: type: string delivery_type: type: string name: type: string postal_code: type: string required: - delivery_type - name - postal_code - address - city type: object basic.Charge: example: charge: 340 charge_calculator_version: 5 charge_config: 1 charge_postage_buyer: 1000 charge_seller: 0 currency: eur payment_method: card price: 10000 properties: charge: description: | The Trustap fee that the buyer will pay, in the `currency`'s smallest unit, for a queried amount. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. format: int64 type: integer charge_calculator_version: description: | The version of the Trustap charge calculator that was used to calculate this charge. This property is present for error-handling purposes. The Trustap API allows apps and users to query how much Trustap will charge for a transaction before creating a transaction. Trustap then requires the queried charge to be provided when creating a transaction or listing. At this point the charge is calculated again and checked against the provided charge, to ensure that the charge calculated for the new resource is the same as the one shown to the user. In the unlikely event that the Trustap charge calculator used to calculate the charge has been updated, then the `charge_calculator_version` property will be used to return an `incorrect_calc_version` to the API client, which will indicate that the `/charge` endpoint should be queried again to get the newest charge value. format: int64 type: integer charge_config: default: 1 description: | The config for which the charge amount is computed. format: int64 type: integer charge_postage_buyer: description: | When the transaction handles the generation of postage labels, then `charge_postage_buyer` will be added to cover this fee together with `charge_postage_client` format: int64 type: integer charge_postage_client: format: int64 type: integer charge_seller: description: | The Trustap fee that the seller will pay, in the `currency`'s smallest unit, for a queried amount. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. format: int64 type: integer currency: type: string payment_method: type: string price: format: int64 type: integer required: - currency - charge - charge_seller - charge_calculator_version - price type: object basic.DeliveryDetails: properties: carrier: type: string city: type: string delivery_center_code: type: string delivery_type: type: string email: type: string full_name: type: string house_number: type: string house_number_suffix: type: string phone: type: string postal_code: type: string street: type: string required: - full_name - phone - email - street - house_number - house_number_suffix - postal_code - city - carrier - delivery_center_code - delivery_type type: object basic.DistanceUnit: enum: - in - cm example: cm type: string basic.Feature: enum: - require_seller_acceptance - use_hr_post - use_shippo example: require_seller_acceptance type: string basic.FinancialAddress: properties: aba: $ref: '#/definitions/basic.Aba' iban: $ref: '#/definitions/basic.Iban' sort_code: $ref: '#/definitions/basic.SortCode' swift: $ref: '#/definitions/basic.Swift' type: object basic.Iban: properties: account_holder_name: type: string bic: type: string country: type: string iban: type: string required: - account_holder_name - bic - country - iban type: object basic.MassUnit: enum: - lb - kg example: kg type: string basic.MultiUseListing: example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 id: 77f36253-7a43-4d47-897d-f73dd208e17a properties: created: format: date-time type: string creator_id: type: string creator_role: $ref: '#/definitions/basic.Role' currency: type: string description: type: string disabled: format: date-time type: string id: type: string pricing: $ref: '#/definitions/basic.Pricing' required: - id - creator_id - created - creator_role type: object basic.PickUpDetails: properties: carrier: type: string city: type: string delivery_type: type: string email: type: string full_name: type: string house_number: type: string house_number_suffix: type: string phone: type: string pick_up_center_code: type: string postal_code: type: string street: type: string required: - full_name - phone - email - street - house_number - house_number_suffix - postal_code - city - carrier - pick_up_center_code - delivery_type type: object basic.Pricing: example: charge: 78 price: 1234 properties: charge: format: int64 type: integer charge_international_payment: format: int64 type: integer charge_seller: format: int64 type: integer price: format: int64 type: integer required: - price - charge - charge_seller type: object basic.Refund: properties: amount: format: int64 type: integer id: type: string refunded: format: date-time type: string required: - id - amount - refunded type: object basic.Review: properties: approved: type: boolean finished: format: date-time type: string outcome_reason: type: string started: format: date-time type: string type: object basic.Role: enum: - buyer - seller example: buyer type: string basic.ServiceLevel: properties: extended_token: type: string name: type: string terms: type: string token: type: string required: - name - terms - token - extended_token type: object basic.ShipmentLabel: properties: label: type: string required: - label type: object basic.ShippoAddress: properties: city: type: string country: type: string email: type: string full_name: type: string phone: type: string state: type: string street_1: type: string street_2: type: string zip_code: type: string required: - full_name - street_1 - zip_code - city - state - country - phone type: object basic.ShippoParcel: properties: distance_unit: type: string height: format: double type: number length: format: double type: number mass_unit: type: string shipment_date: type: string weight: format: double type: number width: format: double type: number required: - height - weight - width - length - mass_unit - distance_unit - shipment_date type: object basic.ShippoRate: properties: amount: type: string amount_local: type: string arrives_by: type: string attributes: items: type: string type: array currency: type: string currency_local: type: string duration_terms: type: string estimated_days: format: int64 type: integer id: type: string provider: type: string provider_image: type: string servicelevel: $ref: '#/definitions/basic.ServiceLevel' required: - id - amount - currency - amount_local - currency_local - provider - provider_image - duration_terms - estimated_days - attributes - servicelevel type: object basic.ShippoShippingRatesResponse: properties: rates: items: $ref: '#/definitions/basic.ShippoRate' type: array shipment_id: type: string required: - shipment_id - rates type: object basic.SingleUseListing: example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 id: 77f36253-7a43-4d47-897d-f73dd208e17a properties: created: format: date-time type: string creator_id: type: string creator_role: $ref: '#/definitions/basic.Role' currency: type: string description: type: string disabled: format: date-time type: string id: type: string pricing: $ref: '#/definitions/basic.Pricing' required: - id - creator_id - created - creator_role type: object basic.SortCode: properties: account_holder_name: type: string account_number: type: string sort_code: type: string required: - account_holder_name - account_number - sort_code type: object basic.Swift: properties: account_number: type: string bank_name: type: string swift_code: type: string required: - account_number - bank_name - swift_code type: object basic.Transaction: example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 charge_seller: 0 client_id: trustap-app created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-25T13:00:00Z description: Soccer ticket funds_released: 2019-12-26T14:00:00Z id: 1309 is_payment_in_progress: false joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z posta_hr_tracking: barcode: ABC12345 barcode_generated: 2019-12-25T12:00:00Z price: 1234 quantity: 1 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: funds_released tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' properties: amount_refunded: format: int64 type: integer amount_released: format: int64 type: integer buyer_id: type: string cancelled: format: date-time type: string charge: format: int64 type: integer charge_international_payment: format: int64 type: integer charge_postage_buyer: format: int64 type: integer charge_postage_client: format: int64 type: integer charge_seller: format: int64 type: integer claimed_by_buyer: format: date-time type: string client_id: type: string complained: format: date-time type: string complaint: $ref: '#/definitions/Complaint' complaint_period_deadline: format: date-time type: string complaint_period_ended: format: date-time type: string created: format: date-time type: string currency: description: | The currency of the transaction. Note that, at present, the buyer must pay using the transaction's currency and the seller will be paid in the transaction's currency. type: string delivered: format: date-time type: string denied: format: date-time type: string description: type: string funds_released: format: date-time type: string id: format: int64 type: integer image_url: description: | URL of the image displayed on the Trustap payment page to show the buyer the item they are paying for. Supports jpg, png, gif, bmp and svg files. Images displayed as a squares. Non-square images are cropped format: absolute_url type: string is_payment_in_progress: description: | If the transaction is paid via a delayed payment method, such as SEPA debit, this field will be `true` until the payment has fully succeeded or failed. type: boolean join_code: type: string joined: format: date-time type: string listing_creator_accepted: format: date-time type: string listing_creator_rejected: format: date-time type: string listing_id: description: | If the transaction is created from a listing then this is the ID of that listing; otherwise this property is omitted. type: string listing_type: $ref: '#/definitions/ListingType' description: | If the transaction is created from a listing then this is the type of that listing; otherwise this property is omitted. order_issue: $ref: '#/definitions/OrderIssue' order_issue_raised: format: date-time type: string paid: format: date-time type: string payment_accepted: format: date-time type: string payment_refunded: format: date-time type: string posta_hr_tracking: $ref: '#/definitions/PostaHrTracking' price: format: int64 type: integer quantity: format: int64 type: integer refunds: items: $ref: '#/definitions/basic.Refund' type: array released_to_seller: type: boolean review: $ref: '#/definitions/basic.Review' review_flagged: format: date-time type: string seller_id: type: string shippo_transaction_id: type: string status: type: string tracked: format: date-time type: string tracking: $ref: '#/definitions/Tracking' tracking_details_deadline: format: date-time type: string tracking_details_window_started: format: date-time type: string required: - id - status - currency - price - charge - charge_seller - description - quantity - created - is_payment_in_progress - client_id type: object basic.TransactionPage: properties: data: items: $ref: '#/definitions/basic.Transaction' type: array page: format: int64 type: integer page_size: format: int64 type: integer total_count: format: int64 type: integer total_pages: format: int64 type: integer required: - data - total_count - page - total_pages - page_size type: object basic.UserDetailsName: example: first: John last: Doe properties: first: type: string last: type: string required: - first - last type: object p2p.Aba: properties: account_number: type: string bank_name: type: string routing_number: type: string required: - account_number - bank_name - routing_number type: object p2p.ActionsUrl: properties: actions_url: type: string required: - actions_url type: object p2p.BankTransferDetails: properties: amount: format: int64 type: integer currency: type: string financial_address: $ref: '#/definitions/p2p.FinancialAddress' hosted_instructions_url: type: string reference: type: string required: - amount - currency - hosted_instructions_url - reference - financial_address type: object p2p.Cancellation: properties: reason: type: string required: - reason type: object p2p.Charge: example: charge: 78 charge_calculator_version: 5 charge_config: 1 charge_seller: 0 currency: eur payment_method: card price: 1234 properties: charge: description: | The Trustap fee that the buyer will pay, in the `currency`'s smallest unit, for a queried amount. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. format: int64 type: integer charge_calculator_version: description: | The version of the Trustap charge calculator that was used to calculate this charge. This property is present for error-handling purposes. The Trustap API allows apps and users to query how much Trustap will charge for a transaction before creating a transaction. Trustap then requires the queried charge to be provided when creating a transaction or listing. At this point the charge is calculated again and checked against the provided charge, to ensure that the charge calculated for the new resource is the same as the one shown to the user. In the unlikely event that the Trustap charge calculator used to calculate the charge has been updated, then the `charge_calculator_version` property will be used to return an `incorrect_calc_version` to the API client, which will indicate that the `/charge` endpoint should be queried again to get the newest charge value. format: int64 type: integer charge_config: default: 1 format: int64 type: integer charge_seller: description: | The Trustap fee that the seller will pay, in the `currency`'s smallest unit, for a queried amount. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. format: int64 type: integer currency: type: string payment_method: type: string price: format: int64 type: integer required: - currency - charge - charge_seller - charge_calculator_version - price type: object p2p.Complaint: example: description: Item was fake properties: description: type: string required: - description type: object p2p.Currency: enum: - aud - eur - gbp - myr - pln - sek - usd - huf example: eur type: string p2p.DepositFeeMultiplier: properties: fee_multiplier: format: double type: number required: - fee_multiplier type: object p2p.DepositPaymentMethod: example: currency: eur deposit_charge: 2000 deposit_charge_seller: 0 deposit_price: 200000 payment_method: bank_transfer properties: charge_config: format: int64 type: integer currency: type: string deposit_charge: format: int64 type: integer deposit_charge_seller: format: int64 type: integer deposit_price: format: int64 type: integer payment_method: type: string required: - payment_method - currency - deposit_price - deposit_charge - deposit_charge_seller type: object p2p.FinancialAddress: properties: aba: $ref: '#/definitions/p2p.Aba' iban: $ref: '#/definitions/p2p.Iban' sort_code: $ref: '#/definitions/p2p.SortCode' swift: $ref: '#/definitions/p2p.Swift' type: object p2p.Iban: properties: account_holder_name: type: string bic: type: string country: type: string iban: type: string required: - account_holder_name - bic - country - iban type: object p2p.ListingType: enum: - single_use - multi_use example: single_use type: string p2p.Pricing: example: charge: 78 price: 1234 properties: charge: format: int64 type: integer charge_international_payment: format: int64 type: integer charge_seller: format: int64 type: integer deposit_fee_multiplier: $ref: '#/definitions/p2p.DepositFeeMultiplier' price: format: int64 type: integer required: - price - charge - charge_seller type: object p2p.Refund: properties: amount: format: int64 type: integer id: type: string refunded: format: date-time type: string required: - id - amount - refunded type: object p2p.Review: properties: approved: type: boolean finished: format: date-time type: string outcome_reason: type: string started: format: date-time type: string type: object p2p.Role: enum: - buyer - seller example: buyer type: string p2p.SortCode: properties: account_holder_name: type: string account_number: type: string sort_code: type: string required: - account_holder_name - account_number - sort_code type: object p2p.StripeToken: properties: stripe_token: type: string required: - stripe_token type: object p2p.Swift: properties: account_number: type: string bank_name: type: string swift_code: type: string required: - account_number - bank_name - swift_code type: object p2p.Transaction: example: buyer_handover_confirmed: 2019-12-25T16:00:00Z buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 client_id: trustap-app created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket funds_released: 2019-12-25T17:00:00Z id: 1309 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_handover_confirmed: 2019-12-25T15:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: funds_released properties: amount_refunded: format: int64 type: integer buyer_handover_confirmed: format: date-time type: string buyer_id: type: string buyer_is_guest: type: boolean cancellation: $ref: '#/definitions/p2p.Cancellation' cancelled: format: date-time type: string claimed_by_buyer: format: date-time type: string claimed_by_seller: format: date-time type: string client_id: type: string complained: format: date-time type: string complaint: $ref: '#/definitions/p2p.Complaint' complaint_period_deadline: format: date-time type: string complaint_period_ended: format: date-time type: string created: format: date-time type: string currency: description: | The currency of the transaction. Note that, at present, the buyer must pay using the transaction's currency and the seller will be paid in the transaction's currency. type: string deposit_accepted: format: date-time type: string deposit_paid: format: date-time type: string deposit_pricing: $ref: '#/definitions/p2p.Pricing' deposit_refunded: format: date-time type: string deposit_review: $ref: '#/definitions/p2p.Review' deposit_review_flagged: format: date-time type: string description: type: string funds_released: format: date-time type: string id: format: int64 type: integer image_url: description: | URL of the image displayed on the Trustap payment page to show the buyer the item they are paying for. Supports jpg, png, gif, bmp and svg files. Images displayed as a squares. Non-square images are cropped format: absolute_url type: string is_deposit_payment_in_progress: description: | If the deposit is paid via a delayed payment method, such as SEPA debit, this field will be `true` until the payment has fully succeeded or failed. type: boolean is_remainder_payment_in_progress: description: | If the remainder is paid via a delayed payment method, such as SEPA debit, this field will be `true` until the payment has fully succeeded or failed. type: boolean join_code: type: string joined: format: date-time type: string listing_id: description: | If the transaction is created from a listing then this is the ID of that listing; otherwise this property is omitted. type: string listing_type: $ref: '#/definitions/p2p.ListingType' description: | If the transaction is created from a listing then this is the type of that listing; otherwise this property is omitted. order_issue_raised: format: date-time type: string priced: format: date-time type: string pricing: $ref: '#/definitions/p2p.Pricing' quantity: format: int64 type: integer refunded: format: date-time type: string refunds: items: $ref: '#/definitions/p2p.Refund' type: array rejected: format: date-time type: string released_to_seller: type: boolean remainder_paid: format: date-time type: string remainder_review: $ref: '#/definitions/p2p.Review' remainder_review_flagged: format: date-time type: string remainder_skipped: format: date-time type: string seller_handover_confirmed: format: date-time type: string seller_id: type: string seller_is_guest: type: boolean seller_phone_number: type: string skip_remainder: description: | If `skip_remainder` is `true` then this transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean status: type: string required: - id - currency - deposit_pricing - description - skip_remainder - status - quantity - created - is_deposit_payment_in_progress - is_remainder_payment_in_progress - client_id type: object p2p.TransactionPage: properties: data: items: $ref: '#/definitions/p2p.Transaction' type: array page: format: int64 type: integer page_size: format: int64 type: integer total_count: format: int64 type: integer total_pages: format: int64 type: integer required: - data - total_count - page - total_pages - page_size type: object personal.BankAccount: properties: bank_name: type: string country: type: string currency_alpha_2: type: string last4: type: string routing: type: string required: - country - currency_alpha_2 - last4 - bank_name type: object personal.BankDetails: properties: account_number: type: string country_code: type: string currency: type: string routing_number: type: string required: - account_number - country_code - currency type: object personal.Card: properties: last4: type: string month: format: int64 type: integer year: format: int64 type: integer required: - last4 - month - year type: object personal.DateValidation: properties: max_date: type: integer max_day: type: integer max_month: type: integer max_year: type: integer min_day: type: integer min_month: type: integer min_year: type: integer type: object personal.DebitAccount: properties: bank_account: $ref: '#/definitions/personal.BankAccount' card: $ref: '#/definitions/personal.Card' required: - bank_account - card type: object personal.Details: properties: address_city: $ref: '#/definitions/personal.VerifiableString' address_country: $ref: '#/definitions/personal.VerifiableString' address_line1: $ref: '#/definitions/personal.VerifiableString' address_line2: $ref: '#/definitions/personal.VerifiableString' address_postal_code: $ref: '#/definitions/personal.VerifiableString' address_state: $ref: '#/definitions/personal.VerifiableString' dob: $ref: '#/definitions/personal.VerifiableDate' id_number: $ref: '#/definitions/personal.VerifiableIdNumber' name_first: $ref: '#/definitions/personal.VerifiableString' name_last: $ref: '#/definitions/personal.VerifiableString' phone: $ref: '#/definitions/personal.VerifiablePhone' required: - name_first - name_last - dob - phone - address_line1 - address_line2 - address_city - address_postal_code - address_state - address_country - id_number type: object personal.FieldType: enum: - date - id_number - phone - string type: string personal.InstantPayoutBalance: properties: amount: format: int64 type: integer currency: type: string required: - amount - currency type: object personal.InvalidReason: properties: code: type: string description: description: An English-language description of the error. type: string required: - code - description type: object personal.PayoutAttempt: properties: amount: format: int64 type: integer arrival_date: format: int64 type: integer created_date: format: int64 type: integer failure_code: enum: - account_closed - account_frozen - bank_account_restricted - bank_ownership_changed - could_not_process - debit_not_authorized - declined - insufficient_funds - invalid_account_number - incorrect_account_holder_name - incorrect_account_holder_address - incorrect_account_holder_tax_id - invalid_currency - no_account - unsupported_card type: string status: enum: - paid - pending - in_transit - canceled - failed type: string required: - amount - created_date - arrival_date - status type: object personal.Validation: properties: cannot_unset: type: boolean cannot_update: type: boolean max_length: type: integer min_length: type: integer type: object personal.VerifiableDate: properties: invalid_reason: $ref: '#/definitions/personal.InvalidReason' required_now: type: boolean status: $ref: '#/definitions/personal.VerificationStatus' type: $ref: '#/definitions/personal.FieldType' validation: $ref: '#/definitions/personal.DateValidation' value: properties: day: type: integer month: type: integer year: type: integer required: - day - month - year type: object required: - value - required_now - validation - status - type type: object personal.VerifiableIdNumber: properties: invalid_reason: $ref: '#/definitions/personal.InvalidReason' required_now: type: boolean status: $ref: '#/definitions/personal.VerificationStatus' type: $ref: '#/definitions/personal.FieldType' validation: properties: max_length: type: integer min_length: type: integer type: object value: properties: provided: type: boolean required: - provided type: object required: - required_now - value - validation - status - type type: object personal.VerifiablePhone: properties: invalid_reason: $ref: '#/definitions/personal.InvalidReason' required_now: type: boolean status: $ref: '#/definitions/personal.VerificationStatus' type: $ref: '#/definitions/personal.FieldType' validation: properties: number_min_length: type: integer type: object value: properties: dial_code: type: string dial_code_country: description: This field is mostly non-functional, but is instead used to render the phone number for the user. This field is necessary because different countries may use the same dial code (for example, the US and Canada). type: string number: type: string required: - dial_code_country - dial_code - number type: object required: - required_now - value - validation - status - type type: object personal.VerifiableString: properties: invalid_reason: $ref: '#/definitions/personal.InvalidReason' required_now: type: boolean status: $ref: '#/definitions/personal.VerificationStatus' type: $ref: '#/definitions/personal.FieldType' validation: $ref: '#/definitions/personal.Validation' value: type: string required: - required_now - type - value - validation - status type: object personal.VerificationSessionLastError: description: | Optional error information if there was an error in the verification session. properties: code: enum: - abandoned - consent_declined - country_not_supported - device_not_supported - document_expired - document_type_not_supported - document_unverified_other - email_unverified_other - email_verification_declined - id_number_insufficient_document_data - id_number_mismatch - id_number_unverified_other - phone_unverified_other - phone_verification_declined - selfie_document_missing_photo - selfie_face_mismatch - selfie_manipulated - selfie_unverified_other - under_supported_age type: string reason: description: | Explanation or description related to the error code. type: string required: - code - reason type: object personal.VerificationStatus: enum: - unset - invalid - verifying - verified_and_verifying - verified - set type: string users.Balances: properties: available: items: properties: amount: format: int64 type: integer currency: type: string required: - currency - amount type: object type: array required: - available type: object users.Features: properties: instant_payouts_enabled: type: boolean type: object users.GuestUser: example: 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 users.TosAcceptance: properties: ip: minLength: 1 type: string unix_timestamp: format: int64 type: integer required: - unix_timestamp - ip type: object users.User: example: id: 2-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 users_client.User: example: email: test@test.com id: 2-feb33a87-3917-4538-9260-127c8a6b5232 properties: email: type: string id: type: string required: - id - email type: object host: dev.stage.trustap.com info: contact: email: support@trustap.com description: | The Trustap API is a REST-based API for managing user data and transactions for Trustap users. Note that, like Stripe, all API `price` and `charge` fields expect amounts to be provided in a currency's smallest unit. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. API Keys -------- Some endpoints such as `/charge` endpoints can be accessed directly using an API key. API keys are provided as the "username" portion of a basic auth authentication. For example, the Trustap fee for a new online transaction can be determined using the following cURL request with an API key: ``` bash curl -u '': 'https://dev.stage.trustap.com/api/v1/charge?currency=eur&price=1234' ``` Deprecation ----------- Deprecated endpoints are tagged with the word `DEPRECATED` at the start of their description. The deprecation message will describe what endpoints/approach should be used instead. Note that deprecated endpoints will not be removed from the current version of the API, but their use is discouraged. Furthermore, migrating to later major versions of the API will be made easier by avoiding deprecated endpoints. Production ---------- This documentation references the staging environment of the Trustap API, which is available at `https://dev.stage.trustap.com` and uses the `trustap-stage` realm during authentication. This environment can be used for implementing and testing features using test credit cards, bank accounts, etc. When all features using Trustap have been implemented and tested sufficiently, the production environment of the Trustap API can be used to process actual currency. This environment is available at `https://dev.trustap.com` and uses the `trustap` realm during authentication. Note that only your client ID will be the same in the staging and production Trustap API environments; your client secret and API key will be different in the two environments. title: Trustap API version: 0.1.0 paths: /batch/transactions: get: description: | This endpoint takes a required `ids` parameter that contains a comma-separated list of transaction IDs, and returns the transactions corresponding to those IDs. A maximum of 50 IDs may be provided, results are returned in the order specified in `ids`, and duplicates are preserved. Transactions that couldn't be found will be returned as `null` values in the result array. The following example request results in the `200 OK` response described below, assuming that the transaction with ID `1990` couldn't be found: ``` http https://dev.stage.trustap.com/api/v1/batch/transactions?ids=1309,609,1990,609 ``` operationId: basic.getTransactionsByIds parameters: - description: | A comma-separated list of transaction IDs in: query name: ids required: true type: string responses: 200: description: OK schema: items: $ref: '#/definitions/basic.Transaction' example: - charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created - buyer_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 charge: 78 created: 2018-12-25T09:00:00Z currency: eur description: Soccer ticket id: 609 join_code: c9cd6a9d-1096-4d38-b4aa-2c354beac845 price: 1234 status: created - null - buyer_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 charge: 78 created: 2018-12-25T09:00:00Z currency: eur description: Soccer ticket id: 609 join_code: c9cd6a9d-1096-4d38-b4aa-2c354beac845 price: 1234 status: created type: array 400: description: | Bad Request `code` can be one of the following: * `ids_missing` * `invalid_id` * `too_many_ids` schema: $ref: '#/definitions/Error' example: code: ids_missing error: '`ids` query parameter is required' summary: Get multiple online transactions by their IDs tags: - Online Transactions /charge: get: description: | This returns the Trustap fee, in the `currency`'s smallest unit, for a transaction involving goods with the supplied `price`. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. operationId: basic.getCharge parameters: - description: | The currency that the `price` is specified in. in: query name: currency required: true type: string - description: | The price of the goods being sold in this transaction, in the `currency`'s smallest unit. For example, if a trading card is being sold for $12.34 (with `currency` as `usd`), then the request for the charge for this transaction would be `/charge?price=1234¤cy=usd`. format: int64 in: query name: price required: true type: integer - description: | When creating transactions from a multi-use listing, the `quantity` parameter can be provided in order to generate a charge for the given price multiplied by the given quantity. See `/multi_use_listings/{listingId}/create_transaction` for more details. format: int64 in: query name: quantity required: false type: integer - description: | The payment method that will be used to pay for the transaction. This is necessary because different payment methods may result in different fees. The default value is `card`. in: query name: payment_method required: false type: string - in: query name: use_hr_post required: false type: boolean - description: The custom `postage_fee` for the transaction. format: int64 in: query name: postage_fee required: false type: integer - default: 1 description: | The charge config for which the charge amount is computed. format: int64 in: query name: charge_config required: false type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Charge' example: charge: 78 charge_calculator_version: 5 charge_config: 1 charge_seller: 0 currency: eur price: 1234 400: description: | Bad Request `code` can be one of the following: * `currency_missing` * `invalid_price` * `negative_price` * `price_too_low` * `unsupported_currency` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' security: - OAuth2: [] - APIKey: [] summary: Get the Trustap fee for an online transaction tags: - Online Payment /client/supported_registration_countries: get: operationId: client.getSupportedRegistrationCountries responses: 200: description: OK schema: items: type: string type: array summary: Get supported registration countries for the current client tags: - Clients /clients/{client_id}/transactions: post: operationId: basic_client.getTransactions parameters: - in: path name: client_id required: true type: string - format: int64 in: query minimum: 1 name: page required: false type: integer - format: int64 in: query minimum: 1 name: page_size required: false type: integer - in: body name: body required: true schema: properties: carrier: type: string currency: type: string date_created_from: type: string date_created_to: type: string date_funds_released_from: type: string descr: type: string exclude_status: type: string handle_tracking: type: boolean quantity: type: integer search_by_user_ids: items: type: string type: array sort_by_name: type: string sort_by_order: type: string statuses: items: type: string type: array total_price: type: string tracking_code: type: string tx_id: type: integer type: object responses: 200: description: Returns paginated list of transactions for a client schema: $ref: '#/definitions/basic.TransactionPage' 400: description: | Bad Request `code` can be one of the following: * `invalid_page` * `page_value_too_low` * `invalid_page_size` * `excessive_page_size` * `page_size_value_too_low` * `sort_by_incorrect_format` 404: description: Not Found summary: Get transactions by page /clients/{client_id}/transactions/{transaction_id}: get: operationId: basic_client.getTransaction parameters: - in: path name: client_id required: true type: string - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_id` schema: $ref: '#/definitions/Error' 403: description: Unauthorized 404: description: Not Found summary: Get an online transaction by its ID as a specific client tags: - Online Transactions /guest_users: post: description: "This endpoint creates guest user which can be used as the buyer or the seller.\nIf guest user is used as the seller in a transaction, they need to be created with\n`country_code` parameter correctly set. This is important because of currencies\nthey can use in their transactions.\n`tos_acceptance` is the parameter which is important for disputes/chargeback and \nrepresent the timestamp when Trustap ToS were accepted https://www.trustap.com/terms.\n" operationId: users.createGuestUser parameters: - in: body name: create_guest_user_body required: true 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: '#/definitions/users.TosAcceptance' required: - email - first_name - last_name - tos_acceptance type: object responses: 201: description: Created schema: $ref: '#/definitions/users.GuestUser' 400: description: | Bad Request `code` can be one of the following: * `email_missing` * `first_name_missing` * `last_name_missing` * `tos_acceptance_ip_missing` * `invalid_country_code` * `invalid_email` * `invalid_tos_acceptance_date` summary: Create a new guest user tags: - Buyers and Sellers /me/account_session: get: operationId: personal.getAccountSession responses: 201: description: OK schema: example: client_secret: accs_secret__*********************************************** properties: client_secret: type: string required: - client_secret type: object summary: Create an account session and retrieve the client secret for it tags: - Personal /me/balances: get: consumes: - application/json operationId: users.getBalances produces: - application/json responses: 200: description: OK schema: $ref: '#/definitions/users.Balances' 400: description: Bad Request schema: $ref: '#/definitions/Error' summary: Get the balance for the current user in each currency tags: - Buyers and Sellers /me/carriers/{carrier_id}/facilities: get: operationId: basic.getCarrierFacilityOptions parameters: - in: path name: carrier_id required: true type: string - in: body name: get_carrier_facility_options required: true schema: example: country: HR delivery_type: parcel_locker search_text: Zagreb properties: country_code: description: | ISO 3166-1 alpha-2 country code. type: string delivery_type: description: | The type of delivery or collection method we want to get options from. `delivery_type` can be one of the following: * `parcel_locker` * `post_office` type: string search_text: description: | Filter text that is used to search available facilities. It can include `City`, `Postal Code` or a string contained within Facility name. type: string required: - country_code - search_text - delivery_type type: object responses: 200: description: OK schema: example: address: 123 Street 1 Zabreb, Croatia city: Zagreb facility_type: post_office name: Zagreb Main Office postal_code: 123456HR items: $ref: '#/definitions/basic.CarrierFacility' type: array 400: description: | Bad Request `code` can be one of the following: * `invalid_carrier` * `invalid_delivery_type` schema: $ref: '#/definitions/Error' example: code: invalid_carrier error: '`carrier` is not a supported carrier' summary: Get the list of facilities for a given carrier tags: - Online Shipping /me/debit_account: get: operationId: personal.getDebitAccount responses: 200: description: OK schema: $ref: '#/definitions/personal.DebitAccount' summary: Get debit account details tags: - Personal post: operationId: personal.setDebitAccount parameters: - in: body name: set_debit_account_body required: true schema: properties: bank_details: $ref: '#/definitions/personal.BankDetails' bank_token: type: string card_details: type: string type: enum: - bank - bank_token - card type: string required: - type type: object responses: 200: description: OK schema: $ref: '#/definitions/personal.DebitAccount' 400: description: | Bad Request `code` can be one of the following: * `routing_number_invalid`: The routing number is invalid. * `account_number_invalid`: The account number is invalid. * `parameter_missing`: Parameter is missing. * `invalid_account_type`: The given debit account type is invalid. * `bank_account_unusable`: The bank account is unusable. * `bank_details_missing`: The bank details are missing. * `bank_token_missing`: The bank token is missing. * `card_details_missing`: The card details are missing. summary: Set debit account details tags: - Personal /me/features: get: consumes: - application/json operationId: users.getUserFeatures produces: - application/json responses: 200: description: OK schema: $ref: '#/definitions/users.Features' 400: description: Bad Request schema: $ref: '#/definitions/Error' summary: Get the status enabled/disabled of user's features tags: - Buyers and Sellers /me/features/instant_payouts: post: operationId: users.setInstantPayouts parameters: - in: body name: set_instant_payouts_body required: true schema: properties: enabled: type: boolean required: - enabled type: object responses: 200: description: OK schema: $ref: '#/definitions/users.Features' 400: description: Bad Request schema: $ref: '#/definitions/Error' summary: Allow users to turn instant payouts feature on/off tags: - Buyers and Sellers /me/instant_payout_balance: get: operationId: personal.getInstantPayoutBalance responses: 200: description: OK schema: $ref: '#/definitions/personal.InstantPayoutBalance' summary: Get instant payout balance tags: - Personal /me/multi_use_listings/create: post: deprecated: true description: | Multi-use listings are disabled once payment has been submitted for a transaction created from it. Offline access is allowed for this endpoint when the user has granted the `basic_ls:offline_create` scope to the client that is performing the request. operationId: basic.createMultiUseListing parameters: - in: body name: create_multi_use_listing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur description: Soccer ticket price: 1234 role: seller properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' description: description: | A description of the goods being sold. type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer role: $ref: '#/definitions/basic.Role' required: - role - currency - price - description - charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 400: description: | Bad Request `code` can be one of the following: * `invalid_role`: '' is not a valid role * `incorrect_charge` * `incorrect_charge_seller` schema: $ref: '#/definitions/Error' summary: Create a new multi-use listing for the logged-in user tags: - Online Multi-use Listings /me/notifications: get: operationId: app_notifs.getNotifications parameters: - description: | Only return transactions that were created chronologically before the transaction with this ID format: int64 in: query minimum: 0 name: before_id type: integer - description: | Only return notifications that were created chronologically after the notification with this ID (i.e. with smaller IDs) format: int64 in: query minimum: 0 name: after_id type: integer - default: 25 description: | The maximum number of notifications to return format: int64 in: query maximum: 50 minimum: 1 name: limit type: integer responses: 200: description: OK schema: items: $ref: '#/definitions/app_notifs.Notification' example: created: 2019-12-25T10:00:00Z description: Buyer has joined transaction for 'Soccer ticket' id: 1990 target: basic/1309 user_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 type: array 400: description: | Bad Request `code` can be one of the following: * `invalid_before_id` * `invalid_after_id` * `invalid_limit` schema: $ref: '#/definitions/Error' example: code: invalid_after_id error: invalid after id summary: Get the notifications for the logged-in user tags: - Notifications /me/payout_attempts: get: description: | Payout attempts are returned in reverse chronological order - the first attempt in the returned array will be the most recent payout attempt. operationId: personal.getPayoutAttempts responses: 200: description: OK schema: items: $ref: '#/definitions/personal.PayoutAttempt' type: array summary: Get the payout attempts that have occurred for this account tags: - Personal /me/personal/additional_identity_document/verification_status: get: operationId: getAdditionalIdentityDocumentVerificationStatus responses: 200: description: OK schema: $ref: '#/definitions/DocumentVerification' summary: Get the verification status for the front side of the secondary identity document tags: - Personal /me/personal/additional_identity_document_back/verification_status: get: operationId: getAdditionalIdentityDocumentBackVerificationStatus responses: 200: description: OK schema: $ref: '#/definitions/DocumentVerification' summary: Get the verification status for the back side of the secondary identity document tags: - Personal /me/personal/details: get: operationId: personal.getDetails responses: 200: description: OK schema: $ref: '#/definitions/personal.Details' summary: Get personal details for the local user tags: - Personal patch: operationId: personal.setDetails parameters: - in: body name: set_details required: true schema: properties: address_city: type: string address_line1: type: string address_line2: type: string address_postal_code: type: string address_state: type: string dob: properties: day: type: integer month: type: integer year: type: integer required: - day - month - year type: object id_number: description: The full ID number for this user. type: string x-nullable: true name_first: type: string name_last: type: string phone: properties: dial_code: type: string dial_code_country: description: This field is mostly non-functional, but is instead used to render the dial code for the user. This field is necessary because different countries may use the same dial code (for example, the US and Canada). type: string number: type: string required: - dial_code_country - dial_code - number type: object x-nullable: true type: object responses: 200: description: OK schema: $ref: '#/definitions/personal.Details' summary: Set personal details for the local user tags: - Personal /me/personal/identity_document/verification_status: get: operationId: getIdentityDocumentVerificationStatus responses: 200: description: OK schema: $ref: '#/definitions/DocumentVerification' summary: Get the verification status for the front side of the primary identity document tags: - Personal /me/personal/identity_document_back/verification_status: get: operationId: getIdentityDocumentBackVerificationStatus responses: 200: description: OK schema: $ref: '#/definitions/DocumentVerification' summary: Get the verification status for the back side of the primary identity document tags: - Personal /me/personal/stripe_publishable_key: get: description: | Returns the Publishable Key for the Stripe Platform which the user is linked to. operationId: getStripePublishableKeyForUser responses: 200: description: OK schema: example: publishable_key: pk_xXxXxXxXxXx properties: publishable_key: type: string type: object summary: | Get the details for the Stripe publishable key the user is linked to tags: - Personal /me/profile/payout_status: get: description: | This endpoint requires the user identified by the `Trustap-User` header to have granted the `profile` scope to the client that is performing the request. Offline access is allowed for this endpoint when the user has granted the `profile` scope to the client that is performing the request. operationId: getProfilePayoutStatus parameters: - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string responses: 200: description: OK schema: $ref: '#/definitions/ProfilePayoutStatus' security: - APIKey: [] - OAuth2: [] summary: | Get the status of a user's ability to accept payouts tags: - Personal /me/single_use_listings/create: post: deprecated: true description: | Single-use listings are disabled once payment has been submitted for a transaction created from it. Offline access is allowed for this endpoint when the user has granted the `basic_ls:offline_create` scope to the client that is performing the request. operationId: basic.createSingleUseListing parameters: - in: body name: create_single_use_listing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur description: Soccer ticket price: 1234 role: seller properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' description: description: | A description of the goods being sold. type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer role: $ref: '#/definitions/basic.Role' required: - role - currency - price - description - charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 400: description: | Bad Request `code` can be one of the following: * `invalid_role`: '' is not a valid role * `incorrect_charge` * `incorrect_charge_seller` summary: Create a new single-use listing for the logged-in user tags: - Online Single-use Listings /me/stripe_financial_connections/add_account: post: operationId: personal.addStripeFinancialConnectionsAccount parameters: - in: body name: body required: true schema: properties: payment_method_id: type: string required: - payment_method_id type: object responses: 200: description: OK schema: $ref: '#/definitions/personal.DebitAccount' summary: Add a new payout method to the current account using a payment method ID tags: - Personal /me/stripe_financial_connections/ownership: get: operationId: personal.getStripeFinancialConnectionsOwnership parameters: - in: query name: setup_intent_id required: true type: string responses: 200: description: OK schema: properties: email: type: string name: type: string raw_address: type: string raw_phone: type: string required: - name - email - raw_phone - raw_address type: object 409: description: | Conflict `code` can be one of the following: * `unconfirmed_setup_intent`: The given SetupIntent has not been confirmed summary: Get the ownership details from the given SetupIntent using Stripe Financial Connections tags: - Personal /me/stripe_financial_connections/prepare_account: post: operationId: personal.prepareStripeFinancialConnectionsAccount responses: 200: description: OK schema: properties: setup_intent_client_secret: type: string setup_intent_id: type: string required: - setup_intent_id - setup_intent_client_secret type: object summary: | Get a SetupIntent ID and secret for starting a Stripe Financial Connections session tags: - Personal /me/transactions: get: description: | Transactions are currently sorted by ID. operationId: basic.getTransactions parameters: - description: | Only return transactions that were created chronologically before the transaction with this ID format: int64 in: query minimum: 0 name: before_id type: integer - description: | Only return transactions that were created chronologically after the transaction with this ID (i.e. with smaller IDs) format: int64 in: query minimum: 0 name: after_id type: integer - default: 25 description: | The maximum number of transactions to return format: int64 in: query maximum: 50 minimum: 1 name: limit type: integer responses: 200: description: OK schema: example: - charge: 78 charge_seller: 0 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created - buyer_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 charge: 78 charge_seller: 0 created: 2018-12-25T09:00:00Z currency: eur description: Soccer ticket id: 609 join_code: c9cd6a9d-1096-4d38-b4aa-2c354beac845 price: 1234 status: created items: $ref: '#/definitions/basic.Transaction' type: array 400: description: | Bad Request `code` can be one of the following: * `invalid_before_id` * `invalid_after_id` * `invalid_limit` schema: $ref: '#/definitions/Error' example: code: invalid_after_id error: invalid after id summary: Get online transactions for the logged-in user tags: - Online Transactions post: description: | A request to this endpoint must be preceded by a call to `/charge` with the price of the goods specified in `price`. operationId: basic.createTransaction parameters: - in: body name: create_transaction_body required: true schema: example: charge: 78 charge_seller: 0 client_id: test-auth created: 2025-08-28T11:47:44.134539654Z currency: eur description: Little Fish id: 1 is_payment_in_progress: false join_code: 02e591b3-e80d-4ed8-927e-743df1a0cc22 price: 1234 quantity: 1 seller_id: 45e2537a-a9f4-4b4e-9f90-3761cfd4f35b status: created properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_config: description: | The charge config for which the charge amount is computed. format: int64 type: integer charge_seller: description: | The seller `charge` value returned from a request to `/charge`. format: int64 type: integer client_id: type: string currency: description: | The currency that the `price` is specified in. type: string description: description: | A description of the goods being sold. type: string features: description: | `features` contains flags that modify the transaction flow. items: $ref: '#/definitions/basic.Feature' type: array payment_method: description: | The payment method to use for the transaction. type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer role: $ref: '#/definitions/basic.Role' required: - role - currency - price - description - charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created 400: description: | Bad Request `code` can be one of the following: * `incorrect_calc_version` * `incorrect_charge` * `incorrect_charge_seller` * `invalid_calc_version` * `negative_price` * `price_too_low` * `invalid_charge_config` schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new online transaction tags: - Online Transactions /me/transactions/create_and_join: post: description: | This endpoint is an optimised call that allows a transaction to be created and joined in a single request. It requires the user identified by `join_user_id` to have granted the `basic_tx:offline_create_join` scope to the client that is performing the request. operationId: basic.createAndJoinTransaction parameters: - in: body name: create_transaction_body required: true schema: example: charge: 78 charge_calculator_version: 5 charge_config: 1 creator_role: seller currency: eur description: Soccer ticket join_user_id: feb33a87-3917-4538-9260-127c8a6b5232 payment_method: bank_transfer price: 1234 role: seller properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_config: default: 1 description: | The charge config for which the charge amount is computed. format: int64 type: integer charge_seller: description: | The seller `charge` value returned from a request to `/charge`. format: int64 type: integer client_id: type: string creator_role: $ref: '#/definitions/basic.Role' description: | This is the role that will be given to the user making the request; the user specified by `join_user_id` will be given the complementary role. currency: description: | The currency that the `price` is specified in. type: string description: description: | A description of the goods being sold. type: string features: description: | `features` contains flags that modify the transaction flow. items: $ref: '#/definitions/basic.Feature' type: array join_user_id: description: | The user that will be joined to the new transaction when it is created. It cannot be the ID of the user making the request. type: string payment_method: description: | The payment method to use for the transaction. type: string postage_fee: description: The custom `postage_fee` for the transaction. format: int64 type: integer price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - join_user_id - creator_role - currency - price - description - charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_join_user_id` * `duplicate_user_id`: The user specified by `join_user_id` is the user making the request. * `incorrect_calc_version` * `incorrect_charge` * `incorrect_charge_seller` * `unsupported_currency` * `user_not_owned_by_client` * `invalid_calc_version` * `negative_price` * `price_too_low` * `user_already_joined` * `already_cancelled` * `feature_not_found` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new online transaction with both users tags: - Online Transactions /me/transactions/create_with_guest_user: post: description: | This endpoint is an optimised call that allows a transaction to be created and joined in a single request. It requires the online user to have granted the `basic_tx:offline_create_join` scope to the client that is performing the request. This endpoint allows creating a transaction with both buyer and seller as guest or full users, or one party to be guest user and the other full user. operationId: basic.createTransactionWithGuestUser parameters: - in: body name: create_transaction_with_guest_user_body required: true schema: example: - buyer_id: 1-bd5bb99j-95bf-87e2-ce0d-95e7541c6ad5 charge: 78 charge_calculator_version: 5 charge_config: 1 charge_seller: 0 creator_role: seller currency: eur description: Soccer ticket payment_method: bank_transfer price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 properties: buyer_id: description: | The id of the buyer for this transaction (it can be full user id or guest user id). type: string charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_config: default: 1 description: | The charge config for which the charge amount is computed. format: int64 type: integer charge_seller: description: | The seller `charge` value returned from a request to `/charge`. format: int64 type: integer client_id: type: string creator_role: $ref: '#/definitions/basic.Role' description: | This is the role that will be given to the user making the request; the user specified by `join_user_id` will be given the complementary role. currency: $ref: '#/definitions/Currency' description: description: | A description of the goods being sold. type: string features: description: | `features` contains flags that modify the transaction flow. items: $ref: '#/definitions/basic.Feature' type: array image_url: description: | URL of the image displayed on the Trustap payment page to show the buyer the item they are paying for. Supports jpg, png, gif, bmp, webp and svg files. Images displayed as a squares. Non-square images are cropped. format: absolute_url maxLength: 2047 type: string payment_method: description: | The payment method to use for the transaction. type: string postage_fee: description: | The custom `postage fee`, this fee only applies in the case `postage fee feature flag` is enabled. format: int64 type: integer price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer seller_id: description: | The id of the seller for this transaction (it can be full user id or guest user id). type: string required: - buyer_id - seller_id - creator_role - currency - price - description - charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: bd5bb99f-85bf-47e1-be0d-15e7541c6ad9 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T09:01:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `incorrect_calc_version` * `incorrect_charge` * `incorrect_charge_seller` * `invalid_calc_version` * `negative_price` * `price_too_low` * `incompatible_countries` * `unsupported_currency` * `invalid_role` * `no_guest_user` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. * `invalid_image_url` * `image_url_too_long` schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new online transaction with both users tags: - Online Transactions /me/verification_method: get: operationId: personal.getVerificationMethod responses: 200: description: OK schema: example: message: not_available verification_method: stripe_identity properties: message: type: string verification_method: type: string required: - verification_method - message type: object 409: description: | Conflict `code` can be one of the following: * `user_is_company`: Verification sessions aren't yet supported for users with a `business_type` of `company`. summary: | Create verification method and message if not available tags: - Personal /me/verification_session: get: description: Offline access is allowed for this endpoint when the user has granted the `profile` scope to the client that is performing the request. operationId: personal.getVerificationSession responses: 201: description: OK schema: example: verification_session_client_secret: vs_1P**********************_******_****_********************************************************************************0PVs properties: verification_session_client_secret: type: string required: - verification_session_client_secret type: object 400: description: | Bad Request `code` can be one of the following: * `stripe_identity_not_available`: stripe identity is currently not available for this account. 409: description: | Conflict `code` can be one of the following: * `user_is_company`: Verification sessions aren't yet supported for users with a `business_type` of `company`. summary: | Create verification session and retrieve client secret for it tags: - Personal /me/verification_session_native: get: description: "Creates verification session for native apps that use Stripe native SDK, \nand returns it's `Verification Session ID` with appropriate `Ephemeral Key`.\nOffline access is allowed for this endpoint when the user has\ngranted the `profile` scope to the client that is performing the request.\n" operationId: personal.getVerificationSessionNative responses: 201: description: OK schema: properties: ephemeral_key: type: string verification_session_id: type: string required: - verification_session_id - ephemeral_key type: object 400: description: | Bad Request `code` can be one of the following: * `stripe_identity_not_available`: stripe identity is currently not available for this account. 409: description: | Conflict `code` can be one of the following: * `user_is_company`: Verification sessions aren't yet supported for users with a `business_type` of `company`. summary: Create verification session for native apps that use Stripe native SDK tags: - Personal /me/verification_status: get: description: Offline access is allowed for this endpoint when the user has granted the `profile` scope to the client that is performing the request. operationId: personal.getVerificationStatus responses: 200: description: OK schema: example: verification_session_id: vs_1PH0bmDnTEntFpTD2xDXZy9t verification_session_status: created properties: verification_session_id: type: string verification_session_last_error: $ref: '#/definitions/personal.VerificationSessionLastError' verification_session_status: type: string required: - verification_session_id - verification_session_status type: object summary: | Get verification status of the user tags: - Personal /multi_use_listings/{listing_id}: delete: deprecated: true operationId: basic.deleteMultiUseListing parameters: - in: path name: listing_id required: true type: string responses: 204: description: No Content 404: description: Not Found summary: Delete this listing tags: - Online Multi-use Listings get: deprecated: true operationId: basic.getMultiUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 id: 77f36253-7a43-4d47-897d-f73dd208e17a 404: description: Not Found summary: Get a listing by its ID tags: - Online Multi-use Listings patch: deprecated: true operationId: basic.updateMultiUseListing parameters: - in: path name: listing_id required: true type: string - in: body name: patch_listing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur description: Soccer ticket price: 1234 properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' description: type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: true 400: description: | Bad Request `code` can be one of the following: * `empty_body`: The request body is empty. * `partial_pricing`: When updating a pricing field, all 3 of `currency`, `price` and `charge` must be supplied. 404: description: Not Found summary: Patch listing properties tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/create_transaction: post: deprecated: true description: | Calling `/create_transaction` with no parameters will create a new transaction with the details provided by the listing. The optional `quantity` parameter can be passed to create a transaction for a multiple of the original listing. In this case, the `price` and `charge` for the new transaction will also need to be passed. As an example, consider a listing for a chair with a price of `1234` `EUR`. If a user wants to buy 10 of these in a single transaction then the charge for the total can be retrieved using `GET /charge?price=1234¤cy=usd&quantity=10` (note the addition of the optional quantity parameter at the end). This will return a `price` of `12340` and an associated `charge`. These new values must then be passed to `/create_transaction` with `quantity=10`, which will create a new transaction with the new pricing information. The new transaction will also include a `quantity` field, which doesn't have a functional effect on the transaction, but is included for informational purposes. Note that this functionality is not available for single-use listings, from which only singular transactions may be created. operationId: basic.createTransactionFromMultiUseListing parameters: - in: path name: listing_id required: true type: string - format: int64 in: query name: quantity required: false type: integer - format: int64 in: query name: price required: false type: integer - format: int64 in: query name: charge required: false type: integer - in: query name: payment_method required: false type: string - format: int64 in: query name: charge_config required: false type: integer responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 charge_seller: 0 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: multi_use price: 1234 quantity: 10 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `no_listing_currency`: The source listing doesn't have a currency. * `no_listing_price`: The source listing doesn't have pricing. * `no_listing_descr`: The source listing doesn't have a description. * `is_listing_creator`: The current user created this listing. * `invalid_charge_config` schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/create_transaction_with_guest_buyer: post: deprecated: true operationId: basic.createTransactionWithGuestBuyerFromMultiUseListing parameters: - in: path name: listing_id required: true type: string responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 charge_seller: 0 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: multi_use price: 1234 quantity: 10 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `no_listing_currency`: The source listing doesn't have a currency. * `no_listing_price`: The source listing doesn't have pricing. * `no_listing_descr`: The source listing doesn't have a description. * `is_listing_creator`: The current user created this listing. schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/disable: post: deprecated: true description: | Calling `/create_transaction` on a disabled listing will return a `400` response. operationId: basic.disableMultiUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket disabled: 2019-12-25T10:00:00Z id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 404: description: Not found summary: Disable this listing tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/enable: post: deprecated: true operationId: basic.enableMultiUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 404: description: Not found summary: Enable this listing tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/set_description: post: deprecated: true operationId: basic.setMultiUseListingDescription parameters: - in: path name: listing_id required: true type: string - in: body name: description_body required: true schema: example: description: Soccer ticket properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a 404: description: Not Found summary: Set description for this listing tags: - Online Multi-use Listings /multi_use_listings/{listing_id}/set_pricing: post: deprecated: true operationId: basic.setMultiUseListingPricing parameters: - in: path name: listing_id required: true type: string - in: body name: create_pricing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur price: 1234 properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - price - charge - charge_calculator_version type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.MultiUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a 404: description: Not Found summary: Set pricing for this listing tags: - Online Multi-use Listings /notifications/{notification_id}: get: operationId: app_notifs.getNotification parameters: - format: int64 in: path name: notification_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/app_notifs.Notification' example: created: 2019-12-25T10:00:00Z description: Buyer has joined transaction for 'Soccer ticket' id: 1990 target: basic/1309 user_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 404: description: Not Found summary: Get a notification by its ID tags: - Notifications /notifications/{notification_id}/mark_as_read: post: operationId: app_notifs.markNotificationAsRead parameters: - format: int64 in: path name: notification_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/app_notifs.Notification' example: created: 2019-12-25T10:00:00Z description: Buyer has joined transaction for 'Soccer ticket' id: 1990 read: 2019-12-25T11:00:00Z target: basic/1309 user_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 404: description: Not Found summary: Mark this notification as read tags: - Notifications /p2p/batch/transactions: get: description: | This endpoint takes a required `ids` parameter that contains a comma-separated list of transaction IDs, and returns the transactions corresponding to those IDs. A maximum of 50 IDs may be provided, and results are returned in the order specified in `ids`, and duplicates are preserved. Transactions that couldn't be found will be returned as `null` values in the result array. The following example request results in the `200 OK` response described below, assuming that the transaction with ID `1990` couldn't be found: ``` http https://dev.stage.trustap.com/api/v1/p2p/batch/transactions?ids=1309,609,1990,609 ``` operationId: getP2pTransactionsByIds parameters: - description: | A comma-separated list of transaction IDs in: query name: ids required: true type: string responses: 200: description: OK schema: items: $ref: '#/definitions/p2p.Transaction' example: - buyer_handover_confirmed: 2019-12-25T16:00:00Z buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket funds_released: 2019-12-25T17:00:00Z id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_handover_confirmed: 2019-12-25T15:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: funds_released - buyer_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 created: 2018-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 609 join_code: c9cd6a9d-1096-4d38-b4aa-2c354beac845 skip_remainder: false status: created - null - buyer_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 created: 2018-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 609 join_code: c9cd6a9d-1096-4d38-b4aa-2c354beac845 skip_remainder: false status: created type: array 400: description: | Bad Request `code` can be one of the following: * `ids_missing` * `invalid_id` * `too_many_ids` schema: $ref: '#/definitions/Error' example: code: ids_missing error: '`ids` query parameter is required' summary: Get multiple face-to-face transactions by their IDs tags: - F2F Transactions /p2p/charge: get: description: | This returns the Trustap fee, in the `currency`'s smallest unit, for a transaction involving goods with the supplied `price`. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. operationId: p2p.getCharge parameters: - description: | The currency that the `price` is specified in. in: query name: currency required: true type: string - description: | The price of the goods being sold in this transaction, in the `currency`'s smallest unit. For example, if a trading card is being sold for $12.34 (with `currency` as `usd`), then the request for the charge for this transaction would be `/p2p/charge?price=1234¤cy=usd`. format: int64 in: query name: price required: true type: integer - description: | The `fee_multiplier` parameter is used to apply a higher percentage fee based on the total price of the transaction. The percentage fee is calculated multiplying the `percentage fee` by the `fee_multiplier`. format: double in: query name: fee_multiplier required: false type: number - description: | When creating transactions from a multi-use listing, the `quantity` parameter can be provided in order to generate a charge for the given price multiplied by the given quantity. See `/p2p/multi_use_listings/{listingId}/create_transaction` for more details. format: int64 in: query name: quantity required: false type: integer - description: | The payment method that will be used to pay for the transaction. This is necessary because different payment methods may result in different fees. The default value is `card`. in: query name: payment_method required: false type: string - default: 1 description: | The charge config for which the charge amount is computed. format: int64 in: query name: charge_config required: false type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Charge' example: charge: 78 charge_calculator_version: 2 charge_config: 1 currency: eur 400: description: | Bad Request `code` can be one of the following: * `currency_missing` * `invalid_price` * `negative_price` * `price_too_low` * `unsupported_currency` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' security: - OAuth2: [] - APIKey: [] summary: Get the Trustap fee for a face-to-face transaction tags: - F2F Payment /p2p/clients/{client_id}/transactions: post: operationId: p2p_client.getTransactions parameters: - in: path name: client_id required: true type: string - format: int64 in: query minimum: 1 name: page required: false type: integer - format: int64 in: query minimum: 1 name: page_size required: false type: integer - in: body name: body required: true schema: properties: currency: type: string date_created_from: type: string date_created_to: type: string date_funds_released_from: type: string descr: type: string exclude_status: type: string quantity: type: integer search_by_user_ids: items: type: string type: array skip_remainder: type: boolean sort_by_name: type: string sort_by_order: type: string statuses: items: type: string type: array total_price: type: string tx_id: type: integer type: object responses: 200: description: Returns paginated list of p2p transactions for a client schema: $ref: '#/definitions/p2p.TransactionPage' 400: description: | Bad Request `code` can be one of the following: * `invalid_page` * `page_value_too_low` * `invalid_page_size` * `excessive_page_size` * `page_size_value_too_low` * `sort_by_incorrect_format` 404: description: Not Found summary: Get p2p transactions by page for a client /p2p/clients/{client_id}/transactions/{transaction_id}: get: operationId: p2p_client.getTransaction parameters: - in: path name: client_id required: true type: string - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_id` schema: $ref: '#/definitions/Error' 403: description: Unauthorized 404: description: Not Found summary: Get a face-to-face transaction by its ID as a specific client tags: - F2F Transactions /p2p/listings/create_with_seller: post: operationId: p2p.createWithSeller parameters: - in: body name: create_with_seller_body required: true schema: properties: ad_id: description: | Unique ID for the product or service. Not used by Trustap internally, but returned in webhook events. type: string currency: $ref: '#/definitions/p2p.Currency' description: description: | Description of the product or service. This description is shown in all emails and payment screens. type: string image_url: description: | URL of the image displayed on the Trustap payment page to show the buyer the item they are paying for. Supports jpg, png, gif, bmp, webp and svg files. Images displayed as a squares. Non-square images are cropped. format: absolute_url maxLength: 2047 type: string seller_country_code: description: | ISO 4217 three-character currency code representing the currency of the transaction. type: string seller_email: description: | Valid email address of your seller. Ensure this email is correct as Trustap will send all transaction correspondence to this email. type: string seller_phone_number: description: | Phone number of seller. type: string value: description: | The price of the product or service. This value must be provided in a currency's smallest unit. format: int64 type: integer required: - seller_email - currency - description - value - ad_id - seller_country_code type: object responses: 201: description: Created schema: $ref: '#/definitions/p2p.ActionsUrl' 400: description: | Bad Request `code` can be one of the following: * `invalid_role`: '' is not a valid role * `invalid_image_url`: '' is not a valid image url * `image_url_too_long` summary: | Creates a transaction with guest seller and returns actions page url tags: - Trustap Lite /p2p/me/multi_use_listings/create: post: deprecated: true description: | Multi-use listings can be used to create transactions. Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_create` scope to the client that is performing the request. operationId: createP2PMultiUseListingWithDetails parameters: - in: body name: create_multi_use_listing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 description: Soccer ticket role: seller properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer description: description: | A description of the goods being sold. type: string role: $ref: '#/definitions/basic.Role' skip_remainder: description: | If `skip_remainder` is `true` then the transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean required: - role - description - currency - deposit_price - deposit_charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 400: description: | Bad Request `code` can be one of the following: * `invalid_role`: '' is not a valid role summary: | Create a new multi-use, face-to-face listing for the logged-in user tags: - F2F Multi-use Listings /p2p/me/single_use_listings/create: post: deprecated: true description: | Single-use listings are disabled once the remainder has been paid for a transaction created from it. Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_create` scope to the client that is performing the request. operationId: createP2PSingleUseListingWithDetails parameters: - in: body name: create_single_use_listing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 description: Soccer ticket role: seller properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The deposit price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer description: description: | A description of the goods being sold. type: string role: $ref: '#/definitions/basic.Role' skip_remainder: description: | If `skip_remainder` is `true` then the transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean required: - role - description - currency - deposit_price - deposit_charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 400: description: | Bad Request `code` can be one of the following: * `invalid_role`: '' is not a valid role summary: | Create a new single-use, face-to-face listing for the logged-in user tags: - F2F Single-use Listings /p2p/me/transactions: get: description: | Transactions are currently sorted by ID. operationId: p2p.getTransactions parameters: - description: | Only return transactions that were created chronologically before the transaction with this ID format: int64 in: query minimum: 0 name: before_id type: integer - description: | Only return transactions that were created chronologically after the transaction with this ID (i.e. with smaller IDs) format: int64 in: query minimum: 0 name: after_id type: integer - default: 25 description: | The maximum number of transactions to return format: int64 in: query maximum: 50 minimum: 1 name: limit type: integer responses: 200: description: OK schema: example: - client_id: test-auth created: 2025-11-03T09:37:47Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 156 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false quantity: 1 seller_id: 1d9a9af7-b57b-4c48-a56f-86fe328f9682 seller_is_guest: false skip_remainder: false status: created - client_id: test-auth created: 2025-11-03T09:37:47Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 155 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false quantity: 1 seller_id: 1d9a9af7-b57b-4c48-a56f-86fe328f9682 seller_is_guest: false skip_remainder: false status: created items: $ref: '#/definitions/p2p.Transaction' type: array 400: description: | Bad Request `code` can be one of the following: * `invalid_before_id` * `invalid_after_id` * `invalid_limit` * `excessive_limit` schema: $ref: '#/definitions/Error' example: code: invalid_after_id error: invalid after id summary: Get face-to-face transactions for the logged-in user tags: - F2F Transactions post: description: | Note that this endpoint is similar to `POST /me/transactions` but takes `deposit_price` and `deposit_charge` fields instead of the `price` and `charge` fields. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. operationId: p2p.createTransaction parameters: - in: body name: create_transaction_body required: true schema: example: charge_calculator_version: 2 currency: eur deposit_charge: 78 deposit_charge_config: 1 deposit_payment_method: bank_transfer deposit_price: 1234 description: Soccer ticket role: seller properties: charge_calculator_version: format: int64 type: integer client_id: type: string currency: $ref: '#/definitions/Currency' deposit_charge: format: int64 type: integer deposit_charge_config: description: | The charge config for which the charge amount is computed. format: int64 type: integer deposit_charge_seller: format: int64 type: integer deposit_payment_method: description: | The payment method to use for the transaction. type: string deposit_price: format: int64 type: integer description: description: | A description of the goods being sold. type: string role: $ref: '#/definitions/basic.Role' skip_remainder: description: | If `skip_remainder` is `true` then this transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean required: - role - currency - description - deposit_price - deposit_charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/p2p.Transaction' example: created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: created 400: description: | Bad Request `code` can be one of the following: * `incorrect_calc_version` * `incorrect_charge` * `incorrect_charge_seller` * `invalid_calc_version` * `negative_price` * `price_too_low` * `invalid_charge_config` schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new face-to-face transaction tags: - F2F Transactions /p2p/me/transactions/create_and_join: post: description: | This endpoint is an optimised call that allows a transaction to be created and joined in a single request. It requires the user identified by `join_user_id` to have granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. Note that this endpoint is similar to `POST /me/transactions` but takes `deposit_price` and `deposit_charge` fields instead of the `price` and `charge` fields. operationId: p2p.createAndJoinTransaction parameters: - in: body name: create_transaction_body required: true schema: example: charge_calculator_version: 5 client_id: test-auth creator_role: seller currency: eur deposit_charge: 118 deposit_charge_config: 1 deposit_charge_seller: 0 deposit_payment_method: bank_transfer deposit_price: 1234 description: Little Fish join_user_id: 2-8ab12191-7508-4efe-b65e-51d1bc440ed9 properties: charge_calculator_version: format: int64 type: integer creator_role: $ref: '#/definitions/p2p.Role' description: | This is the role that will be given to the user making the request; the user specified by `join_user_id` will be given the complementary role. currency: $ref: '#/definitions/Currency' deposit_charge: format: int64 type: integer deposit_charge_config: description: | The charge config for which the charge amount is computed. format: int64 type: integer deposit_charge_seller: format: int64 type: integer deposit_fee_multiplier: description: | The `fee_multiplier` parameter is used to apply a higher percentage fee based on the total price of the transaction. The percentage fee is calculated multiplying the `percentage fee` by the `fee_multiplier`. format: double type: number deposit_payment_method: description: | The payment method to use for the transaction. type: string deposit_price: format: int64 type: integer description: description: | A description of the goods being sold. type: string join_user_id: description: | The user that will be joined to the new transaction when it is created. It cannot be the ID of the user making the request. type: string skip_remainder: description: | If `skip_remainder` is `true` then the transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean required: - join_user_id - creator_role - currency - description - deposit_price - deposit_charge - deposit_charge_seller - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 2-8ab12191-7508-4efe-b65e-51d1bc440ed9 buyer_is_guest: false client_id: test-auth created: 2025-06-05T15:14:57Z currency: eur deposit_pricing: charge: 78 charge_seller: 0 price: 1234 description: Little Fish id: 48 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-06-05T15:14:57Z quantity: 1, seller_id: 2-d25a8868-558d-44d0-bd47-d35f9d2ec32f seller_is_guest: false skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_join_user_id` * `unsupported_currency` * `user_not_owned_by_client` * `duplicate_user_id`: The user specified by * `join_user_id` is the user making the request. * `incorrect_charge` * `incorrect_charge_seller` * `second_party_already_joined` * `duplicate_user_id` * `incompatible_countries` * `incompatible_users` * `negative_price` * `price_too_low` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new face-to-face transaction with both users tags: - F2F Transactions /p2p/me/transactions/create_with_guest_user: post: description: | This endpoint is an optimised call that allows a transaction to be created and joined in a single request. It requires the online user to have granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. This endpoint allows creating a transaction with both buyer and seller as guest users, or one party to be guest user and the other full user. operationId: p2p.createTransactionWithGuestUser parameters: - in: body name: create_transaction_body required: true schema: example: buyer_id: 1-ef9664e4-921a-4696-8eaa-d8b2593d9ff9 charge_calculator_version: 3 creator_role: seller currency: eur deposit_charge: 118 deposit_charge_config: 1 deposit_charge_seller: 0 deposit_payment_method: bank_transfer deposit_price: 1234 description: Little Fish seller_id: 1-f40b6944-3c54-405e-9ae3-3fa9d2be9f91 skip_remainder: true properties: buyer_id: description: | The id of the buyer for this transaction (it can be full user id or guest user id). type: string charge_calculator_version: format: int64 type: integer creator_role: $ref: '#/definitions/p2p.Role' description: | This is the role that will be given to the user making the request; the user specified by `join_user_id` will be given the complementary role. currency: $ref: '#/definitions/p2p.Currency' deposit_charge: format: int64 type: integer deposit_charge_config: description: | The charge config for which the charge amount is computed. format: int64 type: integer deposit_charge_seller: format: int64 type: integer deposit_fee_multiplier: description: | The `fee_multiplier` parameter is used to apply a higher percentage fee based on the total price of the transaction. The percentage fee is calculated multiplying the `percentage fee` by the `fee_multiplier`. format: double type: number deposit_payment_method: description: | The payment method to use for the transaction. type: string deposit_price: format: int64 type: integer description: description: | A description of the goods being sold. type: string image_url: description: | URL of the image displayed on the Trustap payment page to show the buyer the item they are paying for. Supports jpg, png, gif, bmp, webp and svg files. Images displayed as a squares. Non-square images are cropped. format: absolute_url maxLength: 2047 type: string seller_id: description: | The id of the seller for this transaction (it can be full user id or guest user id). type: string skip_remainder: description: | If `skip_remainder` is `true` then the transaction will move to the "confirm handover" step after the deposit has been accepted. type: boolean required: - buyer_id - seller_id - creator_role - currency - description - deposit_price - deposit_charge - charge_calculator_version type: object responses: 201: description: Created schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 1-ef9664e4-921a-4696-8eaa-d8b2593d9ff9 buyer_is_guest: true client_id: test-auth created: 2025-05-29T14:48:48Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 deposit_fee_multiplier: fee_multiplier: 1 price: 1234 description: Little Fish id: 47 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-05-29T14:48:48Z quantity: 1 seller_id: 1-f40b6944-3c54-405e-9ae3-3fa9d2be9f91 seller_is_guest: true skip_remainder: true status: joined 400: description: | Bad Request `code` can be one of the following: * `incompatible_platforms` * `no_guest_user` * `invalid_role` * `incorrect_charge` * `unsupported_currency` * `fee_multiplier_too_low` * `negative_price` * `price_too_low` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. * `invalid_image_url` * `image_url_too_long` schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' summary: Create a new face-to-face transaction with both users tags: - F2F Transactions /p2p/multi_use_listings/{listingId}: delete: deprecated: true operationId: deleteP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 204: description: OK 404: description: Not Found summary: Delete this listing tags: - F2F Multi-use Listings get: deprecated: true operationId: getP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: "" id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Get a listing by its ID tags: - F2F Multi-use Listings patch: deprecated: true operationId: patchP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: patch_listing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 description: Soccer ticket skip_remainder: false properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The deposit price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer description: type: string skip_remainder: type: boolean type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 skip_remainder: false 400: description: | Bad Request `code` can be one of the following: * `empty_body`: The request body is empty. 404: description: Not Found summary: Patch listing properties tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/create_transaction: post: deprecated: true description: | Calling `/create_transaction` with no parameters will create a new transaction with the details provided by the listing. The optional `quantity` parameter can be passed to create a transaction for a multiple of the original listing. In this case, the `price` and `charge` for the new transaction will also need to be passed. As an example, consider a listing for a chair with a price of `1234` `EUR`. If a user wants to buy 10 of these in a single transaction then the charge for the total can be retrieved using `GET /p2p/charge?price=1234¤cy=usd&quantity=10` (note the addition of the optional quantity parameter at the end). This will return a `price` of `12340` and an associated `charge`. These new values must then be passed to `/create_transaction` with `quantity=10`, which will create a new transaction with the new pricing information. The new transaction will also include a `quantity` field, which doesn't have a functional effect on the transaction, but is included for informational purposes. Note that this functionality is not available for single-use listings, from which only singular transactions may be created. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. operationId: createTransactionFromP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer - format: int64 in: query name: quantity required: false type: integer - format: int64 in: query name: price required: false type: integer - format: int64 in: query name: charge required: false type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: multi_use quantity: 10 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `is_listing_creator`: The current user created this listing. schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/disable: post: deprecated: true description: | Calling `/create_transaction` on a disabled listing will return a `400` response. Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: disableP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket disabled: 2019-12-25T10:00:00Z id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Disable this listing tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/enable: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: enableP2PMultiUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Enable this listing tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/set_deposit_pricing: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: setP2PMultiUseListingPricing parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: create_pricing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The deposit price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - deposit_price - deposit_charge - charge_calculator_version type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 skip_remainder: false 404: description: Not Found summary: Set pricing for this listing tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/set_description: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: setP2PMultiUseListingDescription parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: description_body required: true schema: example: description: Soccer ticket properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Set the description for this listing tags: - F2F Multi-use Listings /p2p/multi_use_listings/{listingId}/set_skip_remainder: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: setP2PMultiUseListingSkipRemainder parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: skip_remainder_body required: true schema: properties: skip_remainder: type: boolean required: - skip_remainder type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PMultiUseListing' example: allows_multi_use: true created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Set skip remainder for this listing tags: - F2F Multi-use Listings /p2p/single_use_listings/{listingId}: delete: deprecated: true operationId: deleteP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 204: description: OK 404: description: Not Found summary: Delete this listing tags: - F2F Single-use Listings get: deprecated: true operationId: getP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: "" id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Get a listing by its ID tags: - F2F Single-use Listings patch: deprecated: true operationId: patchP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: patch_listing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 description: Soccer ticket skip_remainder: false properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The deposit price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer description: type: string skip_remainder: type: boolean type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 400: description: | Bad Request `code` can be one of the following: * `empty_body`: The request body is empty. 404: description: Not Found summary: Patch listing properties tags: - F2F Single-use Listings /p2p/single_use_listings/{listingId}/create_transaction: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. operationId: createTransactionFromP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: single_use seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `is_listing_creator`: The current user created this listing. schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - F2F Single-use Listings /p2p/single_use_listings/{listingId}/disable: post: deprecated: true description: | Calling `/create_transaction` on a disabled listing will return a `400` response. Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: disableP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket disabled: 2019-12-25T10:00:00Z id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Disable this listing tags: - F2F Single-use Listings /p2p/single_use_listings/{listingId}/enable: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: enableP2PSingleUseListing parameters: - format: int64 in: path name: listingId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Enable this listing tags: - F2F Single-use Listings /p2p/single_use_listings/{listingId}/set_deposit_pricing: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: setP2PSingleUseListingPricing parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: create_pricing_body required: true schema: example: charge_calculator_version: 5 currency: eur deposit_charge: 78 deposit_price: 1234 properties: charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' deposit_charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer deposit_price: description: | The deposit price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - deposit_price - deposit_charge - charge_calculator_version type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 78 price: 1234 id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Set pricing for this listing tags: - F2F Single-use Listings /p2p/single_use_listings/{listingId}/set_description: post: deprecated: true description: Offline access is allowed for this endpoint when the user has granted the `p2p_ls:offline_update` scope to the client that is performing the request. operationId: setP2PSingleUseListingDescription parameters: - format: int64 in: path name: listingId required: true type: integer - in: body name: description_body required: true schema: example: description: Soccer ticket properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/P2PSingleUseListing' example: allows_multi_use: false created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur deposit_pricing: charge: 150 price: 5000 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a skip_remainder: false 404: description: Not Found summary: Set the description for this listing tags: - F2F Single-use Listings /p2p/transactions/{transaction_id}: get: operationId: p2p.getTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined summary: Get a face-to-face transaction by its ID tags: - F2F Transactions patch: operationId: updateF2fTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: edit_f2f_transaction_body required: true schema: example: currency: eur deposit_charge: 78 deposit_price: 1234 description: Soccer ticket properties: currency: $ref: '#/definitions/Currency' deposit_charge: format: int64 type: integer deposit_price: format: int64 type: integer description: description: | A description of the goods being sold. type: string type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: created 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `second_party_already_joined` * `values_not_changed` schema: $ref: '#/definitions/Error' 403: description: Forbidden 404: description: Not Found summary: Update the description, currency, price and/or charge of this face-to-face transaction tags: - F2F Payment /p2p/transactions/{transaction_id}/accept_complaint: post: operationId: p2p.acceptComplaint parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 complained: 2019-12-25T15:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket funds_released: 2019-12-25T17:00:00Z id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: funds_released 400: description: | Bad Request `code` can be one of the following: * `funds_already_released` * `deposit_not_paid` * `deposit_already_refunded` * `not_complained` 404: description: Not Found summary: Accept a complaint for this face-to-face transaction tags: - F2F Complaint /p2p/transactions/{transaction_id}/accept_deposit: post: description: Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_accept_deposit` scope to the client that is performing the request. operationId: p2p.acceptDeposit parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 785f384d-3203-448d-adbf-9e67330be65f buyer_is_guest: false client_id: test-auth created: "2025-11-03T15:20:08Z" currency: eur deposit_accepted: "2025-11-03T15:20:08Z" deposit_paid: "2025-11-03T15:20:08Z" deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 138, is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: "2025-11-03T15:20:08Z" quantity: 1 seller_id: 75ce2b8e-002a-4a29-bf64-b10d062e10a8 seller_is_guest: false skip_remainder: false status: deposit_accepted 400: description: | Bad Request `code` can be one of the following: * `deposit_not_paid` * `deposit_payment_in_review` * `deposit_already_accepted` * `already_cancelled` * `deposit_already_captured` schema: $ref: '#/definitions/Error' example: code: deposit_not_paid error: deposit payment hasn't been made 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found schema: $ref: '#/definitions/Error' example: code: not_found error: no resource was found under the provided identifier summary: Accept the deposit for this face-to-face transaction tags: - F2F Payment /p2p/transactions/{transaction_id}/accept_deposit_with_guest_seller: post: operationId: p2p.acceptDepositWithGuestSeller parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 1-4a0ee552-b793-4176-93de-f5afe1562b7a, buyer_is_guest: true, client_id: test-auth, created: 2025-05-22T09:19:00Z, currency: eur, deposit_accepted: 2025-05-22T09:19:00Z, deposit_paid: 2025-05-22T09:19:00Z, deposit_pricing: charge: 118, charge_seller: 0, deposit_fee_multiplier: fee_multiplier: 1 price: 1234, description: Little Fish, id: 95, is_deposit_payment_in_progress: false, is_remainder_payment_in_progress: false, joined: 2025-05-22T09:19:00Z, quantity: 1, remainder_skipped: 2025-05-22T09:19:00Z, seller_id: 1-1be63e09-0044-4341-b9e6-4052e7cdf5ff, seller_is_guest: true skip_remainder: true, status: remainder_skipped, 403: description: | Forbidden `code` can be one of the following: * `not_seller` * `subject_is_not_guest_user` * `deposit_not_paid` * `deposit_already_accepted` schema: $ref: '#/definitions/Error' example: code: subject_is_not_guest_user error: this endpoint can only be accessed by guest users 404: description: Not Found summary: Accept the deposit for this face-to-face transaction as a guest seller tags: - F2F Payment /p2p/transactions/{transaction_id}/bank_transfer_details: get: operationId: p2p.getBankTransferDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.BankTransferDetails' example: amount: 20200 currency: eur financial_address: iban: account_holder_name: Trustap Ltd bic: IRBBIE12XXX country: IE iban: IE722848006801920534742 hosted_instructions_url: | https://payments.stripe.com/bank_transfers/instructions/test_YWNjdF8xOWtIRzBEblRFbnpGcFRELF9QTElzVjdEcHg4Y2dUTUlPcUJoTlRSSlBFZU5EbkFt0100bfu5n8c7 reference: TZQ9B3VHF9FK 400: description: | Bad Request `code` can be one of the following: * `payment_method_not_bank_transfer` summary: | Get the bank transfer details for a face-to-face transaction which payment method is `bank_transfer` tags: - F2F Payment /p2p/transactions/{transaction_id}/billing_details: get: operationId: p2p.getBillingDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.BillingDetails' 404: description: Not Found summary: Get billing details from this p2p transaction tags: - F2F Buyer/Seller Details /p2p/transactions/{transaction_id}/cancel_with_description: post: description: | If a transaction is cancelled after the deposit has been paid then the deposit (excluding the Trustap fee) will be returned to the buyer. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_cancel` scope to the client that is performing the request. operationId: p2p.cancelWithDescription parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string - in: body name: cancel_with_description_body required: true schema: example: description: Found another buyer properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 cancellation: reason: Found another buyer cancelled: 2019-12-25T11:00:00Z created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: cancelled 400: description: | Bad Request `code` can be one of the following: * `second_party_not_joined` * `already_cancelled` * `remainder_already_paid` * `handover_already_confirmed` schema: $ref: '#/definitions/Error' example: code: already_cancelled error: transaction already cancelled 404: description: Not Found security: - APIKey: [] summary: Cancel this face-to-face transaction with a description tags: - F2F Cancel /p2p/transactions/{transaction_id}/cancel_with_description_with_guest_user: post: description: | If a transaction is cancelled after the deposit has been paid then the deposit (excluding the Trustap fee) will be returned to the buyer. operationId: p2p.cancelP2PTransactionWithDescriptionAsGuest parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string - in: body name: cancel_with_description_body required: true schema: example: description: Found another buyer properties: description: minLength: 1 type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 cancellation: reason: Found another buyer cancelled: 2019-12-25T11:00:00Z created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: cancelled 400: description: | Bad Request `code` can be one of the following: * `missing_description` * `empty_description` * `already_cancelled` * `remainder_already_paid` * `handover_already_confirmed` schema: $ref: '#/definitions/Error' example: code: already_cancelled error: transaction already cancelled 404: description: Not Found security: - APIKey: [] summary: Cancel this face-to-face transaction with a description with guest user tags: - F2F Cancel /p2p/transactions/{transaction_id}/claim_for_buyer: post: description: | This endpoint enables a client to claim a face-to-face transaction on behalf of a buyer. This endpoint is only accessible for a client. operationId: p2p.claimForBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 785f384d-3203-448d-adbf-9e67330be65f buyer_is_guest: false claimed_by_buyer: 2025-11-03T15:24:28Z client_id: test-auth created: 2025-11-03T15:24:27Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 179 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-11-03T15:24:27Z quantity: 1 seller_id: 1-9ab8a98f-7b7d-409a-9de6-979bec1dc415 seller_is_guest: true skip_remainder: true status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 403: description: Forbidden schema: $ref: '#/definitions/Error' example: code: forbidden error: this client has no access to the resource 404: description: Not Found schema: $ref: '#/definitions/Error' example: code: not_found error: no resource was found under the provided identifier summary: Claim a F2F transaction on behalf of the buyer tags: - F2F Transactions /p2p/transactions/{transaction_id}/claim_for_seller: post: description: | This endpoint enables a client to claim a face-to-face transaction on behalf of a seller. This endpoint is only accessible for a client. operationId: p2p.claimTransactionForSeller parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` * `invalid_user_platform` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 404: description: Not Found summary: Claim a F2F transaction on behalf of the seller tags: - F2F Transactions /p2p/transactions/{transaction_id}/complain: post: description: Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_complain` scope to the client that is performing the request. operationId: p2p.submitComplaint parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: submit_complaint_body required: true schema: example: description: Item was fake properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 complained: 2019-12-25T15:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: complained 400: description: | Bad Request `code` can be one of the following: * `remainder_required` * `already_complained` * `funds_already_released` * `complaint_period_expired` 404: description: Not Found summary: Submit a complaint for this face-to-face transaction tags: - F2F Complaint /p2p/transactions/{transaction_id}/complain_with_guest_buyer: post: operationId: p2p.submitComplaintWithGuestBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: submit_complaint_with_guest_buyer_body required: true schema: example: description: Item was fake properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 complained: 2019-12-25T15:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: complained 400: description: | Bad Request `code` can be one of the following: * `remainder_required` * `already_complained` * `funds_already_released` * `complaint_period_expired` 404: description: Not Found summary: Submit a complaint for this face-to-face transaction with a guest buyer tags: - F2F Complaint /p2p/transactions/{transaction_id}/confirm_handover: post: description: | Both parties should confirm the handover for a face-to-face transaction. The complaints period begins when the seller confirms the handover. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_confirm_handover` scope to the client that is performing the request. operationId: p2p.confirmHandover parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_handover_confirmed: 2019-12-25T15:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: seller_handover_confirmed 400: description: | Bad Request `code` can be one of the following: * `remainder_required` * `already_complained` * `seller_handover_already_confirmed` * `buyer_handover_already_confirmed` * `remainder_payment_in_review` * `already_cancelled` 404: description: Not Found summary: Confirm the handover for this face-to-face transaction tags: - F2F Handover /p2p/transactions/{transaction_id}/confirm_handover_with_guest_user: post: description: | Both parties should confirm the handover for a face-to-face transaction. Full users don't have access to this endpoint. operationId: p2p.confirmHandoverWithGuestUserForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_handover_confirmed: 2019-12-25T15:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: seller_handover_confirmed 400: description: | Bad Request `code` can be one of the following: * `remainder_required` * `already_complained` * `seller_handover_already_confirmed` * `buyer_handover_already_confirmed` 404: description: Not Found summary: Confirm the handover for this face-to-face transaction with a guest user tags: - F2F Handover /p2p/transactions/{transaction_id}/deposit_stripe_client_secret: get: description: | This endpoint is used for the asynchronous payment flow using Stripe. The `client_secret` returned from this endpoint should be passed to [stripe.confirmCardPayment](https://stripe.com/docs/stripe-js/reference#stripe-confirm-card-payment) to start the payment process. operationId: p2p.getDepositStripeClientSecretForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: example: client_secret: '***' properties: client_secret: type: string required: - client_secret type: object 400: description: | Bad Request `code` can be one of the following: * `deposit_already_paid` schema: $ref: '#/definitions/Error' example: code: deposit_already_paid error: deposit payment already made 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Get the Stripe client secret for this face-to-face transaction tags: - F2F Payment /p2p/transactions/{transaction_id}/end_complaint_period_with_guest_buyer: post: operationId: p2p.endComplaintPeriodWithGuestBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 complaint_period_deadline: 2019-12-25T15:00:00Z complaint_period_ended: 2019-12-25T14:30:00Z created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 remainder_paid: 2019-12-25T14:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: complaint_period_ended 400: description: | Bad Request `code` can be one of the following: * `complaint_period_expired` * `already_complained` * `handover_not_confirmed` * `funds_already_released` 404: description: Not Found summary: End the complaint period for this face-to-face transaction with a guest buyer tags: - F2F Complaint /p2p/transactions/{transaction_id}/join_with_guest: post: operationId: p2p.joinWithGuest parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 1-feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `cannot_join_own_transaction` * `already_cancelled`` schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Join the face-to-face transaction as guest user tags: - F2F Transactions /p2p/transactions/{transaction_id}/metadata: get: operationId: p2p.getTransactionMetadata parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: additionalProperties: true type: object 404: description: Not Found summary: Get metadata for a face-to-face transaction tags: - F2F Transactions post: operationId: p2p.setTransactionMetadata parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_transaction_metadata_body schema: additionalProperties: true type: object responses: 200: description: OK schema: additionalProperties: true type: object 400: description: | Bad Request `code` can be one of the following: * `too_many_metadata_fields` * `value_too_long` * `field_name_too_long` * `empty_json` * `json_type_not_allowed`` schema: $ref: '#/definitions/Error' summary: Set metadata for a face-to-face transaction tags: - F2F Transactions /p2p/transactions/{transaction_id}/remainder_stripe_client_secret: get: description: | This endpoint is used for the asynchronous payment flow using Stripe. The `client_secret` returned from this endpoint should be passed to [stripe.confirmCardPayment](https://stripe.com/docs/stripe-js/reference#stripe-confirm-card-payment) to start the payment process. operationId: p2p.getRemainderStripeClientSecretForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: example: client_secret: '***' properties: client_secret: type: string required: - client_secret type: object 400: description: | Bad Request `code` can be one of the following: * `missing_pricing`: Pricing details have not yet been added to this transaction. * `no_client_secret` schema: $ref: '#/definitions/Error' example: code: missing_pricing error: Pricing details have not yet been added to this transaction. 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Get the Stripe client secret for this face-to-face transaction tags: - F2F Buyer/Seller Details /p2p/transactions/{transaction_id}/set_deposit_payment_method: post: description: | Set deposit payment method for face-to-face transaction. Values can be `card`, `bank_transfer`, `p24`, and `fpx`. operationId: p2p.setDepositPaymentMethod parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_deposit_payment_method_body required: true schema: $ref: '#/definitions/p2p.DepositPaymentMethod' responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 22871221-56cf-4835-bdaa-f475615cd799 buyer_is_guest: false client_id: test-custom-fees created: 2025-11-04T17:27:34Z currency: eur deposit_pricing: charge: 120 charge_seller: 0 price: 2000 description: Little Fish id: 21 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-11-04T17:27:34Z quantity: 1 seller_id: 05d63541-2c43-4418-9f72-e4954cfbec5e seller_is_guest: false skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_payment_method` * `deposit_already_paid` * `payment_method_already_set`: The specified payment method and charge configuration are already set. * `invalid_charge_config`: Charge configuration must be an integer greater than or equal to 1. * `unsupported_currency` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. * `currency_missing` * `incorrect_charge`: Specified charge doesn't match expected charge. * `incorrect_charge_seller`: Specified seller charge doesn't match expected seller charge. * `incorrect_price`: Specified price doesn't match expected price. * `incorrect_currency`: Specified currency doesn't match expected currency. schema: $ref: '#/definitions/Error' example: code: unsupported_combination error: the provided payment method, charge config and currency combination isn't supported summary: Set deposit payment method for this face-to-face transaction tags: - F2F Payment /p2p/transactions/{transaction_id}/stripe_publishable_key: get: description: | Returns the Publishable Key for the Stripe Platform which is hosting this transaction. operationId: p2p.getStripePublishableKeyForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer produces: - application/json responses: 200: description: OK schema: example: publishable_key: pk_xXxXxXxXxXx properties: publishable_key: type: string required: - publishable_key type: object 400: description: | Bad Request `code` can be one of the following: * `invalid_id` schema: $ref: '#/definitions/Error' example: code: invalid_id error: 'couldn''t parse transaction id: abc' 403: description: | Forbidden `code` can be one of the following: * `not_buyer` * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Get the details for the Stripe publishable key that is in use for this face-to-face transaction tags: - F2F Buyer/Seller Details /p2p/transactions/{transactionId}/buyer_details: get: operationId: getBuyerDetailsFromP2PTransaction parameters: - format: int64 in: path name: transactionId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/UserDetails' 404: description: Not Found summary: Get the details of the buyer from this face-to-face transaction tags: - F2F Buyer/Seller Details /p2p/transactions/{transactionId}/seller_details: get: operationId: getSellerDetailsFromP2PTransaction parameters: - format: int64 in: path name: transactionId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/UserDetails' 404: description: Not Found summary: Get the details of the seller from this face-to-face transaction tags: - F2F Buyer/Seller Details /p2p/transactions/{transactionId}/set_price: post: description: | `price` is the total price of the item, and thus includes the price already paid for the deposit. Note that this endpoint will return a `remainder_too_low` response if the difference between the total price and the deposit price is too low. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_set_price` scope to the client that is performing the request. operationId: setPriceForP2PTransaction parameters: - format: int64 in: path name: transactionId required: true type: integer - in: body name: create_pricing_body required: true schema: example: charge: 190 charge_calculator_version: 2 currency: eur price: 5000 properties: charge: description: | The `charge` value returned from a request to `/p2p/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/p2p/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - price - charge - charge_calculator_version type: object responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z priced: 2019-12-25T13:00:00Z pricing: charge: 190 price: 5000 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: deposit_accepted 400: description: | Bad Request `code` can be one of the following: * `currency_mismatch`: Pricing currency is different to the transaction's currency. * `remainder_already_skipped` * `remainder_too_low`: The difference between the total price of this transaction isn't larger than the deposit price. schema: $ref: '#/definitions/Error' 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Set the total price for this face-to-face transaction tags: - F2F Payment /p2p/transactions/{transactionId}/skip_remainder: post: description: | This will skip the remainder payment of this transaction, and the total price of the transaction will not need to be set. Note that this must be done before the total price of the transaction is set using `/set_price`. operationId: skipRemainderForP2PTransaction parameters: - format: int64 in: path name: transactionId required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 created: 2019-12-25T09:00:00Z currency: eur deposit_accepted: 2019-12-25T12:00:00Z deposit_paid: 2019-12-25T11:00:00Z deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z remainder_skipped: 2019-12-25T13:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: remainder_skipped 400: description: | Bad Request `code` can be one of the following: * `price_already_set` schema: $ref: '#/definitions/Error' 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Skip the remainder for this face-to-face transaction tags: - F2F Payment /p2p/transactions_by_claim_secret/{secret}/claim_as_buyer: post: description: | This endpoint allows a full user to claim a transaction as buyer given a claim secret. operationId: p2p.claimAsBuyer parameters: - in: path name: secret required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: ad94c131-9510-4e98-8d32-c9dd4f7dfb32 buyer_is_guest: false claimed_by_buyer: 2025-05-21T07:54:30Z client_id: test-auth created: 2025-05-21T07:54:18Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 39 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-05-21T07:54:18Z seller_id: ad0fdfd0-eae7-4c4f-8fdf-7516785ab686 seller_is_guest: false skip_remainder: false status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` * `missing_secret` * `invalid_user_platform` 404: description: Not Found summary: Claim F2F transaction as buyer given a claim secret tags: - F2F Transactions /p2p/transactions_by_claim_secret/{secret}/claim_as_seller: post: description: | This endpoint allows a full user to claim a transaction as seller given a claim secret. operationId: p2p.claimTransactionAsSeller parameters: - in: path name: secret required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 1-ac24e079-fba7-493b-a209-c963bb87355d buyer_is_guest: true claimed_by_seller: 2025-05-21T15:01:44Z client_id: test-auth created: 2025-05-21T15:01:44Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 deposit_fee_multiplier: fee_multiplier: 1 price: 1234 description: Little Fish id: 112 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-05-21T15:01:44Z seller_id: c1bbade1-2e9b-4c12-b393-4905cfa87f2e seller_is_guest: false skip_remainder: true status: joined 400: description: | Bad Request `code` can be one of the following: * `missing_secret` * `already_claimed` * `cannot_claim_own_transaction` * `invalid_user_platform` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 404: description: Not Found summary: Claim a F2F transaction as the seller tags: - F2F Transactions /p2p/transactions_by_join_code/{join_code}/join: post: description: This endpoint allows a user to join a transaction provided a join code. Offline access is allowed for this endpoint when the user has granted the `p2p_tx:offline_create_join` scope to the client that is performing the request. operationId: p2p.joinTransactionByJoinCode parameters: - in: path name: join_code required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 2eea7496-b104-4544-9225-17d53dccddfd buyer_is_guest: false client_id: test-auth created: 2025-11-03T15:15:55Z currency: eur deposit_pricing: charge: 20 charge_seller: 0 price: 2000 description: Little Fish id: 67 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false joined: 2025-11-03T15:15:55Z quantity: 1 seller_id: be92ff26-f8b2-4bae-a915-6641fa55baa9 seller_is_guest: false skip_remainder: true status: joined 400: description: | Bad Request `code` can be one of the following: * `cannot_join_own_transaction` * `already_cancelled` * `unsupported_currency` * `invalid_payment_method` * `invalid_user_id` * `incompatible_users` schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Join a face-to-face transaction by its join code tags: - F2F Transactions /p2p/transactions_by_join_code/{join_code}/reject: post: operationId: p2p.rejectTransactionByJoinCode parameters: - in: path name: join_code required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: buyer_id: 785f384d-3203-448d-adbf-9e67330be65f buyer_is_guest: false client_id: test-auth created: 2025-11-03T15:17:47Z currency: eur deposit_pricing: charge: 118 charge_seller: 0 price: 1234 description: Little Fish id: 111 is_deposit_payment_in_progress: false is_remainder_payment_in_progress: false quantity: 1 rejected: 2025-11-03T15:17:47Z seller_id: 75ce2b8e-002a-4a29-bf64-b10d062e10a8 seller_is_guest: false skip_remainder: false status: rejected 400: description: | Bad Request `code` can be one of the following: * `cannot_reject_own_transaction` schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Reject a face-to-face transaction by its join code tags: - F2F Transactions /p2p/transactions_by_join_code/{joinCode}: get: operationId: getP2PTransactionByJoinCode parameters: - in: path name: joinCode required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/p2p.Transaction' example: created: 2019-12-25T09:00:00Z currency: eur deposit_pricing: charge: 78 price: 1234 description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: created 404: description: Not Found summary: Get a face-to-face transaction by its join code tags: - F2F Transactions /shippo_shipping_rates: post: description: | This returns the list of Shippo shipping rates available for the addreses provided i.e sender's address and recipient's address. operationId: basic.getShippoShippingRates parameters: - in: body name: get_shippo_shipping_rates required: true schema: example: currency: EUR customs_certify: true customs_certify_signer: Joe Doe customs_description: T-Shirt customs_incoterm: DDU customs_mass_unit: lb customs_net_weight: 5 customs_non_delivery_option: return customs_origin_country: US customs_quantity: 20 customs_value_amount: "200" customs_value_currency: USD parcel_distance_unit: cm parcel_height: 10 parcel_length: 10 parcel_mass_unit: lb parcel_weight: 10 parcel_width: 10 recipient_city: New York recipient_country: us recipient_full_name: Ivan Horvat recipient_phone: "123456789" recipient_state: New York recipient_street_1: 21-27 Marshall Court recipient_zip_code: "90218" sender_city: Altona sender_country: au sender_full_name: Ana Potter sender_phone: "123456789" sender_state: Victoria sender_street_1: 21-27 Marshall Court properties: currency: type: string customs_certify: type: boolean customs_certify_signer: type: string customs_description: type: string customs_eel_pfc: type: string customs_incoterm: type: string customs_mass_unit: type: string customs_net_weight: format: double type: number customs_non_delivery_option: enum: - return - abandon type: string customs_origin_country: type: string customs_quantity: format: int64 type: integer customs_value_amount: type: string customs_value_currency: type: string parcel_distance_unit: $ref: '#/definitions/basic.DistanceUnit' parcel_height: format: double type: number parcel_length: format: double type: number parcel_mass_unit: $ref: '#/definitions/basic.MassUnit' parcel_weight: format: double type: number parcel_width: format: double type: number recipient_city: type: string recipient_country: type: string recipient_full_name: type: string recipient_phone: type: string recipient_state: type: string recipient_street_1: type: string recipient_street_2: type: string recipient_zip_code: type: string sender_city: type: string sender_country: type: string sender_full_name: type: string sender_phone: type: string sender_state: type: string sender_street_1: type: string sender_street_2: type: string sender_zip_code: type: string required: - sender_full_name - sender_street_1 - sender_zip_code - sender_city - sender_state - sender_country - sender_phone - recipient_full_name - recipient_street_1 - recipient_zip_code - recipient_city - recipient_state - recipient_country - recipient_phone - parcel_height - parcel_length - parcel_width - parcel_distance_unit - parcel_weight - parcel_mass_unit - currency type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.ShippoShippingRatesResponse' 400: description: | Bad Request `code` can be one of the following: * `missing_shipment_details` schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' security: - OAuth2: [] - APIKey: [] summary: Get the list of Shippo shipping rates available tags: - Online Shipping /single_use_listings/{listing_id}: delete: deprecated: true operationId: basic.deleteSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 204: description: No Content 404: description: Not Found summary: Delete this listing tags: - Online Single-use Listings get: deprecated: true operationId: basic.getSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 id: 77f36253-7a43-4d47-897d-f73dd208e17a 404: description: Not Found summary: Get a listing by its ID tags: - Online Single-use Listings patch: deprecated: true operationId: basic.updateSingleUseListing parameters: - in: path name: listing_id required: true type: string - in: body name: patch_listing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur description: Soccer ticket price: 1234 properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' description: type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 400: description: | Bad Request `code` can be one of the following: * `empty_body`: The request body is empty. * `partial_pricing`: When updating a pricing field, all 3 of `currency`, `price` and `charge` must be supplied. 404: description: Not Found summary: Patch listing properties tags: - Online Single-use Listings /single_use_listings/{listing_id}/create_transaction: post: deprecated: true operationId: basic.createTransactionFromSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: single_use price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `no_listing_currency`: The source listing doesn't have a currency. * `no_listing_price`: The source listing doesn't have pricing. * `no_listing_descr`: The source listing doesn't have a description. * `is_listing_creator`: The current user created this listing. schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - Online Single-use Listings /single_use_listings/{listing_id}/create_transaction_with_guest_buyer: post: deprecated: true operationId: basic.createTransactionWithGuestBuyerFromSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 201: description: Created schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: single_use price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `listing_is_disabled` * `no_listing_currency`: The source listing doesn't have a currency. * `no_listing_price`: The source listing doesn't have pricing. * `no_listing_descr`: The source listing doesn't have a description. * `is_listing_creator`: The current user created this listing. schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Create a transaction from this listing tags: - Online Single-use Listings /single_use_listings/{listing_id}/disable: post: deprecated: true description: | Calling `/create_transaction` on a disabled listing will return a `400` response. operationId: basic.disableSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket disabled: 2019-12-25T10:00:00Z id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 404: description: Not found summary: Disable this listing tags: - Online Single-use Listings /single_use_listings/{listing_id}/enable: post: deprecated: true operationId: basic.enableSingleUseListing parameters: - in: path name: listing_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 404: description: Not found summary: Enable this listing tags: - Online Single-use Listings /single_use_listings/{listing_id}/set_description: post: deprecated: true operationId: basic.setSingleUseListingDescription parameters: - in: path name: listing_id required: true type: string - in: body name: description_body required: true schema: example: description: Soccer ticket properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a 404: description: Not Found summary: Set description for this listing tags: - Online Single-use Listings /single_use_listings/{listing_id}/set_pricing: post: deprecated: true operationId: basic.setSingleUseListingPricing parameters: - in: path name: listing_id required: true type: string - in: body name: create_pricing_body required: true schema: example: charge: 78 charge_calculator_version: 5 currency: eur price: 1234 properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_calculator_version: description: The `charge_calculator_version` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: $ref: '#/definitions/Currency' price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - price - charge - charge_calculator_version type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.SingleUseListing' example: created: 2019-12-25T09:00:00Z creator_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 currency: eur description: Soccer ticket id: 77f36253-7a43-4d47-897d-f73dd208e17a pricing: charge: 78 price: 1234 404: description: Not Found summary: Set pricing for this listing tags: - Online Single-use Listings /supported_carriers: get: description: | This returns the carriers that are currently supported for automated tracking in the online model. The carrier `name` should be shown to users but the `code` should be submitted to the `/track` endpoint when submitting tracking details. Likewise, when showing a transaction to the user, the `carrier` field stored with the transaction should be used to index these carriers and show the human-readable name of the carrier to the user, if this index is found. operationId: getSupportedCarriers responses: 200: description: OK schema: example: - code: an-post name: An Post - code: fedex name: FedEx - code: ups name: UPS - code: usps name: USPS items: $ref: '#/definitions/Carrier' type: array security: - OAuth2: [] - APIKey: [] summary: Get the supported carriers tags: - Online Shipping /transactions: get: operationId: basic.getTransactionByJoinCode parameters: - in: query name: join_code required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created 400: description: | Bad Request `code` can be one of the following: * `join_code_missing` schema: $ref: '#/definitions/Error' example: code: join_code_missing error: '`join_code` query parameter is required' 404: description: Not Found summary: Get an online transaction using a join code tags: - Online Transactions put: description: | A transaction can't be joined using its ID, because only the buyer and seller of a transaction can access a transaction using its ID. operationId: basic.joinTransaction parameters: - in: query name: join_code required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `join_code_missing` schema: $ref: '#/definitions/Error' example: code: join_code_missing error: '`join_code` query parameter is required' 404: description: Not Found summary: Join an online transaction using a join code tags: - Online Transactions /transactions-by-join-code/{join_code}/reject: post: description: | A transaction can't be rejected using its ID, because only the buyer and seller of a transaction can access a transaction using its ID. operationId: basic.rejectTransactionByJoinCode parameters: - in: path name: join_code required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: charge: 78 created: 2019-12-25T09:00:00Z currency: eur denied: 2019-12-25T10:00:00Z description: Soccer ticket id: 1309 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: rejected 400: description: Bad Request schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Reject an online transaction by its join code tags: - Online Transactions /transactions/{transaction_id}: get: operationId: basic.getTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `invalid_id` schema: $ref: '#/definitions/Error' 404: description: Not Found summary: Get an online transaction by its ID tags: - Online Transactions patch: operationId: updateTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: edit_transaction_body required: true schema: example: charge: 78 currency: eur description: Soccer ticket price: 1234 properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: type: string description: description: | A description of the goods being sold. type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `second_party_already_joined` * `values_not_changed` schema: $ref: '#/definitions/Error' 403: description: Forbidden 404: description: Not Found summary: Update the description, currency, price and/or charge of an online transaction tags: - Online Payment /transactions/{transaction_id}/accept_complaint: post: operationId: basic.acceptComplaint parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 complained: 2019-12-25T14:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-25T13:00:00Z description: Soccer ticket funds_released: 2019-12-25T17:00:00Z id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: funds_released tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `funds_already_released` * `not_paid` * `not_complained` schema: $ref: '#/definitions/Error' example: code: complaint_period_expired error: complaint period has expired 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Accept complaint for this online transaction tags: - Online Complaint /transactions/{transaction_id}/accept_listing_transaction: post: description: | "Listing transactions" are transactions created from listings (using the `/create_transaction` endpoints for listings). Listings transactions for online transactions must be accepted by the creator of the listing using `/accept_listing_transaction` in order to proceed. Offline access is allowed for this endpoint when the user has granted the `basic_ls:offline_accept_listing` scope to the client that is performing the request. operationId: basic.acceptListingTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: accepted_by_listing_creator: 2019-12-25T11:00:00Z buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: single_use price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: paid 400: description: | Bad Request `code` can be one of the following: * `no_listing`: This transaction wasn't created from a listing * `already_accepted` * `already_rejected` schema: $ref: '#/definitions/Error' example: code: already_accepted error: transaction already accepted 403: description: | Forbidden `code` can be one of the following: * `not_creator` schema: $ref: '#/definitions/Error' example: code: not_creator error: current user is not the creator for the source listing 404: description: Not Found summary: | Allow this listing-based transaction to proceed tags: - Online Transactions /transactions/{transaction_id}/accept_payment: post: description: | This endpoint lets the seller accept payment and is accessible only if the seller has granted a feature `require_seller_acceptance`. Offline access is allowed for this endpoint when the user has granted the `basic_tx:offline_accept_payment` scope to the client that is performing the request. operationId: basic.acceptPayment parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z payment_accepted: 2019-12-26T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: payment_accepted 400: description: | Bad Request `code` can be one of the following: * `missing_required_feature` * `payment_already_accepted` * `transaction_not_paid_yet` schema: $ref: '#/definitions/Error' example: code: transaction_not_paid_yet error: this transaction is not paid yet 404: description: Not Found summary: Enable the seller to accept payment for an online transaction tags: - Online Payment /transactions/{transaction_id}/accept_payment_with_guest_seller: post: description: | This endpoint allows payment acceptance for the seller specified in the header as `Trustap-User`. operationId: basic.acceptPaymentWithGuestSeller parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z payment_accepted: 2019-12-26T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: payment_accepted 400: description: | Bad Request `code` can be one of the following: * `missing_required_feature` * `payment_already_accepted` * `missing_shippo_shipping_rate_id` * `transaction_not_paid_yet` schema: $ref: '#/definitions/Error' example: code: transaction_not_paid_yet error: this transaction is not paid yet 404: description: Not Found summary: Enable payment acceptance for the seller using `Trustap-User` for an online transaction tags: - Online Payment /transactions/{transaction_id}/bank_transfer_details: get: operationId: basic.getBankTransferDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.BankTransferDetails' example: amount: 20200 currency: eur financial_address: iban: account_holder_name: Trustap Ltd bic: IRBBIE12XXX country: IE iban: IE722848006801920534742 hosted_instructions_url: | https://payments.stripe.com/bank_transfers/instructions/test_YWNjdF8xOWtIRzBEblRFbnpGcFRELF9QTElzVjdEcHg4Y2dUTUlPcUJoTlRSSlBFZU5EbkFt0100bfu5n8c7 reference: TZQ9B3VHF9FK 400: description: | Bad Request `code` can be one of the following: * `payment_method_not_bank_transfer` summary: | Get bank transfer details for an online transaction which payment method is `bank_transfer` tags: - Online Payment /transactions/{transaction_id}/billing_details: get: operationId: basic.getBillingDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.BillingDetails' 404: description: Not Found summary: Get billing details from this online transaction tags: - Online Buyer/Seller Details /transactions/{transaction_id}/buyer_details: get: operationId: basic.getBuyerDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/UserDetails' 404: description: Not Found summary: Get details of the buyer from this online transaction tags: - Online Buyer/Seller Details /transactions/{transaction_id}/cancel: post: description: | Transaction can be cancelled until it's paid or if the feature `RequireSellerAcceptance` is present, it can be cancelled until it's tracked. Offline access is allowed for this endpoint when the user has granted the `basic_tx:offline_cancel` scope to the client that is performing the request. operationId: basic.cancelTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: cancelled: 2022-04-26T11:00:00Z charge: 78 created: 2022-04-26T09:00:00Z currency: eur description: Soccer ticket id: 1309 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: cancelled 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `already_paid` * `already_cancelled` * `tracking_already_added` schema: $ref: '#/definitions/Error' 403: description: Forbidden 404: description: Not Found summary: Cancel this online transaction tags: - Online Cancel /transactions/{transaction_id}/cancel_with_guest_user: post: description: | This endpoint cancels a transaction for the user specified in the header as `Trustap-User`. Transaction can be cancelled until it's paid or if the feature `RequireSellerAcceptance` is present, it can be cancelled until it's tracked. operationId: basic.cancelTransactionWithGuestUser parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: cancelled: 2022-04-26T11:00:00Z charge: 78 created: 2022-04-26T09:00:00Z currency: eur description: Soccer ticket id: 1309 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 skip_remainder: false status: cancelled 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `already_paid` * `already_cancelled` * `tracking_already_added` schema: $ref: '#/definitions/Error' 403: description: Forbidden 404: description: Not Found summary: Cancel this online transaction with a guest user tags: - Online Cancel /transactions/{transaction_id}/charge: get: description: | This returns the Trustap fee, in the `currency`'s smallest unit, for a transaction involving goods with the supplied `price`. See [the Stripe documentation](https://stripe.com/docs/currencies#zero-decimal) for more details. operationId: basic.getChargeForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: | The price of the goods being sold in this transaction, in the `currency`'s smallest unit. For example, if a trading card is being sold for $12.34 (with `currency` as `usd`), then the request for the charge for this transaction would be `/charge?price=1234¤cy=usd`. format: int64 in: query name: price required: true type: integer - description: | When creating transactions from a multi-use listing, the `quantity` parameter can be provided in order to generate a charge for the given price multiplied by the given quantity. See `/multi_use_listings/{listingId}/create_transaction` for more details. format: int64 in: query name: quantity required: false type: integer - description: | The payment method that will be used to pay for the transaction. This is necessary because different payment methods may result in different fees. The default value is `card`. in: query name: payment_method required: false type: string - description: | The charge config for which the charge amount is computed. format: int64 in: query name: charge_config required: false type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Charge' example: charge: 78 charge_calculator_version: 5 currency: eur 400: description: | Bad Request `code` can be one of the following: * `invalid_payment_method` * `unsupported_currency` * `currency_missing` * `invalid_price` * `negative_price` * `price_too_low` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. schema: $ref: '#/definitions/Error' example: code: negative_price error: '`price` cannot be negative' security: - OAuth2: [] - APIKey: [] summary: Get the Trustap fee for an online transaction tags: - Online Payment /transactions/{transaction_id}/claim_for_buyer: post: description: | This endpoint enables a client to claim an online transaction on behalf of a buyer. This endpoint is only accessible for a client. operationId: basic.claimTransactionForBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 404: description: Not Found summary: Claim online transaction on behalf of the buyer tags: - Online Transactions /transactions/{transaction_id}/claim_for_seller: post: description: | This endpoint enables a client to claim an online transaction on behalf of a seller. This endpoint is only accessible for a client. operationId: basic.claimTransactionForSeller parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 404: description: Not Found summary: Claim online transactions on behalf of the seller tags: - Online Transactions /transactions/{transaction_id}/complain_with_description: post: operationId: basic.submitComplaintWithDescription parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: description_body required: true schema: example: description: Item was fake properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 complained: 2019-12-25T14:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-25T13:00:00Z description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: complained tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `empty_complaint_description` * `already_complained` * `unconfirmed_delivery`: The complaint period for this transaction has not yet started. * `complaint_period_ended_prematurely`: The buyer has already ended the complaint period. * `complaint_period_expired` * `funds_already_released` * `invalid_id` schema: $ref: '#/definitions/Error' example: code: complaint_period_expired error: complaint period has expired 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Submit a detailed complaint for this online transaction tags: - Online Complaint /transactions/{transaction_id}/complain_with_guest_buyer: post: operationId: basic.submitComplaintWithGuestBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string - in: body name: description_body required: true schema: example: description: Item was fake properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: 1-feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 complained: 2019-12-25T14:00:00Z complaint: description: Item was fake created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-25T13:00:00Z description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: complained tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `empty_complaint_description` * `already_complained` * `unconfirmed_delivery`: The complaint period for this transaction has not yet started. * `complaint_period_ended_prematurely`: The buyer has already ended the complaint period. * `complaint_period_expired` * `funds_already_released` * `invalid_id` schema: $ref: '#/definitions/Error' example: code: complaint_period_expired error: complaint period has expired 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Submit a detailed complaint for this online transaction for the guest buyer using `Trustap-User` tags: - Online Complaint /transactions/{transaction_id}/confirm_delivery: post: description: | This endpoint allows the buyer to manually confirm the delivery of the item in the case that the state of the transaction was not updated asynchronously by Trustap. operationId: basic.confirmDelivery parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-26T12:00:00Z description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: delivered tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `tracking_not_added` * `delivery_already_set` * `invalid_id` schema: $ref: '#/definitions/Error' example: code: delivery_already_set error: delivery details already added 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Confirm delivery for this online transaction tags: - Online Shipping /transactions/{transaction_id}/confirm_delivery_with_guest_buyer: post: description: | This endpoint allows the client to manually confirm the delivery on behalf of the guest buyer specified in the header as `Trustap-User`. operationId: basic.confirmDeliveryWithGuestBuyer parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-26T12:00:00Z description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: 1-ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: delivered tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `tracking_not_added` * `delivery_already_set` * `invalid_id` schema: $ref: '#/definitions/Error' example: code: delivery_already_set error: delivery details already added 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Confirm delivery for this online transaction tags: - Online Shipping /transactions/{transaction_id}/delivery_point: post: operationId: basic.setDeliveryPoint parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: delivery_point_body required: true schema: example: carrier: posta_hr city: Zagreb delivery_center_code: 321ha32 delivery_type: parcel_locker email: ivan.horvat@email.com full_name: Ivan Horvat house_number: 147 house_number_suffix: A phone: 9.97896541e+08 postal_code: 10000 street: Ilica properties: carrier: type: string city: type: string delivery_center_code: type: string delivery_type: enum: - parcel_locker - postal_office type: string email: type: string full_name: type: string house_number: type: string house_number_suffix: type: string phone: type: string postal_code: type: string street: type: string required: - full_name - phone - email - street - house_number - postal_code - city - carrier - delivery_center_code - delivery_type type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.DeliveryDetails' 400: description: | Bad Request `code` can be one of the following: * `empty_join_code` * `empty_name` * `empty_phone` * `empty_email` * `empty_street` * `empty_house_number` * `empty_postal_code` * `empty_city` * `empty_delivery_center_code` * `empty_delivery_type` * `empty_carrier` * `unsupported_carrier` * `unsupported_delivery_type` schema: $ref: '#/definitions/Error' example: code: empty_name error: '`name` parameter is required' summary: Set a delivery point for HR posta tags: - Online Shipping /transactions/{transaction_id}/end_complaint_period: post: operationId: basic.endComplaintPeriod parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 complaint_period_ended: 2019-12-25T14:00:00Z created: 2019-12-25T09:00:00Z currency: eur delivered: 2019-12-25T13:00:00Z description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: complaint_period_ended tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `complaint_period_expired` * `already_complained` * `complaint_period_ended_prematurely` * `invalid_id` * `unconfirmed_delivery`: The complaint period for this transaction has not yet started. schema: $ref: '#/definitions/Error' example: code: complaint_period_expired error: complaint period has expired 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: End the complaint period for this online transaction tags: - Online Complaint /transactions/{transaction_id}/extend_tracking_deadline: post: description: | This endpoint allows the buyer to extend the tracking details submission deadline for the seller. operationId: basic.extendTrackingDeadlineForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: paid tracking_details_window_start: 2019-12-25T12:00:00Z 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `tracking_already_added` * `payment_details_not_added` * `tracking_submission_window_not_started` 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Extend tracking details submission deadline for this online transaction tags: - Online Shipping /transactions/{transaction_id}/generate_shipment_label: post: consumes: - application/json description: | This endpoint returns a PDF containing the label for the transaction's parcel. Both sender and recipient details have to be submitted before making a call to this endpoint. operationId: basic.generateShipmentLabel parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: query name: carrier required: true type: string produces: - application/json responses: 200: description: OK schema: $ref: '#/definitions/basic.ShipmentLabel' 400: description: | Bad Request `code` can be one of the following: * `pick_up_details_missing` * `drop_off_details_missing` schema: $ref: '#/definitions/Error' example: code: pick_up_details_missing error: there are one or more pick up details properties missing 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Generate a shipment label for this online transaction's parcel tags: - Online Shipping /transactions/{transaction_id}/pick_up_point: post: operationId: basic.setPickUpPoint parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: pick_up_point_body required: true schema: example: carrier: posta_hr city: Zagreb delivery_type: parcel_locker email: ivan.horvat@email.com full_name: Ivan Horvat house_number: 147 house_number_suffix: A phone: 9.97896541e+08 pick_up_center_code: 321ha32 postal_code: 10000 street: Ilica properties: carrier: type: string city: type: string delivery_type: enum: - parcel_locker - postal_office type: string email: type: string full_name: type: string house_number: type: string house_number_suffix: type: string phone: type: string pick_up_center_code: type: string postal_code: type: string street: type: string required: - full_name - phone - email - street - house_number - postal_code - city - carrier - pick_up_center_code - delivery_type type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.PickUpDetails' 400: description: | Bad Request `code` can be one of the following: * `empty_join_code` * `empty_full_name` * `empty_phone` * `empty_email` * `empty_street` * `empty_house_number` * `empty_postal_code` * `empty_city` * `empty_pick_up_center_code` * `empty_delivery_type` * `empty_carrier` * `unsupported_carrier` * `unsupported_delivery_type` schema: $ref: '#/definitions/Error' example: code: empty_name error: '`name` parameter is required' summary: Set a pick up point for carrier (i.e HR posta) tags: - Online Shipping /transactions/{transaction_id}/reject_listing_transaction: post: description: | "Listing transactions" are transactions created from listings (using the `/create_transaction` endpoints for listings). Listings transactions for online transactions must be accepted by the creator of the listing using `/accept_listing_transaction` in order to proceed. This endpoint instead rejects the listing transaction. operationId: basic.rejectListingTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z listing_id: 1990 listing_type: single_use price: 1234 rejected_by_listing_creator: 2019-12-25T11:00:00Z seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: paid 400: description: | Bad Request `code` can be one of the following: * `no_listing`: This transaction wasn't created from a listing * `already_accepted` * `already_rejected` * `second_party_not_joined` schema: $ref: '#/definitions/Error' example: code: already_accepted error: transaction already accepted 403: description: | Forbidden `code` can be one of the following: * `not_creator` schema: $ref: '#/definitions/Error' example: code: not_creator error: current user is not the creator for the source listing 404: description: Not Found summary: | Cancel this listing-based transaction tags: - Online Cancel /transactions/{transaction_id}/seller_details: get: operationId: basic.getSellerDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/UserDetails' 404: description: Not Found summary: Get details of the seller from this online transaction tags: - Online Buyer/Seller Details /transactions/{transaction_id}/set_payment_method: post: description: | Different payment methods incur different rates, so the payment method to be used for a transaction must be set before the payment is made. This requires retrieving the charge associated with the payment method using `GET /transactions/{transaction_id}/charge`, and passing the generated charge as a parameter to this endpoint. operationId: basic.setPaymentMethodForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_payment_method_for_transaction_body required: true schema: properties: charge: description: | The `charge` value returned from a request to `/charge`. format: int64 type: integer charge_config: description: | The charge config for which the charge amount is computed. format: int64 type: integer charge_seller: description: | The `charge_seller` value returned from a request to `/charge`. format: int64 type: integer currency: type: string payment_method: type: string price: description: | The price of the goods being sold, in the `currency`'s smallest unit. The `charge` value should correspond to the Trustap charge created with this price, otherwise this request will fail with a `400` error. format: int64 type: integer required: - currency - price - charge type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: charge: 78 charge_seller: 0 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 join_code: 54c5bb89-a5ea-4be7-ad7a-e740c2eebab4 price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: created 400: description: | Bad Request `code` can be one of the following: * `invalid_payment_method` * `unsupported_currency` * `currency_missing` * `incorrect_charge` * `incorrect_charge_seller` * `incorrect_price` * `incorrect_currency` * `invalid_charge_config` * `unsupported_combination`: The provided payment method, charge config and currency combination isn't supported. * `payment_method_already_set`: The specified payment method and charge configuration are already set. schema: $ref: '#/definitions/Error' example: code: incorrect_price error: specified price doesn't match expected price 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Set the payment method to be used for this online transaction tags: - Online Payment /transactions/{transaction_id}/shipping_details: get: operationId: basic.getShippingDetailsFromTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/ShippingDetails' 404: description: Not Found summary: Get the shipping details of the buyer from this online transaction tags: - Online Shipping post: operationId: basic.setShippingDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: ship_transaction_body required: true schema: example: address_line_1: 3672 Massillon Rd address_line_2: 3672 Massillon Rd city: Green country: us name: John Doe phone: 330-896-9303 postal_code: 44685 state: Ohio 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 responses: 200: description: OK schema: $ref: '#/definitions/ShippingDetails' 400: description: | Bad Request `code` can be one of the following: * `empty_name` * `empty_country` 404: description: Not Found summary: Post the shipping details of the buyer from this online transaction tags: - Online Shipping /transactions/{transaction_id}/shippo_address: post: operationId: basic.setShippoAddress parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_shippo_address_body required: true schema: example: city: Altona country: au full_name: Ivan Horvat phone: 4215559099 postal_code: 10000 state: Victoria street_1: 21-27 Marshall Court properties: city: type: string country: type: string email: type: string full_name: type: string is_sender_address: type: boolean phone: type: string state: type: string street_1: type: string street_2: type: string zip_code: type: string required: - is_sender_address - full_name - street_1 - zip_code - city - state - country - phone type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.ShippoAddress' 400: description: | Bad Request `code` can be one of the following: * `missing_tx_feature` schema: $ref: '#/definitions/Error' example: code: empty_name error: '`name` parameter is required' summary: Set the sender's or recipient's address for Shippo shipment tags: - Online Shipping /transactions/{transaction_id}/shippo_customs_declaration: post: operationId: basic.setShippoCustomsDeclaration parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_shippo_customs_declaration_body required: true schema: example: certify: true certify_signer: Joe Doe description: T-Shirt incoterm: DDU mass_unit: lb net_weight: 5 non_delivery_option: return origin_country: US quantity: 20 value_amount: 200 value_currency: USD properties: certify: type: boolean certify_signer: type: string description: type: string eel_pfc: type: string incoterm: type: string mass_unit: type: string net_weight: format: double type: number non_delivery_option: enum: - return - abandon type: string origin_country: type: string quantity: format: int64 type: integer value_amount: type: string value_currency: type: string required: - certify - certify_signer - non_delivery_option - description - mass_unit - net_weight - origin_country - quantity - value_amount - value_currency type: object responses: 204: description: No Content 400: description: | Bad Request `code` can be one of the following: * `missing_tx_feature` * `customs_declaration_already_submitted` * `nothing_to_declare` schema: $ref: '#/definitions/Error' example: code: missing_tx_feature error: missing transaction feature `use_shippo` summary: Send a customs declaration for this online transaction's shipment tags: - Online Shipping /transactions/{transaction_id}/shippo_parcel_details: post: operationId: basic.setShippoParcelDetails parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_shippo_parcel_details_body required: true schema: example: distance_unit: cm height: 10 lenght: 10 mass_unit: lb weight: 10 width: 10 properties: distance_unit: $ref: '#/definitions/basic.DistanceUnit' height: format: double type: number length: format: double type: number mass_unit: $ref: '#/definitions/basic.DistanceUnit' shipment_date: description: | Date the shipment will be tendered to the carrier. Must be in the format 2014-01-18T00:35:03.463Z type: string weight: format: double type: number width: format: double type: number required: - height - length - width - distance_unit - weight - mass_unit - shipment_date type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.ShippoParcel' 400: description: | Bad Request `code` can be one of the following: * `missing_tx_feature` * `wrong_shipment_date_format` schema: $ref: '#/definitions/Error' example: code: missing_tx_feature error: missing transaction feature `use_shippo` summary: Set Shippo parcel details for this online transaction tags: - Online Shipping /transactions/{transaction_id}/shippo_shipping_label: get: operationId: basic.getShippoShippingLabel parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: $ref: '#/definitions/ShippoLabelDetails' 400: description: | Bad Request `code` can be one of the following: * `transaction_not_tracked` schema: $ref: '#/definitions/Error' example: code: transaction_not_tracked error: transaction missing Shippo tracking details summary: Get Shippo generated label details for this online transaction tags: - Online Shipping /transactions/{transaction_id}/shippo_shipping_rate: post: description: | Set Shippo shipping rate for the transaction. This rate will be used to purchase the Shippo label once the transaction is paid. Shipment ID can be provided as an optional parameter, depending on the flow which is used to obtain it. operationId: basic.setShippoShippingRate parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: set_shippo_shipping_rate_body required: true schema: example: rate_id: d755e91036a84c15bd5318f4b67c7707 properties: rate_id: type: string shipment_id: type: string required: - rate_id type: object responses: 204: description: No Content 400: description: | Bad Request `code` can be one of the following: * `missing_tx_feature` schema: $ref: '#/definitions/Error' example: code: missing_tx_feature error: missing transaction feature `use_shippo` summary: Set Shippo shipping rate for this online transaction tags: - Online Shipping /transactions/{transaction_id}/shippo_shipping_rates: get: operationId: basic.getShippoShippingRatesForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: items: $ref: '#/definitions/basic.ShippoRate' type: array 400: description: | Bad Request `code` can be one of the following: * `missing_tx_feature` * `missing_shipment_details` * `customs_declaration_required` schema: $ref: '#/definitions/Error' example: code: missing_tx_feature error: missing transaction feature `use_shippo` summary: Get Shippo shipping rates based on the sender's and recipient's address and parcel details tags: - Online Shipping /transactions/{transaction_id}/stripe_client_secret: get: description: | This endpoint is used for the asynchronous payment flow using Stripe. The `client_secret` returned from this endpoint should be passed to [stripe.confirmCardPayment](https://stripe.com/docs/stripe-js/reference#stripe-confirm-card-payment) to start the payment process. operationId: getStripeClientSecretForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer responses: 200: description: OK schema: properties: client_secret: type: string required: - client_secret type: object 400: description: | Bad Request `code` can be one of the following: * `already_paid` * `invalid_id` * `not_accepted`: This transaction was created from a listing but the listing's creator has not yet accepted this transaction. schema: $ref: '#/definitions/Error' example: code: already_paid error: payment already made 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Get the Stripe client secret for this online transaction tags: - Online Buyer/Seller Details /transactions/{transaction_id}/stripe_publishable_key: get: description: | Returns the Publishable Key for the Stripe Platform which is hosting this transaction. operationId: basic.getStripePublishableKeyForTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer produces: - application/json responses: 200: description: OK schema: example: publishable_key: pk_xXxXxXxXxXx properties: publishable_key: type: string required: - publishable_key type: object 400: description: | Bad Request `code` can be one of the following: * `invalid_id` schema: $ref: '#/definitions/Error' example: code: invalid_id error: 'couldn''t parse transaction id: abc' 403: description: | Forbidden `code` can be one of the following: * `not_buyer` * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: | Get the details for the Stripe publishable key that is in use for this online transaction tags: - Online Buyer/Seller Details /transactions/{transaction_id}/submit_order_issue: post: operationId: basic.submitOrderIssue parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: description_body required: true schema: example: description: Delivery is delayed properties: description: type: string required: - description type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z order_issue: description: Delivery delayed order_issue_raised: 2019-12-25T13:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: tracked tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `delivery_already_set` * `tracking_not_added` schema: $ref: '#/definitions/Error' example: code: already_delivered error: transaction already delivered 403: description: | Forbidden `code` can be one of the following: * `not_buyer` schema: $ref: '#/definitions/Error' example: code: not_buyer error: current user is not buyer 404: description: Not Found summary: Submit a detailed order issue for this online transaction tags: - Online Transactions /transactions/{transaction_id}/track: post: description: | After the tracking information has been submitted then the state of the transaction will be updated asynchronously by Trustap once the delivery of the item has been confirmed, at which point the `delivered` field of the transaction will be set. Offline access is allowed for this endpoint when the user has granted the `basic_tx:offline_track` scope to the client that is performing the request. operationId: basic.trackTransaction parameters: - format: int64 in: path name: transaction_id required: true type: integer - in: body name: track_transaction_body required: true schema: example: carrier: ups tracking_code: '***' properties: carrier: minLength: 1 type: string tracking_code: minLength: 1 type: string required: - carrier - tracking_code type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: tracked tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `empty_carrier` * `empty_tracking_code` * `tracking_already_added` * `payment_details_not_added` * `tracking_details_deadline_expired` * `already_cancelled` schema: $ref: '#/definitions/Error' example: code: empty_carrier error: '`carrier` parameter is required' 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Set postal tracking details for this online transaction tags: - Online Shipping /transactions/{transaction_id}/track_with_guest_seller: post: description: | Add tracking details for the guest seller specified in the header as `Trustap-User`. operationId: basic.trackTransactionWithGuestSeller parameters: - format: int64 in: path name: transaction_id required: true type: integer - description: Required in client flows, where you make API calls on behalf of another Trustap user. in: header name: Trustap-User required: false type: string - in: body name: track_transaction_body required: true schema: example: carrier: ups tracking_code: '***' properties: carrier: minLength: 1 type: string tracking_code: minLength: 1 type: string required: - carrier - tracking_code type: object responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z paid: 2019-12-25T11:00:00Z price: 1234 seller_id: 1-ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: tracked tracked: 2019-12-25T12:00:00Z tracking: carrier: ups tracking_code: '***' 400: description: | Bad Request `code` can be one of the following: * `invalid_id` * `empty_carrier` * `empty_tracking_code` * `tracking_already_added` * `payment_details_not_added` * `tracking_details_deadline_expired` * `already_cancelled` schema: $ref: '#/definitions/Error' example: code: empty_carrier error: '`carrier` parameter is required' 403: description: | Forbidden `code` can be one of the following: * `not_seller` schema: $ref: '#/definitions/Error' example: code: not_seller error: current user is not seller 404: description: Not Found summary: Set postal tracking details for this online transaction tags: - Online Shipping /transactions_by_claim_secret/{secret}/claim_as_buyer: post: description: | This endpoint allows a full user to claim for a transaction as buyer given a claim secret. operationId: basic.claimAsBuyer parameters: - in: path name: secret required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: feb33a87-3917-4538-9260-127c8a6b5232 charge: 78 created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 joined: 2019-12-25T10:00:00Z price: 1234 seller_id: ad5bb99f-85bf-47e1-be0d-15e7541c6ad7 status: joined 400: description: | Bad Request `code` can be one of the following: * `already_claimed` * `cannot_claim_own_transaction` * `missing_secret` 404: description: Not Found summary: Claim for an online transaction as buyer given a claim secret tags: - Online Transactions /transactions_by_claim_secret/{secret}/claim_as_seller: post: description: | This endpoint allows a full user to claim a transaction as seller given a claim secret. operationId: basic.claimTransactionAsSeller parameters: - in: path name: secret required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/basic.Transaction' example: buyer_id: 7525d21e-d248-4ac8-8411-ca67426e55df charge: 78 chargeseller: 0 claimed_by_buyer: 2025-09-18T10:41:29Z client_id: test-auth created: 2019-12-25T09:00:00Z currency: eur description: Soccer ticket id: 1309 is_payment_in_progress: false joined: 2019-12-25T11:00:00Z price: 1234 quantity: 1 seller_id: 9e6eb994-2879-4484-a31a-7d066ccdc5c6 status: joined 400: description: | Bad Request `code` can be one of the following: * `missing_secret` * `already_claimed` * `cannot_claim_own_transaction` * `invalid_user_platform` schema: $ref: '#/definitions/Error' example: code: already_claimed error: transaction already claimed 404: description: Not Found summary: Claim an Online transaction as the seller tags: - Online Transactions /users/clients/{client_id}/users/{user_id}: get: operationId: users_client.getUserByClientID parameters: - in: path name: client_id required: true type: string - in: path name: user_id required: true type: string responses: 200: description: OK schema: $ref: '#/definitions/users_client.User' summary: Get user details for the specific client tags: - Users produces: - application/json schemes: - https security: - OAuth2: [] securityDefinitions: APIKey: type: basic OAuth2: authorizationUrl: https://sso.trustap.com/auth/realms/trustap-stage/protocol/openid-connect/auth flow: accessCode scopes: basic_ls:offline_accept_listing: | This client may accept Online listings on the user's behalf while the user is offline. basic_ls:offline_create: | This client may create Online listings for the user while the user is offline. basic_tx:offline_accept_payment: | This client may accept payments for Online transactions on the user's behalf while the user is offline. basic_tx:offline_cancel: | This client may cancel Online transactions on the user's behalf while the user is offline. basic_tx:offline_claim: | This client may claim Online transactions on the user's behalf while the user is offline. basic_tx:offline_complain: | This client may submit complaints for Online transactions on the user's behalf while the user is offline. basic_tx:offline_create_join: | This client may create and join Online transactions on the user's behalf while the user is offline. basic_tx:offline_track: | This client may submit tracking information for Online transactions on the user's behalf while the user is offline. openid: | This client is making an OpenID Connect request. p2p_ls:offline_create: | This client may create F2F listings for the user while the user is offline. p2p_ls:offline_update: | This client may update F2F listings on the user's behalf while the user is offline. p2p_tx:offline_accept_deposit: | This client may accept deposits for F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_cancel: | This client may cancel F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_claim: | This client may claim F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_complain: | This client may submit complaints for F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_confirm_handover: | This client may confirm handovers for F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_create_join: | This client may create and join F2F transactions on the user's behalf while the user is offline. p2p_tx:offline_set_price: | This client may set the price for F2F transactions on the user's behalf while the user is offline. profile: | This client may access the user's default profile claims: `name`, `family_name`, `given_name`, `middle_name`, `nickname`, `preferred_username`, `profile`, `picture`, `website`, `gender`, `birthdate`, `zoneinfo`, `locale`, and `updated_at`. tokenUrl: https://sso.trustap.com/auth/realms/trustap-stage/protocol/openid-connect/token type: oauth2 swagger: "2.0" tags: - description: | Online transactions are used when the goods are delivered using registered mail. name: Online Transactions - description: | Clients represent partner applications. name: Clients - description: | Users represent users of the platform. name: Buyers and Sellers - description: | Personal endpoints are used for managing personal details for users, for "Know Your Customer" requirements. name: Personal - description: | Notifications log updates for users. name: Notifications - description: | F2F2 transactions are used when the goods are delivered in person. name: F2F Transactions - description: | Payment endpoints for face-to-face transactions. name: F2F Payment - description: | Handover endpoints for face-to-face transactions. name: F2F Handover - description: | Complaint endpoints for face-to-face transactions. name: F2F Complaint - description: | Cancel endpoints for face-to-face transactions. name: F2F Cancel - description: | User details endpoints for face-to-face transactions. name: F2F Buyer/Seller Details - description: | Subscriptions are used for recurring payments. name: Subscriptions - description: | These endpoints are no longer supported. We do not recommend using these endpoints. name: F2F Multi-use Listings - description: | These endpoints are no longer supported. We do not recommend using these endpoints. name: F2F Single-use Listings - description: | These endpoints are no longer supported. We do not recommend using these endpoints. name: Online Multi-use Listings - description: | These endpoints are no longer supported. We do not recommend using these endpoints. name: Online Single-use Listings - description: | Endpoints for Trustap lite name: Trustap lite x-tagGroups: - name: Users tags: - Buyers and Sellers - Clients - Personal - name: Online transactions tags: - Online Transactions - Online Payment - Online Shipping - Online Complaint - Online Cancel - Online Buyer/Seller Details - name: Face-to-face transactions tags: - F2F Transactions - F2F Payment - F2F Handover - F2F Complaint - F2F Cancel - F2F Buyer/Seller Details - name: Trustap lite tags: - Trustap Lite - name: Notifications tags: - Notifications - name: Deprecated endpoints tags: - Online Multi-use Listings - Online Single-use Listings - F2F Multi-use Listings - F2F Single-use Listings