### Node.js Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BanqueCPHConnectorSettings in Node.js. ```javascript const enablebanking = require('enablebanking'); const CONNECTOR_SETTINGS = { sandbox: true, consentId: null, accessToken: null, redirectUri: "https://your-redirect-uri", clientId: "your-client-id", certPath: "your-cert-path", keyPath: "your-key-path" } const apiClient = new enablebanking.ApiClient('BanqueCPH', CONNECTOR_SETTINGS) ``` -------------------------------- ### Get Account Details Example Source: https://enablebanking.com/docs/api/reference Example request to get account details. ```http GET https://api.enablebanking.com/accounts/{account_id}/details HTTP/1.1 ``` -------------------------------- ### Get ASPSPs Example Request Source: https://enablebanking.com/docs/api/reference Example GET request to retrieve a list of ASPSPs. ```http GET https://api.enablebanking.com/aspsps HTTP/1.1 ``` -------------------------------- ### Node.js Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BancoPostaBusinessConnectorSettings in Node.js. ```javascript const enablebanking = require('enablebanking'); const CONNECTOR_SETTINGS = { sandbox: true, consentId: null, accessToken: null, redirectUri: "https://your-redirect-uri", certPath: "your-cert-path", keyPath: "your-key-path", clientId: "your-client-id", clientSecret: "your-client-secret" } const apiClient = new enablebanking.ApiClient('BancoPostaBusiness', CONNECTOR_SETTINGS) ``` -------------------------------- ### Get Application Example Request Source: https://enablebanking.com/docs/api/reference Example GET request to retrieve information about the associated application. ```http GET https://api.enablebanking.com/application HTTP/1.1 ``` -------------------------------- ### Java Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BanqueCPHConnectorSettings in Java. ```java package com.eb.sample; import com.enablebanking.ApiClient; import com.enablebanking.model.BanqueCPHConnectorSettings; ApiClient apiClient = new ApiClient( new BanqueCPHConnectorSettings() .redirectUri("https://your-redirect-uri") .clientId("your-client-id") .certPath("your-cert-path") .keyPath("your-key-path") .sandbox(true); ``` -------------------------------- ### Python Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BanqueCPHConnectorSettings in Python. ```python import enablebanking connector_settings = enablebanking.BanqueCPHConnectorSettings( client_id="your-client-id", cert_path="your-cert-path", key_path="your-key-path" ) api_client = ApiClient(connector_settings) ``` -------------------------------- ### Get account transactions example request Source: https://enablebanking.com/docs/api/reference Example HTTP GET request to retrieve account transactions. ```http GET https://api.enablebanking.com/accounts/{account_id}/transactions HTTP/1.1 ``` -------------------------------- ### Python Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BancoPostaBusinessConnectorSettings in Python. ```python import enablebanking connector_settings = enablebanking.BancoPostaBusinessConnectorSettings( cert_path="your-cert-path", key_path="your-key-path", client_id="your-client-id", client_secret="your-client-secret" ) api_client = ApiClient(connector_settings) ``` -------------------------------- ### Get account balances example request Source: https://enablebanking.com/docs/api/reference Example HTTP GET request to retrieve account balances. ```http GET https://api.enablebanking.com/accounts/{account_id}/balances HTTP/1.1 ``` -------------------------------- ### Example Request for Get Payment Transaction Source: https://enablebanking.com/docs/api/reference Example GET request to retrieve details of a specific payment transaction. ```http GET https://api.enablebanking.com/payments/{payment_id}/transactions/{transaction_id} HTTP/1.1 ``` -------------------------------- ### Java Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with BancoPostaBusinessConnectorSettings in Java. ```java package com.eb.sample; import com.enablebanking.ApiClient; import com.enablebanking.model.BancoPostaBusinessConnectorSettings; ApiClient apiClient = new ApiClient( new BancoPostaBusinessConnectorSettings() .redirectUri("https://your-redirect-uri") .certPath("your-cert-path") .keyPath("your-key-path") .clientId("your-client-id") .clientSecret("your-client-secret") .sandbox(true); ``` -------------------------------- ### Node.js Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient with DSKBankConnectorSettings in Node.js. ```javascript const enablebanking = require('enablebanking'); const CONNECTOR_SETTINGS = { sandbox: true, consentId: null, accessToken: null, redirectUri: "https://your-redirect-uri", clientId: "your-client-id", client_secret="your-client-secret", certPath: "your-cert-path", keyPath: "your-key-path" } const apiClient = new enablebanking.ApiClient('DSKBank', CONNECTOR_SETTINGS) ``` -------------------------------- ### Get Application 200 Response Example Source: https://enablebanking.com/docs/api/reference Example successful response (200 OK) for the Get Application request, detailing application properties. ```json { "name": "string", "description": "string", "kid": "string", "environment": "SANDBOX", "redirect_urls": [ "http://example.com" ], "active": true, "countries": [ "string" ], "services": [ "AIS" ] } ``` -------------------------------- ### Get ASPSPs 200 Response Example Source: https://enablebanking.com/docs/api/reference Example successful response (200 OK) for the Get ASPSPs request, detailing the structure of an ASPSP object. ```json { "aspsps": [ { "auth_methods": [ { "approach": "REDIRECT", "credentials": [ { "description": "Business identity code (Y-tunnus) in 1234567-8 format", "name": "companyId", "required": true, "template": "^\\d{7}-\\d$", "title": "Company ID" } ], "hidden_method": false, "name": "MTA", "psu_type": "business" } ], "beta": false, "bic": "NDEAFIHH", "country": "FI", "logo": "https://enablebanking.com/brands/FI/Nordea/", "maximum_consent_validity": 15552000, "name": "Nordea", "payments": [ { "allowed_auth_methods": [ "MTA" ], "charge_bearer_values": [ "SLEV" ], "creditor_account_schemas": [ "IBAN" ], "creditor_agent_bic_fi_required": false, "creditor_agent_clearing_system_member_id_required": false, "creditor_country_required": false, "creditor_name_required": false, "creditor_postal_address_required": false, "currencies": [ "EUR" ], "debtor_account_required": true, "debtor_account_schemas": [ "IBAN" ], "debtor_contact_email_required": false, "debtor_contact_phone_required": false, "debtor_currency_required": false, "max_transactions": 1, "payment_type": "SEPA", "priority_codes": [ "NORM" ], "psu_type": "business", "reference_number_schemas": [ "FIRF", "INTL" ], "reference_number_supported": true, "regulatory_reporting_code_required": false, "remittance_information_lines": [ { "max_length": 140, "min_length": 1, "pattern": "^.{1,140}$" } ], "remittance_information_required": true, "requested_execution_date_max_period": 365, "requested_execution_date_supported": true } ], "psu_types": [ "business" ], "required_psu_headers": [ "Psu-Ip-Address" ] } ] } ``` -------------------------------- ### Clone Sample Repositories Source: https://enablebanking.com/docs/core/latest Clone the sample repositories for Java, Javascript, and Python examples. ```bash $ git clone https://github.com/enablebanking/OpenBankingJavaExamples ``` ```bash $ git clone https://github.com/enablebanking/OpenBankingJSExamples ``` ```bash $ git clone https://github.com/enablebanking/OpenBankingPythonExamples ``` -------------------------------- ### Example Request Source: https://enablebanking.com/docs/api/reference Example of a GET request to fetch transaction details. ```http GET https://api.enablebanking.com/accounts/{account_id}/transactions/{transaction_id} HTTP/1.1 ``` -------------------------------- ### Java Example Source: https://enablebanking.com/docs/core/latest Java code sample for initializing ApiClient with BancoBPMConnectorSettings. ```java package com.eb.sample; import com.enablebanking.ApiClient; import com.enablebanking.model.BancoBPMConnectorSettings; ApiClient apiClient = new ApiClient( new BancoBPMConnectorSettings() .redirectUri("https://your-redirect-uri") .certPath("your-cert-path") .keyPath("your-key-path") .clientId("your-client-id") .clientSecret("your-client-secret") .brand("Brands connected through BPM's end point") .sandbox(true); ``` -------------------------------- ### 200 Response Example Source: https://enablebanking.com/docs/api/reference Example successful response for getting account details. ```json { "account_id": { "iban": "FI0455231152453547" }, "all_account_ids": [ { "identification": "123456", "scheme_name": "BBAN" } ], "account_servicer": { "bic_fi": "string", "clearing_system_member_id": { "clearing_system_id": "NZNCC", "member_id": 20368 }, "name": "string" }, "name": "string", "details": "string", "usage": "PRIV", "cash_account_type": "CACC", "product": "string", "currency": "string", "psu_status": "string", "credit_limit": { "currency": "EUR", "amount": "1.23" }, "legal_age": true, "postal_address": { "address_type": "Business", "department": "Department of resources", "sub_department": "Sub Department of resources", "street_name": "Vasavagen", "building_number": "4", "post_code": "00123", "town_name": "Helsinki", "country_sub_division": "Uusimaa", "country": "FI", "address_line": [ "Mr Asko Teirila PO Box 511", "39140 AKDENMAA FINLAND" ] }, "uid": "07cc67f4-45d6-494b-adac-09b5cbc7e2b5", "identification_hash": "WwpbCiJhY2NvdW50IiwKImFjY291bnRfaWQiLAoiaWJhbiIKXQpd.E8GzhnnsFC7K+4e3YMYYKpyM83Zx6toXrjgcvPP/Lqc=", "identification_hashes": [ "WwpbCiJhY2NvdW50IiwKImFjY291bnRfaWQiLAoiaWJhbiIKXQpd.E8GzhnnsFC7K+4e3YMYYKpyM83Zx6toXrjgcvPP/Lqc=", "WwpbCiJhc3BzcF9uYW1lIgpdLApbCiJhc3BzcF9jb3VudHJ5IgpdLApbCiJhY2NvdW50IiwKImFjY291bnRfaWQiLAoib3RoZXIiLAoic2NoZW1lX25hbWUiCl0sClsKImFjY291bnQiLAoiYWNjb3VudF9pZCIsCiJvdGhlciIsCiJpZGVudGlmaWNhdGlvbiIKXQpd.AOm/TULGPD4a4GdcWhR9xh0GPlPUZuB2O1S9SYFWEz0=" ] } ``` -------------------------------- ### Python Example Source: https://enablebanking.com/docs/core/latest Python code sample for initializing ApiClient with BancoBPMConnectorSettings. ```python import enablebanking connector_settings = enablebanking.BancoBPMConnectorSettings( cert_path="your-cert-path", key_path="your-key-path", client_id="your-client-id", client_secret="your-client-secret", brand="Brands connected through BPM's end point" ) api_client = ApiClient(connector_settings) ``` -------------------------------- ### AllitudeConnectorSettings Node.js Example Source: https://enablebanking.com/docs/core/latest Example of initializing ApiClient for Allitude using Node.js. ```javascript const enablebanking = require('enablebanking'); const CONNECTOR_SETTINGS = { sandbox: true, consentId: null, accessToken: null, redirectUri: "https://your-redirect-uri", certPath: "your-cert-path", keyPath: "your-key-path", clientId: "your-client-id", clientSecret: "your-client-secret", brand: "your-brand" } const apiClient = new enablebanking.ApiClient('Allitude', CONNECTOR_SETTINGS) ```