diff --git a/src/lib/sdk/billing.ts b/src/lib/sdk/billing.ts index 8773bb77b..156a259e4 100644 --- a/src/lib/sdk/billing.ts +++ b/src/lib/sdk/billing.ts @@ -702,6 +702,46 @@ export class Billing { ); } + async getOrganizationPaymentMethod( + organizationId: string, + paymentMethodId: string + ): Promise { + const path = `/organizations/${organizationId}/payment-methods/${paymentMethodId}`; + const params = { + organizationId, + paymentMethodId + }; + const uri = new URL(this.client.config.endpoint + path); + return await this.client.call( + 'GET', + uri, + { + 'content-type': 'application/json' + }, + params + ); + } + + async getOrganizationBillingAddress( + organizationId: string, + billingAddressId: string + ): Promise { + const path = `/organizations/${organizationId}/payment-methods/${billingAddressId}`; + const params = { + organizationId, + billingAddressId + }; + const uri = new URL(this.client.config.endpoint + path); + return await this.client.call( + 'GET', + uri, + { + 'content-type': 'application/json' + }, + params + ); + } + //ACCOUNT async listPaymentMethods(queries: [] = []): Promise {