chargebee 3.25.0 → 3.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +44 -0
- package/README.md +39 -0
- package/cjs/RequestWrapper.js +27 -0
- package/cjs/chargebee.cjs.js +3 -0
- package/cjs/chargebee.cjs.worker.js +2 -0
- package/cjs/chargebeeZodValidationError.js +18 -0
- package/cjs/createChargebee.js +5 -0
- package/cjs/environment.js +1 -1
- package/cjs/resources/api_endpoints.js +120 -1
- package/cjs/schema/addon.schema.js +269 -0
- package/cjs/schema/address.schema.js +35 -0
- package/cjs/schema/alert.schema.js +74 -0
- package/cjs/schema/alert_status.schema.js +31 -0
- package/cjs/schema/attached_item.schema.js +144 -0
- package/cjs/schema/business_entity.schema.js +46 -0
- package/cjs/schema/card.schema.js +165 -0
- package/cjs/schema/comment.schema.js +69 -0
- package/cjs/schema/coupon.schema.js +323 -0
- package/cjs/schema/coupon_code.schema.js +49 -0
- package/cjs/schema/coupon_set.schema.js +88 -0
- package/cjs/schema/credit_note.schema.js +502 -0
- package/cjs/schema/currency.schema.js +32 -0
- package/cjs/schema/customer.schema.js +1201 -0
- package/cjs/schema/customer_entitlement.schema.js +14 -0
- package/cjs/schema/differential_price.schema.js +106 -0
- package/cjs/schema/entitlement.schema.js +54 -0
- package/cjs/schema/entitlement_override.schema.js +35 -0
- package/cjs/schema/estimate.schema.js +1535 -0
- package/cjs/schema/event.schema.js +1060 -0
- package/cjs/schema/export.schema.js +3385 -0
- package/cjs/schema/feature.schema.js +78 -0
- package/cjs/schema/gift.schema.js +293 -0
- package/cjs/schema/grant_block.schema.js +47 -0
- package/cjs/schema/hosted_page.schema.js +1777 -0
- package/cjs/schema/in_app_subscription.schema.js +68 -0
- package/cjs/schema/index.js +88 -0
- package/cjs/schema/invoice.schema.js +1685 -0
- package/cjs/schema/item.schema.js +195 -0
- package/cjs/schema/item_entitlement.schema.js +45 -0
- package/cjs/schema/item_family.schema.js +57 -0
- package/cjs/schema/item_price.schema.js +335 -0
- package/cjs/schema/ledger_account_balance.schema.js +21 -0
- package/cjs/schema/ledger_operation.schema.js +104 -0
- package/cjs/schema/meter.schema.js +13 -0
- package/cjs/schema/metered_feature.schema.js +20 -0
- package/cjs/schema/non_subscription.schema.js +28 -0
- package/cjs/schema/offer_event.schema.js +13 -0
- package/cjs/schema/offer_fulfillment.schema.js +20 -0
- package/cjs/schema/omnichannel_one_time_order.schema.js +26 -0
- package/cjs/schema/omnichannel_subscription.schema.js +122 -0
- package/cjs/schema/omnichannel_subscription_item.schema.js +13 -0
- package/cjs/schema/order.schema.js +441 -0
- package/cjs/schema/payment_intent.schema.js +127 -0
- package/cjs/schema/payment_schedule_scheme.schema.js +20 -0
- package/cjs/schema/payment_source.schema.js +630 -0
- package/cjs/schema/payment_voucher.schema.js +57 -0
- package/cjs/schema/personalized_offer.schema.js +28 -0
- package/cjs/schema/plan.schema.js +363 -0
- package/cjs/schema/portal_session.schema.js +22 -0
- package/cjs/schema/price_variant.schema.js +93 -0
- package/cjs/schema/pricing_page_session.schema.js +135 -0
- package/cjs/schema/promotional_credit.schema.js +78 -0
- package/cjs/schema/promotional_grant.schema.js +17 -0
- package/cjs/schema/purchase.schema.js +277 -0
- package/cjs/schema/quote.schema.js +1667 -0
- package/cjs/schema/ramp.schema.js +245 -0
- package/cjs/schema/recorded_purchase.schema.js +32 -0
- package/cjs/schema/resource_migration.schema.js +14 -0
- package/cjs/schema/site_migration_detail.schema.js +81 -0
- package/cjs/schema/subscription.schema.js +3344 -0
- package/cjs/schema/subscription_entitlement.schema.js +25 -0
- package/cjs/schema/time_machine.schema.js +17 -0
- package/cjs/schema/transaction.schema.js +744 -0
- package/cjs/schema/unbilled_charge.schema.js +139 -0
- package/cjs/schema/usage.schema.js +93 -0
- package/cjs/schema/usage_charge.schema.js +17 -0
- package/cjs/schema/usage_event.schema.js +28 -0
- package/cjs/schema/usage_file.schema.js +13 -0
- package/cjs/schema/usage_summary.schema.js +17 -0
- package/cjs/schema/virtual_bank_account.schema.js +71 -0
- package/cjs/schema/webhook_endpoint.schema.js +508 -0
- package/cjs/validationLoader.js +59 -0
- package/esm/RequestWrapper.js +27 -0
- package/esm/chargebee.esm.js +2 -0
- package/esm/chargebee.esm.worker.js +1 -0
- package/esm/chargebeeZodValidationError.js +14 -0
- package/esm/createChargebee.js +5 -0
- package/esm/environment.js +1 -1
- package/esm/resources/api_endpoints.js +120 -1
- package/esm/schema/addon.schema.js +266 -0
- package/esm/schema/address.schema.js +32 -0
- package/esm/schema/alert.schema.js +71 -0
- package/esm/schema/alert_status.schema.js +28 -0
- package/esm/schema/attached_item.schema.js +141 -0
- package/esm/schema/business_entity.schema.js +43 -0
- package/esm/schema/card.schema.js +162 -0
- package/esm/schema/comment.schema.js +66 -0
- package/esm/schema/coupon.schema.js +320 -0
- package/esm/schema/coupon_code.schema.js +46 -0
- package/esm/schema/coupon_set.schema.js +85 -0
- package/esm/schema/credit_note.schema.js +499 -0
- package/esm/schema/currency.schema.js +29 -0
- package/esm/schema/customer.schema.js +1198 -0
- package/esm/schema/customer_entitlement.schema.js +11 -0
- package/esm/schema/differential_price.schema.js +103 -0
- package/esm/schema/entitlement.schema.js +51 -0
- package/esm/schema/entitlement_override.schema.js +32 -0
- package/esm/schema/estimate.schema.js +1532 -0
- package/esm/schema/event.schema.js +1057 -0
- package/esm/schema/export.schema.js +3382 -0
- package/esm/schema/feature.schema.js +75 -0
- package/esm/schema/gift.schema.js +290 -0
- package/esm/schema/grant_block.schema.js +44 -0
- package/esm/schema/hosted_page.schema.js +1774 -0
- package/esm/schema/in_app_subscription.schema.js +65 -0
- package/esm/schema/index.js +72 -0
- package/esm/schema/invoice.schema.js +1682 -0
- package/esm/schema/item.schema.js +192 -0
- package/esm/schema/item_entitlement.schema.js +42 -0
- package/esm/schema/item_family.schema.js +54 -0
- package/esm/schema/item_price.schema.js +332 -0
- package/esm/schema/ledger_account_balance.schema.js +18 -0
- package/esm/schema/ledger_operation.schema.js +101 -0
- package/esm/schema/meter.schema.js +10 -0
- package/esm/schema/metered_feature.schema.js +17 -0
- package/esm/schema/non_subscription.schema.js +25 -0
- package/esm/schema/offer_event.schema.js +10 -0
- package/esm/schema/offer_fulfillment.schema.js +17 -0
- package/esm/schema/omnichannel_one_time_order.schema.js +23 -0
- package/esm/schema/omnichannel_subscription.schema.js +119 -0
- package/esm/schema/omnichannel_subscription_item.schema.js +10 -0
- package/esm/schema/order.schema.js +438 -0
- package/esm/schema/payment_intent.schema.js +124 -0
- package/esm/schema/payment_schedule_scheme.schema.js +17 -0
- package/esm/schema/payment_source.schema.js +627 -0
- package/esm/schema/payment_voucher.schema.js +54 -0
- package/esm/schema/personalized_offer.schema.js +25 -0
- package/esm/schema/plan.schema.js +360 -0
- package/esm/schema/portal_session.schema.js +19 -0
- package/esm/schema/price_variant.schema.js +90 -0
- package/esm/schema/pricing_page_session.schema.js +132 -0
- package/esm/schema/promotional_credit.schema.js +75 -0
- package/esm/schema/promotional_grant.schema.js +14 -0
- package/esm/schema/purchase.schema.js +274 -0
- package/esm/schema/quote.schema.js +1664 -0
- package/esm/schema/ramp.schema.js +242 -0
- package/esm/schema/recorded_purchase.schema.js +29 -0
- package/esm/schema/resource_migration.schema.js +11 -0
- package/esm/schema/site_migration_detail.schema.js +78 -0
- package/esm/schema/subscription.schema.js +3341 -0
- package/esm/schema/subscription_entitlement.schema.js +22 -0
- package/esm/schema/time_machine.schema.js +14 -0
- package/esm/schema/transaction.schema.js +741 -0
- package/esm/schema/unbilled_charge.schema.js +136 -0
- package/esm/schema/usage.schema.js +90 -0
- package/esm/schema/usage_charge.schema.js +14 -0
- package/esm/schema/usage_event.schema.js +25 -0
- package/esm/schema/usage_file.schema.js +10 -0
- package/esm/schema/usage_summary.schema.js +14 -0
- package/esm/schema/virtual_bank_account.schema.js +68 -0
- package/esm/schema/webhook_endpoint.schema.js +505 -0
- package/esm/validationLoader.js +56 -0
- package/package.json +4 -1
- package/types/core.d.ts +3 -0
- package/types/index.d.ts +24 -0
- package/types/resources/Content.d.ts +4 -0
- package/types/resources/CreditNote.d.ts +1 -0
- package/types/resources/GrantBlock.d.ts +59 -0
- package/types/resources/HostedPage.d.ts +5 -1
- package/types/resources/LedgerAccountBalance.d.ts +50 -0
- package/types/resources/LedgerOperation.d.ts +141 -0
- package/types/resources/OmnichannelSubscription.d.ts +2 -0
- package/types/resources/PromotionalGrant.d.ts +37 -0
|
@@ -41,6 +41,7 @@ declare module 'chargebee' {
|
|
|
41
41
|
filter_condition: FilterCondition;
|
|
42
42
|
gateway_error_detail: GatewayErrorDetail;
|
|
43
43
|
gift: Gift;
|
|
44
|
+
grant_block: GrantBlock;
|
|
44
45
|
hierarchy: Hierarchy;
|
|
45
46
|
hosted_page: HostedPage;
|
|
46
47
|
impacted_customer: ImpactedCustomer;
|
|
@@ -54,6 +55,8 @@ declare module 'chargebee' {
|
|
|
54
55
|
item_entitlement: ItemEntitlement;
|
|
55
56
|
item_family: ItemFamily;
|
|
56
57
|
item_price: ItemPrice;
|
|
58
|
+
ledger_account_balance: LedgerAccountBalance;
|
|
59
|
+
ledger_operation: LedgerOperation;
|
|
57
60
|
metadata: Metadata;
|
|
58
61
|
non_subscription: NonSubscription;
|
|
59
62
|
offer_event: OfferEvent;
|
|
@@ -79,6 +82,7 @@ declare module 'chargebee' {
|
|
|
79
82
|
price_variant: PriceVariant;
|
|
80
83
|
pricing_page_session: PricingPageSession;
|
|
81
84
|
promotional_credit: PromotionalCredit;
|
|
85
|
+
promotional_grant: PromotionalGrant;
|
|
82
86
|
purchase: Purchase;
|
|
83
87
|
quote: Quote;
|
|
84
88
|
quote_line_group: QuoteLineGroup;
|
|
@@ -44,6 +44,7 @@ declare module 'chargebee' {
|
|
|
44
44
|
local_currency_code?: string;
|
|
45
45
|
round_off_amount?: number;
|
|
46
46
|
fractional_correction?: number;
|
|
47
|
+
notes?: string[];
|
|
47
48
|
line_items?: CreditNote.LineItem[];
|
|
48
49
|
line_item_tiers?: CreditNote.LineItemTier[];
|
|
49
50
|
line_item_discounts?: CreditNote.LineItemDiscount[];
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
///<reference path='./../core.d.ts'/>
|
|
2
|
+
///<reference path='./../index.d.ts'/>
|
|
3
|
+
///<reference path='./filter.d.ts'/>
|
|
4
|
+
declare module 'chargebee' {
|
|
5
|
+
export interface GrantBlock {
|
|
6
|
+
id: string;
|
|
7
|
+
granted_amount: string;
|
|
8
|
+
effective_from: number;
|
|
9
|
+
expires_at: number;
|
|
10
|
+
balance: string;
|
|
11
|
+
hold_amount: string;
|
|
12
|
+
used_amount: string;
|
|
13
|
+
expired_amount: string;
|
|
14
|
+
rolled_over_amount: string;
|
|
15
|
+
voided_amount: string;
|
|
16
|
+
origin_grant_block_id?: string;
|
|
17
|
+
status: StatusEnum;
|
|
18
|
+
metadata?: string;
|
|
19
|
+
grant_source:
|
|
20
|
+
| 'subscription_created'
|
|
21
|
+
| 'subscription_changed'
|
|
22
|
+
| 'top_up'
|
|
23
|
+
| 'promotional_grants'
|
|
24
|
+
| 'rollover';
|
|
25
|
+
created_at?: number;
|
|
26
|
+
account_type?: 'provisioned' | 'overdraft';
|
|
27
|
+
unit_id?: string;
|
|
28
|
+
unit_type?: 'credit_unit';
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export namespace GrantBlock {
|
|
32
|
+
export class GrantBlockResource {
|
|
33
|
+
listGrantBlocks(
|
|
34
|
+
input: ListGrantBlocksInputParam,
|
|
35
|
+
headers?: ChargebeeRequestHeader,
|
|
36
|
+
): Promise<ChargebeeResponse<ListGrantBlocksResponse>>;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export interface ListGrantBlocksResponse {
|
|
40
|
+
list: { grant_block: GrantBlock }[];
|
|
41
|
+
next_offset?: string;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// REQUEST PARAMS
|
|
45
|
+
//---------------
|
|
46
|
+
|
|
47
|
+
export interface ListGrantBlocksInputParam {
|
|
48
|
+
limit?: number;
|
|
49
|
+
offset?: string;
|
|
50
|
+
subscription_id: filter.String;
|
|
51
|
+
unit_id?: filter.String;
|
|
52
|
+
effective_from?: filter.Timestamp;
|
|
53
|
+
expires_at?: filter.Timestamp;
|
|
54
|
+
created_at?: filter.Timestamp;
|
|
55
|
+
'sort_by[asc]'?: string;
|
|
56
|
+
'sort_by[desc]'?: string;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -7,7 +7,6 @@ declare module 'chargebee' {
|
|
|
7
7
|
type?:
|
|
8
8
|
| 'checkout_new'
|
|
9
9
|
| 'checkout_existing'
|
|
10
|
-
| 'update_payment_method'
|
|
11
10
|
| 'manage_payment_sources'
|
|
12
11
|
| 'collect_now'
|
|
13
12
|
| 'extend_subscription'
|
|
@@ -29,6 +28,7 @@ declare module 'chargebee' {
|
|
|
29
28
|
embed: boolean;
|
|
30
29
|
created_at?: number;
|
|
31
30
|
expires_at?: number;
|
|
31
|
+
layout?: LayoutEnum;
|
|
32
32
|
content: Content;
|
|
33
33
|
updated_at?: number;
|
|
34
34
|
resource_version?: number;
|
|
@@ -77,6 +77,10 @@ declare module 'chargebee' {
|
|
|
77
77
|
headers?: ChargebeeRequestHeader,
|
|
78
78
|
): Promise<ChargebeeResponse<UpdateCardResponse>>;
|
|
79
79
|
|
|
80
|
+
/**
|
|
81
|
+
* @deprecated This method is deprecated and will be removed in a future version.
|
|
82
|
+
*/
|
|
83
|
+
|
|
80
84
|
updatePaymentMethod(
|
|
81
85
|
input: UpdatePaymentMethodInputParam,
|
|
82
86
|
headers?: ChargebeeRequestHeader,
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
///<reference path='./../core.d.ts'/>
|
|
2
|
+
///<reference path='./../index.d.ts'/>
|
|
3
|
+
///<reference path='./filter.d.ts'/>
|
|
4
|
+
declare module 'chargebee' {
|
|
5
|
+
export interface LedgerAccountBalance {
|
|
6
|
+
subscription_id: string;
|
|
7
|
+
unit_id: string;
|
|
8
|
+
unit_type: 'credit_unit';
|
|
9
|
+
modified_at?: number;
|
|
10
|
+
provisioned_balance?: LedgerAccountBalance.ProvisionedBalance;
|
|
11
|
+
overdraft_balance?: LedgerAccountBalance.OverdraftBalance;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export namespace LedgerAccountBalance {
|
|
15
|
+
export class LedgerAccountBalanceResource {
|
|
16
|
+
listLedgerAccountBalances(
|
|
17
|
+
input: ListLedgerAccountBalancesInputParam,
|
|
18
|
+
headers?: ChargebeeRequestHeader,
|
|
19
|
+
): Promise<ChargebeeResponse<ListLedgerAccountBalancesResponse>>;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface ListLedgerAccountBalancesResponse {
|
|
23
|
+
list: { ledger_account_balance: LedgerAccountBalance }[];
|
|
24
|
+
next_offset?: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface ProvisionedBalance {
|
|
28
|
+
total_balance: string;
|
|
29
|
+
usable_balance: string;
|
|
30
|
+
hold_amount: string;
|
|
31
|
+
}
|
|
32
|
+
export interface OverdraftBalance {
|
|
33
|
+
is_unlimited: boolean;
|
|
34
|
+
limit?: string;
|
|
35
|
+
total_balance?: string;
|
|
36
|
+
usable_balance?: string;
|
|
37
|
+
used_amount: string;
|
|
38
|
+
hold_amount: string;
|
|
39
|
+
}
|
|
40
|
+
// REQUEST PARAMS
|
|
41
|
+
//---------------
|
|
42
|
+
|
|
43
|
+
export interface ListLedgerAccountBalancesInputParam {
|
|
44
|
+
limit?: number;
|
|
45
|
+
offset?: string;
|
|
46
|
+
subscription_id: filter.String;
|
|
47
|
+
unit_id?: filter.String;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
///<reference path='./../core.d.ts'/>
|
|
2
|
+
///<reference path='./../index.d.ts'/>
|
|
3
|
+
///<reference path='./filter.d.ts'/>
|
|
4
|
+
declare module 'chargebee' {
|
|
5
|
+
export interface LedgerOperation {
|
|
6
|
+
id: string;
|
|
7
|
+
type:
|
|
8
|
+
| 'allocation'
|
|
9
|
+
| 'capture'
|
|
10
|
+
| 'authorize'
|
|
11
|
+
| 'release_authorization'
|
|
12
|
+
| 'capture_authorization'
|
|
13
|
+
| 'expiry'
|
|
14
|
+
| 'void'
|
|
15
|
+
| 'rollover'
|
|
16
|
+
| 'adjustment';
|
|
17
|
+
amount: string;
|
|
18
|
+
start_balance: string;
|
|
19
|
+
end_balance: string;
|
|
20
|
+
provisioned_start_balance: string;
|
|
21
|
+
provisioned_end_balance: string;
|
|
22
|
+
overdraft_start_balance: string;
|
|
23
|
+
overdraft_end_balance: string;
|
|
24
|
+
parent_ledger_operation_id?: string;
|
|
25
|
+
ledger_operation_timestamp?: number;
|
|
26
|
+
auto_release_timestamp?: number;
|
|
27
|
+
metadata?: string;
|
|
28
|
+
created_at?: number;
|
|
29
|
+
modified_at?: number;
|
|
30
|
+
subscription_id?: string;
|
|
31
|
+
unit_id?: string;
|
|
32
|
+
unit_type?: 'credit_unit';
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export namespace LedgerOperation {
|
|
36
|
+
export class LedgerOperationResource {
|
|
37
|
+
retrieveLedgerOperation(
|
|
38
|
+
ledger_operation_id: string,
|
|
39
|
+
headers?: ChargebeeRequestHeader,
|
|
40
|
+
): Promise<ChargebeeResponse<RetrieveLedgerOperationResponse>>;
|
|
41
|
+
|
|
42
|
+
listLedgerOperations(
|
|
43
|
+
input: ListLedgerOperationsInputParam,
|
|
44
|
+
headers?: ChargebeeRequestHeader,
|
|
45
|
+
): Promise<ChargebeeResponse<ListLedgerOperationsResponse>>;
|
|
46
|
+
|
|
47
|
+
capture(
|
|
48
|
+
input: CaptureInputParam,
|
|
49
|
+
headers?: ChargebeeRequestHeader,
|
|
50
|
+
): Promise<ChargebeeResponse<CaptureResponse>>;
|
|
51
|
+
|
|
52
|
+
authorize(
|
|
53
|
+
input: AuthorizeInputParam,
|
|
54
|
+
headers?: ChargebeeRequestHeader,
|
|
55
|
+
): Promise<ChargebeeResponse<AuthorizeResponse>>;
|
|
56
|
+
|
|
57
|
+
captureAuthorization(
|
|
58
|
+
input: CaptureAuthorizationInputParam,
|
|
59
|
+
headers?: ChargebeeRequestHeader,
|
|
60
|
+
): Promise<ChargebeeResponse<CaptureAuthorizationResponse>>;
|
|
61
|
+
|
|
62
|
+
releaseAuthorization(
|
|
63
|
+
input: ReleaseAuthorizationInputParam,
|
|
64
|
+
headers?: ChargebeeRequestHeader,
|
|
65
|
+
): Promise<ChargebeeResponse<ReleaseAuthorizationResponse>>;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export interface RetrieveLedgerOperationResponse {
|
|
69
|
+
ledger_operation: LedgerOperation;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export interface ListLedgerOperationsResponse {
|
|
73
|
+
list: { ledger_operation: LedgerOperation }[];
|
|
74
|
+
next_offset?: string;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export interface CaptureResponse {
|
|
78
|
+
ledger_operation: LedgerOperation;
|
|
79
|
+
ledger_account_balance: LedgerAccountBalance;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export interface AuthorizeResponse {
|
|
83
|
+
ledger_operation: LedgerOperation;
|
|
84
|
+
ledger_account_balance: LedgerAccountBalance;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export interface CaptureAuthorizationResponse {
|
|
88
|
+
ledger_operation: LedgerOperation;
|
|
89
|
+
ledger_account_balance: LedgerAccountBalance;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export interface ReleaseAuthorizationResponse {
|
|
93
|
+
ledger_operation: LedgerOperation;
|
|
94
|
+
ledger_account_balance: LedgerAccountBalance;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
// REQUEST PARAMS
|
|
98
|
+
//---------------
|
|
99
|
+
|
|
100
|
+
export interface ListLedgerOperationsInputParam {
|
|
101
|
+
limit?: number;
|
|
102
|
+
offset?: string;
|
|
103
|
+
subscription_id: filter.String;
|
|
104
|
+
unit_id?: filter.String;
|
|
105
|
+
created_at?: filter.Timestamp;
|
|
106
|
+
type?: filter.Enum;
|
|
107
|
+
'sort_by[asc]'?: string;
|
|
108
|
+
'sort_by[desc]'?: string;
|
|
109
|
+
}
|
|
110
|
+
export interface CaptureInputParam {
|
|
111
|
+
id?: string;
|
|
112
|
+
subscription_id: string;
|
|
113
|
+
unit_id: string;
|
|
114
|
+
amount: string;
|
|
115
|
+
ledger_operation_timestamp: number;
|
|
116
|
+
metadata?: any;
|
|
117
|
+
}
|
|
118
|
+
export interface AuthorizeInputParam {
|
|
119
|
+
id?: string;
|
|
120
|
+
subscription_id: string;
|
|
121
|
+
unit_id: string;
|
|
122
|
+
amount: string;
|
|
123
|
+
ledger_operation_timestamp: number;
|
|
124
|
+
auto_release_timestamp?: number;
|
|
125
|
+
metadata?: any;
|
|
126
|
+
}
|
|
127
|
+
export interface CaptureAuthorizationInputParam {
|
|
128
|
+
authorization_id: string;
|
|
129
|
+
id?: string;
|
|
130
|
+
amount: string;
|
|
131
|
+
ledger_operation_timestamp: number;
|
|
132
|
+
metadata?: any;
|
|
133
|
+
}
|
|
134
|
+
export interface ReleaseAuthorizationInputParam {
|
|
135
|
+
authorization_id: string;
|
|
136
|
+
id?: string;
|
|
137
|
+
ledger_operation_timestamp: number;
|
|
138
|
+
metadata?: any;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
@@ -74,6 +74,8 @@ declare module 'chargebee' {
|
|
|
74
74
|
id_at_source?: filter.String;
|
|
75
75
|
updated_at?: filter.Timestamp;
|
|
76
76
|
purchased_at?: filter.Timestamp;
|
|
77
|
+
'sort_by[asc]'?: string;
|
|
78
|
+
'sort_by[desc]'?: string;
|
|
77
79
|
}
|
|
78
80
|
export interface OmnichannelTransactionsForOmnichannelSubscriptionInputParam {
|
|
79
81
|
limit?: number;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
///<reference path='./../core.d.ts'/>
|
|
2
|
+
///<reference path='./../index.d.ts'/>
|
|
3
|
+
|
|
4
|
+
declare module 'chargebee' {
|
|
5
|
+
export interface PromotionalGrant {
|
|
6
|
+
subscription_id: string;
|
|
7
|
+
unit_id: string;
|
|
8
|
+
amount: string;
|
|
9
|
+
expires_at: number;
|
|
10
|
+
metadata?: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export namespace PromotionalGrant {
|
|
14
|
+
export class PromotionalGrantResource {
|
|
15
|
+
promotionalGrants(
|
|
16
|
+
input: PromotionalGrantsInputParam,
|
|
17
|
+
headers?: ChargebeeRequestHeader,
|
|
18
|
+
): Promise<ChargebeeResponse<PromotionalGrantsResponse>>;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface PromotionalGrantsResponse {
|
|
22
|
+
ledger_operations: LedgerOperation[];
|
|
23
|
+
grant_blocks: GrantBlock[];
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
// REQUEST PARAMS
|
|
27
|
+
//---------------
|
|
28
|
+
|
|
29
|
+
export interface PromotionalGrantsInputParam {
|
|
30
|
+
subscription_id: string;
|
|
31
|
+
unit_id: string;
|
|
32
|
+
amount: string;
|
|
33
|
+
expires_at: number;
|
|
34
|
+
metadata?: any;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|