Salt Edge PSD2 Compliance Logo
OAuth Authentication Flow OAuth Authentication Flow
Embedded Authentication Flow Embedded Authentication Flow

Show

Return current state of a token.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7fSwiZXhwIjoxNzE0MDQ4OTU2fQ.XD5fDe5X6z8PdHqg1zGNL14aOC9BWjfNzOa04RlPzjTZuLPAazqfuoImqf4zUlVqIsrXGX8-p5GV4JlqOCkuIe0QrBIwGoEUnKQxRS0rPlalsSGDSJTYh24czB4EiWtMKx24dJM3WMRvxxCi9RzwbwAlMMYC1znXpsIV718wKua-GUx8RsV3W6p7bVtg3vye3Fbi45944Sf9Xy6X3gTTJIIvbowgUBwiL3U-pBKBINyj-TjJcs38GaB_0q-wyqmNOnllKZTEAJJL0S7TVh7eiaAG20-0Czs4pNECguzgYrdurWKY2mwdOTAUuXdRFSwSa68rOtlC1BPJARyQ9wkSAA" \ 
 -H "App-Id: 6mWl9hbxoN3rg_nX4804tw" \ 
 -H "App-Secret: 6FdCub2C2AMQbyaI6KSv4Q" \ 
 -H "Access-Token: 7eb89bd116268f02b5ab5ab6f46a89a65a8476d8c287a84fdceae03724d5511ae445b0342c73fc02681b3fcbbfeb12cf78e9292956b67ea76d20dfff0a1ba7a2" \ 
 -H "Client-Request-Id: 54" \ 
 -X GET "/api/v2/tokens"

Example of request parameters

{"data":{},"exp":1574093211}

Example of response

{"data":{"scopes":["accounts","transactions","kyc","payments","funds_availability","trusted_beneficiaries"],"access_token_expires_at":"2019-11-18T16:04:51.638Z"}}
Request

GET /api/v2/tokens

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Access-Token string, required Token for which we are requesting info. Can raise: TokenMissing, TokenNotFound, TokenRevoked, TokenExpired
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
data
hash, required
Wrapper for the data.
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
TokenMissing 400 This request cannot be performed without Access_Token header.
AuthorizationMissing 401 Authorization header is missing.
TokenNotFound 401 Token specified in request does not exist or cannot be retrieved.
TokenRevoked 401 Token specified in request is revoked and cannot be used anymore.
TokenExpired 401 Token specified in request is expired and cannot be used.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Remote

Initiate the process of authentication on behalf of PSU. During this process, TPP will receive callbacks with instructions and current status of session. Prior to this, TPP is required to ask PSU for consent. TPP can also set up a custom expiration period for the consent in the field `consent_period_days`, which cannot be greater than 90 days.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7ImNyZWRlbnRpYWxzIjp7ImF1dGhvcml6YXRpb25fdHlwZSI6IlBTRF9BSVNQIn0sInByb3ZpZGVyX2NvZGUiOiJkZW1vYmFuayIsInJlZGlyZWN0X3VybCI6Imh0dHBzOi8vdXNlci53aWxsLmJlL3JlZGlyZWN0ZWQvaGVyZSIsInNjb3BlcyI6WyJhY2NvdW50cyIsInRyYW5zYWN0aW9ucyIsImt5YyIsInBheW1lbnRzIiwiZnVuZHNfYXZhaWxhYmlsaXR5IiwidHJ1c3RlZF9iZW5lZmljaWFyaWVzIl0sImNvbnNlbnRfcGVyaW9kX2RheXMiOjkwfSwiZXhwIjoxNzE0MDQ4OTU2fQ.qOhaFMobQ3bBSPWbBCb1LC8F3iRN-PyKtp9TDmjXAXcW0d5wlTq8Q6CPoBz6msQRFJC0RJA2gMtIMn7gMdoOMsUw2iadi7d4EnK2dd014k7nCUcIp258ydh7NyxHhl8frAYz6TqZ0Zm_Q3CEPa4ntYhE--ZTBfd9CUH0Mvj_-Y21vaP5KSBNYKRIioBwg_V0siU4r4KSnUgJ30jxucFkWke_MZr__gQS93LxteXu70DG-71bMU-viG6_ihUxOh4Yfy3PFFisaIvxVL6B4Q9brpyGdYmnIf1L2KHTOkTP_wg5-kJjo5GJJ8AKlSCo0ZLbfOiskh_J_NHMxZJlTopKew" \ 
 -H "App-Id: 8PmTDEfMengvyK1SNFkQ4A" \ 
 -H "App-Secret: n4eSP_GK0CLYoeoT8mOQLg" \ 
 -H "Client-Request-Id: 17" \ 
 -X POST "/api/v2/tokens/remote"

