@paygentic/sdk 0.10.1 → 0.10.3
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/dist/commonjs/funcs/billableMetricsCreate.js +2 -2
- package/dist/commonjs/funcs/billableMetricsCreate.js.map +1 -1
- package/dist/commonjs/funcs/billableMetricsListEvents.js +2 -2
- package/dist/commonjs/funcs/billableMetricsListEvents.js.map +1 -1
- package/dist/commonjs/funcs/billableMetricsMeter.js +2 -2
- package/dist/commonjs/funcs/billableMetricsMeter.js.map +1 -1
- package/dist/commonjs/funcs/costsCreateCost.js +2 -2
- package/dist/commonjs/funcs/costsCreateCost.js.map +1 -1
- package/dist/commonjs/funcs/entitlementsList.js +2 -2
- package/dist/commonjs/funcs/entitlementsList.js.map +1 -1
- package/dist/commonjs/funcs/eventsIngest.js +2 -2
- package/dist/commonjs/funcs/eventsIngest.js.map +1 -1
- package/dist/commonjs/funcs/feesCreate.js +2 -2
- package/dist/commonjs/funcs/feesCreate.js.map +1 -1
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.d.ts +1 -1
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.js +1 -1
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.d.ts +1 -1
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.js +1 -1
- package/dist/commonjs/funcs/merchantIntegrationsUpsertMerchantIntegration.js +2 -2
- package/dist/commonjs/funcs/merchantIntegrationsUpsertMerchantIntegration.js.map +1 -1
- package/dist/commonjs/funcs/merchantsReset.js +2 -2
- package/dist/commonjs/funcs/merchantsReset.js.map +1 -1
- package/dist/commonjs/funcs/paymentsCreate.js +2 -2
- package/dist/commonjs/funcs/paymentsCreate.js.map +1 -1
- package/dist/commonjs/funcs/plansCreate.js +2 -2
- package/dist/commonjs/funcs/plansCreate.js.map +1 -1
- package/dist/commonjs/funcs/productsCreate.js +2 -2
- package/dist/commonjs/funcs/productsCreate.js.map +1 -1
- package/dist/commonjs/funcs/testClocksCreate.js +2 -2
- package/dist/commonjs/funcs/testClocksCreate.js.map +1 -1
- package/dist/commonjs/funcs/webhooksEnable.js +2 -2
- package/dist/commonjs/funcs/webhooksEnable.js.map +1 -1
- package/dist/commonjs/funcs/webhooksGetPortal.d.ts +1 -1
- package/dist/commonjs/funcs/webhooksGetPortal.js +1 -1
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/models/costreportresponse.d.ts +14 -2
- package/dist/commonjs/models/costreportresponse.d.ts.map +1 -1
- package/dist/commonjs/models/costreportresponse.js.map +1 -1
- package/dist/commonjs/models/operations/getcostreport.d.ts +2 -2
- package/dist/commonjs/models/operations/getcostsummary.d.ts +2 -2
- package/dist/commonjs/models/operations/getprofitability.d.ts +2 -2
- package/dist/commonjs/models/operations/getrevenue.d.ts +2 -2
- package/dist/commonjs/models/operations/ingestevent.d.ts +4 -4
- package/dist/commonjs/models/operations/listentitlements.d.ts +16 -0
- package/dist/commonjs/models/operations/listentitlements.d.ts.map +1 -1
- package/dist/commonjs/models/operations/listentitlements.js +11 -1
- package/dist/commonjs/models/operations/listentitlements.js.map +1 -1
- package/dist/commonjs/models/profitabilitysummaryresponse.d.ts +4 -4
- package/dist/commonjs/models/revenuesummaryresponse.d.ts +2 -2
- package/dist/commonjs/sdk/invoicesv2.d.ts +2 -2
- package/dist/commonjs/sdk/invoicesv2.js +2 -2
- package/dist/commonjs/sdk/webhooks.d.ts +1 -1
- package/dist/commonjs/sdk/webhooks.js +1 -1
- package/dist/esm/funcs/billableMetricsCreate.js +2 -2
- package/dist/esm/funcs/billableMetricsCreate.js.map +1 -1
- package/dist/esm/funcs/billableMetricsListEvents.js +2 -2
- package/dist/esm/funcs/billableMetricsListEvents.js.map +1 -1
- package/dist/esm/funcs/billableMetricsMeter.js +2 -2
- package/dist/esm/funcs/billableMetricsMeter.js.map +1 -1
- package/dist/esm/funcs/costsCreateCost.js +2 -2
- package/dist/esm/funcs/costsCreateCost.js.map +1 -1
- package/dist/esm/funcs/entitlementsList.js +2 -2
- package/dist/esm/funcs/entitlementsList.js.map +1 -1
- package/dist/esm/funcs/eventsIngest.js +2 -2
- package/dist/esm/funcs/eventsIngest.js.map +1 -1
- package/dist/esm/funcs/feesCreate.js +2 -2
- package/dist/esm/funcs/feesCreate.js.map +1 -1
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.d.ts +1 -1
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.js +1 -1
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.d.ts +1 -1
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.js +1 -1
- package/dist/esm/funcs/merchantIntegrationsUpsertMerchantIntegration.js +2 -2
- package/dist/esm/funcs/merchantIntegrationsUpsertMerchantIntegration.js.map +1 -1
- package/dist/esm/funcs/merchantsReset.js +2 -2
- package/dist/esm/funcs/merchantsReset.js.map +1 -1
- package/dist/esm/funcs/paymentsCreate.js +2 -2
- package/dist/esm/funcs/paymentsCreate.js.map +1 -1
- package/dist/esm/funcs/plansCreate.js +2 -2
- package/dist/esm/funcs/plansCreate.js.map +1 -1
- package/dist/esm/funcs/productsCreate.js +2 -2
- package/dist/esm/funcs/productsCreate.js.map +1 -1
- package/dist/esm/funcs/testClocksCreate.js +2 -2
- package/dist/esm/funcs/testClocksCreate.js.map +1 -1
- package/dist/esm/funcs/webhooksEnable.js +2 -2
- package/dist/esm/funcs/webhooksEnable.js.map +1 -1
- package/dist/esm/funcs/webhooksGetPortal.d.ts +1 -1
- package/dist/esm/funcs/webhooksGetPortal.js +1 -1
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/models/costreportresponse.d.ts +14 -2
- package/dist/esm/models/costreportresponse.d.ts.map +1 -1
- package/dist/esm/models/costreportresponse.js.map +1 -1
- package/dist/esm/models/operations/getcostreport.d.ts +2 -2
- package/dist/esm/models/operations/getcostsummary.d.ts +2 -2
- package/dist/esm/models/operations/getprofitability.d.ts +2 -2
- package/dist/esm/models/operations/getrevenue.d.ts +2 -2
- package/dist/esm/models/operations/ingestevent.d.ts +4 -4
- package/dist/esm/models/operations/listentitlements.d.ts +16 -0
- package/dist/esm/models/operations/listentitlements.d.ts.map +1 -1
- package/dist/esm/models/operations/listentitlements.js +9 -0
- package/dist/esm/models/operations/listentitlements.js.map +1 -1
- package/dist/esm/models/profitabilitysummaryresponse.d.ts +4 -4
- package/dist/esm/models/revenuesummaryresponse.d.ts +2 -2
- package/dist/esm/sdk/invoicesv2.d.ts +2 -2
- package/dist/esm/sdk/invoicesv2.js +2 -2
- package/dist/esm/sdk/webhooks.d.ts +1 -1
- package/dist/esm/sdk/webhooks.js +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/billableMetricsCreate.ts +2 -2
- package/src/funcs/billableMetricsListEvents.ts +2 -2
- package/src/funcs/billableMetricsMeter.ts +2 -2
- package/src/funcs/costsCreateCost.ts +2 -2
- package/src/funcs/entitlementsList.ts +2 -2
- package/src/funcs/eventsIngest.ts +2 -2
- package/src/funcs/feesCreate.ts +2 -2
- package/src/funcs/invoicesV2RecordInvoicePayment.ts +1 -1
- package/src/funcs/invoicesV2RetryInvoicePayment.ts +1 -1
- package/src/funcs/merchantIntegrationsUpsertMerchantIntegration.ts +2 -2
- package/src/funcs/merchantsReset.ts +2 -2
- package/src/funcs/paymentsCreate.ts +2 -2
- package/src/funcs/plansCreate.ts +2 -2
- package/src/funcs/productsCreate.ts +2 -2
- package/src/funcs/testClocksCreate.ts +2 -2
- package/src/funcs/webhooksEnable.ts +2 -2
- package/src/funcs/webhooksGetPortal.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/models/costreportresponse.ts +14 -2
- package/src/models/operations/getcostreport.ts +2 -2
- package/src/models/operations/getcostsummary.ts +2 -2
- package/src/models/operations/getprofitability.ts +2 -2
- package/src/models/operations/getrevenue.ts +2 -2
- package/src/models/operations/ingestevent.ts +4 -4
- package/src/models/operations/listentitlements.ts +33 -0
- package/src/models/profitabilitysummaryresponse.ts +4 -4
- package/src/models/revenuesummaryresponse.ts +2 -2
- package/src/sdk/invoicesv2.ts +2 -2
- package/src/sdk/webhooks.ts +1 -1
|
@@ -5,11 +5,11 @@ export type GetProfitabilityRequest = {
|
|
|
5
5
|
*/
|
|
6
6
|
merchantId: string;
|
|
7
7
|
/**
|
|
8
|
-
* Start of the
|
|
8
|
+
* Start of the read window, included (ISO 8601 format)
|
|
9
9
|
*/
|
|
10
10
|
from: Date;
|
|
11
11
|
/**
|
|
12
|
-
* End of the
|
|
12
|
+
* End of the read window, excluded: the read counts from <= t < to, so a month ends at the first instant of the next month (ISO 8601 format)
|
|
13
13
|
*/
|
|
14
14
|
to: Date;
|
|
15
15
|
/**
|
|
@@ -37,11 +37,11 @@ export declare const PeriodBasis: {
|
|
|
37
37
|
export type PeriodBasis = ClosedEnum<typeof PeriodBasis>;
|
|
38
38
|
export type GetRevenueRequest = {
|
|
39
39
|
/**
|
|
40
|
-
* Start of the
|
|
40
|
+
* Start of the read window, included (ISO 8601 format)
|
|
41
41
|
*/
|
|
42
42
|
startTime: Date;
|
|
43
43
|
/**
|
|
44
|
-
* End of the
|
|
44
|
+
* End of the read window, excluded: the read counts startTime <= t < endTime, so a month ends at the first instant of the next month (ISO 8601 format)
|
|
45
45
|
*/
|
|
46
46
|
endTime: Date;
|
|
47
47
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as z from "zod/v3";
|
|
2
2
|
export type IngestEventRequestBody2 = {
|
|
3
3
|
/**
|
|
4
|
-
* CloudEvents type. Must match an eventType configured on a BillableMetric.
|
|
4
|
+
* CloudEvents type. Must match an eventType configured on a BillableMetric. Must not contain control characters.
|
|
5
5
|
*/
|
|
6
6
|
type: string;
|
|
7
7
|
/**
|
|
@@ -13,7 +13,7 @@ export type IngestEventRequestBody2 = {
|
|
|
13
13
|
*/
|
|
14
14
|
subject?: string | undefined;
|
|
15
15
|
/**
|
|
16
|
-
* Your own customer identifier, matched against the customer's externalId. Fallback for when the Paygentic customer ID is not known — prefer subject when it is. Events reported before the customer exists are linked retroactively once a customer with this externalId is created. Resolution is eventually consistent: after an externalId is removed or reassigned, events may resolve to the previous customer for up to one hour. If subject is also provided, subject takes precedence and externalSubject is recorded but not used for resolution.
|
|
16
|
+
* Your own customer identifier, matched against the customer's externalId. Fallback for when the Paygentic customer ID is not known — prefer subject when it is. Events reported before the customer exists are linked retroactively once a customer with this externalId is created. Resolution is eventually consistent: after an externalId is removed or reassigned, or its customer is deleted, events may resolve to the previous customer for up to one hour, and for up to 48 hours if Paygentic's database is unavailable. If subject is also provided, subject takes precedence and externalSubject is recorded but not used for resolution.
|
|
17
17
|
*/
|
|
18
18
|
externalSubject: string;
|
|
19
19
|
/**
|
|
@@ -41,7 +41,7 @@ export type IngestEventRequestBody2 = {
|
|
|
41
41
|
};
|
|
42
42
|
export type IngestEventRequestBody1 = {
|
|
43
43
|
/**
|
|
44
|
-
* CloudEvents type. Must match an eventType configured on a BillableMetric.
|
|
44
|
+
* CloudEvents type. Must match an eventType configured on a BillableMetric. Must not contain control characters.
|
|
45
45
|
*/
|
|
46
46
|
type: string;
|
|
47
47
|
/**
|
|
@@ -53,7 +53,7 @@ export type IngestEventRequestBody1 = {
|
|
|
53
53
|
*/
|
|
54
54
|
subject: string;
|
|
55
55
|
/**
|
|
56
|
-
* Your own customer identifier, matched against the customer's externalId. Fallback for when the Paygentic customer ID is not known — prefer subject when it is. Events reported before the customer exists are linked retroactively once a customer with this externalId is created. Resolution is eventually consistent: after an externalId is removed or reassigned, events may resolve to the previous customer for up to one hour. If subject is also provided, subject takes precedence and externalSubject is recorded but not used for resolution.
|
|
56
|
+
* Your own customer identifier, matched against the customer's externalId. Fallback for when the Paygentic customer ID is not known — prefer subject when it is. Events reported before the customer exists are linked retroactively once a customer with this externalId is created. Resolution is eventually consistent: after an externalId is removed or reassigned, or its customer is deleted, events may resolve to the previous customer for up to one hour, and for up to 48 hours if Paygentic's database is unavailable. If subject is also provided, subject takes precedence and externalSubject is recorded but not used for resolution.
|
|
57
57
|
*/
|
|
58
58
|
externalSubject?: string | undefined;
|
|
59
59
|
/**
|
|
@@ -45,6 +45,15 @@ export declare const ListEntitlementsObject: {
|
|
|
45
45
|
readonly List: "list";
|
|
46
46
|
};
|
|
47
47
|
export type ListEntitlementsObject = ClosedEnum<typeof ListEntitlementsObject>;
|
|
48
|
+
/**
|
|
49
|
+
* Present only when the database can't be reached, or the list takes more than a second to compute. The response is then the last result for this same request in the past hour, computed at `computedAt`.
|
|
50
|
+
*/
|
|
51
|
+
export type Stale = {
|
|
52
|
+
/**
|
|
53
|
+
* When this result was computed.
|
|
54
|
+
*/
|
|
55
|
+
computedAt: Date;
|
|
56
|
+
};
|
|
48
57
|
/**
|
|
49
58
|
* Successfully retrieved the list of entitlements for the customer.
|
|
50
59
|
*/
|
|
@@ -58,6 +67,10 @@ export type ListEntitlementsResponse = {
|
|
|
58
67
|
* Offset-based pagination response.
|
|
59
68
|
*/
|
|
60
69
|
pagination: models.OffsetPagination;
|
|
70
|
+
/**
|
|
71
|
+
* Present only when the database can't be reached, or the list takes more than a second to compute. The response is then the last result for this same request in the past hour, computed at `computedAt`.
|
|
72
|
+
*/
|
|
73
|
+
stale?: Stale | undefined;
|
|
61
74
|
};
|
|
62
75
|
/** @internal */
|
|
63
76
|
export type ListEntitlementsRequest$Outbound = {
|
|
@@ -77,6 +90,9 @@ export declare function listEntitlementsRequestToJSON(listEntitlementsRequest: L
|
|
|
77
90
|
/** @internal */
|
|
78
91
|
export declare const ListEntitlementsObject$inboundSchema: z.ZodNativeEnum<typeof ListEntitlementsObject>;
|
|
79
92
|
/** @internal */
|
|
93
|
+
export declare const Stale$inboundSchema: z.ZodType<Stale, z.ZodTypeDef, unknown>;
|
|
94
|
+
export declare function staleFromJSON(jsonString: string): SafeParseResult<Stale, SDKValidationError>;
|
|
95
|
+
/** @internal */
|
|
80
96
|
export declare const ListEntitlementsResponse$inboundSchema: z.ZodType<ListEntitlementsResponse, z.ZodTypeDef, unknown>;
|
|
81
97
|
export declare function listEntitlementsResponseFromJSON(jsonString: string): SafeParseResult<ListEntitlementsResponse, SDKValidationError>;
|
|
82
98
|
//# sourceMappingURL=listentitlements.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"listentitlements.d.ts","sourceRoot":"","sources":["../../../../src/models/operations/listentitlements.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AAEtC,MAAM,MAAM,uBAAuB,GAAG;IACpC;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAChC;;OAEG;IACH,kBAAkB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACxC;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAChC;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAChC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC/B;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACpC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B;;OAEG;IACH,EAAE,CAAC,EAAE,IAAI,GAAG,SAAS,CAAC;CACvB,CAAC;AAEF,eAAO,MAAM,sBAAsB;;CAEzB,CAAC;AACX,MAAM,MAAM,sBAAsB,GAAG,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE/E;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAAG;IACrC,MAAM,EAAE,sBAAsB,CAAC;IAC/B;;OAEG;IACH,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,mBAAmB,CAAC,CAAC;IACxC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"listentitlements.d.ts","sourceRoot":"","sources":["../../../../src/models/operations/listentitlements.ts"],"names":[],"mappings":"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"}
|
|
@@ -25,10 +25,19 @@ export function listEntitlementsRequestToJSON(listEntitlementsRequest) {
|
|
|
25
25
|
/** @internal */
|
|
26
26
|
export const ListEntitlementsObject$inboundSchema = z.nativeEnum(ListEntitlementsObject);
|
|
27
27
|
/** @internal */
|
|
28
|
+
export const Stale$inboundSchema = z
|
|
29
|
+
.object({
|
|
30
|
+
computedAt: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
31
|
+
});
|
|
32
|
+
export function staleFromJSON(jsonString) {
|
|
33
|
+
return safeParse(jsonString, (x) => Stale$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Stale' from JSON`);
|
|
34
|
+
}
|
|
35
|
+
/** @internal */
|
|
28
36
|
export const ListEntitlementsResponse$inboundSchema = z.object({
|
|
29
37
|
object: ListEntitlementsObject$inboundSchema.default("list"),
|
|
30
38
|
data: z.array(models.EntitlementListItem$inboundSchema),
|
|
31
39
|
pagination: models.OffsetPagination$inboundSchema,
|
|
40
|
+
stale: z.lazy(() => Stale$inboundSchema).optional(),
|
|
32
41
|
});
|
|
33
42
|
export function listEntitlementsResponseFromJSON(jsonString) {
|
|
34
43
|
return safeParse(jsonString, (x) => ListEntitlementsResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListEntitlementsResponse' from JSON`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"listentitlements.js","sourceRoot":"","sources":["../../../../src/models/operations/listentitlements.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAIjD,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AAyCtC,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,IAAI,EAAE,MAAM;CACJ,CAAC;
|
|
1
|
+
{"version":3,"file":"listentitlements.js","sourceRoot":"","sources":["../../../../src/models/operations/listentitlements.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAIjD,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AAyCtC,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,IAAI,EAAE,MAAM;CACJ,CAAC;AA6CX,gBAAgB;AAChB,MAAM,CAAC,MAAM,sCAAsC,GAI/C,CAAC,CAAC,MAAM,CAAC;IACX,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,kBAAkB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzC,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAChC,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACrC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;IACnC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IACnC,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC,QAAQ,EAAE;CACxD,CAAC,CAAC;AAEH,MAAM,UAAU,6BAA6B,CAC3C,uBAAgD;IAEhD,OAAO,IAAI,CAAC,SAAS,CACnB,sCAAsC,CAAC,KAAK,CAAC,uBAAuB,CAAC,CACtE,CAAC;AACJ,CAAC;AAED,gBAAgB;AAChB,MAAM,CAAC,MAAM,oCAAoC,GAE7C,CAAC,CAAC,UAAU,CAAC,sBAAsB,CAAC,CAAC;AAEzC,gBAAgB;AAChB,MAAM,CAAC,MAAM,mBAAmB,GAA4C,CAAC;KAC1E,MAAM,CAAC;IACN,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAC9D,IAAI,IAAI,CAAC,CAAC,CAAC,CACZ;CACF,CAAC,CAAC;AAEL,MAAM,UAAU,aAAa,CAC3B,UAAkB;IAElB,OAAO,SAAS,CACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,mBAAmB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAC/C,mCAAmC,CACpC,CAAC;AACJ,CAAC;AAED,gBAAgB;AAChB,MAAM,CAAC,MAAM,sCAAsC,GAI/C,CAAC,CAAC,MAAM,CAAC;IACX,MAAM,EAAE,oCAAoC,CAAC,OAAO,CAAC,MAAM,CAAC;IAC5D,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,iCAAiC,CAAC;IACvD,UAAU,EAAE,MAAM,CAAC,8BAA8B;IACjD,KAAK,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,mBAAmB,CAAC,CAAC,QAAQ,EAAE;CACpD,CAAC,CAAC;AAEH,MAAM,UAAU,gCAAgC,CAC9C,UAAkB;IAElB,OAAO,SAAS,CACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,sCAAsC,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAClE,sDAAsD,CACvD,CAAC;AACJ,CAAC"}
|
|
@@ -3,7 +3,7 @@ import { Result as SafeParseResult } from "../types/fp.js";
|
|
|
3
3
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
4
4
|
import { ProfitabilityRow } from "./profitabilityrow.js";
|
|
5
5
|
/**
|
|
6
|
-
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
6
|
+
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
7
7
|
*/
|
|
8
8
|
export type ProfitabilitySummaryResponseRevenueRange = {
|
|
9
9
|
/**
|
|
@@ -16,7 +16,7 @@ export type ProfitabilitySummaryResponseRevenueRange = {
|
|
|
16
16
|
to: Date;
|
|
17
17
|
};
|
|
18
18
|
/**
|
|
19
|
-
* Where the caller's cost data actually lies in time. Present only when the selected range returned no cost. An object carries the bounds of the real cost events; null means the caller has no cost event at any time; an absent field means the extent was not resolved, because the result was not empty, because the lookup failed, or because the metering service does not serve the bounds method. An absent field must never be read as an absence.
|
|
19
|
+
* Where the caller's cost data actually lies in time. Present only when the selected range returned no cost. An object carries the bounds of the real cost events; null means the caller has no cost event at any time; an absent field means the extent was not resolved, because the result was not empty, because the lookup failed, or because the metering service does not serve the bounds method. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it.
|
|
20
20
|
*/
|
|
21
21
|
export type ProfitabilitySummaryResponseCostRange = {
|
|
22
22
|
/**
|
|
@@ -62,11 +62,11 @@ export type ProfitabilitySummaryResponse = {
|
|
|
62
62
|
*/
|
|
63
63
|
warnings?: Array<string> | undefined;
|
|
64
64
|
/**
|
|
65
|
-
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
65
|
+
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
66
66
|
*/
|
|
67
67
|
revenueRange?: ProfitabilitySummaryResponseRevenueRange | null | undefined;
|
|
68
68
|
/**
|
|
69
|
-
* Where the caller's cost data actually lies in time. Present only when the selected range returned no cost. An object carries the bounds of the real cost events; null means the caller has no cost event at any time; an absent field means the extent was not resolved, because the result was not empty, because the lookup failed, or because the metering service does not serve the bounds method. An absent field must never be read as an absence.
|
|
69
|
+
* Where the caller's cost data actually lies in time. Present only when the selected range returned no cost. An object carries the bounds of the real cost events; null means the caller has no cost event at any time; an absent field means the extent was not resolved, because the result was not empty, because the lookup failed, or because the metering service does not serve the bounds method. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it.
|
|
70
70
|
*/
|
|
71
71
|
costRange?: ProfitabilitySummaryResponseCostRange | null | undefined;
|
|
72
72
|
};
|
|
@@ -7,7 +7,7 @@ import { InvoiceSummary } from "./invoicesummary.js";
|
|
|
7
7
|
import { PaymentSummary } from "./paymentsummary.js";
|
|
8
8
|
import { RevenueTrendBucket } from "./revenuetrendbucket.js";
|
|
9
9
|
/**
|
|
10
|
-
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
10
|
+
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
11
11
|
*/
|
|
12
12
|
export type RevenueSummaryResponseRevenueRange = {
|
|
13
13
|
/**
|
|
@@ -63,7 +63,7 @@ export type RevenueSummaryResponse = {
|
|
|
63
63
|
*/
|
|
64
64
|
currencyBreakdown?: Array<CurrencyBreakdownEntry> | undefined;
|
|
65
65
|
/**
|
|
66
|
-
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
66
|
+
* Where the caller's revenue actually lies in time. Scoped by the same filters as the request (merchant, and where given customer, subscription and currency), so it is not an account-wide statement. Present only when the selected range returned nothing. An object carries the bounds of the real revenue; null means no revenue under these filters at any time; an absent field means the extent was not resolved, because the result was not empty or because the lookup failed. An absent field must never be read as an absence. The bounds are instants that exist and both are included, so a window that holds `to` ends after it. The bounds may span more than this endpoint's maximum queryable range, so clamp before re-querying.
|
|
67
67
|
*/
|
|
68
68
|
revenueRange?: RevenueSummaryResponseRevenueRange | null | undefined;
|
|
69
69
|
};
|
|
@@ -60,7 +60,7 @@ export declare class InvoicesV2 extends ClientSDK {
|
|
|
60
60
|
* - `hosted_link`: create a new hosted payment link and email it to the customer. The invoice stays unpaid until the customer pays on the link. Each call replaces the previous link. A payment link expires after 30 days; to collect an invoice whose link has expired, call this method again.
|
|
61
61
|
* - `out_of_band`: record a payment that you collected outside Paygentic. The invoice changes to `PAID` immediately. A second call returns 409.
|
|
62
62
|
*
|
|
63
|
-
* For `hosted_link`, an invoice that does not exist returns
|
|
63
|
+
* For `hosted_link`, an invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
64
64
|
*
|
|
65
65
|
* Paygentic selects the payment provider from your connected payment account. The response reports the provider.
|
|
66
66
|
*
|
|
@@ -111,7 +111,7 @@ export declare class InvoicesV2 extends ClientSDK {
|
|
|
111
111
|
*
|
|
112
112
|
* A 500 response has the standard error body, not `retry_payment_result`. It is an internal error, and a retry does not fix it.
|
|
113
113
|
*
|
|
114
|
-
* An invoice that does not exist returns
|
|
114
|
+
* An invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
115
115
|
*
|
|
116
116
|
* This operation is rate limited to one call each minute for each invoice.
|
|
117
117
|
*/
|
|
@@ -88,7 +88,7 @@ export class InvoicesV2 extends ClientSDK {
|
|
|
88
88
|
* - `hosted_link`: create a new hosted payment link and email it to the customer. The invoice stays unpaid until the customer pays on the link. Each call replaces the previous link. A payment link expires after 30 days; to collect an invoice whose link has expired, call this method again.
|
|
89
89
|
* - `out_of_band`: record a payment that you collected outside Paygentic. The invoice changes to `PAID` immediately. A second call returns 409.
|
|
90
90
|
*
|
|
91
|
-
* For `hosted_link`, an invoice that does not exist returns
|
|
91
|
+
* For `hosted_link`, an invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
92
92
|
*
|
|
93
93
|
* Paygentic selects the payment provider from your connected payment account. The response reports the provider.
|
|
94
94
|
*
|
|
@@ -147,7 +147,7 @@ export class InvoicesV2 extends ClientSDK {
|
|
|
147
147
|
*
|
|
148
148
|
* A 500 response has the standard error body, not `retry_payment_result`. It is an internal error, and a retry does not fix it.
|
|
149
149
|
*
|
|
150
|
-
* An invoice that does not exist returns
|
|
150
|
+
* An invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
151
151
|
*
|
|
152
152
|
* This operation is rate limited to one call each minute for each invoice.
|
|
153
153
|
*/
|
|
@@ -34,7 +34,7 @@ export declare class Webhooks extends ClientSDK {
|
|
|
34
34
|
* Get Portal Access
|
|
35
35
|
*
|
|
36
36
|
* @remarks
|
|
37
|
-
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. Returns 404 unless webhooks are enabled.
|
|
37
|
+
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. The link is read-only unless the caller holds `webhooks:write`: a read-only portal shows endpoints and deliveries but does not let you add or change endpoints, read the signing secret or replay messages. Returns 404 unless webhooks are enabled.
|
|
38
38
|
*/
|
|
39
39
|
getPortal(request?: operations.GetWebhookPortalRequest | undefined, options?: RequestOptions): Promise<models.WebhookPortal>;
|
|
40
40
|
}
|
package/dist/esm/sdk/webhooks.js
CHANGED
|
@@ -49,7 +49,7 @@ export class Webhooks extends ClientSDK {
|
|
|
49
49
|
* Get Portal Access
|
|
50
50
|
*
|
|
51
51
|
* @remarks
|
|
52
|
-
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. Returns 404 unless webhooks are enabled.
|
|
52
|
+
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. The link is read-only unless the caller holds `webhooks:write`: a read-only portal shows endpoints and deliveries but does not let you add or change endpoints, read the signing secret or replay messages. Returns 404 unless webhooks are enabled.
|
|
53
53
|
*/
|
|
54
54
|
async getPortal(request, options) {
|
|
55
55
|
return unwrapAsync(webhooksGetPortal(this, request, options));
|
package/jsr.json
CHANGED
package/package.json
CHANGED
|
@@ -135,7 +135,7 @@ async function $do(
|
|
|
135
135
|
|
|
136
136
|
const doResult = await client._do(req, {
|
|
137
137
|
context,
|
|
138
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
138
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
139
139
|
retryConfig: context.retryConfig,
|
|
140
140
|
retryCodes: context.retryCodes,
|
|
141
141
|
});
|
|
@@ -163,7 +163,7 @@ async function $do(
|
|
|
163
163
|
>(
|
|
164
164
|
M.json(201, models.BillableMetric$inboundSchema),
|
|
165
165
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
166
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
166
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
167
167
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
168
168
|
M.fail("4XX"),
|
|
169
169
|
M.fail("5XX"),
|
|
@@ -151,7 +151,7 @@ async function $do(
|
|
|
151
151
|
|
|
152
152
|
const doResult = await client._do(req, {
|
|
153
153
|
context,
|
|
154
|
-
errorCodes: ["400", "403", "4XX", "500", "5XX"],
|
|
154
|
+
errorCodes: ["400", "403", "404", "4XX", "500", "5XX"],
|
|
155
155
|
retryConfig: context.retryConfig,
|
|
156
156
|
retryCodes: context.retryCodes,
|
|
157
157
|
});
|
|
@@ -179,7 +179,7 @@ async function $do(
|
|
|
179
179
|
>(
|
|
180
180
|
M.json(200, models.MeterEventList$inboundSchema),
|
|
181
181
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
182
|
-
M.jsonErr(403, errors.ErrorT$inboundSchema),
|
|
182
|
+
M.jsonErr([403, 404], errors.ErrorT$inboundSchema),
|
|
183
183
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
184
184
|
M.fail("4XX"),
|
|
185
185
|
M.fail("5XX"),
|
|
@@ -152,7 +152,7 @@ async function $do(
|
|
|
152
152
|
|
|
153
153
|
const doResult = await client._do(req, {
|
|
154
154
|
context,
|
|
155
|
-
errorCodes: ["400", "403", "4XX", "500", "5XX"],
|
|
155
|
+
errorCodes: ["400", "403", "404", "4XX", "500", "5XX"],
|
|
156
156
|
retryConfig: context.retryConfig,
|
|
157
157
|
retryCodes: context.retryCodes,
|
|
158
158
|
});
|
|
@@ -180,7 +180,7 @@ async function $do(
|
|
|
180
180
|
>(
|
|
181
181
|
M.json(200, models.UsageResponse$inboundSchema),
|
|
182
182
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
183
|
-
M.jsonErr(403, errors.ErrorT$inboundSchema),
|
|
183
|
+
M.jsonErr([403, 404], errors.ErrorT$inboundSchema),
|
|
184
184
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
185
185
|
M.fail("4XX"),
|
|
186
186
|
M.fail("5XX"),
|
|
@@ -134,7 +134,7 @@ async function $do(
|
|
|
134
134
|
|
|
135
135
|
const doResult = await client._do(req, {
|
|
136
136
|
context,
|
|
137
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
137
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
138
138
|
retryConfig: context.retryConfig,
|
|
139
139
|
retryCodes: context.retryCodes,
|
|
140
140
|
});
|
|
@@ -162,7 +162,7 @@ async function $do(
|
|
|
162
162
|
>(
|
|
163
163
|
M.json(201, models.Cost$inboundSchema),
|
|
164
164
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
165
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
165
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
166
166
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
167
167
|
M.fail("4XX"),
|
|
168
168
|
M.fail("5XX"),
|
|
@@ -150,7 +150,7 @@ async function $do(
|
|
|
150
150
|
|
|
151
151
|
const doResult = await client._do(req, {
|
|
152
152
|
context,
|
|
153
|
-
errorCodes: ["400", "403", "4XX", "500", "5XX"],
|
|
153
|
+
errorCodes: ["400", "403", "404", "4XX", "500", "5XX"],
|
|
154
154
|
retryConfig: context.retryConfig,
|
|
155
155
|
retryCodes: context.retryCodes,
|
|
156
156
|
});
|
|
@@ -178,7 +178,7 @@ async function $do(
|
|
|
178
178
|
>(
|
|
179
179
|
M.json(200, operations.ListEntitlementsResponse$inboundSchema),
|
|
180
180
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
181
|
-
M.jsonErr(403, errors.ErrorT$inboundSchema),
|
|
181
|
+
M.jsonErr([403, 404], errors.ErrorT$inboundSchema),
|
|
182
182
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
183
183
|
M.fail("4XX"),
|
|
184
184
|
M.fail("5XX"),
|
|
@@ -134,7 +134,7 @@ async function $do(
|
|
|
134
134
|
|
|
135
135
|
const doResult = await client._do(req, {
|
|
136
136
|
context,
|
|
137
|
-
errorCodes: ["400", "401", "403", "422", "4XX", "500", "5XX"],
|
|
137
|
+
errorCodes: ["400", "401", "403", "404", "422", "4XX", "500", "5XX"],
|
|
138
138
|
retryConfig: context.retryConfig,
|
|
139
139
|
retryCodes: context.retryCodes,
|
|
140
140
|
});
|
|
@@ -162,7 +162,7 @@ async function $do(
|
|
|
162
162
|
>(
|
|
163
163
|
M.json(202, models.EventResponse$inboundSchema),
|
|
164
164
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
165
|
-
M.jsonErr([401, 403, 422], errors.ErrorT$inboundSchema),
|
|
165
|
+
M.jsonErr([401, 403, 404, 422], errors.ErrorT$inboundSchema),
|
|
166
166
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
167
167
|
M.fail("4XX"),
|
|
168
168
|
M.fail("5XX"),
|
package/src/funcs/feesCreate.ts
CHANGED
|
@@ -134,7 +134,7 @@ async function $do(
|
|
|
134
134
|
|
|
135
135
|
const doResult = await client._do(req, {
|
|
136
136
|
context,
|
|
137
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
137
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
138
138
|
retryConfig: context.retryConfig,
|
|
139
139
|
retryCodes: context.retryCodes,
|
|
140
140
|
});
|
|
@@ -162,7 +162,7 @@ async function $do(
|
|
|
162
162
|
>(
|
|
163
163
|
M.json(201, models.Fee$inboundSchema),
|
|
164
164
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
165
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
165
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
166
166
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
167
167
|
M.fail("4XX"),
|
|
168
168
|
M.fail("5XX"),
|
|
@@ -34,7 +34,7 @@ import { Result } from "../types/fp.js";
|
|
|
34
34
|
* - `hosted_link`: create a new hosted payment link and email it to the customer. The invoice stays unpaid until the customer pays on the link. Each call replaces the previous link. A payment link expires after 30 days; to collect an invoice whose link has expired, call this method again.
|
|
35
35
|
* - `out_of_band`: record a payment that you collected outside Paygentic. The invoice changes to `PAID` immediately. A second call returns 409.
|
|
36
36
|
*
|
|
37
|
-
* For `hosted_link`, an invoice that does not exist returns
|
|
37
|
+
* For `hosted_link`, an invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
38
38
|
*
|
|
39
39
|
* Paygentic selects the payment provider from your connected payment account. The response reports the provider.
|
|
40
40
|
*
|
|
@@ -49,7 +49,7 @@ import { Result } from "../types/fp.js";
|
|
|
49
49
|
*
|
|
50
50
|
* A 500 response has the standard error body, not `retry_payment_result`. It is an internal error, and a retry does not fix it.
|
|
51
51
|
*
|
|
52
|
-
* An invoice that does not exist returns
|
|
52
|
+
* An invoice that does not exist returns 404, the same as an invoice of another merchant.
|
|
53
53
|
*
|
|
54
54
|
* This operation is rate limited to one call each minute for each invoice.
|
|
55
55
|
*/
|
|
@@ -135,7 +135,7 @@ async function $do(
|
|
|
135
135
|
|
|
136
136
|
const doResult = await client._do(req, {
|
|
137
137
|
context,
|
|
138
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
138
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
139
139
|
retryConfig: context.retryConfig,
|
|
140
140
|
retryCodes: context.retryCodes,
|
|
141
141
|
});
|
|
@@ -163,7 +163,7 @@ async function $do(
|
|
|
163
163
|
>(
|
|
164
164
|
M.json(200, models.MerchantIntegration$inboundSchema),
|
|
165
165
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
166
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
166
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
167
167
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
168
168
|
M.fail("4XX"),
|
|
169
169
|
M.fail("5XX"),
|
|
@@ -144,7 +144,7 @@ async function $do(
|
|
|
144
144
|
|
|
145
145
|
const doResult = await client._do(req, {
|
|
146
146
|
context,
|
|
147
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "502", "5XX"],
|
|
147
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "502", "5XX"],
|
|
148
148
|
retryConfig: context.retryConfig,
|
|
149
149
|
retryCodes: context.retryCodes,
|
|
150
150
|
});
|
|
@@ -172,7 +172,7 @@ async function $do(
|
|
|
172
172
|
>(
|
|
173
173
|
M.nil(204, z.void()),
|
|
174
174
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
175
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
175
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
176
176
|
M.jsonErr([500, 502], errors.ErrorT$inboundSchema),
|
|
177
177
|
M.fail("4XX"),
|
|
178
178
|
M.fail("5XX"),
|
|
@@ -134,7 +134,7 @@ async function $do(
|
|
|
134
134
|
|
|
135
135
|
const doResult = await client._do(req, {
|
|
136
136
|
context,
|
|
137
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
137
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
138
138
|
retryConfig: context.retryConfig,
|
|
139
139
|
retryCodes: context.retryCodes,
|
|
140
140
|
});
|
|
@@ -162,7 +162,7 @@ async function $do(
|
|
|
162
162
|
>(
|
|
163
163
|
M.json([200, 201], models.Payment$inboundSchema),
|
|
164
164
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
165
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
165
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
166
166
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
167
167
|
M.fail("4XX"),
|
|
168
168
|
M.fail("5XX"),
|
package/src/funcs/plansCreate.ts
CHANGED
|
@@ -131,7 +131,7 @@ async function $do(
|
|
|
131
131
|
|
|
132
132
|
const doResult = await client._do(req, {
|
|
133
133
|
context,
|
|
134
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
134
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
135
135
|
retryConfig: context.retryConfig,
|
|
136
136
|
retryCodes: context.retryCodes,
|
|
137
137
|
});
|
|
@@ -159,7 +159,7 @@ async function $do(
|
|
|
159
159
|
>(
|
|
160
160
|
M.json(201, models.Plan$inboundSchema),
|
|
161
161
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
162
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
162
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
163
163
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
164
164
|
M.fail("4XX"),
|
|
165
165
|
M.fail("5XX"),
|
|
@@ -131,7 +131,7 @@ async function $do(
|
|
|
131
131
|
|
|
132
132
|
const doResult = await client._do(req, {
|
|
133
133
|
context,
|
|
134
|
-
errorCodes: ["400", "401", "403", "4XX", "500", "5XX"],
|
|
134
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
135
135
|
retryConfig: context.retryConfig,
|
|
136
136
|
retryCodes: context.retryCodes,
|
|
137
137
|
});
|
|
@@ -159,7 +159,7 @@ async function $do(
|
|
|
159
159
|
>(
|
|
160
160
|
M.json(201, models.Product$inboundSchema),
|
|
161
161
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
162
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
162
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
163
163
|
M.jsonErr(500, errors.ErrorT$inboundSchema),
|
|
164
164
|
M.fail("4XX"),
|
|
165
165
|
M.fail("5XX"),
|
|
@@ -132,7 +132,7 @@ async function $do(
|
|
|
132
132
|
|
|
133
133
|
const doResult = await client._do(req, {
|
|
134
134
|
context,
|
|
135
|
-
errorCodes: ["400", "401", "403", "4XX", "5XX"],
|
|
135
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "5XX"],
|
|
136
136
|
retryConfig: context.retryConfig,
|
|
137
137
|
retryCodes: context.retryCodes,
|
|
138
138
|
});
|
|
@@ -158,7 +158,7 @@ async function $do(
|
|
|
158
158
|
| SDKValidationError
|
|
159
159
|
>(
|
|
160
160
|
M.json(201, models.TestClock$inboundSchema),
|
|
161
|
-
M.jsonErr([400, 401, 403], errors.ErrorT$inboundSchema),
|
|
161
|
+
M.jsonErr([400, 401, 403, 404], errors.ErrorT$inboundSchema),
|
|
162
162
|
M.fail("4XX"),
|
|
163
163
|
M.fail("5XX"),
|
|
164
164
|
)(response, req, { extraFields: responseFields });
|
|
@@ -139,7 +139,7 @@ async function $do(
|
|
|
139
139
|
|
|
140
140
|
const doResult = await client._do(req, {
|
|
141
141
|
context,
|
|
142
|
-
errorCodes: ["400", "401", "403", "4XX", "5XX"],
|
|
142
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "5XX"],
|
|
143
143
|
retryConfig: context.retryConfig,
|
|
144
144
|
retryCodes: context.retryCodes,
|
|
145
145
|
});
|
|
@@ -167,7 +167,7 @@ async function $do(
|
|
|
167
167
|
>(
|
|
168
168
|
M.json(201, models.Webhooks$inboundSchema),
|
|
169
169
|
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
170
|
-
M.jsonErr([401, 403], errors.ErrorT$inboundSchema),
|
|
170
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
171
171
|
M.fail("4XX"),
|
|
172
172
|
M.fail("5XX"),
|
|
173
173
|
)(response, req, { extraFields: responseFields });
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* Get Portal Access
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. Returns 404 unless webhooks are enabled.
|
|
33
|
+
* Returns a link to the webhook portal, where you add endpoints, choose event types, read the signing secret and inspect deliveries. The link opens without a login and expires one hour after it is issued, at `expiresAt`. Treat it as a secret. The link is read-only unless the caller holds `webhooks:write`: a read-only portal shows endpoints and deliveries but does not let you add or change endpoints, read the signing secret or replay messages. Returns 404 unless webhooks are enabled.
|
|
34
34
|
*/
|
|
35
35
|
export function webhooksGetPortal(
|
|
36
36
|
client: PaygenticCore,
|
package/src/lib/config.ts
CHANGED
|
@@ -65,7 +65,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
65
65
|
export const SDK_METADATA = {
|
|
66
66
|
language: "typescript",
|
|
67
67
|
openapiDocVersion: "0.1.0",
|
|
68
|
-
sdkVersion: "0.10.
|
|
68
|
+
sdkVersion: "0.10.3",
|
|
69
69
|
genVersion: "2.879.13",
|
|
70
|
-
userAgent: "speakeasy-sdk/typescript 0.10.
|
|
70
|
+
userAgent: "speakeasy-sdk/typescript 0.10.3 2.879.13 0.1.0 @paygentic/sdk",
|
|
71
71
|
} as const;
|