UNPKG

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

46 lines (45 loc) 2.36 kB
/** * Account information PNZ-API-CentreLib * * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ). */ import { ApiResponse, RequestOptions } from '../core'; import { AC1Initiateclientcredentialsgrant } from '../models/aC1Initiateclientcredentialsgrant'; import { AC2Createaccountaccessconsent } from '../models/aC2Createaccountaccessconsent'; import { BaseController } from './baseController'; export declare class SetupAccountAccessConsentsResourceController extends BaseController { /** * * This step initiates a client credentials grant request for accounts-related activity. * It requires a properly registered application with valid credentials in order to access its resources. * Once you've registered your own Application, you will receive the ClientId, ClientSecret by setting up KeyId, PublicKey, RedirectURI * to reflect details for your own Application. * To call the method, you will need to provide the corresponding PrivateKey of the PublicKey that was entered in the application. * * @param clientID * @param privateKey * @param KID * @return Response from the API call */ initiateClientCredentialsGrant(clientID: string, privateKey: string, KID: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC1Initiateclientcredentialsgrant>>; /** * This step creates an account-access-consents resource. * * Preconditions: * + This step relies on the presence of an AccountAccessToken variable, which is * set upon successful completion of Step AC1 - Initiate client credentials grant. * * Response: * + The response should be an account-access-consents object, with a status 'AwaitingAuthorisation'. * * Troubleshooting: * + The most likely cause of errors is that the step is being attempted out of sequence. Be sure to * follow the steps in sequence * + Another likely cause of errors are out of date variable values. Try starting from Step AC1 - * Initiate client credentials grant again. * * @param authorization * @return Response from the API call */ createAccountAccessConsent(authorization: string, requestOptions?: RequestOptions): Promise<ApiResponse<AC2Createaccountaccessconsent>>; }