Example of request parameters

Example of response

{"data":{"session_secret":"i8wJ74uDGEMjmzjULLWB"}}
Request

POST /api/v2/tokens/remote

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
ScopesInvalid 400 Specified scopes don't match with the ones specified in Provider or OAuthApp. More info in error_message
AccessDenied 401 Action you want to perform is not allowed. More in error_message
AuthorizationMissing 401 Authorization header is missing.
ProviderNotFound 404 Provider specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Reconnect Deprecated

This endpoint allows TPP to refresh current Access-Token. The behavior can be the following: ASPSP can just return a new token, ask for MFA or ask for reconnection. In any of the cases above TPP will receive a session callback and the following behavior will be stored in the session object.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7ImNvbnNlbnRfYXBwcm92ZWQiOnRydWV9LCJleHAiOjE3MTQwNDg5NTd9.G35Dt5VKH3sB-TvbJ5wNsDiHLeL7vh2fJoBlBrwiP0sqO20wT12LcJUSbjMaRv-o-SIExoU5c2UMBZdD02cD5atqfllV5Zh_iIpru0B8Lm0PhW8M1U0qPPkIThHc5AvM57v0ZvrIySZlJdIPXjzT_QaWTBtyiPHY0B7yqyfjff4AHn7ttPJdEcCGigjWzzFtTwv_BVnQFhPdogAq7xEt4FNVtlFWtjtBmySXU9JrsCtt8HGcxbWv0xjOssP-veKAaD9_uY6ww1sBA3dy-RKrzj9LSx0QTSWXfJ_hoVVH2t2H8MoK9Cucf2nSpo-I7Vmhicl4BeER_RnL8y987QDBpA" \ 
 -H "App-Id: tUZHZ05b5klLnOH5ZgRp_Q" \ 
 -H "App-Secret: hfie0Uy_ZnvVIzh3OeA4XA" \ 
 -H "Access-Token: 81a3dac147e5bf8d31f5ef3d16d7423b80c00e66b60eb232a9c98b75af17386e15ed71e5edcf82992a0b3b0c1db58ebf222738dbbc6cf3cc5ec988d798d80fe3" \ 
 -H "Client-Request-Id: 17" \ 
 -X POST "/api/v2/tokens/reconnect"

Example of request parameters

{"data":{"consent_approved":true}}

Example of response

{"data":{"session_secret":"4VxpgSvnYrLd_LL5tarN"}}
Request

POST /api/v2/tokens/reconnect

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Access-Token string, required Token for which we are requesting info. Can raise: TokenMissing, TokenNotFound, TokenRevoked, TokenExpired
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
TokenMissing 400 This request cannot be performed without Access_Token header.
AuthorizationMissing 401 Authorization header is missing.
TokenNotFound 401 Token specified in request does not exist or cannot be retrieved.
TokenRevoked 401 Token specified in request is revoked and cannot be used anymore.
TokenExpired 401 Token specified in request is expired and cannot be used.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Revoke

Revoke an already existing and active access token.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7fSwiZXhwIjoxNzE0MDQ4OTU3fQ.B81pJXovdKic9v5bfl8S407QTjPh91c5aZeQB0ojzQy1koOXNI2dXLu1y9CxkVzs8gEWKI8vwy7x9lNWRuUU9oxMlqsno0Y15r8-oAqXa2b1G11jVef_aXUwtvTw5_odW9rpgpgbR5xRS360CvyOv4_YjGGaaaJYn5Ww8b96_RLP8sFhn0IPZY0iLv866o419Nll0mSqComdBv9UwHlUpQ8lrG-4akYGtwHrbJZnim0TsotFBge7NgeO434QkwqzEQsAb362EdM2fkZ7YX7ufLDKRYxEDuL30hgrvVcFR2fkd2jvhqTF66zLrLQKesJdPSJe7gZDSUpz-V1BeuR3LA" \ 
 -H "App-Id: iiniPo3zkfpOgmHrmk0Osg" \ 
 -H "App-Secret: gNebmvKyKAVTxY_fSVe-kQ" \ 
 -H "Access-Token: 874bcafd85e1332e8657cfb68016ed33f52b055adeead1d97fdfd96fc4cb847b957ee63f407d459b80eef76951e967501ca6c0282e4a4e7f838906856720a0bf" \ 
 -H "Client-Request-Id: 17" \ 
 -X DELETE "/api/v2/tokens"

