All URIs are relative to https://au-api.basiq.io
Method | HTTP request | Description |
---|---|---|
getAccount | GET /users/{userId}/accounts/{accountId} | Use this to retrieve the details of a specific account. This request will return back an account object with the latest data since the last refresh. If you require the latest account details you will need to call the connection refresh resource. |
getAccounts | GET /users/{userId}/accounts | Use this collection to retrieve a list of accounts. Each entry in the array is a separate account object. |
AccountResponseResource getAccount(userId, accountId)
Use this to retrieve the details of a specific account. This request will return back an account object with the latest data since the last refresh. If you require the latest account details you will need to call the connection refresh resource.
Returns an account if a valid account ID was provided. Returns an error otherwise.
var BasiqApi = require('@basiq/basiq-javascript-sdk');
var defaultClient = BasiqApi.ApiClient.instance;
// Configure OAuth2 access token for authorization: application
var application = defaultClient.authentications['application'];
application.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new BasiqApi.AccountsApi();
var userId = "userId_example"; // String | User identifier
var accountId = "accountId_example"; // String | Account identifier
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
apiInstance.getAccount(userId, accountId, callback);
Name | Type | Description | Notes |
---|---|---|---|
userId | String | User identifier | |
accountId | String | Account identifier |
- Content-Type: Not defined
- Accept: application/json
AccountsResponseResource getAccounts(userId)
Use this collection to retrieve a list of accounts. Each entry in the array is a separate account object.
Returns a list with a data property that contains an array of accounts. Each entry in the array is a separate object. If no data is returned, the resulting array will be empty. Otherwise, this call returns an error in the event of1 a failure.
var BasiqApi = require('@basiq/basiq-javascript-sdk');
var defaultClient = BasiqApi.ApiClient.instance;
// Configure OAuth2 access token for authorization: application
var application = defaultClient.authentications['application'];
application.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new BasiqApi.AccountsApi();
var userId = "userId_example"; // String | User identifier
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
apiInstance.getAccounts(userId, callback);
Name | Type | Description | Notes |
---|---|---|---|
userId | String | User identifier |
- Content-Type: Not defined
- Accept: application/json