Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/resources/customers/costs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,13 @@ export class Costs extends APIResource {
* `grouping_value` and `secondary_grouping_value` available.
*/
list(
customerId: string | null,
customerId: string,
query?: CostListParams,
options?: Core.RequestOptions,
): Core.APIPromise<CostListResponse>;
list(customerId: string | null, options?: Core.RequestOptions): Core.APIPromise<CostListResponse>;
list(customerId: string, options?: Core.RequestOptions): Core.APIPromise<CostListResponse>;
list(
customerId: string | null,
customerId: string,
query: CostListParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.APIPromise<CostListResponse> {
Expand Down Expand Up @@ -297,16 +297,16 @@ export class Costs extends APIResource {
* `grouping_value` and `secondary_grouping_value` available.
*/
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query?: CostListByExternalIDParams,
options?: Core.RequestOptions,
): Core.APIPromise<CostListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
options?: Core.RequestOptions,
): Core.APIPromise<CostListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query: CostListByExternalIDParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.APIPromise<CostListByExternalIDResponse> {
Expand Down
12 changes: 6 additions & 6 deletions src/resources/customers/credits/credits.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@ export class Credits extends APIResource {
* Returns a paginated list of unexpired, non-zero credit blocks for a customer.
*/
list(
customerId: string | null,
customerId: string,
query?: CreditListParams,
options?: Core.RequestOptions,
): Core.PagePromise<CreditListResponsesPage, CreditListResponse>;
list(
customerId: string | null,
customerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<CreditListResponsesPage, CreditListResponse>;
list(
customerId: string | null,
customerId: string,
query: CreditListParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<CreditListResponsesPage, CreditListResponse> {
Expand All @@ -42,16 +42,16 @@ export class Credits extends APIResource {
* Returns a paginated list of unexpired, non-zero credit blocks for a customer.
*/
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query?: CreditListByExternalIDParams,
options?: Core.RequestOptions,
): Core.PagePromise<CreditListByExternalIDResponsesPage, CreditListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<CreditListByExternalIDResponsesPage, CreditListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query: CreditListByExternalIDParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<CreditListByExternalIDResponsesPage, CreditListByExternalIDResponse> {
Expand Down
16 changes: 8 additions & 8 deletions src/resources/customers/credits/ledger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,16 +91,16 @@ export class Ledger extends APIResource {
* entry will be added to the ledger to indicate the adjustment of credits.
*/
list(
customerId: string | null,
customerId: string,
query?: LedgerListParams,
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse>;
list(
customerId: string | null,
customerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse>;
list(
customerId: string | null,
customerId: string,
query: LedgerListParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse> {
Expand Down Expand Up @@ -225,7 +225,7 @@ export class Ledger extends APIResource {
* return to the customer, up to the block's initial balance.
*/
createEntry(
customerId: string | null,
customerId: string,
body: LedgerCreateEntryParams,
options?: Core.RequestOptions,
): Core.APIPromise<LedgerCreateEntryResponse> {
Expand Down Expand Up @@ -344,7 +344,7 @@ export class Ledger extends APIResource {
* return to the customer, up to the block's initial balance.
*/
createEntryByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
body: LedgerCreateEntryByExternalIDParams,
options?: Core.RequestOptions,
): Core.APIPromise<LedgerCreateEntryByExternalIDResponse> {
Expand Down Expand Up @@ -438,16 +438,16 @@ export class Ledger extends APIResource {
* entry will be added to the ledger to indicate the adjustment of credits.
*/
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query?: LedgerListByExternalIDParams,
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query: LedgerListByExternalIDParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse> {
Expand Down
20 changes: 10 additions & 10 deletions src/resources/customers/credits/top-ups.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export class TopUps extends APIResource {
* top-up will be replaced.
*/
create(
customerId: string | null,
customerId: string,
body: TopUpCreateParams,
options?: Core.RequestOptions,
): Core.APIPromise<TopUpCreateResponse> {
Expand All @@ -28,16 +28,16 @@ export class TopUps extends APIResource {
* List top-ups
*/
list(
customerId: string | null,
customerId: string,
query?: TopUpListParams,
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListResponsesPage, TopUpListResponse>;
list(
customerId: string | null,
customerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListResponsesPage, TopUpListResponse>;
list(
customerId: string | null,
customerId: string,
query: TopUpListParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListResponsesPage, TopUpListResponse> {
Expand All @@ -53,7 +53,7 @@ export class TopUps extends APIResource {
/**
* Delete top-up
*/
delete(customerId: string | null, topUpId: string, options?: Core.RequestOptions): Core.APIPromise<void> {
delete(customerId: string, topUpId: string, options?: Core.RequestOptions): Core.APIPromise<void> {
return this._client.delete(`/customers/${customerId}/credits/top_ups/${topUpId}`, {
...options,
headers: { Accept: '*/*', ...options?.headers },
Expand All @@ -70,7 +70,7 @@ export class TopUps extends APIResource {
* top-up will be replaced.
*/
createByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
body: TopUpCreateByExternalIDParams,
options?: Core.RequestOptions,
): Core.APIPromise<TopUpCreateByExternalIDResponse> {
Expand All @@ -84,7 +84,7 @@ export class TopUps extends APIResource {
* Delete top-up by external ID
*/
deleteByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
topUpId: string,
options?: Core.RequestOptions,
): Core.APIPromise<void> {
Expand All @@ -98,16 +98,16 @@ export class TopUps extends APIResource {
* List top-ups by external ID
*/
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query?: TopUpListByExternalIDParams,
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListByExternalIDResponsesPage, TopUpListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListByExternalIDResponsesPage, TopUpListByExternalIDResponse>;
listByExternalId(
externalCustomerId: string | null,
externalCustomerId: string,
query: TopUpListByExternalIDParams | Core.RequestOptions = {},
options?: Core.RequestOptions,
): Core.PagePromise<TopUpListByExternalIDResponsesPage, TopUpListByExternalIDResponse> {
Expand Down
4 changes: 2 additions & 2 deletions src/resources/customers/usage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export class Usage extends APIResource {
* using multiple calls with small adjacent (e.g. every hour) timeframes.
*/
update(
id: string | null,
id: string,
params: UsageUpdateParams,
options?: Core.RequestOptions,
): Core.APIPromise<UsageUpdateResponse> {
Expand Down Expand Up @@ -215,7 +215,7 @@ export class Usage extends APIResource {
* using multiple calls with small adjacent (e.g. every hour) timeframes.
*/
updateByExternalId(
id: string | null,
id: string,
params: UsageUpdateByExternalIDParams,
options?: Core.RequestOptions,
): Core.APIPromise<UsageUpdateByExternalIDResponse> {
Expand Down