# SumSub KYC token sharing

{% hint style="warning" %}
This flow is disabled by default and only supported for merchants signing a special contract. Contact customer support team for more information.
{% endhint %}

{% hint style="danger" %}
This flow does not skip KYC on XGateway side. Any missing information, including liveness check, PoA, accepting XGateway and XGateway partners T\&C will still be required from the customer.&#x20;
{% endhint %}

{% hint style="info" %}
Testing this flow on Demo requires generation of tokens on SumSub sandbox environment.&#x20;

Succesfull testing is not guaranteed, as it relies on SumSub sandbox environment.
{% endhint %}

The flow includes the following steps:

1. Generate the token of the applicant on [SumSub side](https://docs.sumsub.com/reference/generate-share-token-query). The customer should already have the KYC passed.&#x20;
2. Create bank account for the customer.&#x20;
3. Export KYC applicant with the same external customer id&#x20;
4. Check that KYC applicant is exported successfully
   1. If the user status is NOT KYC\_FULL\_USER - request a KYC link and ask the customer to finish the KYC by filling the missing details.&#x20;
5. Check the bank account status and retrieve bank account data for a customer before showing the IBAN to the customer
   1. Funds sent to the IBAN of a user with status different from KYC\_FULL\_USER will be bounced back.&#x20;

### API requests

This section includes API description of evey endpoint needed to get the bank account details via token sharing.&#x20;

## Creates a bank transfer account for a customer.

> Registers a new bank transfer account for a customer associated with the given external ID.\
> Available only for FULL\_USER KYC applicants.\
> \
> Access to this endpoint requires a valid API key. The API key is sent in the \`x-api-key\` header on requests.

```json
{"openapi":"3.0.0","info":{"title":"x-gateway-external-api","version":"0.0.1"},"servers":[{"url":"https://api.xgateway.tech/api/v2"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"in":"header","name":"x-api-key","type":"apiKey"}},"schemas":{"AppSuccessResponse_CreateBankTransferAccountResponse_":{"description":"The AppSuccessResponse object contains general information about the success execution.","properties":{"success":{"type":"boolean","default":true},"data":{"$ref":"#/components/schemas/CreateBankTransferAccountResponse"}},"required":["success","data"],"type":"object","additionalProperties":false},"CreateBankTransferAccountResponse":{"properties":{"accountNumber":{"type":"string"},"bic":{"type":"string"},"customerFirstName":{"type":"string"},"customerLastName":{"type":"string"},"country":{"type":"string"},"currency":{"$ref":"#/components/schemas/BankTransferFiatCurrency"},"iban":{"type":"string"},"sortCode":{"type":"string"},"status":{"$ref":"#/components/schemas/UnblockBankAccountStatus"}},"required":["country","currency","status"],"type":"object","additionalProperties":false},"BankTransferFiatCurrency":{"type":"string","enum":["EUR","GBP"],"description":"Represents supported fiat currencies for `bank-transfer` payments in the payment processing\nsystem.\n\nCurrencies:\n- `EUR` - Euro\n- `GBP` - Pound Sterling."},"UnblockBankAccountStatus":{"type":"string"},"AppErrorResponse":{"description":"The AppErrorResponse object contains general information about the error message.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"IAppError":{"description":"The IAppError interface represents an application error message.","properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/AppClientErrorResponseCode"},{"$ref":"#/components/schemas/AppServerErrorResponseCode"}]},"message":{"type":"string"}},"required":["code","message"],"type":"object","additionalProperties":false},"AppClientErrorResponseCode":{"type":"string","enum":["bad_request","db_violation","unauthorized","payment_required","forbidden","not_found","method_not_allowed","not_acceptable","proxy_authentication_required","request_timeout","conflict","db_unique_violation","gone","length_required","precondition_failed","payload_too_large","uri_too_long","unsupported_media_type","range_not_satisfiable","expectation_failed","misdirected_request","unprocessable_content","db_non_null_violation","locked","failed_dependency","upgrade_required","precondition_required","too_many_requests","request_header_fields_too_large","unavailable_for_legal_reasons"],"nullable":false,"description":"The AppClientErrorResponseCode object contains all client error response codes."},"AppServerErrorResponseCode":{"type":"string","enum":["internal_server_error","not_implemented","bad_gateway","service_unavailable","gateway_timeout","http_version_not_supported","variant_also_negotiates","insufficient_storage","loop_detected","not_extended","network_authentication_required"],"nullable":false,"description":"The AppServerErrorResponseCode object contains all server error response codes."},"AppAuthenticationErrorResponse":{"description":"The AppAuthenticationErrorResponse object contains general information about the authentication\nerror.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array","default":[{"code":"unauthorized","message":"You do not have permission to access this resource."}]}},"required":["success","errors"],"type":"object","additionalProperties":false},"AppValidationErrorResponse":{"description":"The AppValidationErrorResponse object contains general information about the validation error.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"CreateBankTransferBankAccountInput":{"properties":{"currency":{"type":"string","enum":["EUR","GBP"]}},"type":"object"}}},"paths":{"/customer/{id}/bank-transfer/bank-account":{"post":{"operationId":"CreateBankTransferAccount","responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppSuccessResponse_CreateBankTransferAccountResponse_"}}}},"400":{"description":"Database violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAuthenticationErrorResponse"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppValidationErrorResponse"}}}},"422":{"description":"Unprocessable content","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppValidationErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}}},"description":"Registers a new bank transfer account for a customer associated with the given external ID.\nAvailable only for FULL_USER KYC applicants.\n\nAccess to this endpoint requires a valid API key. The API key is sent in the `x-api-key` header on requests.","summary":"Creates a bank transfer account for a customer.","tags":["Customer"],"parameters":[{"description":"- The external identifier for the customer, used to uniquely identify them\nand associate them with a merchant.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"- Contains customer data for creating a bank\naccount.\n\n__Params__:\n- __currency__ - The currency code. \"EUR\" || \"GBP\".","required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBankTransferBankAccountInput","description":"- Contains customer data for creating a bank\naccount.\n\n__Params__:\n- __currency__ - The currency code. \"EUR\" || \"GBP\"."}}}}}}}}
```

<br>

## Export a KYC applicant from external provider.

> Exports an existing applicant from a KYC provider and binds it with a customer using the given external ID.\
> \
> Access to this endpoint requires a valid API key. The API key is sent in the \`x-api-key\` header on requests.

```json
{"openapi":"3.0.0","info":{"title":"x-gateway-external-api","version":"0.0.1"},"servers":[{"url":"https://api.xgateway.tech/api/v2"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"in":"header","name":"x-api-key","type":"apiKey"}},"schemas":{"AppSuccessResponse_string_":{"description":"The AppSuccessResponse object contains general information about the success execution.","properties":{"success":{"type":"boolean","default":true},"data":{"type":"string"}},"required":["success","data"],"type":"object","additionalProperties":false},"AppErrorResponse":{"description":"The AppErrorResponse object contains general information about the error message.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"IAppError":{"description":"The IAppError interface represents an application error message.","properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/AppClientErrorResponseCode"},{"$ref":"#/components/schemas/AppServerErrorResponseCode"}]},"message":{"type":"string"}},"required":["code","message"],"type":"object","additionalProperties":false},"AppClientErrorResponseCode":{"type":"string","enum":["bad_request","db_violation","unauthorized","payment_required","forbidden","not_found","method_not_allowed","not_acceptable","proxy_authentication_required","request_timeout","conflict","db_unique_violation","gone","length_required","precondition_failed","payload_too_large","uri_too_long","unsupported_media_type","range_not_satisfiable","expectation_failed","misdirected_request","unprocessable_content","db_non_null_violation","locked","failed_dependency","upgrade_required","precondition_required","too_many_requests","request_header_fields_too_large","unavailable_for_legal_reasons"],"nullable":false,"description":"The AppClientErrorResponseCode object contains all client error response codes."},"AppServerErrorResponseCode":{"type":"string","enum":["internal_server_error","not_implemented","bad_gateway","service_unavailable","gateway_timeout","http_version_not_supported","variant_also_negotiates","insufficient_storage","loop_detected","not_extended","network_authentication_required"],"nullable":false,"description":"The AppServerErrorResponseCode object contains all server error response codes."},"AppAuthenticationErrorResponse":{"description":"The AppAuthenticationErrorResponse object contains general information about the authentication\nerror.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array","default":[{"code":"unauthorized","message":"You do not have permission to access this resource."}]}},"required":["success","errors"],"type":"object","additionalProperties":false},"AppValidationErrorResponse":{"description":"The AppValidationErrorResponse object contains general information about the validation error.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"ExportKycApplicantInput":{"properties":{"sourceOfFunds":{"type":"string","enum":["BUSINESS_INCOME","OTHER","PENSION","SALARY"]},"shareToken":{"type":"string"}},"type":"object"}}},"paths":{"/customer/{id}/bank-transfer/export-kyc-applicant":{"post":{"operationId":"ExportKycApplicant","responses":{"201":{"description":"Applicant exported successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppSuccessResponse_string_"}}}},"400":{"description":"Database violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAuthenticationErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"422":{"description":"Unprocessable content","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppValidationErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}}},"description":"Exports an existing applicant from a KYC provider and binds it with a customer using the given external ID.\n\nAccess to this endpoint requires a valid API key. The API key is sent in the `x-api-key` header on requests.","summary":"Export a KYC applicant from external provider.","tags":["Customer"],"parameters":[{"description":"- The external identifier for the customer, used to uniquely identify them\nand associate them with a merchant.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"- Contains share token and additional params for exporting application data.\n\n__Params__:\n- __shareToken__ - The share token you got from the KYC provider to export the applicant.\n- __sourceOfFunds__ - The source of funds. \"BUSINESS_INCOME\" || \"PENSION\" || \"SALARY\" || \"OTHER\".","required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportKycApplicantInput","description":"- Contains share token and additional params for exporting application data.\n\n__Params__:\n- __shareToken__ - The share token you got from the KYC provider to export the applicant.\n- __sourceOfFunds__ - The source of funds. \"BUSINESS_INCOME\" || \"PENSION\" || \"SALARY\" || \"OTHER\"."}}}}}}}}
```

## Retrieves the details of a Know Your Customer (KYC) application for a specified customer.

> Retrieves the details of a Know Your Customer (KYC) application for a specified customer.\
> This includes the KYC status, any missing documents, and details about any issues or rejections in the KYC process.\
> \
> Access to this endpoint requires a valid API key. The API key is sent in the \`x-api-key\` header on requests.\
> \
> \*\*Status values:\*\*\
> \- \`null\` - No customer or customer profile exists yet. Customer needs to be created and have an profile.\
> \- \`"CREATED"\` - Customer exists, but KYC applicant has not been created yet.\
> \- Other values - KYC process is in progress or completed (e.g., "FULL\_USER", "SOFT\_KYC\_FAILED", etc.).

```json
{"openapi":"3.0.0","info":{"title":"x-gateway-external-api","version":"0.0.1"},"servers":[{"url":"https://api.xgateway.tech/api/v2"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"in":"header","name":"x-api-key","type":"apiKey"}},"schemas":{"AppSuccessResponse_KycApplicationDetailsResponse_":{"description":"The AppSuccessResponse object contains general information about the success execution.","properties":{"success":{"type":"boolean","default":true},"data":{"$ref":"#/components/schemas/KycApplicationDetailsResponse"}},"required":["success","data"],"type":"object","additionalProperties":false},"KycApplicationDetailsResponse":{"properties":{"id":{"type":"string"},"status":{"$ref":"#/components/schemas/CustomerBankAccountStatus"},"kycProcessingStatus":{"allOf":[{"$ref":"#/components/schemas/KycProcessingStatus"}],"nullable":true},"docsMissing":{"items":{"properties":{"docType":{"$ref":"#/components/schemas/UnblockKYCDocType"}},"required":["docType"],"type":"object"},"type":"array"},"kycEndUserErrorMessage":{"type":"string"},"kycRejectLabel":{"type":"string"},"missingLegalDocuments":{"items":{"properties":{"docType":{"$ref":"#/components/schemas/UnblockLegalDocType"}},"required":["docType"],"type":"object"},"type":"array"}},"required":["id","status"],"type":"object","additionalProperties":false},"CustomerBankAccountStatus":{"allOf":[{"$ref":"#/components/schemas/UnblockKycSubType"}],"nullable":true,"description":"Type alias for customer bank account KYC status.\nActs as a naming mask to avoid exposing \"Unblock\" provider name in OpenAPI specification.\nRepresents all possible KYC verification statuses for a bank transfer customer."},"UnblockKycSubType":{"description":"Represents possible customer verification statuses in Unblock system.","enum":["CREATED","FULL_USER","KYC_NEEDED","PENDING_KYC_DATA","KYC_PENDING","SOFT_KYC_FAILED","HARD_KYC_FAILED","SUSPENDED"],"type":"string"},"KycProcessingStatus":{"description":"Represents the current in-flight KYC operation for a customer provider profile.\nThis is an internal X-Gateway operational state, separate from the provider-defined KYC lifecycle.\nThe column is null when no operation is in progress.","enum":["USER_CREATION_IN_PROGRESS","APPLICANT_CREATION_IN_PROGRESS","DOCUMENT_UPLOAD_IN_PROGRESS","VERIFICATION_IN_PROGRESS"],"type":"string"},"UnblockKYCDocType":{"enum":["ID_CARD","PASSPORT","DRIVERS","RESIDENCE_PERMIT","UTILITY_BILL","SELFIE","VIDEO_SELFIE","PROFILE_IMAGE","ID_DOC_PHOTO","AGREEMENT","CONTRACT","DRIVERS_TRANSLATION","VEHICLE_REGISTRATION_CERTIFICATE","PAYMENT_METHOD","BANK_CARD","COVID_VACCINATION_FORM","OTHER"],"type":"string"},"UnblockLegalDocType":{"enum":["PRIVACY_POLICY","TERMS_AND_CONDITIONS","TERMS_OF_SERVICE","MERCHANT_CUSTOM_DOCUMENT"],"type":"string"},"AppErrorResponse":{"description":"The AppErrorResponse object contains general information about the error message.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"IAppError":{"description":"The IAppError interface represents an application error message.","properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/AppClientErrorResponseCode"},{"$ref":"#/components/schemas/AppServerErrorResponseCode"}]},"message":{"type":"string"}},"required":["code","message"],"type":"object","additionalProperties":false},"AppClientErrorResponseCode":{"type":"string","enum":["bad_request","db_violation","unauthorized","payment_required","forbidden","not_found","method_not_allowed","not_acceptable","proxy_authentication_required","request_timeout","conflict","db_unique_violation","gone","length_required","precondition_failed","payload_too_large","uri_too_long","unsupported_media_type","range_not_satisfiable","expectation_failed","misdirected_request","unprocessable_content","db_non_null_violation","locked","failed_dependency","upgrade_required","precondition_required","too_many_requests","request_header_fields_too_large","unavailable_for_legal_reasons"],"nullable":false,"description":"The AppClientErrorResponseCode object contains all client error response codes."},"AppServerErrorResponseCode":{"type":"string","enum":["internal_server_error","not_implemented","bad_gateway","service_unavailable","gateway_timeout","http_version_not_supported","variant_also_negotiates","insufficient_storage","loop_detected","not_extended","network_authentication_required"],"nullable":false,"description":"The AppServerErrorResponseCode object contains all server error response codes."},"AppAuthenticationErrorResponse":{"description":"The AppAuthenticationErrorResponse object contains general information about the authentication\nerror.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array","default":[{"code":"unauthorized","message":"You do not have permission to access this resource."}]}},"required":["success","errors"],"type":"object","additionalProperties":false}}},"paths":{"/customer/{id}/bank-transfer/kyc":{"get":{"operationId":"GetKycApplicationDetails","responses":{"200":{"description":"Ok","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppSuccessResponse_KycApplicationDetailsResponse_"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAuthenticationErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}}},"description":"Retrieves the details of a Know Your Customer (KYC) application for a specified customer.\nThis includes the KYC status, any missing documents, and details about any issues or rejections in the KYC process.\n\nAccess to this endpoint requires a valid API key. The API key is sent in the `x-api-key` header on requests.\n\n**Status values:**\n- `null` - No customer or customer profile exists yet. Customer needs to be created and have an profile.\n- `\"CREATED\"` - Customer exists, but KYC applicant has not been created yet.\n- Other values - KYC process is in progress or completed (e.g., \"FULL_USER\", \"SOFT_KYC_FAILED\", etc.).","summary":"Retrieves the details of a Know Your Customer (KYC) application for a specified customer.","tags":["Customer"],"parameters":[{"description":"- The external identifier for the customer for whom to retrieve KYC details.","in":"path","name":"id","required":true,"schema":{"type":"string"}}]}}}}
```

## Generates a KYC checkout link for a customer.

> Initiates a KYC checkout link for a specified customer.\
> \
> It generates a KYC checkout link for the customer, optionally localized by the provided locale.

```json
{"openapi":"3.0.0","info":{"title":"x-gateway-external-api","version":"0.0.1"},"servers":[{"url":"https://api.xgateway.tech/api/v2"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"in":"header","name":"x-api-key","type":"apiKey"}},"schemas":{"AppSuccessResponse_string_":{"description":"The AppSuccessResponse object contains general information about the success execution.","properties":{"success":{"type":"boolean","default":true},"data":{"type":"string"}},"required":["success","data"],"type":"object","additionalProperties":false},"AppErrorResponse":{"description":"The AppErrorResponse object contains general information about the error message.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"IAppError":{"description":"The IAppError interface represents an application error message.","properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/AppClientErrorResponseCode"},{"$ref":"#/components/schemas/AppServerErrorResponseCode"}]},"message":{"type":"string"}},"required":["code","message"],"type":"object","additionalProperties":false},"AppClientErrorResponseCode":{"type":"string","enum":["bad_request","db_violation","unauthorized","payment_required","forbidden","not_found","method_not_allowed","not_acceptable","proxy_authentication_required","request_timeout","conflict","db_unique_violation","gone","length_required","precondition_failed","payload_too_large","uri_too_long","unsupported_media_type","range_not_satisfiable","expectation_failed","misdirected_request","unprocessable_content","db_non_null_violation","locked","failed_dependency","upgrade_required","precondition_required","too_many_requests","request_header_fields_too_large","unavailable_for_legal_reasons"],"nullable":false,"description":"The AppClientErrorResponseCode object contains all client error response codes."},"AppServerErrorResponseCode":{"type":"string","enum":["internal_server_error","not_implemented","bad_gateway","service_unavailable","gateway_timeout","http_version_not_supported","variant_also_negotiates","insufficient_storage","loop_detected","not_extended","network_authentication_required"],"nullable":false,"description":"The AppServerErrorResponseCode object contains all server error response codes."},"AppAuthenticationErrorResponse":{"description":"The AppAuthenticationErrorResponse object contains general information about the authentication\nerror.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array","default":[{"code":"unauthorized","message":"You do not have permission to access this resource."}]}},"required":["success","errors"],"type":"object","additionalProperties":false},"InitiateCheckoutBaseSchemaInput":{"properties":{"isKycNoSdk":{"type":"boolean"},"applicationId":{"type":"string"},"locale":{"type":"string"}},"type":"object"}}},"paths":{"/customer/{id}/bank-transfer/kyc/initiate":{"post":{"operationId":"InitiateCheckoutKYC","responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppSuccessResponse_string_"}}}},"400":{"description":"Database violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAuthenticationErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}}},"description":"Initiates a KYC checkout link for a specified customer.\n\nIt generates a KYC checkout link for the customer, optionally localized by the provided locale.","summary":"Generates a KYC checkout link for a customer.","tags":["Customer"],"parameters":[{"description":"- Unique identifier of the customer.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"- The request body containing KYC link options.","required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitiateCheckoutBaseSchemaInput","description":"- The request body containing KYC link options."}}}}}}}}
```

## Retrieves bank transfer details for all accounts of a specified customer.

> Retrieves bank transfer details for all accounts of a specified customer.\
> \
> This endpoint fetches the bank transfer details for all accounts associated with a given\
> customer ID.\
> \
> It ensures that the requester has appropriate authorization before providing access to the\
> sensitive account information.\
> \
> Access to this endpoint requires a valid API key. The API key is sent in the \`x-api-key\` header on requests.\
> \
> The response includes an array of accounts with following properties:\
> \- account number, for GBP\
> \- BIC, for EUR\
> \- country\
> \- currency\
> \- IBAN, for EUR\
> \- ID\
> \- sort core, for GBP\
> \- status.

```json
{"openapi":"3.0.0","info":{"title":"x-gateway-external-api","version":"0.0.1"},"servers":[{"url":"https://api.xgateway.tech/api/v2"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"in":"header","name":"x-api-key","type":"apiKey"}},"schemas":{"AppSuccessResponse_BankTransferAccountResponse-Array_":{"description":"The AppSuccessResponse object contains general information about the success execution.","properties":{"success":{"type":"boolean","default":true},"data":{"items":{"$ref":"#/components/schemas/BankTransferAccountResponse"},"type":"array"}},"required":["success","data"],"type":"object","additionalProperties":false},"BankTransferAccountResponse":{"properties":{"accountNumber":{"type":"string"},"bic":{"type":"string"},"customerFirstName":{"type":"string"},"customerLastName":{"type":"string"},"country":{"type":"string","nullable":true},"currency":{"type":"string","nullable":true},"iban":{"type":"string"},"id":{"type":"string"},"sortCode":{"type":"string"},"status":{"$ref":"#/components/schemas/CustomerBankAccountStatus"}},"required":["country","currency","id","status"],"type":"object","additionalProperties":false},"CustomerBankAccountStatus":{"allOf":[{"$ref":"#/components/schemas/UnblockKycSubType"}],"nullable":true,"description":"Type alias for customer bank account KYC status.\nActs as a naming mask to avoid exposing \"Unblock\" provider name in OpenAPI specification.\nRepresents all possible KYC verification statuses for a bank transfer customer."},"UnblockKycSubType":{"description":"Represents possible customer verification statuses in Unblock system.","enum":["CREATED","FULL_USER","KYC_NEEDED","PENDING_KYC_DATA","KYC_PENDING","SOFT_KYC_FAILED","HARD_KYC_FAILED","SUSPENDED"],"type":"string"},"AppErrorResponse":{"description":"The AppErrorResponse object contains general information about the error message.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array"}},"required":["success","errors"],"type":"object","additionalProperties":false},"IAppError":{"description":"The IAppError interface represents an application error message.","properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/AppClientErrorResponseCode"},{"$ref":"#/components/schemas/AppServerErrorResponseCode"}]},"message":{"type":"string"}},"required":["code","message"],"type":"object","additionalProperties":false},"AppClientErrorResponseCode":{"type":"string","enum":["bad_request","db_violation","unauthorized","payment_required","forbidden","not_found","method_not_allowed","not_acceptable","proxy_authentication_required","request_timeout","conflict","db_unique_violation","gone","length_required","precondition_failed","payload_too_large","uri_too_long","unsupported_media_type","range_not_satisfiable","expectation_failed","misdirected_request","unprocessable_content","db_non_null_violation","locked","failed_dependency","upgrade_required","precondition_required","too_many_requests","request_header_fields_too_large","unavailable_for_legal_reasons"],"nullable":false,"description":"The AppClientErrorResponseCode object contains all client error response codes."},"AppServerErrorResponseCode":{"type":"string","enum":["internal_server_error","not_implemented","bad_gateway","service_unavailable","gateway_timeout","http_version_not_supported","variant_also_negotiates","insufficient_storage","loop_detected","not_extended","network_authentication_required"],"nullable":false,"description":"The AppServerErrorResponseCode object contains all server error response codes."},"AppAuthenticationErrorResponse":{"description":"The AppAuthenticationErrorResponse object contains general information about the authentication\nerror.","properties":{"success":{"type":"boolean","default":false},"errors":{"items":{"$ref":"#/components/schemas/IAppError"},"type":"array","default":[{"code":"unauthorized","message":"You do not have permission to access this resource."}]}},"required":["success","errors"],"type":"object","additionalProperties":false}}},"paths":{"/customer/{id}/bank-transfer":{"get":{"operationId":"GetBankTransferAccounts","responses":{"200":{"description":"Ok","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppSuccessResponse_BankTransferAccountResponse-Array_"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAuthenticationErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorResponse"}}}}},"description":"Retrieves bank transfer details for all accounts of a specified customer.\n\nThis endpoint fetches the bank transfer details for all accounts associated with a given\ncustomer ID.\n\nIt ensures that the requester has appropriate authorization before providing access to the\nsensitive account information.\n\nAccess to this endpoint requires a valid API key. The API key is sent in the `x-api-key` header on requests.\n\nThe response includes an array of accounts with following properties:\n- account number, for GBP\n- BIC, for EUR\n- country\n- currency\n- IBAN, for EUR\n- ID\n- sort core, for GBP\n- status.","summary":"Retrieves bank transfer details for all accounts of a specified customer.","tags":["Customer"],"parameters":[{"description":"- The external ID of the customer whose bank transfer details are being\nrequested.","in":"path","name":"id","required":true,"schema":{"type":"string"}}]}}}}
```