Example of request parameters

{"data":{},"exp":1574093211}

Example of response

{"data":{"revoked":true,"access_token":"yVJ-2246zz-1yRutZstm"}}
Request

DELETE /api/v2/tokens

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Access-Token string, required Token for which we are requesting info. Can raise: TokenMissing, TokenNotFound, TokenRevoked, TokenExpired
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
data
hash, required
Wrapper for the data.
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
TokenMissing 400 This request cannot be performed without Access_Token header.
AuthorizationMissing 401 Authorization header is missing.
TokenNotFound 401 Token specified in request does not exist or cannot be retrieved.
TokenRevoked 401 Token specified in request is revoked and cannot be used anymore.
TokenExpired 401 Token specified in request is expired and cannot be used.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Show

Due to the asynchronous nature of requests, most of responses represent a session_secret. This endpoint could be used to verify the currrent state of newly created sessions.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7fSwiZXhwIjoxNzE0MDQ4OTU3fQ.B81pJXovdKic9v5bfl8S407QTjPh91c5aZeQB0ojzQy1koOXNI2dXLu1y9CxkVzs8gEWKI8vwy7x9lNWRuUU9oxMlqsno0Y15r8-oAqXa2b1G11jVef_aXUwtvTw5_odW9rpgpgbR5xRS360CvyOv4_YjGGaaaJYn5Ww8b96_RLP8sFhn0IPZY0iLv866o419Nll0mSqComdBv9UwHlUpQ8lrG-4akYGtwHrbJZnim0TsotFBge7NgeO434QkwqzEQsAb362EdM2fkZ7YX7ufLDKRYxEDuL30hgrvVcFR2fkd2jvhqTF66zLrLQKesJdPSJe7gZDSUpz-V1BeuR3LA" \ 
 -H "App-Id: lYbM35hScWwT52d6Zxz-Lg" \ 
 -H "App-Secret: ssZn53PTzxSv6kI1nJzlUQ" \ 
 -H "Client-Request-Id: 4565" \ 
 -X GET "/api/v2/sessions/:secret"

Example of request parameters

{"data":{},"exp":1574093210}

Example of response

{"data":{"secret":"BVuveSLQCrA5jBYUyxXe","status":"fetched_kyc","extra":{"scopes":["accounts","transactions","kyc","payments","funds_availability","trusted_beneficiaries"]},"token":{"access_token":"5kHijxm_DEWoP5ncHWcF","expires_at":"2019-11-18T16:04:50.915Z"},"provider_code":"demobank","id":302,"fail_at":"2019-11-18T16:04:50.915Z","success_at":"2019-11-18T16:04:50.915Z","created_at":"2019-11-18T16:04:50.915Z","updated_at":"2019-11-18T16:04:50.915Z","events":[{}],"authorization_details":{"instruction":"Use PIN code from the received SMS.","mfa_fields":[{"code":"sms_pincode","display_name":"SMS-PIN","optional":true,"type":"embedded","nature":"text"}]},"customer_id":983}}
Request

GET /api/v2/sessions/:secret

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
data
hash, required
Wrapper for the data.
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
secret (path)
string, required
Another session identifier that can be used for session lookup and confirmation. Can raise: SessionNotFound
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
AuthorizationMissing 401 Authorization header is missing.
SessionNotFound 404 Session specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Confirm

This endpoint is used for processing additional interactive steps in the process of access token creation or account's refresh.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7ImNyZWRlbnRpYWxzIjp7InNtc19waW5jb2RlIjoiNDU2OCJ9fSwiZXhwIjoxNzE0MDQ4OTU3fQ.WLELHrah_Ie09aFk6ucXtcP22tDfnnqZHAcRgcOvLfcpx8-9EoUlycRDZzdOofMAE7o3O2Lxn-uPnu4lf_wv1ozAcx2hcNftaFN0D8cmToSL-HBMPPhBaDl9m1yAPKWND1vdEYBKGiHNfURYgV1RIszOYfQCgs_QwcP2pbY7KqVO2m2l4XM-2mforGgSsv46xojTBL2m2by3qM45idZ8ELGyKDpysMIARFAYyAWTriclssYZwdt0hMX2hlVTxW-fkQDhbuNPB611mCVErSWJNTOtK0u2_PAsae-CWzpiek2BYIvb_5iyMH8kYhRw-QWef3xdL0Dd-0zdj7deIuCe8g" \ 
 -H "App-Id: RC37EiVDTH72Dy66RiWfRA" \ 
 -H "App-Secret: X-iIITSQB7qTeTYH_99H5A" \ 
 -H "Client-Request-Id: 17" \ 
 -X PUT "/api/v2/sessions/:secret"

