Skip to content

@sourceloop/payment-service / Exports / IGateway

Interface: IGateway

Table of contents

Methods

Methods

charge

charge(chargeResponse): Promise<DataObject<{ res: string }>>

Parameters

Name Type
chargeResponse DataObject<{}>

Returns

Promise<DataObject<{ res: string }>>

Defined in

services/payment-service/src/providers/types.ts:13


create

create(payorder, paymentTemplate): DataObject<{}> | Promise<unknown>

Parameters

Name Type
payorder Orders
paymentTemplate undefined | string

Returns

DataObject<{}> | Promise<unknown>

Defined in

services/payment-service/src/providers/types.ts:9


refund

refund(transactionId): void | Promise<unknown>

Parameters

Name Type
transactionId string

Returns

void | Promise<unknown>

Defined in

services/payment-service/src/providers/types.ts:14


subscriptionCharge

subscriptionCharge(chargeResponse): Promise<DataObject<{ res: string }>>

Parameters

Name Type
chargeResponse DataObject<{ stripeEmail: string ; stripeToken: string ; subscriptionId: string }>

Returns

Promise<DataObject<{ res: string }>>

Defined in

services/payment-service/src/providers/types.ts:19


subscriptionCreate

subscriptionCreate(subscriptions, paymentTemplate): {} | Promise<string>

Parameters

Name Type
subscriptions Subscriptions
paymentTemplate undefined | string

Returns

{} | Promise<string>

Defined in

services/payment-service/src/providers/types.ts:15


subscriptionWebHook

subscriptionWebHook(sub): Promise<{}>

Parameters

Name Type
sub DataObject<{ data: DataObject<{ object: DataObject<{ status: string ; subscription: string }> }> }>

Returns

Promise<{}>

Defined in

services/payment-service/src/providers/types.ts:26