/** * PagarmeApiSDKLib * * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ). */ import { array, lazy, nullable, number, object, optional, Schema, string, } from '../schema'; import { GetWithdrawSourceResponse, getWithdrawSourceResponseSchema, } from './getWithdrawSourceResponse'; import { GetWithdrawTargetResponse, getWithdrawTargetResponseSchema, } from './getWithdrawTargetResponse'; export interface GetWithdrawResponse { id?: string | null; gatewayId?: string | null; amount?: number | null; status?: string | null; createdAt?: string | null; updatedAt?: string | null; metadata?: string[] | null; fee?: number | null; fundingDate?: string | null; fundingEstimatedDate?: string | null; type?: string | null; source?: GetWithdrawSourceResponse | null; target?: GetWithdrawTargetResponse | null; } export const getWithdrawResponseSchema: Schema = object({ id: ['id', optional(nullable(string()))], gatewayId: ['gateway_id', optional(nullable(string()))], amount: ['amount', optional(nullable(number()))], status: ['status', optional(nullable(string()))], createdAt: ['created_at', optional(nullable(string()))], updatedAt: ['updated_at', optional(nullable(string()))], metadata: ['metadata', optional(nullable(array(string())))], fee: ['fee', optional(nullable(number()))], fundingDate: ['funding_date', optional(nullable(string()))], fundingEstimatedDate: [ 'funding_estimated_date', optional(nullable(string())), ], type: ['type', optional(nullable(string()))], source: [ 'source', optional(nullable(lazy(() => getWithdrawSourceResponseSchema))), ], target: [ 'target', optional(nullable(lazy(() => getWithdrawTargetResponseSchema))), ], });