Example of request parameters

{"data":{"credentials":{"sms_pincode":"4568"}},"exp":1574093210}

Example of response

{"data":{"secret":"xkeTNwR3GHH3cHcq3UCt","status":"waiting_confirmation_code","extra":{"scopes":["accounts","transactions","kyc","payments","funds_availability","trusted_beneficiaries"]},"token":{"access_token":"BVGU4xsgFdZRDx2BDoG1","expires_at":"2019-11-18T16:04:50.787Z"},"provider_code":"demobank","id":625,"events":[{}],"authorization_details":{},"customer_id":469,"fail_at":"2019-11-18T16:04:50.787Z","success_at":"2019-11-18T16:04:50.787Z","created_at":"2019-11-18T16:04:50.787Z","updated_at":"2019-11-18T16:04:50.787Z"}}
Request

PUT /api/v2/sessions/:secret

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
secret (path)
string, required
Another session identifier that can be used for session lookup and confirmation. Can raise: SessionNotFound, SessionClosed, SessionExpired, ActionNotAllowed
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
SessionClosed 400 Session specified in request is already closed and cannot be modified.
SessionExpired 401 Found session is expired and cannot be processed anymore.
AuthorizationMissing 401 Authorization header is missing.
SessionNotFound 404 Session specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.
ActionNotAllowed 406 You're not allowed to perform this action. This might be a configuration problem or parameters incompatibility.

Destroy

Cancel session.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7fSwiZXhwIjoxNzE0MDQ4OTU3fQ.B81pJXovdKic9v5bfl8S407QTjPh91c5aZeQB0ojzQy1koOXNI2dXLu1y9CxkVzs8gEWKI8vwy7x9lNWRuUU9oxMlqsno0Y15r8-oAqXa2b1G11jVef_aXUwtvTw5_odW9rpgpgbR5xRS360CvyOv4_YjGGaaaJYn5Ww8b96_RLP8sFhn0IPZY0iLv866o419Nll0mSqComdBv9UwHlUpQ8lrG-4akYGtwHrbJZnim0TsotFBge7NgeO434QkwqzEQsAb362EdM2fkZ7YX7ufLDKRYxEDuL30hgrvVcFR2fkd2jvhqTF66zLrLQKesJdPSJe7gZDSUpz-V1BeuR3LA" \ 
 -H "App-Id: TnzE5rqosgx9vrox4mU5EA" \ 
 -H "App-Secret: ngYWj5vwwkf-fT1MkB6DBQ" \ 
 -H "Client-Request-Id: 17" \ 
 -X DELETE "/api/v2/sessions/:secret"

Example of request parameters

{"data":{},"exp":1574093210}

Example of response

{"data":{"session_secret":"_PkwuzoztNR3vz2-MzrJ"}}
Request

DELETE /api/v2/sessions/:secret

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
data
hash, required
Wrapper for the data.
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
secret (path)
string, required
Session secret. Can raise: SessionNotFound, SessionClosed, SessionExpired, ActionNotAllowed
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
SessionClosed 400 Session specified in request is already closed and cannot be modified.
SessionExpired 401 Found session is expired and cannot be processed anymore.
AuthorizationMissing 401 Authorization header is missing.
SessionNotFound 404 Session specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.
ActionNotAllowed 406 You're not allowed to perform this action. This might be a configuration problem or parameters incompatibility.

Show

