@takeal/cusfront-sdk 0.6.6 → 0.6.11
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 +75 -2
- package/README.md +60 -7
- package/dist/{cards-DwmzjKDC.d.ts → cards-CuUdrQ0H.d.ts} +65 -7
- package/dist/{cards-BiXmrz7h.d.cts → cards-nXmDP0ei.d.cts} +65 -7
- package/dist/index.cjs +80 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -6
- package/dist/index.d.ts +10 -6
- package/dist/index.js +80 -7
- package/dist/index.js.map +1 -1
- package/dist/react/index.d.cts +2 -1
- package/dist/react/index.d.ts +2 -1
- package/dist/resources/auth.cjs.map +1 -1
- package/dist/resources/auth.d.cts +2 -1
- package/dist/resources/auth.d.ts +2 -1
- package/dist/resources/auth.js.map +1 -1
- package/dist/resources/cards.cjs +33 -4
- package/dist/resources/cards.cjs.map +1 -1
- package/dist/resources/cards.d.cts +2 -1
- package/dist/resources/cards.d.ts +2 -1
- package/dist/resources/cards.js +33 -5
- package/dist/resources/cards.js.map +1 -1
- package/dist/resources/claims.cjs +40 -0
- package/dist/resources/claims.cjs.map +1 -0
- package/dist/resources/claims.d.cts +114 -0
- package/dist/resources/claims.d.ts +114 -0
- package/dist/resources/claims.js +38 -0
- package/dist/resources/claims.js.map +1 -0
- package/dist/resources/deposits.cjs.map +1 -1
- package/dist/resources/deposits.d.cts +2 -1
- package/dist/resources/deposits.d.ts +2 -1
- package/dist/resources/deposits.js.map +1 -1
- package/dist/resources/funding-options.d.cts +2 -1
- package/dist/resources/funding-options.d.ts +2 -1
- package/dist/resources/me.d.cts +2 -1
- package/dist/resources/me.d.ts +2 -1
- package/dist/resources/subscription.cjs +9 -0
- package/dist/resources/subscription.cjs.map +1 -1
- package/dist/resources/subscription.d.cts +19 -2
- package/dist/resources/subscription.d.ts +19 -2
- package/dist/resources/subscription.js +9 -0
- package/dist/resources/subscription.js.map +1 -1
- package/dist/resources/support.cjs.map +1 -1
- package/dist/resources/support.d.cts +8 -3
- package/dist/resources/support.d.ts +8 -3
- package/dist/resources/support.js.map +1 -1
- package/dist/telegram.cjs +79 -6
- package/dist/telegram.cjs.map +1 -1
- package/dist/telegram.d.cts +2 -1
- package/dist/telegram.d.ts +2 -1
- package/dist/telegram.js +79 -6
- package/dist/telegram.js.map +1 -1
- package/package.json +9 -4
package/dist/index.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { T as TokenStore, F as FetchLike } from './http-CL97TjMO.cjs';
|
|
|
2
2
|
export { d as defaultBrowserStore, i as inMemoryStore } from './http-CL97TjMO.cjs';
|
|
3
3
|
import { AuthResource } from './resources/auth.cjs';
|
|
4
4
|
export { ChangePasswordInput, EmailChangeRequested, EmailCodeSent, EmailCodeSession, ExchangeTelegramInput, JwtIssued, LinkTelegramInput, LoginInput, LoginResponse, OtpSentResponse, RegisterInput, RequestEmailCodeInput, Session, TelegramLink, TelegramUnknown, TotpRequired, TotpSetupComplete, TotpSetupRequired, User, VerifyEmailCodeInput } from './resources/auth.cjs';
|
|
5
|
-
import { b as DepositsResource, F as FundingOptionsResource, c as CardsResource } from './cards-
|
|
6
|
-
export { A as Address, B as BillingAddress, a as Card, d as CardBalance, e as CardDesignRef, f as CardForm, g as CardInTransit, h as CardLoadStatus, i as CardOrder, j as CardOrderError, k as CardOrderInput, C as CardProduct, l as CardProductPrice, m as CardStatus, n as CardStatusSource, o as CardTariff, p as CardTopUp, q as CardTopUpStatus, r as CardTransfer, s as CardType, t as Cardholder, u as CloseBlockedReason, v as CreateCardInput, w as CreateDepositRefundInput, x as CreateQuoteInput, y as CustomerInfo, D as Deposit, z as DepositMethod, E as DepositStatus, G as DepositTarget, H as FeeKind, I as FunderMode, J as FundingOption, K as FundingQuote, L as InitiateDepositInput, M as IssuanceBonus, N as IssueCardInput, O as MethodTerms, R as Refund, P as RevealCardInput, Q as
|
|
5
|
+
import { b as DepositsResource, F as FundingOptionsResource, c as CardsResource } from './cards-nXmDP0ei.cjs';
|
|
6
|
+
export { A as Address, B as BillingAddress, a as Card, d as CardBalance, e as CardDesignRef, f as CardForm, g as CardInTransit, h as CardLoadStatus, i as CardOrder, j as CardOrderError, k as CardOrderInput, C as CardProduct, l as CardProductPrice, m as CardStatus, n as CardStatusSource, o as CardTariff, p as CardTopUp, q as CardTopUpStatus, r as CardTransfer, s as CardType, t as Cardholder, u as CloseBlockedReason, v as CreateCardInput, w as CreateDepositRefundInput, x as CreateQuoteInput, y as CustomerInfo, D as Deposit, z as DepositMethod, E as DepositStatus, G as DepositTarget, H as FeeKind, I as FunderMode, J as FundingOption, K as FundingQuote, L as InitiateDepositInput, M as IssuanceBonus, N as IssueCardInput, O as MethodTerms, R as Refund, P as RevealCardInput, Q as RevealState, S as RevealedCard, T as SetPinInput, U as TopUpInput, V as TopUpResult, W as TopUpTerms, X as TransferInput, Y as TransferResult, Z as UpdateCardInput, _ as revealState } from './cards-nXmDP0ei.cjs';
|
|
7
7
|
import { BalanceResource } from './resources/balance.cjs';
|
|
8
8
|
export { Balance } from './resources/balance.cjs';
|
|
9
9
|
import { BonusResource } from './resources/bonus.cjs';
|
|
@@ -12,12 +12,14 @@ import { DebtResource } from './resources/debt.cjs';
|
|
|
12
12
|
export { CardFeeKind, Debt, DebtAmount, DebtLine } from './resources/debt.cjs';
|
|
13
13
|
import { CloseRequestsResource } from './resources/close-requests.cjs';
|
|
14
14
|
export { CloseAmount, CloseRefund, CloseRequest, CloseRequestError, CloseRequestStatus, PayoutDetailsInput, PayoutDetailsShown } from './resources/close-requests.cjs';
|
|
15
|
+
import { ClaimsResource } from './resources/claims.cjs';
|
|
16
|
+
export { Claim, ClaimError, ClaimKind, ClaimPage, ClaimStatus, ClaimTransaction, CreateClaimInput } from './resources/claims.cjs';
|
|
15
17
|
import { CodesResource } from './resources/codes.cjs';
|
|
16
18
|
export { CodeCheck, CodeDiscount, CodeEffect, CodeEffectOutcome, CodeOperation, CodeRejection, CodeResult, ValidateCodeInput } from './resources/codes.cjs';
|
|
17
19
|
import { ReferralResource } from './resources/referral.cjs';
|
|
18
20
|
export { InvitedFriend, Referral, ReferralReward } from './resources/referral.cjs';
|
|
19
21
|
import { SubscriptionResource } from './resources/subscription.cjs';
|
|
20
|
-
export { UserSubscription } from './resources/subscription.cjs';
|
|
22
|
+
export { CancelledSubscription, UserSubscription } from './resources/subscription.cjs';
|
|
21
23
|
import { BrandingResource } from './resources/branding.cjs';
|
|
22
24
|
export { Branding } from './resources/branding.cjs';
|
|
23
25
|
import { WalletResource } from './resources/wallet.cjs';
|
|
@@ -79,7 +81,7 @@ interface BrandConfig {
|
|
|
79
81
|
* Which platform versions this SDK works with, as a semver range:
|
|
80
82
|
* comparators separated by ", ". Keep this the only definition.
|
|
81
83
|
*/
|
|
82
|
-
declare const SUPPORTED_MEISTER = ">=0.6
|
|
84
|
+
declare const SUPPORTED_MEISTER = ">=0.7.6, <1.0.0";
|
|
83
85
|
/** What `client.ready()` returns. */
|
|
84
86
|
interface ReadyInfo {
|
|
85
87
|
/** `true` when the platform reported a version inside `supportedMeister`. */
|
|
@@ -185,7 +187,7 @@ declare function isNetworkError(e: unknown): e is NetworkError;
|
|
|
185
187
|
* `define`. `src/version.test.ts` checks it matches `package.json`, so a
|
|
186
188
|
* release bump that forgets this file fails the test run.
|
|
187
189
|
*/
|
|
188
|
-
declare const SDK_VERSION = "0.6.
|
|
190
|
+
declare const SDK_VERSION = "0.6.11";
|
|
189
191
|
|
|
190
192
|
/**
|
|
191
193
|
* `@takeal/cusfront-sdk` — typed client for the Takeal end-user API.
|
|
@@ -252,11 +254,13 @@ interface CusfrontClient {
|
|
|
252
254
|
readonly debt: DebtResource;
|
|
253
255
|
/** Close a card that still holds money: the rest goes back the way it was paid. */
|
|
254
256
|
readonly closeRequests: CloseRequestsResource;
|
|
257
|
+
/** Dispute a card operation or complain, and follow claims (lost and stolen cards included) by number and status. */
|
|
258
|
+
readonly claims: ClaimsResource;
|
|
255
259
|
/** Promo and referral codes: check what a code would do before using it. */
|
|
256
260
|
readonly codes: CodesResource;
|
|
257
261
|
/** For referrers: the referral code, the link to share, invited friends and rewards. */
|
|
258
262
|
readonly referral: ReferralResource;
|
|
259
|
-
/** The user's own subscription tier or gift,
|
|
263
|
+
/** The user's own subscription tier or gift, a promo code for its monthly fee, and cancelling it. */
|
|
260
264
|
readonly subscription: SubscriptionResource;
|
|
261
265
|
/** The wallet's currency: read it, switch it while the wallet is empty. */
|
|
262
266
|
readonly wallet: WalletResource;
|
package/dist/index.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { T as TokenStore, F as FetchLike } from './http-CL97TjMO.js';
|
|
|
2
2
|
export { d as defaultBrowserStore, i as inMemoryStore } from './http-CL97TjMO.js';
|
|
3
3
|
import { AuthResource } from './resources/auth.js';
|
|
4
4
|
export { ChangePasswordInput, EmailChangeRequested, EmailCodeSent, EmailCodeSession, ExchangeTelegramInput, JwtIssued, LinkTelegramInput, LoginInput, LoginResponse, OtpSentResponse, RegisterInput, RequestEmailCodeInput, Session, TelegramLink, TelegramUnknown, TotpRequired, TotpSetupComplete, TotpSetupRequired, User, VerifyEmailCodeInput } from './resources/auth.js';
|
|
5
|
-
import { b as DepositsResource, F as FundingOptionsResource, c as CardsResource } from './cards-
|
|
6
|
-
export { A as Address, B as BillingAddress, a as Card, d as CardBalance, e as CardDesignRef, f as CardForm, g as CardInTransit, h as CardLoadStatus, i as CardOrder, j as CardOrderError, k as CardOrderInput, C as CardProduct, l as CardProductPrice, m as CardStatus, n as CardStatusSource, o as CardTariff, p as CardTopUp, q as CardTopUpStatus, r as CardTransfer, s as CardType, t as Cardholder, u as CloseBlockedReason, v as CreateCardInput, w as CreateDepositRefundInput, x as CreateQuoteInput, y as CustomerInfo, D as Deposit, z as DepositMethod, E as DepositStatus, G as DepositTarget, H as FeeKind, I as FunderMode, J as FundingOption, K as FundingQuote, L as InitiateDepositInput, M as IssuanceBonus, N as IssueCardInput, O as MethodTerms, R as Refund, P as RevealCardInput, Q as
|
|
5
|
+
import { b as DepositsResource, F as FundingOptionsResource, c as CardsResource } from './cards-CuUdrQ0H.js';
|
|
6
|
+
export { A as Address, B as BillingAddress, a as Card, d as CardBalance, e as CardDesignRef, f as CardForm, g as CardInTransit, h as CardLoadStatus, i as CardOrder, j as CardOrderError, k as CardOrderInput, C as CardProduct, l as CardProductPrice, m as CardStatus, n as CardStatusSource, o as CardTariff, p as CardTopUp, q as CardTopUpStatus, r as CardTransfer, s as CardType, t as Cardholder, u as CloseBlockedReason, v as CreateCardInput, w as CreateDepositRefundInput, x as CreateQuoteInput, y as CustomerInfo, D as Deposit, z as DepositMethod, E as DepositStatus, G as DepositTarget, H as FeeKind, I as FunderMode, J as FundingOption, K as FundingQuote, L as InitiateDepositInput, M as IssuanceBonus, N as IssueCardInput, O as MethodTerms, R as Refund, P as RevealCardInput, Q as RevealState, S as RevealedCard, T as SetPinInput, U as TopUpInput, V as TopUpResult, W as TopUpTerms, X as TransferInput, Y as TransferResult, Z as UpdateCardInput, _ as revealState } from './cards-CuUdrQ0H.js';
|
|
7
7
|
import { BalanceResource } from './resources/balance.js';
|
|
8
8
|
export { Balance } from './resources/balance.js';
|
|
9
9
|
import { BonusResource } from './resources/bonus.js';
|
|
@@ -12,12 +12,14 @@ import { DebtResource } from './resources/debt.js';
|
|
|
12
12
|
export { CardFeeKind, Debt, DebtAmount, DebtLine } from './resources/debt.js';
|
|
13
13
|
import { CloseRequestsResource } from './resources/close-requests.js';
|
|
14
14
|
export { CloseAmount, CloseRefund, CloseRequest, CloseRequestError, CloseRequestStatus, PayoutDetailsInput, PayoutDetailsShown } from './resources/close-requests.js';
|
|
15
|
+
import { ClaimsResource } from './resources/claims.js';
|
|
16
|
+
export { Claim, ClaimError, ClaimKind, ClaimPage, ClaimStatus, ClaimTransaction, CreateClaimInput } from './resources/claims.js';
|
|
15
17
|
import { CodesResource } from './resources/codes.js';
|
|
16
18
|
export { CodeCheck, CodeDiscount, CodeEffect, CodeEffectOutcome, CodeOperation, CodeRejection, CodeResult, ValidateCodeInput } from './resources/codes.js';
|
|
17
19
|
import { ReferralResource } from './resources/referral.js';
|
|
18
20
|
export { InvitedFriend, Referral, ReferralReward } from './resources/referral.js';
|
|
19
21
|
import { SubscriptionResource } from './resources/subscription.js';
|
|
20
|
-
export { UserSubscription } from './resources/subscription.js';
|
|
22
|
+
export { CancelledSubscription, UserSubscription } from './resources/subscription.js';
|
|
21
23
|
import { BrandingResource } from './resources/branding.js';
|
|
22
24
|
export { Branding } from './resources/branding.js';
|
|
23
25
|
import { WalletResource } from './resources/wallet.js';
|
|
@@ -79,7 +81,7 @@ interface BrandConfig {
|
|
|
79
81
|
* Which platform versions this SDK works with, as a semver range:
|
|
80
82
|
* comparators separated by ", ". Keep this the only definition.
|
|
81
83
|
*/
|
|
82
|
-
declare const SUPPORTED_MEISTER = ">=0.6
|
|
84
|
+
declare const SUPPORTED_MEISTER = ">=0.7.6, <1.0.0";
|
|
83
85
|
/** What `client.ready()` returns. */
|
|
84
86
|
interface ReadyInfo {
|
|
85
87
|
/** `true` when the platform reported a version inside `supportedMeister`. */
|
|
@@ -185,7 +187,7 @@ declare function isNetworkError(e: unknown): e is NetworkError;
|
|
|
185
187
|
* `define`. `src/version.test.ts` checks it matches `package.json`, so a
|
|
186
188
|
* release bump that forgets this file fails the test run.
|
|
187
189
|
*/
|
|
188
|
-
declare const SDK_VERSION = "0.6.
|
|
190
|
+
declare const SDK_VERSION = "0.6.11";
|
|
189
191
|
|
|
190
192
|
/**
|
|
191
193
|
* `@takeal/cusfront-sdk` — typed client for the Takeal end-user API.
|
|
@@ -252,11 +254,13 @@ interface CusfrontClient {
|
|
|
252
254
|
readonly debt: DebtResource;
|
|
253
255
|
/** Close a card that still holds money: the rest goes back the way it was paid. */
|
|
254
256
|
readonly closeRequests: CloseRequestsResource;
|
|
257
|
+
/** Dispute a card operation or complain, and follow claims (lost and stolen cards included) by number and status. */
|
|
258
|
+
readonly claims: ClaimsResource;
|
|
255
259
|
/** Promo and referral codes: check what a code would do before using it. */
|
|
256
260
|
readonly codes: CodesResource;
|
|
257
261
|
/** For referrers: the referral code, the link to share, invited friends and rewards. */
|
|
258
262
|
readonly referral: ReferralResource;
|
|
259
|
-
/** The user's own subscription tier or gift,
|
|
263
|
+
/** The user's own subscription tier or gift, a promo code for its monthly fee, and cancelling it. */
|
|
260
264
|
readonly subscription: SubscriptionResource;
|
|
261
265
|
/** The wallet's currency: read it, switch it while the wallet is empty. */
|
|
262
266
|
readonly wallet: WalletResource;
|
package/dist/index.js
CHANGED
|
@@ -185,6 +185,11 @@ function cardOrderBody(input) {
|
|
|
185
185
|
if (input.metadata !== void 0) body["metadata"] = input.metadata;
|
|
186
186
|
return body;
|
|
187
187
|
}
|
|
188
|
+
function revealState(r) {
|
|
189
|
+
if (r.details_pending) return "pending";
|
|
190
|
+
if (r.reveal_url) return "page";
|
|
191
|
+
return "numbers";
|
|
192
|
+
}
|
|
188
193
|
var CardsResource = class {
|
|
189
194
|
constructor(http) {
|
|
190
195
|
this.http = http;
|
|
@@ -340,15 +345,22 @@ var CardsResource = class {
|
|
|
340
345
|
* keep the result in volatile memory only, never write it to
|
|
341
346
|
* localStorage / logs, and clear it within `expires_in_seconds`.
|
|
342
347
|
*
|
|
343
|
-
*
|
|
344
|
-
* when the issuer shows them on a
|
|
345
|
-
* frame right away, it is
|
|
348
|
+
* `state` tells the three answers apart: `numbers`; `page`, with
|
|
349
|
+
* `reveal_url` and empty `pan` and `cvv` when the issuer shows them on a
|
|
350
|
+
* page of its own (open that page in a frame right away, it is
|
|
351
|
+
* short-lived); or `pending` while the card's details are still being
|
|
352
|
+
* prepared, which doesn't count against the limit. A card says the same
|
|
353
|
+
* in {@link Card.details_pending}, so there is no need to call this just
|
|
354
|
+
* to find out.
|
|
346
355
|
*
|
|
347
356
|
* 403 not your card · 409 `card_locked` · 429 rate-limited · 501 connector
|
|
348
357
|
* has no sensitive-data endpoint · 503 `provider_unavailable`.
|
|
349
358
|
*/
|
|
350
359
|
async reveal(id, _input) {
|
|
351
|
-
|
|
360
|
+
const r = await this.http.post(
|
|
361
|
+
`/me/cards/${encodeURIComponent(id)}/reveal`
|
|
362
|
+
);
|
|
363
|
+
return { ...r, state: revealState(r) };
|
|
352
364
|
}
|
|
353
365
|
/**
|
|
354
366
|
* Unfreeze a previously-frozen card. Idempotent on an already-active card.
|
|
@@ -359,6 +371,22 @@ var CardsResource = class {
|
|
|
359
371
|
async unfreeze(id) {
|
|
360
372
|
return this.http.post(`/me/cards/${encodeURIComponent(id)}/unfreeze`, { body: {} });
|
|
361
373
|
}
|
|
374
|
+
/**
|
|
375
|
+
* Report the card lost or stolen. Works at any time, on an active or a
|
|
376
|
+
* frozen card. The report is recorded first with the server's time, which
|
|
377
|
+
* decides who pays for operations someone else made; then the card is
|
|
378
|
+
* frozen at its issuer and only support can unfreeze it. Resolves to the
|
|
379
|
+
* claim (`client.claims`): show its `number` and `reported_at`. When the
|
|
380
|
+
* issuer can't be reached, `card_freeze` is `"pending"`: the report still
|
|
381
|
+
* counts and support freezes the card by hand. Reporting again while the
|
|
382
|
+
* report is open returns the same claim. 404 / 403 not the user's card ·
|
|
383
|
+
* 409 `card_not_open`: the card is closed or was never issued.
|
|
384
|
+
*/
|
|
385
|
+
async reportLost(id, input) {
|
|
386
|
+
return this.http.post(`/me/cards/${encodeURIComponent(id)}/report-lost`, {
|
|
387
|
+
body: { kind: input.kind, details: input.details }
|
|
388
|
+
});
|
|
389
|
+
}
|
|
362
390
|
/**
|
|
363
391
|
* Set the PIN of the caller's own physical card. The session is enough; the
|
|
364
392
|
* call is rate-limited like {@link reveal} and the PIN is kept nowhere.
|
|
@@ -811,6 +839,41 @@ var CloseRequestsResource = class {
|
|
|
811
839
|
}
|
|
812
840
|
};
|
|
813
841
|
|
|
842
|
+
// src/resources/claims.ts
|
|
843
|
+
var ClaimsResource = class {
|
|
844
|
+
constructor(http) {
|
|
845
|
+
this.http = http;
|
|
846
|
+
}
|
|
847
|
+
/**
|
|
848
|
+
* Dispute a card operation, or complain. 400 `validation`: a description
|
|
849
|
+
* that is too short or too long, an operation that isn't on the user's
|
|
850
|
+
* cards, or a lost or stolen card (use `cards.reportLost()`) · 404 no
|
|
851
|
+
* such card · 409 `too_many_claims`: 20 claims are waiting for an answer.
|
|
852
|
+
*/
|
|
853
|
+
async create(input) {
|
|
854
|
+
return this.http.post("/me/claims", {
|
|
855
|
+
body: {
|
|
856
|
+
kind: input.kind,
|
|
857
|
+
description: input.description,
|
|
858
|
+
card_id: input.cardId,
|
|
859
|
+
transaction_id: input.transactionId
|
|
860
|
+
}
|
|
861
|
+
});
|
|
862
|
+
}
|
|
863
|
+
/** The user's claims, lost and stolen cards included, newest first. */
|
|
864
|
+
async list(opts = {}) {
|
|
865
|
+
const qs = new URLSearchParams();
|
|
866
|
+
if (opts.limit != null) qs.set("limit", String(opts.limit));
|
|
867
|
+
if (opts.offset != null) qs.set("offset", String(opts.offset));
|
|
868
|
+
const q = qs.toString();
|
|
869
|
+
return this.http.get(`/me/claims${q ? `?${q}` : ""}`, { signal: opts.signal });
|
|
870
|
+
}
|
|
871
|
+
/** One claim. 404 when it isn't the user's. */
|
|
872
|
+
async get(id, opts = {}) {
|
|
873
|
+
return this.http.get(`/me/claims/${encodeURIComponent(id)}`, { signal: opts.signal });
|
|
874
|
+
}
|
|
875
|
+
};
|
|
876
|
+
|
|
814
877
|
// src/resources/codes.ts
|
|
815
878
|
var CodesResource = class {
|
|
816
879
|
constructor(http) {
|
|
@@ -854,6 +917,15 @@ var SubscriptionResource = class {
|
|
|
854
917
|
async setPromoCode(code) {
|
|
855
918
|
return this.http.put("/me/subscription/promo-code", { body: { code } });
|
|
856
919
|
}
|
|
920
|
+
/**
|
|
921
|
+
* Cancel the subscription now, in one step. What was paid for the current
|
|
922
|
+
* period comes back to the balance for the days not used. No subscription
|
|
923
|
+
* running → 404; 503 `refund_unavailable` when the refund can't be made
|
|
924
|
+
* right now (the subscription keeps running; try again).
|
|
925
|
+
*/
|
|
926
|
+
async cancel() {
|
|
927
|
+
return this.http.post("/me/subscription/cancel", {});
|
|
928
|
+
}
|
|
857
929
|
};
|
|
858
930
|
|
|
859
931
|
// src/resources/branding.ts
|
|
@@ -1513,7 +1585,7 @@ var FundingOptionsResource = class {
|
|
|
1513
1585
|
};
|
|
1514
1586
|
|
|
1515
1587
|
// src/version.ts
|
|
1516
|
-
var SDK_VERSION = "0.6.
|
|
1588
|
+
var SDK_VERSION = "0.6.11";
|
|
1517
1589
|
|
|
1518
1590
|
// src/client-platform.ts
|
|
1519
1591
|
var CLIENT_HEADER = "X-Takeal-Client";
|
|
@@ -1588,7 +1660,7 @@ function isAbsolute(url) {
|
|
|
1588
1660
|
}
|
|
1589
1661
|
|
|
1590
1662
|
// src/compat.ts
|
|
1591
|
-
var SUPPORTED_MEISTER = ">=0.6
|
|
1663
|
+
var SUPPORTED_MEISTER = ">=0.7.6, <1.0.0";
|
|
1592
1664
|
var SEMVER = /^v?(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-([0-9A-Za-z.-]+))?(?:\+[0-9A-Za-z.-]+)?$/;
|
|
1593
1665
|
function parse(v) {
|
|
1594
1666
|
const m = SEMVER.exec(v.trim());
|
|
@@ -2103,6 +2175,7 @@ function createClient(opts) {
|
|
|
2103
2175
|
bonus: new BonusResource(http),
|
|
2104
2176
|
debt: new DebtResource(http),
|
|
2105
2177
|
closeRequests: new CloseRequestsResource(http),
|
|
2178
|
+
claims: new ClaimsResource(http),
|
|
2106
2179
|
codes: new CodesResource(http),
|
|
2107
2180
|
referral: new ReferralResource(http),
|
|
2108
2181
|
subscription: new SubscriptionResource(http),
|
|
@@ -2138,6 +2211,6 @@ function defaultFetch() {
|
|
|
2138
2211
|
);
|
|
2139
2212
|
}
|
|
2140
2213
|
|
|
2141
|
-
export { ANALYTICS_EVENTS, ApiError, CLIENT_HEADER, DISPUTE_DOCUMENTS_CONSENT, HOLDER_DATA_CONSENT, METRIKA_GOALS, NO_CAPTURE_CLASS, NetworkError, SDK_VERSION, SUPPORTED_MEISTER, anonymousKey, createClient, currentTouch, defaultBrowserStore, detectClientPlatform, identify, inMemoryStore, initAnalytics, isApiError, isCardOtp, isNetworkError, page, posthogDistinctId, resetAnalytics, resolveAssetUrl, sanitizeProperties, sanitizeUrl, satisfies, setAnalyticsZone, track };
|
|
2214
|
+
export { ANALYTICS_EVENTS, ApiError, CLIENT_HEADER, DISPUTE_DOCUMENTS_CONSENT, HOLDER_DATA_CONSENT, METRIKA_GOALS, NO_CAPTURE_CLASS, NetworkError, SDK_VERSION, SUPPORTED_MEISTER, anonymousKey, createClient, currentTouch, defaultBrowserStore, detectClientPlatform, identify, inMemoryStore, initAnalytics, isApiError, isCardOtp, isNetworkError, page, posthogDistinctId, resetAnalytics, resolveAssetUrl, revealState, sanitizeProperties, sanitizeUrl, satisfies, setAnalyticsZone, track };
|
|
2142
2215
|
//# sourceMappingURL=index.js.map
|
|
2143
2216
|
//# sourceMappingURL=index.js.map
|