...
Tip | ||||
---|---|---|---|---|
| ||||
You need to deploy the following APIS.
| ||||
Warning | ||||
For evaluation purposes, you may manually register the ADR application and invoke the Consumer Data Rights API by following all the steps given below. | ||||
Table of Content Zone | ||||
| ||||
Step 1 - Sign up as an Accredited Data RecipientIn this step, the Accredited Data Recipient (ADR) registers its application in WSO2 API store. Expand | | |||
| ||||
Expand | ||||
| ||||
Field | Description | |||
Username/Email | The username/email that the DR uses to sign in to the API Store. | |||
Password | The password that the DR uses to sign in to the API Store. | |||
Retype Password | This is to prevent the DR from accidentally setting an incorrect password. | |||
Last Name | This is the last name of the DR. | |||
First Name | This is the first name of the DR. | |||
Field | Description | |||
Legal Entity Name | The official name of the DR. | |||
Country of Registration | The country in which the DR is registered. | |||
Legal Identifier Number (LEI) | This identifies the DR. | |||
Company Register | The organization that registered the DR. | |||
Company Registration Number | Identifier issued at the DR registration. | |||
Address Line 1 | Address of the DR. | |||
Address Line 2 | Address of the DR. | |||
City | City in which the DR is located. | |||
Postal Code | Postal code of the geographical location of the DR. | |||
Country | The country in which the DR is located. | |||
Field | Description | |||
Competent Authority | The regulatory body that authorises and supervises the open banking services delivered by the DR. | |||
Competent Authority Country | Country of the competent authority that authorised the DR to provide open banking services. | |||
Competent Authority Registration Number | The registration number issued by the Competent Authority to the DR. | |||
URL of the Competent Authority Register Page | URL of the page that has the list of organizations authorised by the competent authority. |
Note |
---|
It is not mandatory to include the approval step for approving the ADR. In order to add this step, you need to configure workflows in the WSO2 Open Banking solution. |
Expand | ||
---|---|---|
| ||
Now the DR can sign in to the API store. |
Step 3 - Sign in to the API store as the ADR
Expand | ||
---|---|---|
| ||
The homepage of the API store is now displayed along with the APIs. |
Step 4 - Create an application
title | Click here to see how it is done... |
---|
Click Add Application.
Enter application details.
Field
Description
Name
Application name.
Per Token Quota
Determines the maximum number of API requests accepted within a given duration.
Description
This describes the purpose of the application.
Click Add.
Note |
---|
An application can be used to subscribe to multiple APIs. See Subscribe to an API for instructions. |
Step 5 - Subscribe to API
The ADR user needs to subscribe to the ConsumerDataStandards v1
API in order to access its API resources. Once subscribed, the users can access all the supported services of the API resources.
title | Click here to see how it is done... |
---|
Go to the APIs tab in the API Store.
Select the ConsumerDataStandards
v1
API.
Set the Tiers
to Unlimited
.
Click Subscribe.
Now that you have subscribed to the API, generate access tokens and invoke the API.
Step 6 - Create certificates
The ADR user needs to create certificates to validate whether the ADR is registered in a governing entity.
title | Click here to see how it is done... |
---|
A keystore file is used to store the trusted certificates of the ADR in the WSO2 Open Banking solution. Use the commands given below in a command-line interface in order to create a keystore file as an ADR.
Make sure to update the following placeholders:
<alias>
<filename>
Code Block |
---|
keytool -genkey -alias <alias> -keyalg RSA -keystore <filename>.jks |
During the command execution, the ADR user requires to;
Convert the keystore from the .jks format to .PKCS12. Make sure to update the following placeholders:
<keyStoreName>
<filename>
, given above.<PKCS12FileName>
Code Block |
---|
keytool -importkeystore -srckeystore <keystoreStoreName>.jks -destkeystore <PKCS12FileName>.p12 -deststoretype PKCS12 |
During the command execution, the ADR user requires to;
- Set a password for the destination keystore.
- Enter the source keystore password, as defined in the above step .
Create the application certificate (.pem) file in the PKCS12 format using the keystore. e.g: dr.p12.
Make sure to update the following placeholders:
<PKCS12FileName>
<PEMFileName>
Code Block |
---|
openssl pkcs12 -in <PKCS12FileName>.p12 -nokeys -out <PEMFileName>.pem |
During the command execution, the ADR user requires to;
- Set a password to import the .pem file.
Import the public key you extracted in the previous step to the truststore file.
Update the placeholder values and use the given command.
<alias>
<PEMFileName>
<truststoreFileName>
<password>
Code Block |
---|
keytool -import -alias <alias> -file <PEMFileName>.pem -keystore <truststoreFileName>.jks -storepass <password> |
Step 7 - Generate keys
The ADR user requires a Client ID (Consumer Key) and a Client secret (Consumer Secret) to access the subscribed APIs.
title | Click here to see how it is done... |
---|
Sign in to the API store as an ADR user and go to the Applications tab.
Choose your application from the Application List and select either of the following:
Production Keys: Generates access tokens in the production environment.
Sandbox Keys: Generates access tokens in the sandbox environment.
Provide the requested information as defined below:
Field
Description
Grant Types
These determine the credentials that are used to generate the access token.
Refresh Token: This is to renew an expired access token.
Client Credential: This relates to the client credentials grant type and is applicable when consuming the API as an application.
Code: This relates to the authorisation code grant type and is applicable when consuming the API as a user.
Callback URL
This is the URL used by the ADR to receive the authorisation code sent from the Data Holder (bank). The authorisation code can be used later to generate an OAuth2 access token.
Application Certificate
This is the content between the BEGIN CERTIFICATE and END CERTIFICATE strings of the application certificate (.pem) that you created above.
Click Request Access if you are generating production keys. If workflows are configured in the solution, it sends a request to Approver user to approve the token generation. Otherwise, it generates consumer key and consumer secret.
Click Generate Keys if you are generating sandbox keys. It generates consumer key and consumer secret.
Step 8 - Approve Production Key generation
This step includes instructions to an Approver user to review and approve a request to generate production keys for an application.
Note |
---|
It is not mandatory to include the approval step for the Production Key generation. In order to add this step, you need to configure workflows in the WSO2 Open Banking solution. |
title | Click here to see how it is done... |
---|
Sign in to the WSO2 Open Banking API Manager Admin portal as an Approver at https://<WSO2_OB_APIM_HOST>:9443/admin
.
Click Tasks and then Application Registration.
Locate the approval request and click Assign To Me.
The consumer key and consumer secret are displayed as follows:
Step 9
Table of Content Zone | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Step 1 - Authorising account consentsThe bank redirects the bank customer to authenticate and approve/deny application-provided consents.
Step102 - Generate user access tokenIn this section, you will be generating an access token using the authorization code generated in the section above.
Step113 - Invoke Consumer Data Standards APIThis section shows how to invoke the endpoints in the GET /banking/accountsThe ADR is able to obtain a list of accounts that the consumer has authorised the ADR to access.
POST /banking/accounts/balancesThe ADR is able to obtain balances for a specified list of accounts. The request body contains a list of account IDs to obtain balances for.
|