Endpoint used to fetch all data relevant to a trusted beneficiary including alias_name, identifiers, status and other.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7fSwiZXhwIjoxNzE0MDQ4OTU4fQ.W5Gizw_5Tm9TweC2AmUFzhOM4LY2pKs8A_p-3zrxCSUeSK3V65kruLY7hVPrTG2FBTtuhKjxVkGpTkrUD9YvJ4TEmDRftFOE4e3Bx7-Sn-9Mxd2PeAYwXsjB8Mt7a7h2AOEs6q7bykDhHRNz6cTqSwsVnfr_J9Ww0EYtFSGQUC_69ocoh9W8yTYIizVb5a76TpN_JX9qKzTOhWLvmj6b8K8lmrCvGroMQU-NDWdvvMjnUDVeoAc28c2vELN7yi4WhD9pJnjK_IhQqRyE7P3b7_DEptIrHbBFk5D_JUfcTVDFdWOZGliQaqvkjXIiORWCCYf1m-N0kvc5rWCgrPbXdw" \ 
 -H "App-Id: uNwDiUgp12XhONz1E_rV6g" \ 
 -H "App-Secret: QsSGnN7sJHqUCyRnP6IHsQ" \ 
 -H "Access-Token: bf0d0bb0c89896811579dbe456507cb7cf2f5bb9b0b06291670339a22e55eb484f81de6b286235c71c0f27adb1229a717c4b7f089dadaa51cc24145128ad65ab" \ 
 -H "Client-Request-Id: 13" \ 
 -X GET "/api/v2/trusted_beneficiaries/:id"

Example of request parameters

{"data":{},"exp":1574173799,"id":414}

Example of response

{"data":{"alias_name":"John Smith GB","status":"approved","template_id":"516","identifiers":{"iban":"FK35****81**45****5635","currency_code":"GBP"},"session_secret":"P5rrqb4hWZ_ghjTj4cBj","provider_code":"demobank","id":719}}
Request

GET /api/v2/trusted_beneficiaries/:id

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Access-Token string, required Token for which we are requesting info. Can raise: TokenMissing, TokenNotFound, TokenRevoked, TokenExpired
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
data
hash, required
Wrapper for the data.
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
id
integer, required
Trusted Beneficiary identifier on Salt Edge PSD2 Compliance side. Can raise: TrustedBeneficiaryNotFound
Response

Endpoint used to fetch all data relevant to a trusted beneficiary including alias_name, identifiers, status and other.


Related Errors
Class Code Description
TokenMissing 400 This request cannot be performed without Access_Token header.
AuthorizationMissing 401 Authorization header is missing.
TokenNotFound 401 Token specified in request does not exist or cannot be retrieved.
TokenRevoked 401 Token specified in request is revoked and cannot be used anymore.
TokenExpired 401 Token specified in request is expired and cannot be used.
TrustedBeneficiaryNotFound 404 Trusted Beneficiary specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Index

Endpoint used to fetch all data relevant to trusted beneficiaries.

CURL

curl -i  \ 
 -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJkYXRhIjp7InByb3ZpZGVyX2NvZGUiOiJkZW1vYmFuayJ9LCJleHAiOjE3MTQwNDg5NTh9.iatXqjsSplFtpDTin_9fBvUVlsXfAkpk_XsBmV_jLYz5XSjjkvI7EUhe2ozNZ4-wYIdToQn1JiOg8dZacVuSC6wFNexDKD8kcixlYngf_97ymglJRVOJfYH-ZTU0SoxrH0CL8Hg6i9Wfpcd36P3o3pFss4eTQqsaJV9ktKztq4lZR1m_7h4HobsPXgCcZeglKiEFVpejxSclLfBfolvI5lEdJMoSwrDUFWLLbWn3PT_JBYDt6T48-OkmpPW5n3-PmHe9knXWV76OH9HMJvizdBpBhhgdH14lJfd2A-BLWVOJ6cYC5bddSyMR-U1fPvtxbjhuoOywGGp8V963sYGirw" \ 
 -H "App-Id: IsiyTiKCOZDsV6mbafDzgg" \ 
 -H "App-Secret: fzST4gs0xQHOJA9bToRqeQ" \ 
 -H "Access-Token: 2bae74fd42f750e7401e0aa3cc9d5644ac815f5b9d2c16627af18cc76b2f507bc2dac1a10ab77c1b90b7e16423e2a0396d786959f09db9dc02128d820609d8df" \ 
 -H "Client-Request-Id: 17" \ 
 -X GET "/api/v2/trusted_beneficiaries"

Example of request parameters

{"data":{"provider_code":"demobank"},"exp":1574093211}

Example of response

{"data":[{"id":752,"alias_name":"Example Name","status":"approved","template_id":"75","identifiers":{"amount":"227.13","to_account":"1313613","description":"Test payment.","from_account":"1313634"},"provider_code":"demobank"}]}
Request

GET /api/v2/trusted_beneficiaries

Headers
Header Type Description
Authorization string, required JSON Web Token containing payload, signed using RSA256 and application.private_key. Can raise: AuthorizationMissing
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Access-Token string, required Token for which we are requesting info. Can raise: TokenMissing, TokenNotFound, TokenRevoked, TokenExpired
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
exp
integer, required
The lifetime of the request in timestamp UTC format. Values greater than: Current time.
Response

