@getivy/node-sdk 0.1.0-alpha.2 → 0.1.0-alpha.4
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 +16 -0
- package/LICENSE +1 -1
- package/README.md +17 -17
- package/core.js +9 -9
- package/core.js.map +1 -1
- package/core.mjs +10 -10
- package/core.mjs.map +1 -1
- package/error.d.ts +2 -2
- package/error.d.ts.map +1 -1
- package/error.js +4 -4
- package/error.js.map +1 -1
- package/error.mjs +2 -2
- package/error.mjs.map +1 -1
- package/index.d.mts +13 -10
- package/index.d.ts +13 -10
- package/index.d.ts.map +1 -1
- package/index.js +45 -42
- package/index.js.map +1 -1
- package/index.mjs +42 -39
- package/index.mjs.map +1 -1
- package/package.json +3 -3
- package/resource.d.ts +3 -3
- package/resource.d.ts.map +1 -1
- package/resource.js.map +1 -1
- package/resource.mjs.map +1 -1
- package/resources/index.d.ts +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/webhooksubscription.d.ts +155 -0
- package/resources/webhooksubscription.d.ts.map +1 -0
- package/resources/webhooksubscription.js +42 -0
- package/resources/webhooksubscription.js.map +1 -0
- package/resources/webhooksubscription.mjs +38 -0
- package/resources/webhooksubscription.mjs.map +1 -0
- package/src/core.ts +10 -10
- package/src/error.ts +2 -2
- package/src/index.ts +56 -27
- package/src/resource.ts +3 -3
- package/src/resources/index.ts +13 -0
- package/src/resources/webhooksubscription.ts +353 -0
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/error.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { castToError } from "./core.mjs";
|
|
3
|
-
export class
|
|
3
|
+
export class IvyError extends Error {
|
|
4
4
|
}
|
|
5
|
-
export class APIError extends
|
|
5
|
+
export class APIError extends IvyError {
|
|
6
6
|
constructor(status, error, message, headers) {
|
|
7
7
|
super(`${APIError.makeMessage(status, error, message)}`);
|
|
8
8
|
this.status = status;
|
package/error.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.mjs","sourceRoot":"","sources":["src/error.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAW;AAE/B,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"error.mjs","sourceRoot":"","sources":["src/error.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAW;AAE/B,MAAM,OAAO,QAAS,SAAQ,KAAK;CAAG;AAEtC,MAAM,OAAO,QAIX,SAAQ,QAAQ;IAQhB,YAAY,MAAe,EAAE,KAAa,EAAE,OAA2B,EAAE,OAAiB;QACxF,KAAK,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,EAAE,CAAC,CAAC;QACzD,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;IAEO,MAAM,CAAC,WAAW,CAAC,MAA0B,EAAE,KAAU,EAAE,OAA2B;QAC5F,MAAM,GAAG,GACP,KAAK,EAAE,OAAO,CAAC,CAAC;YACd,OAAO,KAAK,CAAC,OAAO,KAAK,QAAQ,CAAC,CAAC;gBACjC,KAAK,CAAC,OAAO;gBACf,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,OAAO,CAAC;YACjC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC;gBAC/B,CAAC,CAAC,OAAO,CAAC;QAEZ,IAAI,MAAM,IAAI,GAAG,EAAE;YACj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5D,MAAM,OAAO,wBAAyB,SAAQ,QAAsB;CAAG;AAEvE,MAAM,OAAO,cAAe,SAAQ,QAAsB;CAAG;AAE7D,MAAM,OAAO,mBAAoB,SAAQ,QAAyB;CAAG"}
|
package/index.d.mts
CHANGED
|
@@ -15,6 +15,7 @@ import { PayoutCreateParams, PayoutListParams, PayoutListResponse, PayoutRetriev
|
|
|
15
15
|
import { RefundBatchParams, RefundBatchResponse, RefundCreateParams, RefundResponse, Refunds } from "./resources/refunds.js";
|
|
16
16
|
import { PayoutReport, ReportCreateParams, ReportCreateResponse, ReportDownloadParams, ReportRetrieveParams, ReportRetrieveResponse, Reports } from "./resources/reports.js";
|
|
17
17
|
import { Subaccount, SubaccountCreateParams, SubaccountRetrieveParams, Subaccounts } from "./resources/subaccounts.js";
|
|
18
|
+
import { Webhooksubscription, WebhooksubscriptionCreateParams, WebhooksubscriptionCreateResponse, WebhooksubscriptionDeleteParams, WebhooksubscriptionDeleteResponse, WebhooksubscriptionListParams, WebhooksubscriptionListResponse, WebhooksubscriptionPingParams, WebhooksubscriptionPingResponse, WebhooksubscriptionUpdateParams, WebhooksubscriptionUpdateResponse } from "./resources/webhooksubscription.js";
|
|
18
19
|
declare const environments: {
|
|
19
20
|
production: string;
|
|
20
21
|
sandbox: string;
|
|
@@ -36,7 +37,7 @@ export interface ClientOptions {
|
|
|
36
37
|
/**
|
|
37
38
|
* Override the default base URL for the API, e.g., "https://api.example.com/v2/"
|
|
38
39
|
*
|
|
39
|
-
* Defaults to process.env['
|
|
40
|
+
* Defaults to process.env['IVY_BASE_URL'].
|
|
40
41
|
*/
|
|
41
42
|
baseURL?: string | null | undefined;
|
|
42
43
|
/**
|
|
@@ -84,17 +85,17 @@ export interface ClientOptions {
|
|
|
84
85
|
defaultQuery?: Core.DefaultQuery | undefined;
|
|
85
86
|
}
|
|
86
87
|
/**
|
|
87
|
-
* API Client for interfacing with the
|
|
88
|
+
* API Client for interfacing with the Ivy API.
|
|
88
89
|
*/
|
|
89
|
-
export declare class
|
|
90
|
+
export declare class Ivy extends Core.APIClient {
|
|
90
91
|
apiKey: string;
|
|
91
92
|
private _options;
|
|
92
93
|
/**
|
|
93
|
-
* API Client for interfacing with the
|
|
94
|
+
* API Client for interfacing with the Ivy API.
|
|
94
95
|
*
|
|
95
96
|
* @param {string | undefined} [opts.apiKey=process.env['IVY_API_KEY'] ?? undefined]
|
|
96
97
|
* @param {Environment} [opts.environment=production] - Specifies the environment URL to use for the API.
|
|
97
|
-
* @param {string} [opts.baseURL=process.env['
|
|
98
|
+
* @param {string} [opts.baseURL=process.env['IVY_BASE_URL'] ?? https://api.getivy.de] - Override the default base URL for the API.
|
|
98
99
|
* @param {number} [opts.timeout=1 minute] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
|
|
99
100
|
* @param {number} [opts.httpAgent] - An HTTP agent used to manage HTTP(s) connections.
|
|
100
101
|
* @param {Core.Fetch} [opts.fetch] - Specify a custom `fetch` function implementation.
|
|
@@ -115,12 +116,13 @@ export declare class Getivy extends Core.APIClient {
|
|
|
115
116
|
reports: API.Reports;
|
|
116
117
|
subaccounts: API.Subaccounts;
|
|
117
118
|
balance: API.Balance;
|
|
119
|
+
webhooksubscription: API.Webhooksubscription;
|
|
118
120
|
protected defaultQuery(): Core.DefaultQuery | undefined;
|
|
119
121
|
protected defaultHeaders(opts: Core.FinalRequestOptions): Core.Headers;
|
|
120
122
|
protected authHeaders(opts: Core.FinalRequestOptions): Core.Headers;
|
|
121
|
-
static
|
|
123
|
+
static Ivy: typeof Ivy;
|
|
122
124
|
static DEFAULT_TIMEOUT: number;
|
|
123
|
-
static
|
|
125
|
+
static IvyError: typeof Errors.IvyError;
|
|
124
126
|
static APIError: typeof Errors.APIError;
|
|
125
127
|
static APIConnectionError: typeof Errors.APIConnectionError;
|
|
126
128
|
static APIConnectionTimeoutError: typeof Errors.APIConnectionTimeoutError;
|
|
@@ -136,7 +138,7 @@ export declare class Getivy extends Core.APIClient {
|
|
|
136
138
|
static toFile: typeof Uploads.toFile;
|
|
137
139
|
static fileFromPath: typeof Uploads.fileFromPath;
|
|
138
140
|
}
|
|
139
|
-
export declare namespace
|
|
141
|
+
export declare namespace Ivy {
|
|
140
142
|
export type RequestOptions = Core.RequestOptions;
|
|
141
143
|
export { Banks as Banks, type BankRetrieveResponse as BankRetrieveResponse, type BankListResponse as BankListResponse, type BankSearchResponse as BankSearchResponse, type BankRetrieveParams as BankRetrieveParams, type BankListParams as BankListParams, type BankSearchParams as BankSearchParams, };
|
|
142
144
|
export { Checkoutsession as Checkoutsession, type CheckoutsessionCreateResponse as CheckoutsessionCreateResponse, type CheckoutsessionRetrieveResponse as CheckoutsessionRetrieveResponse, type CheckoutsessionExpireResponse as CheckoutsessionExpireResponse, type CheckoutsessionCreateParams as CheckoutsessionCreateParams, type CheckoutsessionRetrieveParams as CheckoutsessionRetrieveParams, type CheckoutsessionExpireParams as CheckoutsessionExpireParams, };
|
|
@@ -150,8 +152,9 @@ export declare namespace Getivy {
|
|
|
150
152
|
export { Reports as Reports, type PayoutReport as PayoutReport, type ReportCreateResponse as ReportCreateResponse, type ReportRetrieveResponse as ReportRetrieveResponse, type ReportCreateParams as ReportCreateParams, type ReportRetrieveParams as ReportRetrieveParams, type ReportDownloadParams as ReportDownloadParams, };
|
|
151
153
|
export { Subaccounts as Subaccounts, type Subaccount as Subaccount, type SubaccountCreateParams as SubaccountCreateParams, type SubaccountRetrieveParams as SubaccountRetrieveParams, };
|
|
152
154
|
export { Balance as Balance, type BalanceRetrieveResponse as BalanceRetrieveResponse, type BalanceRetrieveParams as BalanceRetrieveParams, };
|
|
155
|
+
export { Webhooksubscription as Webhooksubscription, type WebhooksubscriptionCreateResponse as WebhooksubscriptionCreateResponse, type WebhooksubscriptionUpdateResponse as WebhooksubscriptionUpdateResponse, type WebhooksubscriptionListResponse as WebhooksubscriptionListResponse, type WebhooksubscriptionDeleteResponse as WebhooksubscriptionDeleteResponse, type WebhooksubscriptionPingResponse as WebhooksubscriptionPingResponse, type WebhooksubscriptionCreateParams as WebhooksubscriptionCreateParams, type WebhooksubscriptionUpdateParams as WebhooksubscriptionUpdateParams, type WebhooksubscriptionListParams as WebhooksubscriptionListParams, type WebhooksubscriptionDeleteParams as WebhooksubscriptionDeleteParams, type WebhooksubscriptionPingParams as WebhooksubscriptionPingParams, };
|
|
153
156
|
}
|
|
154
157
|
export { toFile, fileFromPath } from "./uploads.js";
|
|
155
|
-
export {
|
|
156
|
-
export default
|
|
158
|
+
export { IvyError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./error.js";
|
|
159
|
+
export default Ivy;
|
|
157
160
|
//# sourceMappingURL=index.d.ts.map
|
package/index.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ import { PayoutCreateParams, PayoutListParams, PayoutListResponse, PayoutRetriev
|
|
|
15
15
|
import { RefundBatchParams, RefundBatchResponse, RefundCreateParams, RefundResponse, Refunds } from "./resources/refunds.js";
|
|
16
16
|
import { PayoutReport, ReportCreateParams, ReportCreateResponse, ReportDownloadParams, ReportRetrieveParams, ReportRetrieveResponse, Reports } from "./resources/reports.js";
|
|
17
17
|
import { Subaccount, SubaccountCreateParams, SubaccountRetrieveParams, Subaccounts } from "./resources/subaccounts.js";
|
|
18
|
+
import { Webhooksubscription, WebhooksubscriptionCreateParams, WebhooksubscriptionCreateResponse, WebhooksubscriptionDeleteParams, WebhooksubscriptionDeleteResponse, WebhooksubscriptionListParams, WebhooksubscriptionListResponse, WebhooksubscriptionPingParams, WebhooksubscriptionPingResponse, WebhooksubscriptionUpdateParams, WebhooksubscriptionUpdateResponse } from "./resources/webhooksubscription.js";
|
|
18
19
|
declare const environments: {
|
|
19
20
|
production: string;
|
|
20
21
|
sandbox: string;
|
|
@@ -36,7 +37,7 @@ export interface ClientOptions {
|
|
|
36
37
|
/**
|
|
37
38
|
* Override the default base URL for the API, e.g., "https://api.example.com/v2/"
|
|
38
39
|
*
|
|
39
|
-
* Defaults to process.env['
|
|
40
|
+
* Defaults to process.env['IVY_BASE_URL'].
|
|
40
41
|
*/
|
|
41
42
|
baseURL?: string | null | undefined;
|
|
42
43
|
/**
|
|
@@ -84,17 +85,17 @@ export interface ClientOptions {
|
|
|
84
85
|
defaultQuery?: Core.DefaultQuery | undefined;
|
|
85
86
|
}
|
|
86
87
|
/**
|
|
87
|
-
* API Client for interfacing with the
|
|
88
|
+
* API Client for interfacing with the Ivy API.
|
|
88
89
|
*/
|
|
89
|
-
export declare class
|
|
90
|
+
export declare class Ivy extends Core.APIClient {
|
|
90
91
|
apiKey: string;
|
|
91
92
|
private _options;
|
|
92
93
|
/**
|
|
93
|
-
* API Client for interfacing with the
|
|
94
|
+
* API Client for interfacing with the Ivy API.
|
|
94
95
|
*
|
|
95
96
|
* @param {string | undefined} [opts.apiKey=process.env['IVY_API_KEY'] ?? undefined]
|
|
96
97
|
* @param {Environment} [opts.environment=production] - Specifies the environment URL to use for the API.
|
|
97
|
-
* @param {string} [opts.baseURL=process.env['
|
|
98
|
+
* @param {string} [opts.baseURL=process.env['IVY_BASE_URL'] ?? https://api.getivy.de] - Override the default base URL for the API.
|
|
98
99
|
* @param {number} [opts.timeout=1 minute] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
|
|
99
100
|
* @param {number} [opts.httpAgent] - An HTTP agent used to manage HTTP(s) connections.
|
|
100
101
|
* @param {Core.Fetch} [opts.fetch] - Specify a custom `fetch` function implementation.
|
|
@@ -115,12 +116,13 @@ export declare class Getivy extends Core.APIClient {
|
|
|
115
116
|
reports: API.Reports;
|
|
116
117
|
subaccounts: API.Subaccounts;
|
|
117
118
|
balance: API.Balance;
|
|
119
|
+
webhooksubscription: API.Webhooksubscription;
|
|
118
120
|
protected defaultQuery(): Core.DefaultQuery | undefined;
|
|
119
121
|
protected defaultHeaders(opts: Core.FinalRequestOptions): Core.Headers;
|
|
120
122
|
protected authHeaders(opts: Core.FinalRequestOptions): Core.Headers;
|
|
121
|
-
static
|
|
123
|
+
static Ivy: typeof Ivy;
|
|
122
124
|
static DEFAULT_TIMEOUT: number;
|
|
123
|
-
static
|
|
125
|
+
static IvyError: typeof Errors.IvyError;
|
|
124
126
|
static APIError: typeof Errors.APIError;
|
|
125
127
|
static APIConnectionError: typeof Errors.APIConnectionError;
|
|
126
128
|
static APIConnectionTimeoutError: typeof Errors.APIConnectionTimeoutError;
|
|
@@ -136,7 +138,7 @@ export declare class Getivy extends Core.APIClient {
|
|
|
136
138
|
static toFile: typeof Uploads.toFile;
|
|
137
139
|
static fileFromPath: typeof Uploads.fileFromPath;
|
|
138
140
|
}
|
|
139
|
-
export declare namespace
|
|
141
|
+
export declare namespace Ivy {
|
|
140
142
|
export type RequestOptions = Core.RequestOptions;
|
|
141
143
|
export { Banks as Banks, type BankRetrieveResponse as BankRetrieveResponse, type BankListResponse as BankListResponse, type BankSearchResponse as BankSearchResponse, type BankRetrieveParams as BankRetrieveParams, type BankListParams as BankListParams, type BankSearchParams as BankSearchParams, };
|
|
142
144
|
export { Checkoutsession as Checkoutsession, type CheckoutsessionCreateResponse as CheckoutsessionCreateResponse, type CheckoutsessionRetrieveResponse as CheckoutsessionRetrieveResponse, type CheckoutsessionExpireResponse as CheckoutsessionExpireResponse, type CheckoutsessionCreateParams as CheckoutsessionCreateParams, type CheckoutsessionRetrieveParams as CheckoutsessionRetrieveParams, type CheckoutsessionExpireParams as CheckoutsessionExpireParams, };
|
|
@@ -150,8 +152,9 @@ export declare namespace Getivy {
|
|
|
150
152
|
export { Reports as Reports, type PayoutReport as PayoutReport, type ReportCreateResponse as ReportCreateResponse, type ReportRetrieveResponse as ReportRetrieveResponse, type ReportCreateParams as ReportCreateParams, type ReportRetrieveParams as ReportRetrieveParams, type ReportDownloadParams as ReportDownloadParams, };
|
|
151
153
|
export { Subaccounts as Subaccounts, type Subaccount as Subaccount, type SubaccountCreateParams as SubaccountCreateParams, type SubaccountRetrieveParams as SubaccountRetrieveParams, };
|
|
152
154
|
export { Balance as Balance, type BalanceRetrieveResponse as BalanceRetrieveResponse, type BalanceRetrieveParams as BalanceRetrieveParams, };
|
|
155
|
+
export { Webhooksubscription as Webhooksubscription, type WebhooksubscriptionCreateResponse as WebhooksubscriptionCreateResponse, type WebhooksubscriptionUpdateResponse as WebhooksubscriptionUpdateResponse, type WebhooksubscriptionListResponse as WebhooksubscriptionListResponse, type WebhooksubscriptionDeleteResponse as WebhooksubscriptionDeleteResponse, type WebhooksubscriptionPingResponse as WebhooksubscriptionPingResponse, type WebhooksubscriptionCreateParams as WebhooksubscriptionCreateParams, type WebhooksubscriptionUpdateParams as WebhooksubscriptionUpdateParams, type WebhooksubscriptionListParams as WebhooksubscriptionListParams, type WebhooksubscriptionDeleteParams as WebhooksubscriptionDeleteParams, type WebhooksubscriptionPingParams as WebhooksubscriptionPingParams, };
|
|
153
156
|
}
|
|
154
157
|
export { toFile, fileFromPath } from "./uploads.js";
|
|
155
|
-
export {
|
|
156
|
-
export default
|
|
158
|
+
export { IvyError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./error.js";
|
|
159
|
+
export default Ivy;
|
|
157
160
|
//# sourceMappingURL=index.d.ts.map
|
package/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAC5C,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,MAAM,MAAM,SAAS,CAAC;AAClC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,GAAG,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,qBAAqB,EAAE,uB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AkB,EAC7C,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;IAEF,OAAO,EACL,WAAW,IAAI,WAAW,EAC1B,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;IAEF,OAAO,EACL,OAAO,IAAI,OAAO,EAClB,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;IAEF,OAAO,EACL,mBAAmB,IAAI,mBAAmB,EAC1C,KAAK,iCAAiC,IAAI,iCAAiC,EAC3E,KAAK,iCAAiC,IAAI,iCAAiC,EAC3E,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,iCAAiC,IAAI,iCAAiC,EAC3E,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,6BAA6B,IAAI,6BAA6B,GACpE,CAAC;CACH;AAED,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,EACL,QAAQ,EACR,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB,MAAM,SAAS,CAAC;AAEjB,eAAe,GAAG,CAAC"}
|
package/index.js
CHANGED
|
@@ -25,7 +25,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
25
25
|
};
|
|
26
26
|
var _a;
|
|
27
27
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
|
-
exports.UnprocessableEntityError = exports.PermissionDeniedError = exports.InternalServerError = exports.AuthenticationError = exports.BadRequestError = exports.RateLimitError = exports.ConflictError = exports.NotFoundError = exports.APIUserAbortError = exports.APIConnectionTimeoutError = exports.APIConnectionError = exports.APIError = exports.
|
|
28
|
+
exports.UnprocessableEntityError = exports.PermissionDeniedError = exports.InternalServerError = exports.AuthenticationError = exports.BadRequestError = exports.RateLimitError = exports.ConflictError = exports.NotFoundError = exports.APIUserAbortError = exports.APIConnectionTimeoutError = exports.APIConnectionError = exports.APIError = exports.IvyError = exports.fileFromPath = exports.toFile = exports.Ivy = void 0;
|
|
29
29
|
const Core = __importStar(require("./core.js"));
|
|
30
30
|
const Errors = __importStar(require("./error.js"));
|
|
31
31
|
const Uploads = __importStar(require("./uploads.js"));
|
|
@@ -42,20 +42,21 @@ const payouts_1 = require("./resources/payouts.js");
|
|
|
42
42
|
const refunds_1 = require("./resources/refunds.js");
|
|
43
43
|
const reports_1 = require("./resources/reports.js");
|
|
44
44
|
const subaccounts_1 = require("./resources/subaccounts.js");
|
|
45
|
+
const webhooksubscription_1 = require("./resources/webhooksubscription.js");
|
|
45
46
|
const environments = {
|
|
46
47
|
production: 'https://api.getivy.de',
|
|
47
48
|
sandbox: 'https://api.sand.getivy.de',
|
|
48
49
|
};
|
|
49
50
|
/**
|
|
50
|
-
* API Client for interfacing with the
|
|
51
|
+
* API Client for interfacing with the Ivy API.
|
|
51
52
|
*/
|
|
52
|
-
class
|
|
53
|
+
class Ivy extends Core.APIClient {
|
|
53
54
|
/**
|
|
54
|
-
* API Client for interfacing with the
|
|
55
|
+
* API Client for interfacing with the Ivy API.
|
|
55
56
|
*
|
|
56
57
|
* @param {string | undefined} [opts.apiKey=process.env['IVY_API_KEY'] ?? undefined]
|
|
57
58
|
* @param {Environment} [opts.environment=production] - Specifies the environment URL to use for the API.
|
|
58
|
-
* @param {string} [opts.baseURL=process.env['
|
|
59
|
+
* @param {string} [opts.baseURL=process.env['IVY_BASE_URL'] ?? https://api.getivy.de] - Override the default base URL for the API.
|
|
59
60
|
* @param {number} [opts.timeout=1 minute] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
|
|
60
61
|
* @param {number} [opts.httpAgent] - An HTTP agent used to manage HTTP(s) connections.
|
|
61
62
|
* @param {Core.Fetch} [opts.fetch] - Specify a custom `fetch` function implementation.
|
|
@@ -63,9 +64,9 @@ class Getivy extends Core.APIClient {
|
|
|
63
64
|
* @param {Core.Headers} opts.defaultHeaders - Default headers to include with every request to the API.
|
|
64
65
|
* @param {Core.DefaultQuery} opts.defaultQuery - Default query parameters to include with every request to the API.
|
|
65
66
|
*/
|
|
66
|
-
constructor({ baseURL = Core.readEnv('
|
|
67
|
+
constructor({ baseURL = Core.readEnv('IVY_BASE_URL'), apiKey = Core.readEnv('IVY_API_KEY'), ...opts } = {}) {
|
|
67
68
|
if (apiKey === undefined) {
|
|
68
|
-
throw new Errors.
|
|
69
|
+
throw new Errors.IvyError("The IVY_API_KEY environment variable is missing or empty; either provide it, or instantiate the Ivy client with an apiKey option, like new Ivy({ apiKey: 'My API Key' }).");
|
|
69
70
|
}
|
|
70
71
|
const options = {
|
|
71
72
|
apiKey,
|
|
@@ -74,7 +75,7 @@ class Getivy extends Core.APIClient {
|
|
|
74
75
|
environment: opts.environment ?? 'production',
|
|
75
76
|
};
|
|
76
77
|
if (baseURL && opts.environment) {
|
|
77
|
-
throw new Errors.
|
|
78
|
+
throw new Errors.IvyError('Ambiguous URL; The `baseURL` option (or IVY_BASE_URL env var) and the `environment` option are given. If you want to use the environment you must pass baseURL: null');
|
|
78
79
|
}
|
|
79
80
|
super({
|
|
80
81
|
baseURL: options.baseURL || environments[options.environment || 'production'],
|
|
@@ -95,6 +96,7 @@ class Getivy extends Core.APIClient {
|
|
|
95
96
|
this.reports = new API.Reports(this);
|
|
96
97
|
this.subaccounts = new API.Subaccounts(this);
|
|
97
98
|
this.balance = new API.Balance(this);
|
|
99
|
+
this.webhooksubscription = new API.Webhooksubscription(this);
|
|
98
100
|
this._options = options;
|
|
99
101
|
this.apiKey = apiKey;
|
|
100
102
|
}
|
|
@@ -111,42 +113,43 @@ class Getivy extends Core.APIClient {
|
|
|
111
113
|
return { 'X-Ivy-Api-Key': this.apiKey };
|
|
112
114
|
}
|
|
113
115
|
}
|
|
114
|
-
exports.
|
|
115
|
-
_a =
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
116
|
+
exports.Ivy = Ivy;
|
|
117
|
+
_a = Ivy;
|
|
118
|
+
Ivy.Ivy = _a;
|
|
119
|
+
Ivy.DEFAULT_TIMEOUT = 60000; // 1 minute
|
|
120
|
+
Ivy.IvyError = Errors.IvyError;
|
|
121
|
+
Ivy.APIError = Errors.APIError;
|
|
122
|
+
Ivy.APIConnectionError = Errors.APIConnectionError;
|
|
123
|
+
Ivy.APIConnectionTimeoutError = Errors.APIConnectionTimeoutError;
|
|
124
|
+
Ivy.APIUserAbortError = Errors.APIUserAbortError;
|
|
125
|
+
Ivy.NotFoundError = Errors.NotFoundError;
|
|
126
|
+
Ivy.ConflictError = Errors.ConflictError;
|
|
127
|
+
Ivy.RateLimitError = Errors.RateLimitError;
|
|
128
|
+
Ivy.BadRequestError = Errors.BadRequestError;
|
|
129
|
+
Ivy.AuthenticationError = Errors.AuthenticationError;
|
|
130
|
+
Ivy.InternalServerError = Errors.InternalServerError;
|
|
131
|
+
Ivy.PermissionDeniedError = Errors.PermissionDeniedError;
|
|
132
|
+
Ivy.UnprocessableEntityError = Errors.UnprocessableEntityError;
|
|
133
|
+
Ivy.toFile = Uploads.toFile;
|
|
134
|
+
Ivy.fileFromPath = Uploads.fileFromPath;
|
|
135
|
+
Ivy.Banks = banks_1.Banks;
|
|
136
|
+
Ivy.Checkoutsession = checkoutsession_1.Checkoutsession;
|
|
137
|
+
Ivy.Customers = customers_1.Customers;
|
|
138
|
+
Ivy.Orders = orders_1.Orders;
|
|
139
|
+
Ivy.Charges = charges_1.Charges;
|
|
140
|
+
Ivy.Mandates = mandates_1.Mandates;
|
|
141
|
+
Ivy.Capabilities = capabilities_1.Capabilities;
|
|
142
|
+
Ivy.Refunds = refunds_1.Refunds;
|
|
143
|
+
Ivy.Payouts = payouts_1.Payouts;
|
|
144
|
+
Ivy.Reports = reports_1.Reports;
|
|
145
|
+
Ivy.Subaccounts = subaccounts_1.Subaccounts;
|
|
146
|
+
Ivy.Balance = balance_1.Balance;
|
|
147
|
+
Ivy.Webhooksubscription = webhooksubscription_1.Webhooksubscription;
|
|
145
148
|
var uploads_1 = require("./uploads.js");
|
|
146
149
|
Object.defineProperty(exports, "toFile", { enumerable: true, get: function () { return uploads_1.toFile; } });
|
|
147
150
|
Object.defineProperty(exports, "fileFromPath", { enumerable: true, get: function () { return uploads_1.fileFromPath; } });
|
|
148
151
|
var error_1 = require("./error.js");
|
|
149
|
-
Object.defineProperty(exports, "
|
|
152
|
+
Object.defineProperty(exports, "IvyError", { enumerable: true, get: function () { return error_1.IvyError; } });
|
|
150
153
|
Object.defineProperty(exports, "APIError", { enumerable: true, get: function () { return error_1.APIError; } });
|
|
151
154
|
Object.defineProperty(exports, "APIConnectionError", { enumerable: true, get: function () { return error_1.APIConnectionError; } });
|
|
152
155
|
Object.defineProperty(exports, "APIConnectionTimeoutError", { enumerable: true, get: function () { return error_1.APIConnectionTimeoutError; } });
|
|
@@ -159,6 +162,6 @@ Object.defineProperty(exports, "AuthenticationError", { enumerable: true, get: f
|
|
|
159
162
|
Object.defineProperty(exports, "InternalServerError", { enumerable: true, get: function () { return error_1.InternalServerError; } });
|
|
160
163
|
Object.defineProperty(exports, "PermissionDeniedError", { enumerable: true, get: function () { return error_1.PermissionDeniedError; } });
|
|
161
164
|
Object.defineProperty(exports, "UnprocessableEntityError", { enumerable: true, get: function () { return error_1.UnprocessableEntityError; } });
|
|
162
|
-
exports = module.exports =
|
|
163
|
-
exports.default =
|
|
165
|
+
exports = module.exports = Ivy;
|
|
166
|
+
exports.default = Ivy;
|
|
164
167
|
//# sourceMappingURL=index.js.map
|
package/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGtF,gDAA+B;AAC/B,mDAAkC;AAClC,sDAAqC;AACrC,0DAAyC;AACzC,oDAA8F;AAC9F,gDAQ2B;AAC3B,8DAA8G;AAC9G,oDAA0E;AAC1E,oEAQqC;AACrC,wDAM+B;AAC/B,sDAO8B;AAC9B,kDAM4B;AAC5B,oDAO6B;AAC7B,oDAM6B;AAC7B,oDAQ6B;AAC7B,4DAKiC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGtF,gDAA+B;AAC/B,mDAAkC;AAClC,sDAAqC;AACrC,0DAAyC;AACzC,oDAA8F;AAC9F,gDAQ2B;AAC3B,8DAA8G;AAC9G,oDAA0E;AAC1E,oEAQqC;AACrC,wDAM+B;AAC/B,sDAO8B;AAC9B,kDAM4B;AAC5B,oDAO6B;AAC7B,oDAM6B;AAC7B,oDAQ6B;AAC7B,4DAKiC;AACjC,4EAYyC;AAEzC,MAAM,YAAY,GAAG;IACnB,UAAU,EAAE,uBAAuB;IACnC,OAAO,EAAE,4BAA4B;CACtC,CAAC;AA2EF;;GAEG;AACH,MAAa,GAAI,SAAQ,IAAI,CAAC,SAAS;IAKrC;;;;;;;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ACjB,sGAAA,aAAa,OAAA;AACb,sGAAA,aAAa,OAAA;AACb,uGAAA,cAAc,OAAA;AACd,wGAAA,eAAe,OAAA;AACf,4GAAA,mBAAmB,OAAA;AACnB,4GAAA,mBAAmB,OAAA;AACnB,8GAAA,qBAAqB,OAAA;AACrB,iHAAA,wBAAwB,OAAA;AAG1B,kBAAe,GAAG,CAAC"}
|
package/index.mjs
CHANGED
|
@@ -16,20 +16,21 @@ import { Payouts, } from "./resources/payouts.mjs";
|
|
|
16
16
|
import { Refunds, } from "./resources/refunds.mjs";
|
|
17
17
|
import { Reports, } from "./resources/reports.mjs";
|
|
18
18
|
import { Subaccounts, } from "./resources/subaccounts.mjs";
|
|
19
|
+
import { Webhooksubscription, } from "./resources/webhooksubscription.mjs";
|
|
19
20
|
const environments = {
|
|
20
21
|
production: 'https://api.getivy.de',
|
|
21
22
|
sandbox: 'https://api.sand.getivy.de',
|
|
22
23
|
};
|
|
23
24
|
/**
|
|
24
|
-
* API Client for interfacing with the
|
|
25
|
+
* API Client for interfacing with the Ivy API.
|
|
25
26
|
*/
|
|
26
|
-
export class
|
|
27
|
+
export class Ivy extends Core.APIClient {
|
|
27
28
|
/**
|
|
28
|
-
* API Client for interfacing with the
|
|
29
|
+
* API Client for interfacing with the Ivy API.
|
|
29
30
|
*
|
|
30
31
|
* @param {string | undefined} [opts.apiKey=process.env['IVY_API_KEY'] ?? undefined]
|
|
31
32
|
* @param {Environment} [opts.environment=production] - Specifies the environment URL to use for the API.
|
|
32
|
-
* @param {string} [opts.baseURL=process.env['
|
|
33
|
+
* @param {string} [opts.baseURL=process.env['IVY_BASE_URL'] ?? https://api.getivy.de] - Override the default base URL for the API.
|
|
33
34
|
* @param {number} [opts.timeout=1 minute] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
|
|
34
35
|
* @param {number} [opts.httpAgent] - An HTTP agent used to manage HTTP(s) connections.
|
|
35
36
|
* @param {Core.Fetch} [opts.fetch] - Specify a custom `fetch` function implementation.
|
|
@@ -37,9 +38,9 @@ export class Getivy extends Core.APIClient {
|
|
|
37
38
|
* @param {Core.Headers} opts.defaultHeaders - Default headers to include with every request to the API.
|
|
38
39
|
* @param {Core.DefaultQuery} opts.defaultQuery - Default query parameters to include with every request to the API.
|
|
39
40
|
*/
|
|
40
|
-
constructor({ baseURL = Core.readEnv('
|
|
41
|
+
constructor({ baseURL = Core.readEnv('IVY_BASE_URL'), apiKey = Core.readEnv('IVY_API_KEY'), ...opts } = {}) {
|
|
41
42
|
if (apiKey === undefined) {
|
|
42
|
-
throw new Errors.
|
|
43
|
+
throw new Errors.IvyError("The IVY_API_KEY environment variable is missing or empty; either provide it, or instantiate the Ivy client with an apiKey option, like new Ivy({ apiKey: 'My API Key' }).");
|
|
43
44
|
}
|
|
44
45
|
const options = {
|
|
45
46
|
apiKey,
|
|
@@ -48,7 +49,7 @@ export class Getivy extends Core.APIClient {
|
|
|
48
49
|
environment: opts.environment ?? 'production',
|
|
49
50
|
};
|
|
50
51
|
if (baseURL && opts.environment) {
|
|
51
|
-
throw new Errors.
|
|
52
|
+
throw new Errors.IvyError('Ambiguous URL; The `baseURL` option (or IVY_BASE_URL env var) and the `environment` option are given. If you want to use the environment you must pass baseURL: null');
|
|
52
53
|
}
|
|
53
54
|
super({
|
|
54
55
|
baseURL: options.baseURL || environments[options.environment || 'production'],
|
|
@@ -69,6 +70,7 @@ export class Getivy extends Core.APIClient {
|
|
|
69
70
|
this.reports = new API.Reports(this);
|
|
70
71
|
this.subaccounts = new API.Subaccounts(this);
|
|
71
72
|
this.balance = new API.Balance(this);
|
|
73
|
+
this.webhooksubscription = new API.Webhooksubscription(this);
|
|
72
74
|
this._options = options;
|
|
73
75
|
this.apiKey = apiKey;
|
|
74
76
|
}
|
|
@@ -85,37 +87,38 @@ export class Getivy extends Core.APIClient {
|
|
|
85
87
|
return { 'X-Ivy-Api-Key': this.apiKey };
|
|
86
88
|
}
|
|
87
89
|
}
|
|
88
|
-
_a =
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
90
|
+
_a = Ivy;
|
|
91
|
+
Ivy.Ivy = _a;
|
|
92
|
+
Ivy.DEFAULT_TIMEOUT = 60000; // 1 minute
|
|
93
|
+
Ivy.IvyError = Errors.IvyError;
|
|
94
|
+
Ivy.APIError = Errors.APIError;
|
|
95
|
+
Ivy.APIConnectionError = Errors.APIConnectionError;
|
|
96
|
+
Ivy.APIConnectionTimeoutError = Errors.APIConnectionTimeoutError;
|
|
97
|
+
Ivy.APIUserAbortError = Errors.APIUserAbortError;
|
|
98
|
+
Ivy.NotFoundError = Errors.NotFoundError;
|
|
99
|
+
Ivy.ConflictError = Errors.ConflictError;
|
|
100
|
+
Ivy.RateLimitError = Errors.RateLimitError;
|
|
101
|
+
Ivy.BadRequestError = Errors.BadRequestError;
|
|
102
|
+
Ivy.AuthenticationError = Errors.AuthenticationError;
|
|
103
|
+
Ivy.InternalServerError = Errors.InternalServerError;
|
|
104
|
+
Ivy.PermissionDeniedError = Errors.PermissionDeniedError;
|
|
105
|
+
Ivy.UnprocessableEntityError = Errors.UnprocessableEntityError;
|
|
106
|
+
Ivy.toFile = Uploads.toFile;
|
|
107
|
+
Ivy.fileFromPath = Uploads.fileFromPath;
|
|
108
|
+
Ivy.Banks = Banks;
|
|
109
|
+
Ivy.Checkoutsession = Checkoutsession;
|
|
110
|
+
Ivy.Customers = Customers;
|
|
111
|
+
Ivy.Orders = Orders;
|
|
112
|
+
Ivy.Charges = Charges;
|
|
113
|
+
Ivy.Mandates = Mandates;
|
|
114
|
+
Ivy.Capabilities = Capabilities;
|
|
115
|
+
Ivy.Refunds = Refunds;
|
|
116
|
+
Ivy.Payouts = Payouts;
|
|
117
|
+
Ivy.Reports = Reports;
|
|
118
|
+
Ivy.Subaccounts = Subaccounts;
|
|
119
|
+
Ivy.Balance = Balance;
|
|
120
|
+
Ivy.Webhooksubscription = Webhooksubscription;
|
|
118
121
|
export { toFile, fileFromPath } from "./uploads.mjs";
|
|
119
|
-
export {
|
|
120
|
-
export default
|
|
122
|
+
export { IvyError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./error.mjs";
|
|
123
|
+
export default Ivy;
|
|
121
124
|
//# sourceMappingURL=index.mjs.map
|
package/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;;OAG/E,KAAK,IAAI;OACT,KAAK,MAAM;OACX,KAAK,OAAO;OACZ,KAAK,GAAG;OACR,EAAE,OAAO,EAAkD;OAC3D,EAOL,KAAK,GACN;OACM,EAAE,YAAY,EAAwD;OACtE,EAA8B,OAAO,EAAE;OACvC,EACL,eAAe,GAOhB;OACM,EAKL,SAAS,GACV;OACM,EAML,QAAQ,GACT;OACM,EAKL,MAAM,GACP;OACM,EAKL,OAAO,GAER;OACM,EAKL,OAAO,GACR;OACM,EAOL,OAAO,GACR;OACM,EAIL,WAAW,GACZ;AAED,MAAM,YAAY,GAAG;IACnB,UAAU,EAAE,uBAAuB;IACnC,OAAO,EAAE,4BAA4B;CACtC,CAAC;AA2EF;;GAEG;AACH,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;;OAG/E,KAAK,IAAI;OACT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CAAC;AAChC,GAAG,CAAC,OAAO,GAAG,OAAO,CAAC;AACtB,GAAG,CAAC,OAAO,GAAG,OAAO,CAAC;AACtB,GAAG,CAAC,OAAO,GAAG,OAAO,CAAC;AACtB,GAAG,CAAC,WAAW,GAAG,WAAW,CAAC;AAC9B,GAAG,CAAC,OAAO,GAAG,OAAO,CAAC;AACtB,GAAG,CAAC,mBAAmB,GAAG,mBAAmB,CAAC;OAgHvC,EAAE,MAAM,EAAE,YAAY,EAAE;OACxB,EACL,QAAQ,EACR,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB;AAED,eAAe,GAAG,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getivy/node-sdk",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
4
|
-
"description": "The official TypeScript library for the
|
|
5
|
-
"author": "
|
|
3
|
+
"version": "0.1.0-alpha.4",
|
|
4
|
+
"description": "The official TypeScript library for the Ivy API",
|
|
5
|
+
"author": "Ivy <developer@getivy.de>",
|
|
6
6
|
"types": "./index.d.ts",
|
|
7
7
|
"main": "./index.js",
|
|
8
8
|
"type": "commonjs",
|
package/resource.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Ivy } from "./index.js";
|
|
2
2
|
export declare class APIResource {
|
|
3
|
-
protected _client:
|
|
4
|
-
constructor(client:
|
|
3
|
+
protected _client: Ivy;
|
|
4
|
+
constructor(client: Ivy);
|
|
5
5
|
}
|
|
6
6
|
//# sourceMappingURL=resource.d.ts.map
|
package/resource.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.d.ts","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"resource.d.ts","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,SAAS,CAAC;AAEnC,qBAAa,WAAW;IACtB,SAAS,CAAC,OAAO,EAAE,GAAG,CAAC;gBAEX,MAAM,EAAE,GAAG;CAGxB"}
|
package/resource.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.js","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAItF,MAAa,WAAW;IAGtB,YAAY,
|
|
1
|
+
{"version":3,"file":"resource.js","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAItF,MAAa,WAAW;IAGtB,YAAY,MAAW;QACrB,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC;IACxB,CAAC;CACF;AAND,kCAMC"}
|
package/resource.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.mjs","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAItF,MAAM,OAAO,WAAW;IAGtB,YAAY,
|
|
1
|
+
{"version":3,"file":"resource.mjs","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAItF,MAAM,OAAO,WAAW;IAGtB,YAAY,MAAW;QACrB,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC;IACxB,CAAC;CACF"}
|
package/resources/index.d.ts
CHANGED
|
@@ -10,4 +10,5 @@ export { Payouts, type PublicUserPayout, type PayoutListResponse, type PayoutCre
|
|
|
10
10
|
export { Refunds, type RefundResponse, type RefundBatchResponse, type RefundCreateParams, type RefundBatchParams, } from "./refunds.js";
|
|
11
11
|
export { Reports, type PayoutReport, type ReportCreateResponse, type ReportRetrieveResponse, type ReportCreateParams, type ReportRetrieveParams, type ReportDownloadParams, } from "./reports.js";
|
|
12
12
|
export { Subaccounts, type Subaccount, type SubaccountCreateParams, type SubaccountRetrieveParams, } from "./subaccounts.js";
|
|
13
|
+
export { Webhooksubscription, type WebhooksubscriptionCreateResponse, type WebhooksubscriptionUpdateResponse, type WebhooksubscriptionListResponse, type WebhooksubscriptionDeleteResponse, type WebhooksubscriptionPingResponse, type WebhooksubscriptionCreateParams, type WebhooksubscriptionUpdateParams, type WebhooksubscriptionListParams, type WebhooksubscriptionDeleteParams, type WebhooksubscriptionPingParams, } from "./webhooksubscription.js";
|
|
13
14
|
//# sourceMappingURL=index.d.ts.map
|
package/resources/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,KAAK,uBAAuB,EAAE,KAAK,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAC9F,OAAO,EACL,KAAK,EACL,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,GACtB,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,YAAY,EAAE,KAAK,0BAA0B,EAAE,KAAK,wBAAwB,EAAE,MAAM,gBAAgB,CAAC;AAC9G,OAAO,EAAE,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC1E,OAAO,EACL,eAAe,EACf,KAAK,6BAA6B,EAClC,KAAK,+BAA+B,EACpC,KAAK,6BAA6B,EAClC,KAAK,2BAA2B,EAChC,KAAK,6BAA6B,EAClC,KAAK,2BAA2B,GACjC,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,SAAS,EACT,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,GAC5B,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,MAAM,EACN,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,OAAO,EACP,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,GACtB,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,OAAO,EACP,KAAK,cAAc,EACnB,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,GACvB,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,OAAO,EACP,KAAK,YAAY,EACjB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,GAC1B,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,GAC9B,MAAM,eAAe,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,KAAK,uBAAuB,EAAE,KAAK,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAC9F,OAAO,EACL,KAAK,EACL,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,GACtB,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,YAAY,EAAE,KAAK,0BAA0B,EAAE,KAAK,wBAAwB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