import { PaymentProcessorFlow } from "./enums"; import { ConfigScope } from "./enums"; import { PaymentMethod } from "./enums"; import { ImplementationTeam } from "./enums"; import { PaymentProcessorId } from "./enums"; import { OpenGovTenant } from "./enums"; import { PaymentStatus } from "./enums"; export type Maybe = T | null; export type InputMaybe = Maybe; export type Exact = { [K in keyof T]: T[K]; }; export type MakeOptional = Omit & { [SubKey in K]?: Maybe; }; export type MakeMaybe = Omit & { [SubKey in K]: Maybe; }; /** All built-in and custom scalars, mapped to their actual values */ export type Scalars = { ID: string; String: string; Boolean: boolean; Int: number; Float: number; DateTime: Date | string; JSON: any; /** Opaque token representing a payment account associated with a user. */ PaymentAccountToken: any; }; export type ApplicationMetadata = { address?: InputMaybe; allowEWalletPayment?: InputMaybe; community?: InputMaybe; departmentID?: InputMaybe; departmentName?: InputMaybe; itemsMetadata?: InputMaybe; itemsMetadata2?: InputMaybe; itemsMetadata3?: InputMaybe; mode?: InputMaybe; orgName?: InputMaybe; paymentID?: InputMaybe; paymentMethod?: InputMaybe; recordID?: InputMaybe; recordNo?: InputMaybe; recordStepID?: InputMaybe; recordType?: InputMaybe; recordTypeID?: InputMaybe; }; export type ApplicationMetadataResponse = { __typename?: "ApplicationMetadataResponse"; address?: Maybe; community?: Maybe; departmentID?: Maybe; departmentName?: Maybe; itemsMetadata?: Maybe; paymentID?: Maybe; paymentMethod?: Maybe; recordID?: Maybe; recordNo?: Maybe; recordStepID?: Maybe; recordType?: Maybe; recordTypeID?: Maybe; }; export type Card = { __typename?: "Card"; card: CardDetails; }; export type CardDetails = { __typename?: "CardDetails"; authorizationCode?: Maybe; cardType?: Maybe; last4?: Maybe; }; export enum CardType { AMERICAN_EXPRESS = "AMERICAN_EXPRESS", DISCOVER = "DISCOVER", MASTERCARD = "MASTERCARD", UNKNOWN = "UNKNOWN", VISA = "VISA", } export type Cash = { __typename?: "Cash"; cash: CashDetails; }; export type CashDetails = { __typename?: "CashDetails"; paidAmount?: Maybe; }; export type Check = { __typename?: "Check"; check: ECheckDetails; }; export type ConfigPluginFlowRequest = { applicationMetadata?: InputMaybe; community: Scalars["String"]; processorID: PaymentProcessorId; scope: ConfigScope; sourceApp?: InputMaybe; }; export type ConfigPluginFlowResponse = FlowResponseType & { __typename?: "ConfigPluginFlowResponse"; flowType: PaymentProcessorFlow; }; export { ConfigScope }; export enum Currency { AUD = "AUD", USD = "USD", } export type ECheck = { __typename?: "ECheck"; e_check: ECheckDetails; }; export type ECheckDetails = { __typename?: "ECheckDetails"; last4?: Maybe; }; export type EnvironmentConfig = { __typename?: "EnvironmentConfig"; key: Scalars["String"]; value?: Maybe; }; export type FeeItem = { feeAccountNumber?: InputMaybe; feeAmount?: InputMaybe; feeTitle?: InputMaybe; recordID?: InputMaybe; record_StepID?: InputMaybe; step_FeeID?: InputMaybe; }; export type FeeItemResponse = { __typename?: "FeeItemResponse"; feeAccountNumber?: Maybe; feeAmount?: Maybe; feeTitle?: Maybe; recordID?: Maybe; record_StepID?: Maybe; step_FeeID?: Maybe; }; /** Represents a successful grant with a token */ export type FlowGrant = { __typename?: "FlowGrant"; /** Flow token payload */ flowToken: Scalars["String"]; flowType: PaymentProcessorFlow; }; export type FlowGrantResponse = | FlowGrant | FlowRequestInvalid | FlowUnsupported; /** Error result when flow request input is invalid. */ export type FlowRequestInvalid = { __typename?: "FlowRequestInvalid"; message?: Maybe; }; /** * Common interface for all flow responses. * The flowType will always match the value of the flowType field in the validation request. */ export type FlowResponseType = { flowType: PaymentProcessorFlow; }; /** Signed FlowResult from the SEPS SDK using JWS standard (see https://tools.ietf.org/id/draft-ietf-jose-json-web-signature-14.html#JSComplete) */ export type FlowResult = { header?: InputMaybe
; payload: Scalars["String"]; protected?: InputMaybe; signature?: InputMaybe; signatures?: InputMaybe>; }; /** Error result when processor does not support the request flow type. */ export type FlowUnsupported = { __typename?: "FlowUnsupported"; message?: Maybe; }; export type FlowValidationResponse = | ConfigPluginFlowResponse | FuturePaymentFlowResponse | InvalidFlowResult | InvalidSignature | OfflinePaymentFlowResponse | OfflineRefundFlowResponse | OneTimePaymentFlowResponse | OnlinePaymentFlowResponse | OnlineRefundFlowResponse | OnlineVoidFlowResponse | TerminalPaymentFlowResponse | UpdatePaymentFlowResponse; export type FuturePaymentFlowRequest = { applicationMetadata?: InputMaybe; entityID: Scalars["String"]; idempotencyKey?: InputMaybe; invoiceEmail?: InputMaybe; paymentMethod: PaymentMethod; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; userID: Scalars["ID"]; }; export type FuturePaymentFlowResponse = FlowResponseType & { __typename?: "FuturePaymentFlowResponse"; flowType: PaymentProcessorFlow; idempotencyKey?: Maybe; paymentAccountToken?: Maybe; paymentMethodDetails?: Maybe; status: Scalars["String"]; }; export type Header = { alg?: InputMaybe; }; export { ImplementationTeam }; /** Error response when FlowResult contains invalid payload data. */ export type InvalidFlowResult = ResponseErrorMessage & { __typename?: "InvalidFlowResult"; message: Scalars["String"]; }; /** Error response when FlowResult signature is invalid. */ export type InvalidSignature = ResponseErrorMessage & { __typename?: "InvalidSignature"; message: Scalars["String"]; }; export type Mutation = { __typename?: "Mutation"; /** Requests configuration flow grant for payment Processor. */ configPlugin: FlowGrantResponse; /** Requests a grant to perform the FUTURE_PAYMENT flow. */ futurePayment: FlowGrantResponse; /** Requests a grant based on an idempotecy key. */ getMetadata?: Maybe; /** Requests a grant to perform the OFFLINE_PAYMENT flow. */ offlinePayment: FlowGrantResponse; /** Requests a grant to perform the OFFLINE_REFUND flow. */ offlineRefund: FlowGrantResponse; /** Requests a grant to perform the ONETIME_PAYMENT flow. */ oneTimePayment: FlowGrantResponse; /** Requests a grant to perform the ONLINE_PAYMENT flow. */ onlinePayment: FlowGrantResponse; /** Requests a grant to perform the ONLINE_REFUND flow. */ onlineRefund: FlowGrantResponse; /** Requests a grant to perform the ONLINE_VOID flow. */ onlineVoid: FlowGrantResponse; /** Requests a grant to perform the TERMINAL_PAYMENT flow. */ terminalPayment: FlowGrantResponse; /** Requests a grant to perform the update of a payment */ updatePayment: FlowGrantResponse; /** Requests validation of a signed JWT */ validateFlowResult: FlowValidationResponse; }; export type MutationconfigPluginArgs = { request?: InputMaybe; }; export type MutationfuturePaymentArgs = { request?: InputMaybe; }; export type MutationgetMetadataArgs = { idempotencyKey?: InputMaybe; }; export type MutationofflinePaymentArgs = { request?: InputMaybe; }; export type MutationofflineRefundArgs = { request?: InputMaybe; }; export type MutationoneTimePaymentArgs = { request?: InputMaybe; }; export type MutationonlinePaymentArgs = { request?: InputMaybe; }; export type MutationonlineRefundArgs = { request: OnlineRefundFlowRequest; }; export type MutationonlineVoidArgs = { request: OnlineVoidFlowRequest; }; export type MutationterminalPaymentArgs = { request?: InputMaybe; }; export type MutationupdatePaymentArgs = { request?: InputMaybe; }; export type MutationvalidateFlowResultArgs = { flowResult: FlowResult; flowType?: InputMaybe; }; export type OfflinePaymentFlowRequest = { amount: Scalars["Float"]; applicationMetadata?: InputMaybe; attributes?: InputMaybe; currency: Scalars["String"]; description: Scalars["String"]; entityID: Scalars["String"]; idempotencyKey?: InputMaybe; items?: InputMaybe>>; paymentAccountToken: Scalars["PaymentAccountToken"]; paymentID: Scalars["String"]; paymentMethod: PaymentMethod; processingFee: Scalars["Float"]; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; userID: Scalars["ID"]; }; export type OfflinePaymentFlowResponse = FlowResponseType & { __typename?: "OfflinePaymentFlowResponse"; amount: Scalars["Float"]; attributes?: Maybe; currency?: Maybe; description?: Maybe; entityID: Scalars["String"]; flowType: PaymentProcessorFlow; idempotencyKey?: Maybe; items?: Maybe>>; /** * Token representing the payment account used for this payment. * Payment processors may refresh this token periodically. */ paymentAccountToken?: Maybe; paymentID: Scalars["ID"]; paymentMethodDetails: PaymentMethodDetails; processingFee?: Maybe; sourceApp: Scalars["String"]; status: Scalars["String"]; transactionID?: Maybe; userID: Scalars["ID"]; }; export type OfflineRefundFlowRequest = { amount: Scalars["Float"]; applicationMetadata?: InputMaybe; attributes?: InputMaybe; currency: Currency; entityID: Scalars["String"]; idempotencyKey?: InputMaybe; items?: InputMaybe>>; originalPaymentID: Scalars["ID"]; processingFee: Scalars["Float"]; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; userID: Scalars["ID"]; }; export type OfflineRefundFlowResponse = FlowResponseType & { __typename?: "OfflineRefundFlowResponse"; amount: Scalars["Float"]; attributes?: Maybe; currency: Currency; entityID: Scalars["String"]; flowType: PaymentProcessorFlow; idempotencyKey?: Maybe; items?: Maybe>>; originalPaymentID: Scalars["ID"]; processingFee: Scalars["Float"]; sourceApp: Scalars["String"]; userID: Scalars["ID"]; }; export type OneTimePaymentFlowRequest = { amount: Scalars["Float"]; applicationMetadata?: InputMaybe; currency: Scalars["String"]; description: Scalars["String"]; entityID: Scalars["String"]; paymentID: Scalars["String"]; paymentMethod: PaymentMethod; processingFee: Scalars["Float"]; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; userID: Scalars["ID"]; }; /** Response from performing the ONETIME_PAYMENT flow. */ export type OneTimePaymentFlowResponse = FlowResponseType & { __typename?: "OneTimePaymentFlowResponse"; amount?: Maybe; currency?: Maybe; description?: Maybe; flowType: PaymentProcessorFlow; paymentAccountToken?: Maybe; paymentID: Scalars["ID"]; paymentMethodDetails: PaymentMethodDetails; processingFee?: Maybe; status: Scalars["String"]; transactionID?: Maybe; }; export type OnlinePaymentFlowRequest = { amount: Scalars["Float"]; applicationMetadata?: InputMaybe; currency: Scalars["String"]; description: Scalars["String"]; entityID: Scalars["String"]; idempotencyKey?: InputMaybe; invoiceEmail?: InputMaybe; items?: InputMaybe>>; paymentID: Scalars["String"]; paymentMethod: PaymentMethod; processingFee: Scalars["Float"]; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; tenantID?: InputMaybe; userID: Scalars["ID"]; }; export type OnlinePaymentFlowResponse = FlowResponseType & { __typename?: "OnlinePaymentFlowResponse"; amount?: Maybe; currency?: Maybe; description?: Maybe; destinationPaymentID?: Maybe; flowType: PaymentProcessorFlow; idempotencyKey?: Maybe; payer?: Maybe; paymentChannel?: Maybe; paymentID: Scalars["ID"]; paymentMethodDetails: PaymentMethodDetails; /** Deprecated: Use payoutDetails instead */ payoutDate?: Maybe; payoutDetails?: Maybe; processingFee?: Maybe; status: Scalars["String"]; transactionID?: Maybe; }; export type OnlineRefundFlowRequest = { amount: Scalars["Float"]; applicationMetadata?: InputMaybe; currency?: InputMaybe; entityID: Scalars["ID"]; idempotencyKey?: InputMaybe; items?: InputMaybe>>; originalPaymentID: Scalars["ID"]; paymentID: Scalars["ID"]; processingFee: Scalars["Float"]; processorID: PaymentProcessorId; reason?: InputMaybe; sourceApp: Scalars["String"]; transactionID: Scalars["String"]; userID: Scalars["ID"]; }; export type OnlineRefundFlowResponse = FlowResponseType & { __typename?: "OnlineRefundFlowResponse"; amount: Scalars["Float"]; flowType: PaymentProcessorFlow; idempotencyKey?: Maybe; paymentID: Scalars["ID"]; status: Scalars["String"]; transactionID?: Maybe; }; export type OnlineVoidFlowRequest = { applicationMetadata?: InputMaybe; entityID: Scalars["ID"]; idempotencyKey?: InputMaybe; processorID: PaymentProcessorId; sourceApp: Scalars["String"]; transactionID: Scalars["String"]; userID: Scalars["ID"]; }; export type OnlineVoidFlowResponse = FlowResponseType & { __typename?: "OnlineVoidFlowResponse"; flowType: PaymentProcessorFlow; status: Scalars["String"]; transactionID?: Maybe; }; export { OpenGovTenant }; export type Payer = { __typename?: "Payer"; name?: Maybe; }; export enum PaymentChannel { CASHIER = "CASHIER", KIOSK = "KIOSK", TERMINAL = "TERMINAL", WEB = "WEB", } export type PaymentMetadataResponse = { __typename?: "PaymentMetadataResponse"; amount?: Maybe; applicationMetadata?: Maybe; currency?: Maybe; description?: Maybe; entityID?: Maybe; idempotencyKey?: Maybe; items?: Maybe>>; originalPaymentID?: Maybe; paymentID?: Maybe; paymentMethod?: Maybe; processingFee?: Maybe; processorID?: Maybe; sourceApp?: Maybe; tenantID?: Maybe; userID?: Maybe; }; export { PaymentMethod }; export type PaymentMethodDetails = Card | Cash | Check | ECheck; export enum PaymentMode { LIVE = "LIVE", TEST = "TEST", } export type PaymentProcessor = { __typename?: "PaymentProcessor"; baseFee?: Maybe; /** For use in client SDK */ clientPluginUrl?: Maybe; config?: Maybe>; id: PaymentProcessorId; implementationTeam?: Maybe; name: Scalars["String"]; pluginDependencyUrls?: Maybe>; processingFees?: Maybe; supportedFlows: Array; supportedPaymentMethods: Array; supportsWebhooks?: Maybe; }; export { PaymentProcessorFlow }; export { PaymentProcessorId }; export { PaymentStatus }; export type PayoutDetails = { __typename?: "PayoutDetails"; date?: Maybe; id?: Maybe; }; export type ProcessingFeeMetadata = { __typename?: "ProcessingFeeMetadata"; allowCommunityPays?: Maybe; calculatesFeesAtCheckout?: Maybe; fee?: Maybe; scheduled?: Maybe; }; export type ProcessingFees = { __typename?: "ProcessingFees"; CREDIT_CARD?: Maybe; E_CHECK?: Maybe; }; export type Query = { __typename?: "Query"; SEPSMetadata: SEPSMetadata; paymentProcessor?: Maybe; }; export type QuerypaymentProcessorArgs = { id: PaymentProcessorId; }; export type RefundMethodDetails = { __typename?: "RefundMethodDetails"; feeID?: Maybe; label?: Maybe; recordID?: Maybe; recordStepID?: Maybe; userID?: Maybe; }; /** Common interface for mutation responses that fail for predictable reasons. */ export type ResponseErrorMessage = { message: Scalars["String"]; }; export type SEPSMetadata = { __typename?: "SEPSMetadata"; environment: Scalars["String"]; supportedPaymentProcessors: Array; }; export type Signature = { header?: InputMaybe
; protected: Scalars["String"]; signature: Scalars["String"]; }; export enum TerminalPaySessionResultStatus { APPROVED = "APPROVED", DECLINED = "DECLINED", ERROR = "ERROR", IN_PROGRESS = "IN_PROGRESS", UNKNOWN = "UNKNOWN", } export type TerminalPaymentFlowRequest = { /** Amount to be paid */ amount: Scalars["Float"]; applicationMetadata?: InputMaybe; currency?: InputMaybe; description?: InputMaybe; /** Integrator system or client system or tenant */ entityID: Scalars["String"]; idempotencyKey?: InputMaybe; invoiceEmail?: InputMaybe; items?: InputMaybe>>; /** Unique payent transaction reference in integrator system */ paymentID: Scalars["String"]; /** Type of payment channel for transaction */ paymentMethod: PaymentMethod; /** Processing fee to be paid */ processingFee?: InputMaybe; /** Payment plug processor */ processorId: PaymentProcessorId; sourceApp?: InputMaybe; /** Identifier for terminal device */ terminalID?: InputMaybe; /** Options if need to mention for terminal device */ terminalOptions?: InputMaybe; /** Type of terminal device */ terminalType?: InputMaybe; /** User initiating or on behalf of whom the payment is being made */ userID?: InputMaybe; /** Deprecated: User initiating or on behalf of whom the payment is being made */ userId: Scalars["ID"]; }; export type TerminalPaymentFlowResponse = FlowResponseType & { __typename?: "TerminalPaymentFlowResponse"; flowType: PaymentProcessorFlow; paymentMethodDetails: PaymentMethodDetails; serviceFeeAmount?: Maybe; txnReferenceId: Scalars["String"]; txnSessionId: Scalars["Int"]; txnSessionMessage?: Maybe; txnSessionResultStatus: TerminalPaySessionResultStatus; }; export type UpdatePaymentFlowRequest = { amount?: InputMaybe; currency?: InputMaybe; entityID: Scalars["String"]; last4?: InputMaybe; paymentReference: Scalars["String"]; processingFee?: InputMaybe; processorID: PaymentProcessorId; status: PaymentStatus; tenantID: OpenGovTenant; transactionID?: InputMaybe; }; export type UpdatePaymentFlowResponse = FlowResponseType & { __typename?: "UpdatePaymentFlowResponse"; amount?: Maybe; currency?: Maybe; destinationPaymentID?: Maybe; entityID: Scalars["String"]; flowType: PaymentProcessorFlow; last4?: Maybe; paymentReference: Scalars["String"]; payoutDetails?: Maybe; processingFee?: Maybe; processorID: PaymentProcessorId; status?: Maybe; tenantID: OpenGovTenant; transactionID?: Maybe; };