pnz-payments-sdk
Version:
PNZ Payments Account and Transaction API
37 lines (33 loc) • 1.68 kB
text/typescript
/**
* Account and Transaction API SpecificationLib
*
* This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
*/
import { lazy, object, optional, Schema, string } from '../schema';
import { CreditorAccount, creditorAccountSchema } from './creditorAccount';
import { CreditorAgent, creditorAgentSchema } from './creditorAgent';
import { Reference, referenceSchema } from './reference';
export interface BeneficiaryModel {
/** A unique and immutable identifier used to identify the account resource. This identifier has no meaning to the account owner. */
accountId: string;
/** A unique and immutable identifier used to identify the beneficiary resource. This identifier has no meaning to the account owner. */
beneficiaryId?: string;
reference?: Reference;
/**
* Party that manages the account on behalf of the account owner, that is manages the registration and booking of entries on the account, calculates balances on the account and provides information about the account.
* This is the servicer of the beneficiary account.
*/
creditorAgent?: CreditorAgent;
/** Unambiguous identification of the account of the creditor, in the case of a debit transaction. */
creditorAccount?: CreditorAccount;
}
export const beneficiaryModelSchema: Schema<BeneficiaryModel> = object({
accountId: ['AccountId', string()],
beneficiaryId: ['BeneficiaryId', optional(string())],
reference: ['Reference', optional(lazy(() => referenceSchema))],
creditorAgent: ['CreditorAgent', optional(lazy(() => creditorAgentSchema))],
creditorAccount: [
'CreditorAccount',
optional(lazy(() => creditorAccountSchema)),
],
});