PayWithMyBank (Trustly) identity API
The identity API from PayWithMyBank (Trustly) — 3 operation(s) for identity.
The identity API from PayWithMyBank (Trustly) — 3 operation(s) for identity.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/paywithmybank-identity-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Identity API
version: 1.0.0
servers:
- url: https://sandbox.trustly.one/api/v1
description: Sandbox
tags:
- name: identity
paths:
/transactions/{transactionId}/user:
get:
operationId: get-trustly-id-user-data
summary: Get user
description: Retrieve the User object associated with the Trustly ID authorization transaction.
tags:
- identity
parameters:
- name: transactionId
in: path
description: Transaction ID retrieved from a Trustly Authorization transaction.
required: true
schema:
type: string
- name: expand
in: query
description: "A field in the API response to be expanded in order for more details to be provided.\nSupported values:\n * `segmentedName`: returns a segmented version of the name field returned in the response."
required: false
schema:
type: array
items:
$ref: '#/components/schemas/TransactionsTransactionIdUserGetParametersExpandSchemaItems'
- name: Authorization
in: header
description: ''
required: true
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/User'
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/Get-trustly-id-user-dataRequestBadRequestError'
/transactions/{transactionId}/user/detail:
get:
operationId: get-trustly-id-user-details
summary: Get user verification details
description: "Retrieve the verification results and details of a Trustly ID-enabled authorization transaction. The details returned by this endpoint are segmented into two lists: verifications and attributes. \n\nThe verification objects contain the `name` and `result` of the verification as well as reason codes and reason descriptions corresponding to the results. If a verification includes a sanction screening and a match was returned, the results of the screening will also be included. If no `screeningResults` property is returned in the verification object, no match was returned.\n>**Note:** Verifications are configured per application, check with your Trustly services team member for definitions of your configured verifications.\n\nThe attribute objects contain metadata which describe how the property was verified and a list of `verification` objects which apply to the attribute."
tags:
- identity
parameters:
- name: transactionId
in: path
description: Transaction ID retrieved from a Trustly Authorization transaction.
required: true
schema:
type: string
- name: expand
in: query
description: "A field in the API response to be expanded in order for more details to be provided.\nSupported values:\n * `verification`: returns human-readable reason rules and descriptions."
required: false
schema:
type: array
items:
$ref: '#/components/schemas/TransactionsTransactionIdUserDetailGetParametersExpandSchemaItems'
- name: Authorization
in: header
description: ''
required: true
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/UserVerificationDetail'
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/Get-trustly-id-user-detailsRequestBadRequestError'
/transactions/{transactionId}/feedback:
post:
operationId: post-transaction-feedback
summary: Update user status
description: "This endpoint updates the status of a user by posting feedback data to Trustly for an authorized Identity transaction. This communicates to Trustly that the user associated with the transaction has been successfully registered in the merchant system, or that the user record has been voided and therefore will not be eligible for future payment transactions. \n\nTo confirm a user was registered, set properties `status` to `4`, `subStatus` to `559` and `description` to `Registered`. To void a user who did not complete registration after completing the Trustly ID flow, set `status` to `13`, `subStatus` to `558` and `description` to `Known bad user`. \n\nfor more information about Trustly ID, see [Verify identity with Trustly ID](/integrate/retrieve-data/trustly-id)."
tags:
- identity
parameters:
- name: transactionId
in: path
description: Transaction ID retrieved from a Trustly Authorization transaction.
required: true
schema:
type: string
- name: Authorization
in: header
description: ''
required: true
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/Transaction'
'401':
description: Access not authorized
content:
application/json:
schema:
$ref: '#/components/schemas/Post-transaction-feedbackRequestUnauthorizedError'
requestBody:
content:
application/json:
schema:
type: object
properties:
status:
type: integer
default: 4
subStatus:
type: integer
default: 559
description:
type: string
default: Registered
components:
schemas:
ScreeningResult:
type: array
items:
$ref: '#/components/schemas/ScreeningResultItems'
title: ScreeningResult
SchemasAddressCountry:
type: string
enum:
- US
description: 2 character ISO Country code. Currently only the US is supported.
title: SchemasAddressCountry
WatchlistScreeningResult:
type: object
properties:
screeningType:
$ref: '#/components/schemas/ScreeningResultScreeningType'
score:
type: number
format: double
description: Match score indicating the strength of a match.
name:
type: string
description: Name of the user.
aliases:
type: array
items:
type: string
description: List of known aliases.
dateOfBirth:
type: string
format: date
description: Date of birth.
nationality:
type: string
description: Nationality.
source:
type: string
description: Source of the information.
sourceRegion:
type: string
description: Region of the source.
remarks:
type: string
description: Additional remarks.
caution:
type: string
description: Caution notes.
url:
type: string
format: uri
description: Source's URL.
address:
type: string
description: Full street address of the user with city and country.
gender:
$ref: '#/components/schemas/WatchlistScreeningResultGender'
description: Gender of the user.
designationDate:
type: string
format: date
description: Designation date.
trustedEntity:
type: string
description: The name of the entity that provided the watchlist match.
description: Screening information for Watchlist Screening.
title: WatchlistScreeningResult
PaymentCountry:
type: string
enum:
- US
- CA
- UK
- DE
- AU
description: 2-character ISO code of the country for the bank account that was selected. Currently only the US, CA, UK, DE, and AU are supported.
title: PaymentCountry
Get-trustly-id-user-detailsRequestBadRequestError:
type: object
properties:
errors:
type: array
items:
$ref: '#/components/schemas/TransactionsTransactionIdUserDetailGetResponsesContentApplicationJsonSchemaErrorsItems'
required:
- errors
title: Get-trustly-id-user-detailsRequestBadRequestError
TransactionsTransactionIdUserDetailGetResponsesContentApplicationJsonSchemaErrorsItems:
type: object
properties:
domain:
type: string
code:
type: number
format: double
location:
type: string
message:
type: string
occurredAt:
type: number
format: double
required:
- domain
- code
- location
- message
- occurredAt
title: TransactionsTransactionIdUserDetailGetResponsesContentApplicationJsonSchemaErrorsItems
PaymentPaymentType:
type: string
enum:
- '1'
- '2'
- '3'
- '4'
- '5'
- '6'
description: "Financial Institution Account Type:\n * `1`: Instant -\tInstant payment. The debit instruction is automatically initiated with that day's batch after consumer authorization.\n * `2`: Deferred - Deferred payment. Payment is authorized but the capture operation must be called to initiate the debit. You can start to initiate multiple captures that are less than or equal to the original transaction authorization amount.\n * `3`: Recurring - Recurring payment. Same as deferred but associated to a payment agreement between consumer and merchant that defines how much and when the capture can be started.\n * `4`: Disbursement - Disbursement payment. This payment type can only be used for disbursements.\n * `5`: Verification - This payment type is used to verify the customer financial institution account as the payments will be done outside of the Trustly system.\n * `6`: Retrieval\tData retrieval. This payment type is used to retrieve account and user information from Trustly without an associated payment request. This payment type is not enabled by default. Contact Trustly if you need this feature."
title: PaymentPaymentType
AttributeVerificationDetailName:
type: string
enum:
- taxId
- name
- address
- phone
- dateOfBirth
- email
- driverLicense
- deceased
description: Which attribute does this entry refer to.
title: AttributeVerificationDetailName
AdversityMediaScreeningResult:
type: object
properties:
screeningType:
$ref: '#/components/schemas/ScreeningResultScreeningType'
score:
type: number
format: double
description: Match score indicating the strength of a match.
name:
type: string
description: Name of the user.
text:
type: string
description: Text description.
url:
type: string
description: Source's URL.
title:
type: string
description: The adverse media title.
date:
type: string
format: date
description: The adverse media date.
trustedEntity:
type: string
description: The name of the entity that provided the adverse media match.
description: Screening information for Adversity Media Screening.
title: AdversityMediaScreeningResult
UserVerificationDetail:
type: object
properties:
detail:
$ref: '#/components/schemas/UserVerificationDetailDetail'
title: UserVerificationDetail
PaymentProviderTransaction:
type: object
properties:
paymentProviderTransactionId:
type: string
description: Unique payment provider transaction identifier.
status:
type: string
description: See Payment Provider Transaction Status Codes.
statusMessage:
type: string
description: Payment provider transaction status message.
signature:
type: string
statusDescription:
type: string
paymentProcessor:
$ref: '#/components/schemas/PaymentProviderTransactionPaymentProcessor'
thirdPartyDeclineCode:
type: string
clearingHouse:
type: string
instantSettle:
type: boolean
description: Whether instant settlement was used for transaction.
description: Payment Provider Transaction
title: PaymentProviderTransaction
Post-transaction-feedbackRequestUnauthorizedError:
type: object
properties:
errors:
type: array
items:
$ref: '#/components/schemas/BaseException'
required:
- errors
title: Post-transaction-feedbackRequestUnauthorizedError
PaymentProviderSubtype:
type: string
enum:
- '1000'
- '2000'
- '2001'
description: "Payment Provider Subtype:\n * `1000`: EasyOnline\n * `2000`: MEC\n * `2001`: MCD"
title: PaymentProviderSubtype
SegmentedName:
type: object
properties:
title:
type: string
description: The title of a given full name.
firstName:
type: string
description: The first name of a given full name.
middleName:
type: array
items:
type: string
description: The list of middle names of a given full name.
lastName:
type: string
description: The last name of a given full name.
suffix:
type: string
description: The suffix of a given full name.
description: The segmented version of a given name.
title: SegmentedName
TransactionStatus:
type: string
enum:
- '0'
- '1'
- '2'
- '3'
- '4'
- '5'
- '6'
- '7'
- '8'
- '10'
- '11'
- '12'
- '13'
- '14'
description: Status code of the Payment Provider Transaction record. See [Transaction Types](/integrate/api-fundamentals/status-codes-and-type-definitions#transaction-types)
title: TransactionStatus
UserVerificationResultCode:
type: string
enum:
- '1'
- '2'
- '3'
description: 'A code indicating the final outcome of the verification. May be:
* `1`: the verification was rejected.
* `2`: the verification was inconclusive.
* `3`: the verification was approved.'
title: UserVerificationResultCode
BaseException:
type: object
properties:
domain:
type: string
code:
type: integer
location:
type: string
message:
type: string
occurredAt:
type: integer
title: BaseException
StateCode:
type: string
description: 2 character ISO State code.
title: StateCode
PaymentProvider:
type: object
properties:
paymentProviderId:
type: string
description: A unique identifier for the Payment Provider.
type:
type: number
format: double
name:
type: string
description: Name of the payment provider
instantPayoutAvailable:
type: boolean
description: Whether payment provider supports instant payout.
subType:
$ref: '#/components/schemas/PaymentProviderSubType'
description: "Financial Institution Account Type:\n * `1000`: Online Banking\n * `2000`: Manual Entry\n * `2001`: Manual Entry with Challenge Deposit\n"
swift:
type: string
address:
$ref: '#/components/schemas/Address'
country:
$ref: '#/components/schemas/PaymentProviderCountry'
description: 2-letter ISO country code of the financial institution
instantPayment:
type: boolean
required:
- name
description: Details of the Financial institution
title: PaymentProvider
TransactionCurrency:
type: string
enum:
- USD
description: 3-letter ISO Currency Code. Currently only USD is supported.
title: TransactionCurrency
Get-trustly-id-user-dataRequestBadRequestError:
type: object
properties:
errors:
type: array
items:
$ref: '#/components/schemas/TransactionsTransactionIdUserGetResponsesContentApplicationJsonSchemaErrorsItems'
required:
- errors
title: Get-trustly-id-user-dataRequestBadRequestError
PaymentProviderSubType:
type: string
enum:
- '1000'
- '2000'
- '2001'
description: "Financial Institution Account Type:\n * `1000`: Online Banking\n * `2000`: Manual Entry\n * `2001`: Manual Entry with Challenge Deposit\n"
title: PaymentProviderSubType
UserVerificationReason:
type: object
properties:
code:
$ref: '#/components/schemas/UserVerificationErrorCode'
reason:
type: string
description: Descriptive text, in English, on why the user verification failed.
description: An object describing why an user verification has succeeded or failed.
title: UserVerificationReason
VerificationStatus:
type: string
enum:
- '1'
- '2'
- '3'
- '4'
description: "Verification Status:\n * `1`: Automatic - Payment verification followed Trustly internal rules.\n * `2`: ToVerify\t- Payment transaction is held (status = OnHold) for further investigation and approval by the merchant.\n * `3`: Verified - Payment was verified and approved by the merchant or Trustly (see Verification Mode).\n * `4`: Refused - Payment was denied by the merchant or Trustly after verification.\n"
title: VerificationStatus
AttributeVerificationResult:
type: integer
description: 'Indicates the result of the individual attribute verification. It can be:
* `1` meaning the attribute did not match the expected value.
* `2` meaning the result was inconclusive.
* `3` meaning attribute did match the expected attribute.'
title: AttributeVerificationResult
TransactionsTransactionIdUserGetResponsesContentApplicationJsonSchemaErrorsItems:
type: object
properties:
domain:
type: string
code:
type: number
format: double
location:
type: string
message:
type: string
occurredAt:
type: number
format: double
required:
- domain
- code
- location
- message
- occurredAt
title: TransactionsTransactionIdUserGetResponsesContentApplicationJsonSchemaErrorsItems
Transaction:
type: object
properties:
transactionId:
type: string
description: A unique transaction identifier generated by Trustly (15 character max).
transactionType:
$ref: '#/components/schemas/TransactionTransactionType'
description: Type of transaction record. See [Transaction Types](/integrate/api-fundamentals/status-codes-and-type-definitions#transaction-types)
payment:
$ref: '#/components/schemas/Payment'
currency:
$ref: '#/components/schemas/TransactionCurrency'
description: 3-letter ISO Currency Code. Currently only USD is supported.
amount:
type: string
description: The amount of the transaction. (10 characters with support for 2 decimal places)
pending:
type: string
description: The total amount that is still pending completion. (10 characters with support for 2 decimal places)
paid:
type: string
description: The total amount that was already paid. (10 characters with support for 2 decimal places)
refunded:
type: string
description: The total amount that was refunded. (10 characters with support for 2 decimal places)
reversed:
type: string
description: The total amount that was reversed. (10 characters with support for 2 decimal places)
balance:
type: string
description: The balance of the amount paid, minus the amount reversed and/or refunded. (10 characters with support for 2 decimal places)
paymentProviderTransaction:
$ref: '#/components/schemas/PaymentProviderTransaction'
status:
$ref: '#/components/schemas/TransactionStatus'
description: Status code of the Payment Provider Transaction record. See [Transaction Types](/integrate/api-fundamentals/status-codes-and-type-definitions#transaction-types)
statusMessage:
type: string
description: A descriptive status message. (120 characters)
ip:
type: string
description: The client IP address in IPv4 or IPv6 format.
createdAt:
type: integer
description: The date and time the transaction was created as a UNIX timestamp.
processedAt:
type: integer
description: The date and time the transaction was processed as a UNIX timestamp.
completedAt:
type: integer
description: The date and time the transaction was completed as a UNIX timestamp.
updatedAt:
type: integer
description: The date and time the transaction was last updated as a UNIX timestamp.
ppTrxId:
type: string
description: internal use only
merchantReference:
type: string
description: Merchants internal reference id for the transaction.
expiredAt:
type: integer
description: The date and time the preauthorization will expire as a UNIX timestamp.
recordVersion:
type: number
format: double
description: The current record version.
originalTransactionId:
type: string
fee:
type: string
timeZone:
type: string
representmentScheduledAt:
type: number
format: double
paymentProcessorType:
type: string
statusCode:
type: string
preAuthorized:
type: boolean
required:
- transactionId
- transactionType
- payment
- currency
- amount
- pending
- paid
- refunded
- reversed
- balance
- paymentProviderTransaction
- status
- statusMessage
- ip
- createdAt
- processedAt
- completedAt
- updatedAt
- merchantReference
- recordVersion
description: A Trustly transaction object
title: Transaction
PaymentAuth:
type: object
properties:
token:
type: string
description: Authorization token.
status:
type: integer
description: See Authorization Status Values.
message:
type: string
description: Authorization message.
title: PaymentAuth
AccountCountry:
type: string
enum:
- US
- CA
- UK
- DE
- AU
description: 2-character ISO code of the country for the bank account that was selected. Currently only the US, CA, UK, DE, and AU are supported.
title: AccountCountry
PaymentProviderTransactionPaymentProcessor:
type: object
properties:
paymentProcessorId:
type: string
type:
type: integer
name:
type: string
shortName:
type: string
url:
type: string
active:
type: string
title: PaymentProviderTransactionPaymentProcessor
AttributeVerificationDetailSource:
type: object
properties:
name:
type: string
description: The name of the entity where the attribute value was fetched from.
type:
type: integer
description: 'Indicates the type of the entity that provided this piece of data. It can be:
* `1` the data came from a financial institution.
* `2` the data came from the user.
* `4` the data came from an external provider.
* `5` the data came from the merchant.'
title: AttributeVerificationDetailSource
User:
type: object
properties:
name:
type: string
description: The full name of the user
address:
type: array
items:
$ref: '#/components/schemas/schemas-Address'
description: Array of addresses associated with the user.
phone:
type: array
items:
type: string
description: Array of phone numbers associated with the user.
email:
type: array
items:
type: string
description: Array of e-mail addresses associated with the user.
dateOfBirth:
type: string
description: The date of birth of the user in the format YYYY-MM-DD
taxId:
type: string
description: The user's government issued tax ID e.g. SSN (US) or SIN (CA)
deceased:
type: boolean
description: If `true`, then the user is deceased.
driverLicense:
$ref: '#/components/schemas/schemas-DriverLicense'
eligible:
type: boolean
description: Indicates if the user has got a successful result in all verifications and is eligible.
createdAt:
type: integer
description: Timestamp representing the time the User Object was created.
updatedAt:
type: integer
description: Timestamp representing the time the User Object was last updated.
segmentedName:
$ref: '#/components/schemas/SegmentedName'
description: Trustly User
title: User
Address:
type: object
properties:
address1:
type: string
description: Address line 1 (e.g., street or PO Box)
address2:
type: string
description: Address line 2 (e.g., apartment, suite or unit number)
city:
type: string
description: City, district, town or village
state:
type: string
description: State, province or region code
zip:
type: string
description: ZIP or Postal Code
country:
type: string
description: 2 character [ISO Country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
required:
- country
description: Valid mailing or billing address associated with the customer
title: Address
Verification:
type: object
properties:
status:
$ref: '#/components/schemas/VerificationStatus'
description: "Verification Status:\n * `1`: Automatic - Payment verification followed Trustly internal rules.\n * `2`: ToVerify\t- Payment transaction is held (status = OnHold) for further investigation and approval by the merchant.\n * `3`: Verified - Payment was verified and approved by the merchant or Trustly (see Verification Mode).\n * `4`: Refused - Payment was denied by the merchant or Trustly after verification.\n"
mode:
$ref: '#/components/schemas/VerificationMode'
description: "Verification Mode:\n * `1`: VerifiedByMerchant\n * `2`: ApprovedByMerchant\n * `3`: VerifiedByTrustly\n * `4`: AmountAuthorizedByMerchant\n"
verifyCustomer:
type: boolean
description: If true, the Customer information (name and zip code) was verified against information provided by the User's bank.
title: Verification
WatchlistScreeningResultGender:
type: string
enum:
- male
- female
description: Gender of the user.
title: WatchlistScreeningResultGender
UserVerificationErrorCode:
type: string
enum:
- '-1'
- '1'
- '2'
- '3'
- '4'
- '5'
- '6'
description: 'An error code indicating why the user verification has failed. May be:
* `-1`: no error. the verification was successful.
* `1`: there was an internal, unspecified error (should not happen).
* `2`: the user is below the minimum age.
* `3`: some of the attributes did not meet the minimum verification criteria.
* `4`: some mandatory attributes are not available.
* `5`: the user was identified as a person who is deceased.
* `6`: entries were matched during the screening process'
title: UserVerificationErrorCode
AttributeVerificationMethod:
type: integer
description: 'Indicates which type of verification was performed. It can be:
* `1` means electronic identity verification.
* `2` meaning it is manual document verification.
* `3` meaning it is OCR verification.
* `4` meaning it is Trusted Entity.'
title: AttributeVerificationMethod
ScreeningResultScreeningType:
type: string
enum:
- '1'
- '2'
- '3'
description: 'Type of screening being performed. May be:
* `1`: Watchlist Screening.
* `2`: Adverse Media Screening.
* `3`: PEP Screening.'
title: ScreeningResultScreeningType
PaymentMerchant:
type: object
properties:
merchantId:
type: string
description: Unique Trustly Merchant ID.
name:
type: string
description: Merchants name.
title: PaymentMerchant
schemas-Address:
type: object
properties:
address1:
type: string
description: Address Line 1.
address2:
type: string
description: Address Line 2.
city:
type: string
description: Address City.
state:
$ref: '#/components/schemas/StateCode'
zip:
type: string
description: 5 character US Zip Code.
country:
$ref: '#/components/schemas/SchemasAddressCountry'
description: 2 character ISO Country code. Currently only the US is supported.
required:
- country
title: schemas-Address
Recurrence:
type: object
properties:
startDate:
type: string
format: date-time
description: Recurring payment start date as a UNIX timestamp.
endDate:
type: string
format: date-time
description: Recurring payment end date as a UNIX timestamp.
nextOccurrence:
type: string
format: date-time
description: When the next capture will be issued if using automatic captures as a UNIX timestamp.
recurringAmount:
type: string
description: Recurring payment amount. (maximum of 10 characters with support for 2 decimal places)
debtSettlement:
type: string
description: Any debt amount settlement done outside of the Trustly like discounts or when consumers pays one recurring debt using another payment method like traditional checks or credit cards. (maximum of 10 characters with support for 2 decimal places)
frequency:
type: integer
default: 1
description: 'How many payments per frequencyUnit. Defaults to 1. Example: To define 2 recurring payments every 3 months set: frequency=2, frequencyUnit=3 and frequencyUnitType=3.'
frequencyUnit:
type: number
format: double
description: Defines with frequencyUnitType the interval of the frequency of payments.
frequencyUnitType:
$ref: '#/components/schemas/RecurrenceFrequencyUnitType'
description: Frequency Unit Type
automaticCapture:
type: boolean
description: If true, payment captures are issued automatically.
recurrenceId:
type: string
description: Recurring payment options
title: Recurrence
TransactionsTransactionIdUserGetParametersExpandSchemaItems:
type: string
enum:
- segmented
# --- truncated at 32 KB (56 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/paywithmybank/refs/heads/main/openapi/paywithmybank-identity-api-openapi.yml