pnz-apicentre-sandbox-sdk
Version:
The sandbox, powered by Middleware New Zealand, is a dedicated environment that mimics an API Provider, as defined in the [Payments NZ API Centre standards](https://paymentsnz.atlassian.net/wiki/spaces/PaymentsNZAPIStandards/overview). This SDK is generat
570 lines (569 loc) • 23.9 kB
TypeScript
/**
* Account information PNZ-API-CentreLib
*
* This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
*/
import { ApiResponse, RequestOptions } from '../core';
import { AC1110Retrieveaccountstatements } from '../models/aC1110Retrieveaccountstatements';
import { AC111Retrieveanaccount } from '../models/aC111Retrieveanaccount';
import { AC112Retrieveaccountbalance } from '../models/aC112Retrieveaccountbalance';
import { AC113Retrieveaccountbeneficiaries } from '../models/aC113Retrieveaccountbeneficiaries';
import { AC114Retrieveaccountdirectdebits } from '../models/aC114Retrieveaccountdirectdebits';
import { AC115Retrieveaccountoffers } from '../models/aC115Retrieveaccountoffers';
import { AC116Retrieveaccountparty } from '../models/aC116Retrieveaccountparty';
import { AC117Retrieveaccountscheduledpayments } from '../models/aC117Retrieveaccountscheduledpayments';
import { AC118Retrieveaccountstandingorders } from '../models/aC118Retrieveaccountstandingorders';
import { AC119Retrieveaccounttransactions } from '../models/aC119Retrieveaccounttransactions';
import { AC121Retrieveastatement } from '../models/aC121Retrieveastatement';
import { AC123Retrievetransactionsforaspecificstatement } from '../models/aC123Retrievetransactionsforaspecificstatement';
import { BaseController } from './baseController';
export declare class SpecificAccountEndpointsController extends BaseController {
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information.
*
*
* Response:
*
* * The response should be a single account resource, whose id is PNZ-T-AC-AccountId.
* * The balance of the accounts resource is dynamic so the balance returned may vary.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAnAccount(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC111Retrieveanaccount>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a single balance resource for the account whose id is PNZ-T-AC-AccountId.
* * The balance of the accounts is dynamic so the balance returned may vary.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountBalance(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC112Retrieveaccountbalance>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of beneficiary resources for the account whose id is PNZ-T-
* AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountBeneficiaries(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC113Retrieveaccountbeneficiaries>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of direct-debit resources for the account whose id is PNZ-T-
* AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountDirectDebits(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC114Retrieveaccountdirectdebits>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of offer resources for the account whose id is PNZ-T-AC-
* AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountOffers(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC115Retrieveaccountoffers>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a single party resource for the owner of the account whose id is PNZ-T-AC-
* AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountParty(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC116Retrieveaccountparty>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of scheduled-payment resources for the account whose id is
* PNZ-T-AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountScheduledPayments(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC117Retrieveaccountscheduledpayments>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of standing-order resources for the account whose id is PNZ-
* T-AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountStandingOrders(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC118Retrieveaccountstandingorders>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of transaction resources for the account whose id is PNZ-T-
* AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountTransactions(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC119Retrieveaccounttransactions>>;
/**
* This request queries the account whose id is specified in the PNZ-T-AC-AccountId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
*
*
* Response:
*
* * The response should be a collection of statement resources for the account whose id is PNZ-T-AC-
* AccountId.
*
*
* Postconditions:
*
* * The StatementId for the first statement in the collection is saved in the PNZ-T-AC-StatementId
* environment variable in preparation for subsequent statement-related steps, such as Step AC12.1 -
* Retrieve a statement
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC10.1 has not been completed prior to making this
* request. Complete Step AC10.1 - Retrieve consented account information before trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param authorization
* @return Response from the API call
*/
retrieveAccountStatements(pNZTACAccountId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC1110Retrieveaccountstatements>>;
/**
* This request queries the statement whose id is specified in the PNZ-T-AC-StatementId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
* * This step also relies on the PNZ-T-AC-StatementId environment variable, which is set from Step
* AC11.10 - Retrieve account statements
*
*
* Response:
*
* * The response should be a single statement resource whose id is PNZ-T-AC-StatementId for the
* account whose id is PNZ-T-AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC11.10 - Retrieve account statements has not been
* completed prior to making this request. Complete Step AC11.10 - Retrieve account statements before
* trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param pNZTACStatementId
* @param authorization
* @return Response from the API call
*/
retrieveStatement(pNZTACAccountId: string, pNZTACStatementId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC121Retrieveastatement>>;
/**
* This request queries the statement whose id is specified in the PNZ-T-AC-StatementId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
* * This step also relies on the PNZ-T-AC-StatementId environment variable, which is set from Step
* AC11.10 - Retrieve account statements
*
*
* Response:
*
* * The response should be a single statement resource whose id is PNZ-T-AC-StatementId for the
* account whose id is PNZ-T-AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC11.10 - Retrieve account statements has not been
* completed prior to making this request. Complete Step AC11.10 - Retrieve account statements before
* trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param accept
* @param pNZTACAccountId
* @param pNZTACStatementId
* @param authorization
* @return Response from the API call
*/
retrieveStatementFile(accept: string, pNZTACAccountId: string, pNZTACStatementId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<string>>;
/**
* This request queries the statement whose id is specified in the PNZ-T-AC-StatementId environment
* variable.
*
* Preconditions:
*
* * This step relies on the presence of a PNZ-T-AC-AuthAccessToken, which is set upon successful
* completion of Step HF-AC8 - Exchange authorization-code for access token or Step DF-AC5 - Exchange
* auth_req_id for access token.
* * This step also relies on the PNZ-T-AC-AccountId environment variable, which is set from Step
* AC10.1 - Retrieve consented account information
* * This step also relies on the PNZ-T-AC-StatementId environment variable, which is set from Step
* AC11.10 - Retrieve account statements
*
*
* Response:
*
* * The response should be a collection of transaction resources for the statement whose id is PNZ-T-
* AC-StatementId for the account whose id is PNZ-T-AC-AccountId.
*
*
* Postconditions:
*
* * None
*
*
* Examples:
*
* * There is one example which shows the request and the expected response.
*
*
* Troubleshooting:
*
* * The most likely cause of errors is that Step AC11.10 - Retrieve account statements has not been
* completed prior to making this request. Complete Step AC11.10 - Retrieve account statements before
* trying again.
* * Another likely cause of errors is an expired access token. Try starting from Step AC1 - Initiate
* client credentials grant again.
*
* @param pNZTACAccountId
* @param pNZTACStatementId
* @param authorization
* @return Response from the API call
*/
retrieveTransactionsForSpecificStatement(pNZTACAccountId: string, pNZTACStatementId: string, authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC123Retrievetransactionsforaspecificstatement>>;
}