Endpoint used to fetch all data relevant to trusted beneficiaries.


Related Errors
Class Code Description
TokenMissing 400 This request cannot be performed without Access_Token header.
AccessDenied 401 Action you want to perform is not allowed. More in error_message
AuthorizationMissing 401 Authorization header is missing.
TokenNotFound 401 Token specified in request does not exist or cannot be retrieved.
TokenRevoked 401 Token specified in request is revoked and cannot be used anymore.
TokenExpired 401 Token specified in request is expired and cannot be used.
ProviderNotFound 404 Provider specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Index

Returns all ASPSPs which have approved access for your TPP. More information could be found at #requesting-provider-access compartment.

CURL

curl -i  \ 
 -H "App-Id: 5L1UlLqFeEjlFlJ4dzJFDw" \ 
 -H "App-Secret: ym7AeWUYxHp0KG4MghAo-g" \ 
 -H "Client-Request-Id: 17" \ 
 -X GET "/api/v2/providers"

Example of request parameters

{"per_page":50,"from_id":1}

Example of response

{"data":[{"id":846,"name":"Example Name","code":"demobank","connector_url":"https://user.will.be/redirected/here","status":"live","scopes":["accounts","transactions","kyc","payments","funds_availability","trusted_beneficiaries"],"created_at":"2019-11-18T16:04:50.725Z","updated_at":"2019-11-18T16:04:50.725Z","authorization_types":[{"code":"sms_pin","display_name":"SMS-PIN","scopes":["accounts","transactions"],"instruction":"Use PIN code from SMS to authorize.","required_fields":[{"code":"req_field","optional":"false","display_name":"Sms_pin","type":"string"}],"mfa_fields":[{"code":"req_field2","optional":"false","display_name":"Password","type":"string"}],"sandbox_credentials":{"required_fields":[{"example":"req_field","code":"req_field"}],"mfa_fields":[{"example":"mfa_field","code":"mfa_field"}]}}]}],"meta":{"next_id":2,"time":"2019-11-18T16:04:50.725Z"}}
Request

GET /api/v2/providers

Headers
Header Type Description
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
per_page
integer, optional
Number of providers that should be returned per request or less. Values in range between: 1 and 1000 Default value: 20
from_id
integer, optional
Return providers starting with a specific id. Default value: 0 Values greater than: 0
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.

Templates

Returns all available payment templates which belong to a specific Provider.

CURL

curl -i  \ 
 -H "App-Id: X3R1wYzjbqdHUnePBINH8A" \ 
 -H "App-Secret: K6gV3EPYH9ZYT7KOrjCuZg" \ 
 -H "Client-Request-Id: 17" \ 
 -X GET "/api/v2/providers/:provider_code/templates"

Example of response

{"data":[{"id":757,"description":"Internal transfer","provider_id":251,"payment_type":"internal_transfer","default":false,"extra":{},"created_at":"2019-11-18T16:04:50.658Z","updated_at":"2019-11-18T16:04:50.658Z","payment_attributes":[{"attribute_name":"amount","attribute_type":"number","label":"Amount","optional":false,"position":1,"values":[]},{"attribute_name":"to_account","attribute_type":"text","label":"To account","optional":false,"position":2,"values":[]},{"attribute_name":"currency","attribute_type":"dropdown","label":"Currency","optional":false,"position":3,"values":["EUR","USD"]}]}]}
Request

GET /api/v2/providers/:provider_code/templates

Headers
Header Type Description
App-Id string, required Application’s app_id from connection details tab. Can raise: OauthAppNotFound, CertificateNotFound
App-Secret string, required Application’s app_secret from connection details tab.
Client-Request-Id string, optional Request identifier. If present, it will be returned within meta field in response.
Unpacked Request Authorization
provider_code (path)
string, required
Human readable Provider identifier. Can raise: ProviderNotFound, AccessDenied
Response

Upon successful request, 200 status code will be returned. See ‘Related Errors’ table for other possibilities.


Related Errors
Class Code Description
AccessDenied 401 Action you want to perform is not allowed. More in error_message
ProviderNotFound 404 Provider specified in request does not exist or cannot be retrieved.
OauthAppNotFound 404 OAuth Application specified in request does not exist or cannot be retrieved.
CertificateNotFound 404 Certificate has no permissions.