@cimplify/sdk 0.76.0 → 0.79.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/advanced.d.mts +3 -3
- package/dist/advanced.d.ts +3 -3
- package/dist/{chunk-QS4XDVHI.js → chunk-5BPBDWAA.js} +94 -0
- package/dist/{chunk-J7L5LHGK.mjs → chunk-BNA4GW4D.mjs} +34 -11
- package/dist/{chunk-BYWJSPT4.mjs → chunk-FURKCWVG.mjs} +6 -3
- package/dist/{chunk-H337NF4O.mjs → chunk-LBFTEXGD.mjs} +94 -1
- package/dist/{chunk-OGQFDCZM.js → chunk-OSTOGR4F.js} +34 -11
- package/dist/{chunk-Y64AIRGW.js → chunk-T7ALPOK7.js} +8 -5
- package/dist/{client-D7MP5Zi7.d.ts → client-BAzvXSLJ.d.ts} +2 -2
- package/dist/{client-DDWRDb9m.d.mts → client-Byysg2IX.d.mts} +2 -2
- package/dist/{client-CBQJQn7E.d.mts → client-Cn5trGYV.d.ts} +41 -4
- package/dist/{client-ciWgfgLw.d.ts → client-D16qfHAB.d.mts} +41 -4
- package/dist/{index-lt-fe29V.d.mts → index-Bu76UyFz.d.mts} +3 -3
- package/dist/{index-DTGS0QC1.d.ts → index-Moe4cGMB.d.ts} +3 -3
- package/dist/index.d.mts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +13 -9
- package/dist/index.mjs +1 -1
- package/dist/mock/cli.mjs +34 -11
- package/dist/mock/library.js +34 -11
- package/dist/mock/library.mjs +34 -11
- package/dist/mock/msw.js +34 -11
- package/dist/mock/msw.mjs +34 -11
- package/dist/{payment-C-2gApyQ.d.mts → payment-B7qzWdaJ.d.mts} +1 -1
- package/dist/{payment-CfemTORM.d.ts → payment-mVIJIJcq.d.ts} +1 -1
- package/dist/{price-CZBQw-Rh.d.mts → price-BfOaGqjx.d.mts} +1 -1
- package/dist/{price-DNeyoO7y.d.ts → price-CS1IsORZ.d.ts} +1 -1
- package/dist/{product-_GFoaPHU.d.mts → product-BgFOFmQw.d.mts} +7 -0
- package/dist/{product-_GFoaPHU.d.ts → product-BgFOFmQw.d.ts} +7 -0
- package/dist/react.d.mts +18 -5
- package/dist/react.d.ts +18 -5
- package/dist/react.js +22 -3
- package/dist/react.mjs +21 -3
- package/dist/server-BXT62nBC.d.mts +1186 -0
- package/dist/server-BXT62nBC.d.ts +1186 -0
- package/dist/{server-G8I4JtqK.d.mts → server-CGO4zneR.d.mts} +1 -1
- package/dist/{server-1hXIXH2k.d.ts → server-Daq42vK7.d.ts} +1 -1
- package/dist/server.d.mts +4 -4
- package/dist/server.d.ts +4 -4
- package/dist/server.js +2 -2
- package/dist/server.mjs +1 -1
- package/dist/testing/msw.d.mts +2 -2
- package/dist/testing/msw.d.ts +2 -2
- package/dist/testing/msw.js +2 -2
- package/dist/testing/msw.mjs +1 -1
- package/dist/testing/suite.d.mts +6 -6
- package/dist/testing/suite.d.ts +6 -6
- package/dist/testing/suite.js +22 -22
- package/dist/testing/suite.mjs +3 -3
- package/dist/testing.d.mts +20 -5
- package/dist/testing.d.ts +20 -5
- package/dist/testing.js +78 -78
- package/dist/testing.mjs +4 -4
- package/dist/utils.d.mts +4 -4
- package/dist/utils.d.ts +4 -4
- package/package.json +1 -1
package/dist/server.d.mts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ad as CimplifyClient } from './client-
|
|
2
|
-
export { K as CacheOptions, cq as ReadRequestOptions, cM as Result } from './client-
|
|
3
|
-
export { Q as Category, T as CimplifyError, U as Collection, aX as Product, b9 as ProductWithDetails } from './product-
|
|
1
|
+
import { ad as CimplifyClient } from './client-D16qfHAB.mjs';
|
|
2
|
+
export { K as CacheOptions, cq as ReadRequestOptions, cM as Result } from './client-D16qfHAB.mjs';
|
|
3
|
+
export { Q as Category, T as CimplifyError, U as Collection, aX as Product, b9 as ProductWithDetails } from './product-BgFOFmQw.mjs';
|
|
4
4
|
import { JWTVerifyResult } from 'jose';
|
|
5
|
-
import './payment-
|
|
5
|
+
import './payment-B7qzWdaJ.mjs';
|
|
6
6
|
|
|
7
7
|
interface ServerClientOptions {
|
|
8
8
|
/**
|
package/dist/server.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ad as CimplifyClient } from './client-
|
|
2
|
-
export { K as CacheOptions, cq as ReadRequestOptions, cM as Result } from './client-
|
|
3
|
-
export { Q as Category, T as CimplifyError, U as Collection, aX as Product, b9 as ProductWithDetails } from './product-
|
|
1
|
+
import { ad as CimplifyClient } from './client-Cn5trGYV.js';
|
|
2
|
+
export { K as CacheOptions, cq as ReadRequestOptions, cM as Result } from './client-Cn5trGYV.js';
|
|
3
|
+
export { Q as Category, T as CimplifyError, U as Collection, aX as Product, b9 as ProductWithDetails } from './product-BgFOFmQw.js';
|
|
4
4
|
import { JWTVerifyResult } from 'jose';
|
|
5
|
-
import './payment-
|
|
5
|
+
import './payment-mVIJIJcq.js';
|
|
6
6
|
|
|
7
7
|
interface ServerClientOptions {
|
|
8
8
|
/**
|
package/dist/server.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk5BPBDWAA_js = require('./chunk-5BPBDWAA.js');
|
|
4
4
|
var chunkCV5QMDQS_js = require('./chunk-CV5QMDQS.js');
|
|
5
5
|
require('./chunk-7Y2O3E4D.js');
|
|
6
6
|
var chunkXA3ZNR75_js = require('./chunk-XA3ZNR75.js');
|
|
@@ -26,7 +26,7 @@ function readEnv(...keys) {
|
|
|
26
26
|
var getServerClient = react.cache((opts = {}) => {
|
|
27
27
|
const baseUrl = opts.apiUrl ?? readEnv("CIMPLIFY_API_URL", "NEXT_PUBLIC_CIMPLIFY_API_URL") ?? defaultBaseUrl();
|
|
28
28
|
const publicKey = opts.secretKey ?? readEnv("CIMPLIFY_SECRET_KEY", "NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY") ?? "mock-dev";
|
|
29
|
-
const client =
|
|
29
|
+
const client = chunk5BPBDWAA_js.createCimplifyClient({
|
|
30
30
|
baseUrl,
|
|
31
31
|
publicKey,
|
|
32
32
|
suppressPublicKeyWarning: true
|
package/dist/server.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createCimplifyClient } from './chunk-
|
|
1
|
+
import { createCimplifyClient } from './chunk-LBFTEXGD.mjs';
|
|
2
2
|
import { PKCE_COOKIE, decodePkceState, PKCE_COOKIE_PATH, DEFAULT_ISSUER } from './chunk-3BKMNVTR.mjs';
|
|
3
3
|
import './chunk-TD3AY34U.mjs';
|
|
4
4
|
export { CimplifyError } from './chunk-AMZXALF6.mjs';
|
package/dist/testing/msw.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { A as AppHandle, C as CreateAppOptions } from '../server-
|
|
1
|
+
import { A as AppHandle, C as CreateAppOptions } from '../server-CGO4zneR.mjs';
|
|
2
2
|
import 'hono';
|
|
3
|
-
import '../product-
|
|
3
|
+
import '../product-BgFOFmQw.mjs';
|
|
4
4
|
|
|
5
5
|
interface MswHandlerSetup {
|
|
6
6
|
handlers: unknown[];
|
package/dist/testing/msw.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { A as AppHandle, C as CreateAppOptions } from '../server-
|
|
1
|
+
import { A as AppHandle, C as CreateAppOptions } from '../server-Daq42vK7.js';
|
|
2
2
|
import 'hono';
|
|
3
|
-
import '../product-
|
|
3
|
+
import '../product-BgFOFmQw.js';
|
|
4
4
|
|
|
5
5
|
interface MswHandlerSetup {
|
|
6
6
|
handlers: unknown[];
|
package/dist/testing/msw.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkOSTOGR4F_js = require('../chunk-OSTOGR4F.js');
|
|
4
4
|
require('../chunk-XA3ZNR75.js');
|
|
5
5
|
require('../chunk-OWW5GUSB.js');
|
|
6
6
|
|
|
7
7
|
// src/mock/msw.ts
|
|
8
8
|
async function createMswHandlers(options = {}) {
|
|
9
9
|
const baseUrl = options.baseUrl ?? "http://localhost:8787";
|
|
10
|
-
const handle =
|
|
10
|
+
const handle = chunkOSTOGR4F_js.createMockApp(options);
|
|
11
11
|
const msw = await import('msw').catch(() => {
|
|
12
12
|
throw new Error("msw is required to use @cimplify/sdk/mock/msw \u2014 install it as a peer dependency");
|
|
13
13
|
});
|
package/dist/testing/msw.mjs
CHANGED
package/dist/testing/suite.d.mts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { TestAPI } from 'vitest';
|
|
2
|
-
import { T as TestClientHandle } from '../client-
|
|
3
|
-
import { C as CreateAppOptions } from '../server-
|
|
4
|
-
export { S as SeedName } from '../server-
|
|
5
|
-
import '../client-
|
|
6
|
-
import '../product-
|
|
7
|
-
import '../payment-
|
|
2
|
+
import { T as TestClientHandle } from '../client-Byysg2IX.mjs';
|
|
3
|
+
import { C as CreateAppOptions } from '../server-CGO4zneR.mjs';
|
|
4
|
+
export { S as SeedName } from '../server-CGO4zneR.mjs';
|
|
5
|
+
import '../client-D16qfHAB.mjs';
|
|
6
|
+
import '../product-BgFOFmQw.mjs';
|
|
7
|
+
import '../payment-B7qzWdaJ.mjs';
|
|
8
8
|
import 'hono';
|
|
9
9
|
|
|
10
10
|
/**
|
package/dist/testing/suite.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { TestAPI } from 'vitest';
|
|
2
|
-
import { T as TestClientHandle } from '../client-
|
|
3
|
-
import { C as CreateAppOptions } from '../server-
|
|
4
|
-
export { S as SeedName } from '../server-
|
|
5
|
-
import '../client-
|
|
6
|
-
import '../product-
|
|
7
|
-
import '../payment-
|
|
2
|
+
import { T as TestClientHandle } from '../client-BAzvXSLJ.js';
|
|
3
|
+
import { C as CreateAppOptions } from '../server-Daq42vK7.js';
|
|
4
|
+
export { S as SeedName } from '../server-Daq42vK7.js';
|
|
5
|
+
import '../client-Cn5trGYV.js';
|
|
6
|
+
import '../product-BgFOFmQw.js';
|
|
7
|
+
import '../payment-mVIJIJcq.js';
|
|
8
8
|
import 'hono';
|
|
9
9
|
|
|
10
10
|
/**
|
package/dist/testing/suite.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../chunk-
|
|
5
|
-
require('../chunk-
|
|
3
|
+
var chunkT7ALPOK7_js = require('../chunk-T7ALPOK7.js');
|
|
4
|
+
require('../chunk-OSTOGR4F.js');
|
|
5
|
+
require('../chunk-5BPBDWAA.js');
|
|
6
6
|
require('../chunk-CV5QMDQS.js');
|
|
7
7
|
require('../chunk-7Y2O3E4D.js');
|
|
8
8
|
require('../chunk-XA3ZNR75.js');
|
|
@@ -20,11 +20,11 @@ var PLACEHOLDER_PHRASES = [
|
|
|
20
20
|
function createBrandSuite(opts) {
|
|
21
21
|
vitest.describe(opts.label ?? "brand schema", () => {
|
|
22
22
|
vitest.it("conforms to the Cimplify brand contract", () => {
|
|
23
|
-
vitest.expect(() =>
|
|
23
|
+
vitest.expect(() => chunkT7ALPOK7_js.assertBrand(opts.brand)).not.toThrow();
|
|
24
24
|
});
|
|
25
25
|
vitest.it("declares a known mock seed", () => {
|
|
26
26
|
const b = opts.brand;
|
|
27
|
-
vitest.expect(
|
|
27
|
+
vitest.expect(chunkT7ALPOK7_js.SeedNameSchema.safeParse(b.mock?.seed).success).toBe(true);
|
|
28
28
|
});
|
|
29
29
|
vitest.it("has no placeholder copy left in", () => {
|
|
30
30
|
const offenders = [];
|
|
@@ -56,7 +56,7 @@ ${msg}`);
|
|
|
56
56
|
vitest.expect(b.mock?.businessId).toMatch(/^bus_/);
|
|
57
57
|
});
|
|
58
58
|
vitest.it("zod-parses cleanly", () => {
|
|
59
|
-
const result =
|
|
59
|
+
const result = chunkT7ALPOK7_js.BrandSchema.safeParse(opts.brand);
|
|
60
60
|
if (!result.success) {
|
|
61
61
|
throw new Error(
|
|
62
62
|
"Brand schema violations:\n" + result.error.issues.map((i) => ` \u2022 brand.${i.path.join(".")}: ${i.message}`).join("\n")
|
|
@@ -71,23 +71,23 @@ function createCartFlowSuite(opts = {}) {
|
|
|
71
71
|
vitest.describe(opts.label ?? "cart flow against in-process mock", () => {
|
|
72
72
|
let h;
|
|
73
73
|
vitest.beforeEach(() => {
|
|
74
|
-
h =
|
|
74
|
+
h = chunkT7ALPOK7_js.createTestClient(opts);
|
|
75
75
|
});
|
|
76
76
|
vitest.afterEach(() => h.dispose());
|
|
77
77
|
vitest.it("starts with an empty cart matching the canonical shape", async () => {
|
|
78
78
|
const res = await h.client.cart.get();
|
|
79
79
|
vitest.expect(res.ok).toBe(true);
|
|
80
80
|
if (!res.ok) return;
|
|
81
|
-
vitest.expect(() =>
|
|
81
|
+
vitest.expect(() => chunkT7ALPOK7_js.assertCart(res.value)).not.toThrow();
|
|
82
82
|
vitest.expect(res.value.items).toHaveLength(0);
|
|
83
83
|
});
|
|
84
84
|
vitest.it("adds the first product, persists it, and returns a shape-valid cart", async () => {
|
|
85
|
-
const { product, variantId } = await
|
|
85
|
+
const { product, variantId } = await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
86
86
|
vitest.expect(product.id).toBeTruthy();
|
|
87
87
|
const get = await h.client.cart.get();
|
|
88
88
|
vitest.expect(get.ok).toBe(true);
|
|
89
89
|
if (!get.ok) return;
|
|
90
|
-
vitest.expect(() =>
|
|
90
|
+
vitest.expect(() => chunkT7ALPOK7_js.assertCart(get.value)).not.toThrow();
|
|
91
91
|
vitest.expect(get.value.items).toHaveLength(1);
|
|
92
92
|
vitest.expect(get.value.items[0]?.item_id).toBe(product.id);
|
|
93
93
|
if (variantId) {
|
|
@@ -98,8 +98,8 @@ function createCartFlowSuite(opts = {}) {
|
|
|
98
98
|
vitest.expect(parseFloat(String(get.value.pricing.subtotal))).toBeGreaterThan(0);
|
|
99
99
|
});
|
|
100
100
|
vitest.it("dedupes by line_key when adding the same product twice", async () => {
|
|
101
|
-
await
|
|
102
|
-
await
|
|
101
|
+
await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
102
|
+
await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
103
103
|
const res = await h.client.cart.get();
|
|
104
104
|
vitest.expect(res.ok).toBe(true);
|
|
105
105
|
if (!res.ok) return;
|
|
@@ -107,7 +107,7 @@ function createCartFlowSuite(opts = {}) {
|
|
|
107
107
|
vitest.expect(res.value.items[0]?.quantity).toBe(2);
|
|
108
108
|
});
|
|
109
109
|
vitest.it("removes items and zeroes the subtotal", async () => {
|
|
110
|
-
await
|
|
110
|
+
await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
111
111
|
const before = await h.client.cart.get();
|
|
112
112
|
if (!before.ok) throw before.error;
|
|
113
113
|
const itemId = before.value.items[0]?.id;
|
|
@@ -133,28 +133,28 @@ function createContractSuite(opts = {}) {
|
|
|
133
133
|
vitest.describe(opts.label ?? "SDK \u2194 mock contract", () => {
|
|
134
134
|
let h;
|
|
135
135
|
vitest.beforeEach(() => {
|
|
136
|
-
h =
|
|
136
|
+
h = chunkT7ALPOK7_js.createTestClient(opts);
|
|
137
137
|
});
|
|
138
138
|
vitest.afterEach(() => h.dispose());
|
|
139
139
|
vitest.it("AddItemPayload schema accepts a minimal valid body", () => {
|
|
140
|
-
const result =
|
|
140
|
+
const result = chunkT7ALPOK7_js.AddItemPayloadSchema.safeParse({ item_id: "prod_x", quantity: 1 });
|
|
141
141
|
vitest.expect(result.success).toBe(true);
|
|
142
142
|
});
|
|
143
143
|
vitest.it("AddItemPayload schema rejects negative quantity", () => {
|
|
144
|
-
const result =
|
|
144
|
+
const result = chunkT7ALPOK7_js.AddItemPayloadSchema.safeParse({ item_id: "prod_x", quantity: -1 });
|
|
145
145
|
vitest.expect(result.success).toBe(false);
|
|
146
146
|
});
|
|
147
147
|
vitest.it("AddItemPayload schema rejects empty item_id", () => {
|
|
148
|
-
const result =
|
|
148
|
+
const result = chunkT7ALPOK7_js.AddItemPayloadSchema.safeParse({ item_id: "", quantity: 1 });
|
|
149
149
|
vitest.expect(result.success).toBe(false);
|
|
150
150
|
});
|
|
151
151
|
vitest.it("Cart line items returned by the mock match CartItemSchema", async () => {
|
|
152
|
-
const { product } = await
|
|
152
|
+
const { product } = await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
153
153
|
const get = await h.client.cart.get();
|
|
154
154
|
if (!get.ok) throw get.error;
|
|
155
155
|
vitest.expect(get.value.items.length).toBeGreaterThan(0);
|
|
156
156
|
for (const item of get.value.items) {
|
|
157
|
-
const result =
|
|
157
|
+
const result = chunkT7ALPOK7_js.CartItemSchema.safeParse(item);
|
|
158
158
|
if (!result.success) {
|
|
159
159
|
const issues = result.error.issues.map((i) => ` \u2022 ${i.path.join(".")}: ${i.message}`).join("\n");
|
|
160
160
|
throw new Error(`Cart item shape mismatch for ${product.name}:
|
|
@@ -164,19 +164,19 @@ ${issues}`);
|
|
|
164
164
|
}
|
|
165
165
|
});
|
|
166
166
|
vitest.it("CheckoutResponse from the mock includes bill_token", async () => {
|
|
167
|
-
await
|
|
167
|
+
await chunkT7ALPOK7_js.fixtures.addFirstProduct(h.client);
|
|
168
168
|
const cartRes = await h.client.cart.get();
|
|
169
169
|
if (!cartRes.ok) throw cartRes.error;
|
|
170
170
|
const checkout = await h.client.checkout.process({
|
|
171
171
|
cart_id: cartRes.value.id,
|
|
172
|
-
customer:
|
|
172
|
+
customer: chunkT7ALPOK7_js.fixtures.customer(),
|
|
173
173
|
order_type: "delivery",
|
|
174
174
|
payment_method: "mobile_money",
|
|
175
175
|
mobile_money_details: { phone_number: "+233244000000", provider: "mtn" }
|
|
176
176
|
});
|
|
177
177
|
vitest.expect(checkout.ok).toBe(true);
|
|
178
178
|
if (!checkout.ok) return;
|
|
179
|
-
const result =
|
|
179
|
+
const result = chunkT7ALPOK7_js.CheckoutResponseSchema.safeParse(checkout.value);
|
|
180
180
|
if (!result.success) {
|
|
181
181
|
const issues = result.error.issues.map((i) => ` \u2022 ${i.path.join(".")}: ${i.message}`).join("\n");
|
|
182
182
|
throw new Error(`CheckoutResponse shape mismatch:
|
package/dist/testing/suite.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { assertBrand, SeedNameSchema, BrandSchema, createTestClient, assertCart, fixtures, AddItemPayloadSchema, CartItemSchema, CheckoutResponseSchema } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
import '../chunk-
|
|
1
|
+
import { assertBrand, SeedNameSchema, BrandSchema, createTestClient, assertCart, fixtures, AddItemPayloadSchema, CartItemSchema, CheckoutResponseSchema } from '../chunk-FURKCWVG.mjs';
|
|
2
|
+
import '../chunk-BNA4GW4D.mjs';
|
|
3
|
+
import '../chunk-LBFTEXGD.mjs';
|
|
4
4
|
import '../chunk-3BKMNVTR.mjs';
|
|
5
5
|
import '../chunk-TD3AY34U.mjs';
|
|
6
6
|
import '../chunk-AMZXALF6.mjs';
|
package/dist/testing.d.mts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { $ZodType } from 'zod/v4/core';
|
|
3
|
-
export { A as AddFirstProductOptions, a as AddFirstProductResult, P as ProductSummary, T as TestClientHandle, c as createTestClient, f as fixtures } from './client-
|
|
4
|
-
import './client-
|
|
5
|
-
import './product-
|
|
6
|
-
import './payment-
|
|
7
|
-
import './server-
|
|
3
|
+
export { A as AddFirstProductOptions, a as AddFirstProductResult, P as ProductSummary, T as TestClientHandle, c as createTestClient, f as fixtures } from './client-Byysg2IX.mjs';
|
|
4
|
+
import './client-D16qfHAB.mjs';
|
|
5
|
+
import './product-BgFOFmQw.mjs';
|
|
6
|
+
import './payment-B7qzWdaJ.mjs';
|
|
7
|
+
import './server-CGO4zneR.mjs';
|
|
8
8
|
import 'hono';
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -1065,6 +1065,9 @@ declare const CartPricingSchema: z.ZodObject<{
|
|
|
1065
1065
|
currency: z.ZodString;
|
|
1066
1066
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1067
1067
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1068
|
+
tax_inclusive: z.ZodBoolean;
|
|
1069
|
+
deposit_required: z.ZodBoolean;
|
|
1070
|
+
deposit_amount: z.ZodString;
|
|
1068
1071
|
}, z.core.$strip>;
|
|
1069
1072
|
declare const CartSchema: z.ZodObject<{
|
|
1070
1073
|
id: z.ZodString;
|
|
@@ -1223,6 +1226,9 @@ declare const CartSchema: z.ZodObject<{
|
|
|
1223
1226
|
currency: z.ZodString;
|
|
1224
1227
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1225
1228
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1229
|
+
tax_inclusive: z.ZodBoolean;
|
|
1230
|
+
deposit_required: z.ZodBoolean;
|
|
1231
|
+
deposit_amount: z.ZodString;
|
|
1226
1232
|
}, z.core.$strip>;
|
|
1227
1233
|
customer_info: z.ZodObject<{
|
|
1228
1234
|
name: z.ZodString;
|
|
@@ -1386,6 +1392,9 @@ declare const assertCart: (value: unknown) => asserts value is {
|
|
|
1386
1392
|
service_charge: string;
|
|
1387
1393
|
total_price: string;
|
|
1388
1394
|
currency: string;
|
|
1395
|
+
tax_inclusive: boolean;
|
|
1396
|
+
deposit_required: boolean;
|
|
1397
|
+
deposit_amount: string;
|
|
1389
1398
|
tax_rate?: string | undefined;
|
|
1390
1399
|
service_charge_rate?: string | undefined;
|
|
1391
1400
|
};
|
|
@@ -1932,6 +1941,9 @@ declare const PUBLIC_SCHEMAS: {
|
|
|
1932
1941
|
currency: z.ZodString;
|
|
1933
1942
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1934
1943
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1944
|
+
tax_inclusive: z.ZodBoolean;
|
|
1945
|
+
deposit_required: z.ZodBoolean;
|
|
1946
|
+
deposit_amount: z.ZodString;
|
|
1935
1947
|
}, z.core.$strip>;
|
|
1936
1948
|
customer_info: z.ZodObject<{
|
|
1937
1949
|
name: z.ZodString;
|
|
@@ -2100,6 +2112,9 @@ declare const PUBLIC_SCHEMAS: {
|
|
|
2100
2112
|
currency: z.ZodString;
|
|
2101
2113
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
2102
2114
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
2115
|
+
tax_inclusive: z.ZodBoolean;
|
|
2116
|
+
deposit_required: z.ZodBoolean;
|
|
2117
|
+
deposit_amount: z.ZodString;
|
|
2103
2118
|
}, z.core.$strip>;
|
|
2104
2119
|
readonly CheckoutBody: z.ZodObject<{
|
|
2105
2120
|
cart_id: z.ZodString;
|
package/dist/testing.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { $ZodType } from 'zod/v4/core';
|
|
3
|
-
export { A as AddFirstProductOptions, a as AddFirstProductResult, P as ProductSummary, T as TestClientHandle, c as createTestClient, f as fixtures } from './client-
|
|
4
|
-
import './client-
|
|
5
|
-
import './product-
|
|
6
|
-
import './payment-
|
|
7
|
-
import './server-
|
|
3
|
+
export { A as AddFirstProductOptions, a as AddFirstProductResult, P as ProductSummary, T as TestClientHandle, c as createTestClient, f as fixtures } from './client-BAzvXSLJ.js';
|
|
4
|
+
import './client-Cn5trGYV.js';
|
|
5
|
+
import './product-BgFOFmQw.js';
|
|
6
|
+
import './payment-mVIJIJcq.js';
|
|
7
|
+
import './server-Daq42vK7.js';
|
|
8
8
|
import 'hono';
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -1065,6 +1065,9 @@ declare const CartPricingSchema: z.ZodObject<{
|
|
|
1065
1065
|
currency: z.ZodString;
|
|
1066
1066
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1067
1067
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1068
|
+
tax_inclusive: z.ZodBoolean;
|
|
1069
|
+
deposit_required: z.ZodBoolean;
|
|
1070
|
+
deposit_amount: z.ZodString;
|
|
1068
1071
|
}, z.core.$strip>;
|
|
1069
1072
|
declare const CartSchema: z.ZodObject<{
|
|
1070
1073
|
id: z.ZodString;
|
|
@@ -1223,6 +1226,9 @@ declare const CartSchema: z.ZodObject<{
|
|
|
1223
1226
|
currency: z.ZodString;
|
|
1224
1227
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1225
1228
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1229
|
+
tax_inclusive: z.ZodBoolean;
|
|
1230
|
+
deposit_required: z.ZodBoolean;
|
|
1231
|
+
deposit_amount: z.ZodString;
|
|
1226
1232
|
}, z.core.$strip>;
|
|
1227
1233
|
customer_info: z.ZodObject<{
|
|
1228
1234
|
name: z.ZodString;
|
|
@@ -1386,6 +1392,9 @@ declare const assertCart: (value: unknown) => asserts value is {
|
|
|
1386
1392
|
service_charge: string;
|
|
1387
1393
|
total_price: string;
|
|
1388
1394
|
currency: string;
|
|
1395
|
+
tax_inclusive: boolean;
|
|
1396
|
+
deposit_required: boolean;
|
|
1397
|
+
deposit_amount: string;
|
|
1389
1398
|
tax_rate?: string | undefined;
|
|
1390
1399
|
service_charge_rate?: string | undefined;
|
|
1391
1400
|
};
|
|
@@ -1932,6 +1941,9 @@ declare const PUBLIC_SCHEMAS: {
|
|
|
1932
1941
|
currency: z.ZodString;
|
|
1933
1942
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
1934
1943
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
1944
|
+
tax_inclusive: z.ZodBoolean;
|
|
1945
|
+
deposit_required: z.ZodBoolean;
|
|
1946
|
+
deposit_amount: z.ZodString;
|
|
1935
1947
|
}, z.core.$strip>;
|
|
1936
1948
|
customer_info: z.ZodObject<{
|
|
1937
1949
|
name: z.ZodString;
|
|
@@ -2100,6 +2112,9 @@ declare const PUBLIC_SCHEMAS: {
|
|
|
2100
2112
|
currency: z.ZodString;
|
|
2101
2113
|
tax_rate: z.ZodOptional<z.ZodString>;
|
|
2102
2114
|
service_charge_rate: z.ZodOptional<z.ZodString>;
|
|
2115
|
+
tax_inclusive: z.ZodBoolean;
|
|
2116
|
+
deposit_required: z.ZodBoolean;
|
|
2117
|
+
deposit_amount: z.ZodString;
|
|
2103
2118
|
}, z.core.$strip>;
|
|
2104
2119
|
readonly CheckoutBody: z.ZodObject<{
|
|
2105
2120
|
cart_id: z.ZodString;
|