UNPKG

modem-pay

Version:

A TypeScript SDK for integrating with the Modem Pay payment gateway, enabling seamless payment processing and financial services in your applications.

19 lines (18 loc) 1.04 kB
import Core from "../interfaces/core"; import { Customer, CustomerCreateOption, CustomerListOption, CustomerParams, List, ListOption, PaymentMethod } from "../types"; import BaseResource from "./base"; export default class CustomersResource extends BaseResource implements Core<Customer> { constructor(apiKey: string, maxRetries: number, timeout: number); /** Creates a new customer. */ create(params: CustomerParams, options?: CustomerCreateOption): Promise<Customer>; /** Retrieves a Customer's data. */ retrieve(id: string): Promise<Customer>; /** Returns a list of customers. */ list(options?: CustomerListOption): Promise<List<Customer>>; /** Updates the specified customer. */ update(id: string, params: CustomerParams): Promise<Customer>; /** Permanently deletes a customer. */ delete(id: string): Promise<void>; /** Returns a list of payment methods associated with a specific customer. */ listPaymentMethods(id: string, options?: ListOption): Promise<List<PaymentMethod>>; }