Class Api<SecurityDataType>

Title

Gringotts api

Version

0.1.0

Base Url

http://localhost:7171/api

Documentation for the Gringotts api

Type Parameters

  • SecurityDataType extends unknown

Hierarchy

Constructors

  • Type Parameters

    • SecurityDataType extends unknown

    Parameters

    Returns Api<SecurityDataType>

Properties

baseUrl: string = 'http://localhost:7171/api'
customer: { createCustomer: ((body: CustomerUpdateBody, params?: RequestParams) => Promise<HttpResponse<Customer, ErrorResponse>>); createPaymentMethod: ((customerId: string, body: { redirectUrl: string }, params?: RequestParams) => Promise<HttpResponse<{ checkoutUrl?: string; paymentMethodId?: string }, ErrorResponse>>); deleteCustomer: ((customerId: string, params?: RequestParams) => Promise<HttpResponse<SuccessResponse, ErrorResponse>>); deletePaymentMethod: ((customerId: string, paymentMethodId: string, params?: RequestParams) => Promise<HttpResponse<{ ok?: boolean }, ErrorResponse>>); getCustomer: ((customerId: string, params?: RequestParams) => Promise<HttpResponse<Customer, ErrorResponse>>); getPaymentMethod: ((customerId: string, paymentMethodId: string, params?: RequestParams) => Promise<HttpResponse<PaymentMethod, ErrorResponse>>); listCustomerInvoices: ((customerId: string, params?: RequestParams) => Promise<HttpResponse<Invoice[], ErrorResponse>>); listCustomerSubscriptions: ((customerId: string, params?: RequestParams) => Promise<HttpResponse<Subscription[], ErrorResponse>>); listCustomers: ((query?: { email?: string }, params?: RequestParams) => Promise<HttpResponse<Customer[], ErrorResponse>>); listPaymentMethods: ((customerId: string, params?: RequestParams) => Promise<HttpResponse<PaymentMethod[], ErrorResponse>>); patchCustomer: ((customerId: string, body: CustomerUpdateBody, params?: RequestParams) => Promise<HttpResponse<Customer, ErrorResponse>>) } = ...

Type declaration

invoice: { generateInvoiceDownloadLink: ((invoiceId: string, params?: RequestParams) => Promise<HttpResponse<{ url: string }, ErrorResponse>>); getInvoice: ((invoiceId: string, params?: RequestParams) => Promise<HttpResponse<Invoice, ErrorResponse>>); listInvoices: ((params?: RequestParams) => Promise<HttpResponse<Invoice[], any>>); patchInvoice: ((invoiceId: string, body: { status?: string }, params?: RequestParams) => Promise<HttpResponse<SuccessResponse, ErrorResponse>>) } = ...

Type declaration

payment: { getPayment: ((paymentId: string, params?: RequestParams) => Promise<HttpResponse<Payment, ErrorResponse>>); listPayments: ((params?: RequestParams) => Promise<HttpResponse<Payment[], any>>) } = ...

Type declaration

project: { createProject: ((body: ProjectUpdateBody, params?: RequestParams) => Promise<HttpResponse<Project, ErrorResponse>>); deleteProject: ((projectId: string, params?: RequestParams) => Promise<HttpResponse<SuccessResponse, ErrorResponse>>); getProject: ((projectId: string, params?: RequestParams) => Promise<HttpResponse<Project, ErrorResponse>>); listProjects: ((params?: RequestParams) => Promise<HttpResponse<Project[], ErrorResponse>>); patchProject: ((projectId: string, body: ProjectUpdateBody, params?: RequestParams) => Promise<HttpResponse<Project, ErrorResponse>>) } = ...

Type declaration

subscription: { createSubscription: ((body: { customerId: string; metadata?: object; pricePerUnit: number; units: number }, params?: RequestParams) => Promise<HttpResponse<Subscription, ErrorResponse>>); getSubscription: ((subscriptionId: string, params?: RequestParams) => Promise<HttpResponse<Subscription, ErrorResponse>>); listSubscriptionInvoices: ((subscriptionId: string, params?: RequestParams) => Promise<HttpResponse<Invoice[], ErrorResponse>>); listSubscriptions: ((params?: RequestParams) => Promise<HttpResponse<Subscription[], any>>); patchSubscription: ((subscriptionId: string, body: { error?: string; metadata?: object; pricePerUnit?: number; status?: "error" | "active" | "paused" | "canceled"; units?: number }, params?: RequestParams) => Promise<HttpResponse<SuccessResponse, ErrorResponse>>) } = ...

Type declaration

Methods

  • Parameters

    • cancelToken: CancelToken

    Returns void

  • Parameters

    • data: null | SecurityDataType

    Returns void

Generated using TypeDoc