@gigapay-dev/contracts 2.0.0 → 3.0.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/build/domains/admin/index.d.ts +150 -0
- package/build/domains/admin/index.d.ts.map +1 -0
- package/build/domains/admin/index.js +72 -0
- package/build/domains/admin/index.js.map +1 -0
- package/build/domains/auth/commands.d.ts +294 -0
- package/build/domains/auth/commands.d.ts.map +1 -0
- package/build/domains/auth/commands.js +116 -0
- package/build/domains/auth/commands.js.map +1 -0
- package/build/domains/auth/dtos.d.ts +37 -0
- package/build/domains/auth/dtos.d.ts.map +1 -0
- package/build/domains/auth/dtos.js +26 -0
- package/build/domains/auth/dtos.js.map +1 -0
- package/build/domains/auth/events.d.ts +35 -0
- package/build/domains/auth/events.d.ts.map +1 -0
- package/build/domains/auth/events.js +24 -0
- package/build/domains/auth/events.js.map +1 -0
- package/build/domains/auth/index.d.ts +165 -0
- package/build/domains/auth/index.d.ts.map +1 -0
- package/build/{commands/products → domains/auth}/index.js +11 -6
- package/build/domains/auth/index.js.map +1 -0
- package/build/domains/auth/queries.d.ts +75 -0
- package/build/domains/auth/queries.d.ts.map +1 -0
- package/build/domains/auth/queries.js +25 -0
- package/build/domains/auth/queries.js.map +1 -0
- package/build/domains/catalog/commands.d.ts +255 -0
- package/build/domains/catalog/commands.d.ts.map +1 -0
- package/build/domains/catalog/commands.js +82 -0
- package/build/domains/catalog/commands.js.map +1 -0
- package/build/domains/catalog/dtos.d.ts +89 -0
- package/build/domains/catalog/dtos.d.ts.map +1 -0
- package/build/domains/catalog/dtos.js +43 -0
- package/build/domains/catalog/dtos.js.map +1 -0
- package/build/domains/catalog/index.d.ts +194 -0
- package/build/domains/catalog/index.d.ts.map +1 -0
- package/build/{commands/payment-methods → domains/catalog}/index.js +10 -4
- package/build/domains/catalog/index.js.map +1 -0
- package/build/domains/catalog/queries.d.ts +168 -0
- package/build/domains/catalog/queries.d.ts.map +1 -0
- package/build/domains/catalog/queries.js +29 -0
- package/build/domains/catalog/queries.js.map +1 -0
- package/build/domains/config/index.d.ts +40 -0
- package/build/domains/config/index.d.ts.map +1 -0
- package/build/domains/config/index.js +18 -0
- package/build/domains/config/index.js.map +1 -0
- package/build/domains/orders/commands.d.ts +262 -0
- package/build/domains/orders/commands.d.ts.map +1 -0
- package/build/domains/orders/commands.js +47 -0
- package/build/domains/orders/commands.js.map +1 -0
- package/build/domains/orders/dtos.d.ts +112 -0
- package/build/domains/orders/dtos.d.ts.map +1 -0
- package/build/domains/orders/dtos.js +44 -0
- package/build/domains/orders/dtos.js.map +1 -0
- package/build/domains/orders/events.d.ts +21 -0
- package/build/domains/orders/events.d.ts.map +1 -0
- package/build/domains/orders/events.js +19 -0
- package/build/domains/orders/events.js.map +1 -0
- package/build/domains/orders/index.d.ts +381 -0
- package/build/domains/orders/index.d.ts.map +1 -0
- package/build/domains/orders/index.js +28 -0
- package/build/domains/orders/index.js.map +1 -0
- package/build/domains/orders/queries.d.ts +532 -0
- package/build/domains/orders/queries.d.ts.map +1 -0
- package/build/domains/orders/queries.js +40 -0
- package/build/domains/orders/queries.js.map +1 -0
- package/build/domains/payments/index.d.ts +96 -0
- package/build/domains/payments/index.d.ts.map +1 -0
- package/build/domains/payments/index.js +34 -0
- package/build/domains/payments/index.js.map +1 -0
- package/build/domains/products/commands.d.ts +302 -0
- package/build/domains/products/commands.d.ts.map +1 -0
- package/build/domains/products/commands.js +101 -0
- package/build/domains/products/commands.js.map +1 -0
- package/build/domains/products/dtos.d.ts +122 -0
- package/build/domains/products/dtos.d.ts.map +1 -0
- package/build/domains/products/dtos.js +54 -0
- package/build/domains/products/dtos.js.map +1 -0
- package/build/domains/products/index.d.ts +276 -0
- package/build/domains/products/index.d.ts.map +1 -0
- package/build/{commands/auth → domains/products}/index.js +10 -6
- package/build/domains/products/index.js.map +1 -0
- package/build/domains/products/queries.d.ts +334 -0
- package/build/domains/products/queries.d.ts.map +1 -0
- package/build/domains/products/queries.js +41 -0
- package/build/domains/products/queries.js.map +1 -0
- package/build/domains/promo-codes/index.d.ts +92 -0
- package/build/domains/promo-codes/index.d.ts.map +1 -0
- package/build/domains/promo-codes/index.js +40 -0
- package/build/domains/promo-codes/index.js.map +1 -0
- package/build/domains/stats/index.d.ts +274 -0
- package/build/domains/stats/index.d.ts.map +1 -0
- package/build/domains/stats/index.js +76 -0
- package/build/domains/stats/index.js.map +1 -0
- package/build/domains/users/dtos.d.ts +9 -0
- package/build/domains/users/dtos.d.ts.map +1 -0
- package/build/domains/users/dtos.js +11 -0
- package/build/domains/users/dtos.js.map +1 -0
- package/build/domains/users/index.d.ts +101 -0
- package/build/domains/users/index.d.ts.map +1 -0
- package/build/domains/users/index.js +52 -0
- package/build/domains/users/index.js.map +1 -0
- package/build/index.d.ts +1309 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js +34 -1
- package/build/index.js.map +1 -1
- package/build/shared/api-response.d.ts +17 -0
- package/build/shared/api-response.d.ts.map +1 -0
- package/build/shared/api-response.js +22 -0
- package/build/shared/api-response.js.map +1 -0
- package/build/shared/common.d.ts +14 -0
- package/build/shared/common.d.ts.map +1 -0
- package/build/shared/common.js +8 -0
- package/build/shared/common.js.map +1 -0
- package/build/shared/errors.d.ts +34 -0
- package/build/shared/errors.d.ts.map +1 -0
- package/build/shared/errors.js +36 -0
- package/build/shared/errors.js.map +1 -0
- package/build/shared/index.d.ts +7 -0
- package/build/shared/index.d.ts.map +1 -0
- package/build/{commands/orders → shared}/index.js +6 -6
- package/build/shared/index.js.map +1 -0
- package/build/shared/money.d.ts +32 -0
- package/build/shared/money.d.ts.map +1 -0
- package/build/shared/money.js +20 -0
- package/build/shared/money.js.map +1 -0
- package/build/shared/pagination.d.ts +27 -0
- package/build/shared/pagination.d.ts.map +1 -0
- package/build/{commands/common.js → shared/pagination.js} +2 -9
- package/build/shared/pagination.js.map +1 -0
- package/build/shared/types.d.ts +20 -0
- package/build/shared/types.d.ts.map +1 -0
- package/build/shared/types.js.map +1 -0
- package/package.json +43 -48
- package/build/client.d.ts +0 -934
- package/build/client.d.ts.map +0 -1
- package/build/client.js +0 -184
- package/build/client.js.map +0 -1
- package/build/commands/api-response.d.ts +0 -19
- package/build/commands/api-response.d.ts.map +0 -1
- package/build/commands/api-response.js +0 -14
- package/build/commands/api-response.js.map +0 -1
- package/build/commands/auth/confirm.d.ts +0 -12
- package/build/commands/auth/confirm.d.ts.map +0 -1
- package/build/commands/auth/confirm.js +0 -12
- package/build/commands/auth/confirm.js.map +0 -1
- package/build/commands/auth/endpoints.d.ts +0 -115
- package/build/commands/auth/endpoints.d.ts.map +0 -1
- package/build/commands/auth/endpoints.js +0 -51
- package/build/commands/auth/endpoints.js.map +0 -1
- package/build/commands/auth/index.d.ts +0 -7
- package/build/commands/auth/index.d.ts.map +0 -1
- package/build/commands/auth/index.js.map +0 -1
- package/build/commands/auth/login.d.ts +0 -21
- package/build/commands/auth/login.d.ts.map +0 -1
- package/build/commands/auth/login.js +0 -12
- package/build/commands/auth/login.js.map +0 -1
- package/build/commands/auth/profile.d.ts +0 -19
- package/build/commands/auth/profile.d.ts.map +0 -1
- package/build/commands/auth/profile.js +0 -11
- package/build/commands/auth/profile.js.map +0 -1
- package/build/commands/auth/register.d.ts +0 -13
- package/build/commands/auth/register.d.ts.map +0 -1
- package/build/commands/auth/register.js +0 -12
- package/build/commands/auth/register.js.map +0 -1
- package/build/commands/auth/reset.d.ts +0 -13
- package/build/commands/auth/reset.d.ts.map +0 -1
- package/build/commands/auth/reset.js +0 -10
- package/build/commands/auth/reset.js.map +0 -1
- package/build/commands/common.d.ts +0 -65
- package/build/commands/common.d.ts.map +0 -1
- package/build/commands/common.js.map +0 -1
- package/build/commands/consts.d.ts +0 -2
- package/build/commands/consts.d.ts.map +0 -1
- package/build/commands/consts.js +0 -5
- package/build/commands/consts.js.map +0 -1
- package/build/commands/endpoints.d.ts +0 -4643
- package/build/commands/endpoints.d.ts.map +0 -1
- package/build/commands/endpoints.js +0 -26
- package/build/commands/endpoints.js.map +0 -1
- package/build/commands/index.d.ts +0 -16
- package/build/commands/index.d.ts.map +0 -1
- package/build/commands/index.js +0 -32
- package/build/commands/index.js.map +0 -1
- package/build/commands/orders/create.d.ts +0 -100
- package/build/commands/orders/create.d.ts.map +0 -1
- package/build/commands/orders/create.js +0 -43
- package/build/commands/orders/create.js.map +0 -1
- package/build/commands/orders/endpoints.d.ts +0 -742
- package/build/commands/orders/endpoints.d.ts.map +0 -1
- package/build/commands/orders/endpoints.js +0 -48
- package/build/commands/orders/endpoints.js.map +0 -1
- package/build/commands/orders/enums.d.ts +0 -8
- package/build/commands/orders/enums.d.ts.map +0 -1
- package/build/commands/orders/enums.js +0 -26
- package/build/commands/orders/enums.js.map +0 -1
- package/build/commands/orders/index.d.ts +0 -7
- package/build/commands/orders/index.d.ts.map +0 -1
- package/build/commands/orders/index.js.map +0 -1
- package/build/commands/orders/query.d.ts +0 -104
- package/build/commands/orders/query.d.ts.map +0 -1
- package/build/commands/orders/query.js +0 -46
- package/build/commands/orders/query.js.map +0 -1
- package/build/commands/orders/read.d.ts +0 -235
- package/build/commands/orders/read.d.ts.map +0 -1
- package/build/commands/orders/read.js +0 -84
- package/build/commands/orders/read.js.map +0 -1
- package/build/commands/orders/update.d.ts +0 -24
- package/build/commands/orders/update.d.ts.map +0 -1
- package/build/commands/orders/update.js +0 -17
- package/build/commands/orders/update.js.map +0 -1
- package/build/commands/pagination.d.ts +0 -13
- package/build/commands/pagination.d.ts.map +0 -1
- package/build/commands/pagination.js +0 -9
- package/build/commands/pagination.js.map +0 -1
- package/build/commands/payment-methods/create.d.ts +0 -46
- package/build/commands/payment-methods/create.d.ts.map +0 -1
- package/build/commands/payment-methods/create.js +0 -23
- package/build/commands/payment-methods/create.js.map +0 -1
- package/build/commands/payment-methods/endpoints.d.ts +0 -537
- package/build/commands/payment-methods/endpoints.d.ts.map +0 -1
- package/build/commands/payment-methods/endpoints.js +0 -64
- package/build/commands/payment-methods/endpoints.js.map +0 -1
- package/build/commands/payment-methods/index.d.ts +0 -5
- package/build/commands/payment-methods/index.d.ts.map +0 -1
- package/build/commands/payment-methods/index.js.map +0 -1
- package/build/commands/payment-methods/read.d.ts +0 -72
- package/build/commands/payment-methods/read.d.ts.map +0 -1
- package/build/commands/payment-methods/read.js +0 -29
- package/build/commands/payment-methods/read.js.map +0 -1
- package/build/commands/payment-methods/update.d.ts +0 -46
- package/build/commands/payment-methods/update.d.ts.map +0 -1
- package/build/commands/payment-methods/update.js +0 -20
- package/build/commands/payment-methods/update.js.map +0 -1
- package/build/commands/products/create.d.ts +0 -242
- package/build/commands/products/create.d.ts.map +0 -1
- package/build/commands/products/create.js +0 -129
- package/build/commands/products/create.js.map +0 -1
- package/build/commands/products/endpoints.d.ts +0 -1980
- package/build/commands/products/endpoints.d.ts.map +0 -1
- package/build/commands/products/endpoints.js +0 -100
- package/build/commands/products/endpoints.js.map +0 -1
- package/build/commands/products/enums.d.ts +0 -20
- package/build/commands/products/enums.d.ts.map +0 -1
- package/build/commands/products/enums.js +0 -28
- package/build/commands/products/enums.js.map +0 -1
- package/build/commands/products/index.d.ts +0 -7
- package/build/commands/products/index.d.ts.map +0 -1
- package/build/commands/products/index.js.map +0 -1
- package/build/commands/products/query.d.ts +0 -80
- package/build/commands/products/query.d.ts.map +0 -1
- package/build/commands/products/query.js +0 -56
- package/build/commands/products/query.js.map +0 -1
- package/build/commands/products/read.d.ts +0 -1233
- package/build/commands/products/read.d.ts.map +0 -1
- package/build/commands/products/read.js +0 -242
- package/build/commands/products/read.js.map +0 -1
- package/build/commands/products/update.d.ts +0 -85
- package/build/commands/products/update.d.ts.map +0 -1
- package/build/commands/products/update.js +0 -11
- package/build/commands/products/update.js.map +0 -1
- package/build/commands/promocode-activations/create.d.ts +0 -19
- package/build/commands/promocode-activations/create.d.ts.map +0 -1
- package/build/commands/promocode-activations/create.js +0 -11
- package/build/commands/promocode-activations/create.js.map +0 -1
- package/build/commands/promocode-activations/endpoints.d.ts +0 -158
- package/build/commands/promocode-activations/endpoints.d.ts.map +0 -1
- package/build/commands/promocode-activations/endpoints.js +0 -39
- package/build/commands/promocode-activations/endpoints.js.map +0 -1
- package/build/commands/promocode-activations/index.d.ts +0 -5
- package/build/commands/promocode-activations/index.d.ts.map +0 -1
- package/build/commands/promocode-activations/index.js +0 -21
- package/build/commands/promocode-activations/index.js.map +0 -1
- package/build/commands/promocode-activations/read.d.ts +0 -22
- package/build/commands/promocode-activations/read.d.ts.map +0 -1
- package/build/commands/promocode-activations/read.js +0 -15
- package/build/commands/promocode-activations/read.js.map +0 -1
- package/build/commands/promocode-activations/update.d.ts +0 -19
- package/build/commands/promocode-activations/update.d.ts.map +0 -1
- package/build/commands/promocode-activations/update.js +0 -11
- package/build/commands/promocode-activations/update.js.map +0 -1
- package/build/commands/promocodes/create.d.ts +0 -40
- package/build/commands/promocodes/create.d.ts.map +0 -1
- package/build/commands/promocodes/create.js +0 -19
- package/build/commands/promocodes/create.js.map +0 -1
- package/build/commands/promocodes/endpoints.d.ts +0 -354
- package/build/commands/promocodes/endpoints.d.ts.map +0 -1
- package/build/commands/promocodes/endpoints.js +0 -47
- package/build/commands/promocodes/endpoints.js.map +0 -1
- package/build/commands/promocodes/enums.d.ts +0 -6
- package/build/commands/promocodes/enums.d.ts.map +0 -1
- package/build/commands/promocodes/enums.js +0 -10
- package/build/commands/promocodes/enums.js.map +0 -1
- package/build/commands/promocodes/index.d.ts +0 -6
- package/build/commands/promocodes/index.d.ts.map +0 -1
- package/build/commands/promocodes/index.js +0 -22
- package/build/commands/promocodes/index.js.map +0 -1
- package/build/commands/promocodes/read.d.ts +0 -46
- package/build/commands/promocodes/read.d.ts.map +0 -1
- package/build/commands/promocodes/read.js +0 -24
- package/build/commands/promocodes/read.js.map +0 -1
- package/build/commands/promocodes/update.d.ts +0 -34
- package/build/commands/promocodes/update.d.ts.map +0 -1
- package/build/commands/promocodes/update.js +0 -17
- package/build/commands/promocodes/update.js.map +0 -1
- package/build/commands/refresh-sessions/create.d.ts +0 -25
- package/build/commands/refresh-sessions/create.d.ts.map +0 -1
- package/build/commands/refresh-sessions/create.js +0 -14
- package/build/commands/refresh-sessions/create.js.map +0 -1
- package/build/commands/refresh-sessions/endpoints.d.ts +0 -216
- package/build/commands/refresh-sessions/endpoints.d.ts.map +0 -1
- package/build/commands/refresh-sessions/endpoints.js +0 -47
- package/build/commands/refresh-sessions/endpoints.js.map +0 -1
- package/build/commands/refresh-sessions/enums.d.ts +0 -4
- package/build/commands/refresh-sessions/enums.d.ts.map +0 -1
- package/build/commands/refresh-sessions/enums.js +0 -9
- package/build/commands/refresh-sessions/enums.js.map +0 -1
- package/build/commands/refresh-sessions/index.d.ts +0 -6
- package/build/commands/refresh-sessions/index.d.ts.map +0 -1
- package/build/commands/refresh-sessions/index.js +0 -22
- package/build/commands/refresh-sessions/index.js.map +0 -1
- package/build/commands/refresh-sessions/read.d.ts +0 -28
- package/build/commands/refresh-sessions/read.d.ts.map +0 -1
- package/build/commands/refresh-sessions/read.js +0 -18
- package/build/commands/refresh-sessions/read.js.map +0 -1
- package/build/commands/refresh-sessions/update.d.ts +0 -25
- package/build/commands/refresh-sessions/update.d.ts.map +0 -1
- package/build/commands/refresh-sessions/update.js +0 -17
- package/build/commands/refresh-sessions/update.js.map +0 -1
- package/build/commands/settings/endpoints.d.ts +0 -109
- package/build/commands/settings/endpoints.d.ts.map +0 -1
- package/build/commands/settings/endpoints.js +0 -44
- package/build/commands/settings/endpoints.js.map +0 -1
- package/build/commands/settings/index.d.ts +0 -4
- package/build/commands/settings/index.d.ts.map +0 -1
- package/build/commands/settings/index.js +0 -20
- package/build/commands/settings/index.js.map +0 -1
- package/build/commands/settings/read.d.ts +0 -19
- package/build/commands/settings/read.d.ts.map +0 -1
- package/build/commands/settings/read.js +0 -11
- package/build/commands/settings/read.js.map +0 -1
- package/build/commands/settings/update.d.ts +0 -19
- package/build/commands/settings/update.d.ts.map +0 -1
- package/build/commands/settings/update.js +0 -11
- package/build/commands/settings/update.js.map +0 -1
- package/build/commands/stats/endpoints.d.ts +0 -68
- package/build/commands/stats/endpoints.d.ts.map +0 -1
- package/build/commands/stats/endpoints.js +0 -14
- package/build/commands/stats/endpoints.js.map +0 -1
- package/build/commands/stats/index.d.ts +0 -4
- package/build/commands/stats/index.d.ts.map +0 -1
- package/build/commands/stats/index.js +0 -20
- package/build/commands/stats/index.js.map +0 -1
- package/build/commands/stats/query.d.ts +0 -32
- package/build/commands/stats/query.d.ts.map +0 -1
- package/build/commands/stats/query.js +0 -16
- package/build/commands/stats/query.js.map +0 -1
- package/build/commands/stats/read.d.ts +0 -31
- package/build/commands/stats/read.d.ts.map +0 -1
- package/build/commands/stats/read.js +0 -18
- package/build/commands/stats/read.js.map +0 -1
- package/build/commands/users/create.d.ts +0 -43
- package/build/commands/users/create.d.ts.map +0 -1
- package/build/commands/users/create.js +0 -20
- package/build/commands/users/create.js.map +0 -1
- package/build/commands/users/endpoints.d.ts +0 -404
- package/build/commands/users/endpoints.d.ts.map +0 -1
- package/build/commands/users/endpoints.js +0 -40
- package/build/commands/users/endpoints.js.map +0 -1
- package/build/commands/users/enums.d.ts +0 -7
- package/build/commands/users/enums.d.ts.map +0 -1
- package/build/commands/users/enums.js +0 -11
- package/build/commands/users/enums.js.map +0 -1
- package/build/commands/users/index.d.ts +0 -7
- package/build/commands/users/index.d.ts.map +0 -1
- package/build/commands/users/index.js +0 -23
- package/build/commands/users/index.js.map +0 -1
- package/build/commands/users/query.d.ts +0 -53
- package/build/commands/users/query.d.ts.map +0 -1
- package/build/commands/users/query.js +0 -22
- package/build/commands/users/query.js.map +0 -1
- package/build/commands/users/read.d.ts +0 -61
- package/build/commands/users/read.d.ts.map +0 -1
- package/build/commands/users/read.js +0 -29
- package/build/commands/users/read.js.map +0 -1
- package/build/commands/users/update.d.ts +0 -43
- package/build/commands/users/update.d.ts.map +0 -1
- package/build/commands/users/update.js +0 -20
- package/build/commands/users/update.js.map +0 -1
- package/build/types.d.ts +0 -9
- package/build/types.d.ts.map +0 -1
- package/build/types.js.map +0 -1
- /package/build/{types.js → shared/types.js} +0 -0
|
@@ -0,0 +1,532 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const GetOrderByIdEndpoint: {
|
|
3
|
+
readonly method: "GET";
|
|
4
|
+
readonly path: "/api/orders/:id";
|
|
5
|
+
readonly params: z.ZodObject<{
|
|
6
|
+
id: z.ZodCoercedNumber<unknown>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
readonly response: z.ZodObject<{
|
|
9
|
+
id: z.ZodNumber;
|
|
10
|
+
email: z.ZodString;
|
|
11
|
+
displayCurrency: z.ZodEnum<{
|
|
12
|
+
USD: "USD";
|
|
13
|
+
RUB: "RUB";
|
|
14
|
+
UAH: "UAH";
|
|
15
|
+
}>;
|
|
16
|
+
subtotal: z.ZodObject<{
|
|
17
|
+
usd: z.ZodString;
|
|
18
|
+
rub: z.ZodString;
|
|
19
|
+
uah: z.ZodString;
|
|
20
|
+
}, z.core.$strip>;
|
|
21
|
+
discount: z.ZodObject<{
|
|
22
|
+
usd: z.ZodString;
|
|
23
|
+
rub: z.ZodString;
|
|
24
|
+
uah: z.ZodString;
|
|
25
|
+
}, z.core.$strip>;
|
|
26
|
+
total: z.ZodObject<{
|
|
27
|
+
usd: z.ZodString;
|
|
28
|
+
rub: z.ZodString;
|
|
29
|
+
uah: z.ZodString;
|
|
30
|
+
}, z.core.$strip>;
|
|
31
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
32
|
+
source: z.ZodEnum<{
|
|
33
|
+
dessly: "dessly";
|
|
34
|
+
cbr: "cbr";
|
|
35
|
+
nbu: "nbu";
|
|
36
|
+
cache: "cache";
|
|
37
|
+
fallback: "fallback";
|
|
38
|
+
mixed: "mixed";
|
|
39
|
+
}>;
|
|
40
|
+
fetchedAt: z.ZodString;
|
|
41
|
+
rates: z.ZodObject<{
|
|
42
|
+
usdRub: z.ZodString;
|
|
43
|
+
usdUah: z.ZodString;
|
|
44
|
+
}, z.core.$strip>;
|
|
45
|
+
}, z.core.$strip>;
|
|
46
|
+
status: z.ZodEnum<{
|
|
47
|
+
PENDING: "PENDING";
|
|
48
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
49
|
+
PAID: "PAID";
|
|
50
|
+
PROCESSING: "PROCESSING";
|
|
51
|
+
SUCCESS: "SUCCESS";
|
|
52
|
+
FAILED: "FAILED";
|
|
53
|
+
REFUNDED: "REFUNDED";
|
|
54
|
+
CANCELLED: "CANCELLED";
|
|
55
|
+
}>;
|
|
56
|
+
items: z.ZodArray<z.ZodObject<{
|
|
57
|
+
id: z.ZodNumber;
|
|
58
|
+
productId: z.ZodNumber;
|
|
59
|
+
variantId: z.ZodNumber;
|
|
60
|
+
quantity: z.ZodNumber;
|
|
61
|
+
price: z.ZodObject<{
|
|
62
|
+
usd: z.ZodString;
|
|
63
|
+
rub: z.ZodString;
|
|
64
|
+
uah: z.ZodString;
|
|
65
|
+
}, z.core.$strip>;
|
|
66
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
67
|
+
status: z.ZodEnum<{
|
|
68
|
+
PENDING: "PENDING";
|
|
69
|
+
PROCESSING: "PROCESSING";
|
|
70
|
+
FAILED: "FAILED";
|
|
71
|
+
REFUNDED: "REFUNDED";
|
|
72
|
+
DELIVERED: "DELIVERED";
|
|
73
|
+
}>;
|
|
74
|
+
}, z.core.$strip>>;
|
|
75
|
+
createdAt: z.ZodString;
|
|
76
|
+
}, z.core.$strip>;
|
|
77
|
+
readonly requiresAuth: true;
|
|
78
|
+
};
|
|
79
|
+
export declare const ListOrdersForUserEndpoint: {
|
|
80
|
+
readonly method: "GET";
|
|
81
|
+
readonly path: "/api/orders";
|
|
82
|
+
readonly query: z.ZodObject<{
|
|
83
|
+
skip: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
84
|
+
take: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
85
|
+
}, z.core.$strip>;
|
|
86
|
+
readonly response: z.ZodObject<{
|
|
87
|
+
items: z.ZodArray<z.ZodObject<{
|
|
88
|
+
id: z.ZodNumber;
|
|
89
|
+
email: z.ZodString;
|
|
90
|
+
displayCurrency: z.ZodEnum<{
|
|
91
|
+
USD: "USD";
|
|
92
|
+
RUB: "RUB";
|
|
93
|
+
UAH: "UAH";
|
|
94
|
+
}>;
|
|
95
|
+
subtotal: z.ZodObject<{
|
|
96
|
+
usd: z.ZodString;
|
|
97
|
+
rub: z.ZodString;
|
|
98
|
+
uah: z.ZodString;
|
|
99
|
+
}, z.core.$strip>;
|
|
100
|
+
discount: z.ZodObject<{
|
|
101
|
+
usd: z.ZodString;
|
|
102
|
+
rub: z.ZodString;
|
|
103
|
+
uah: z.ZodString;
|
|
104
|
+
}, z.core.$strip>;
|
|
105
|
+
total: z.ZodObject<{
|
|
106
|
+
usd: z.ZodString;
|
|
107
|
+
rub: z.ZodString;
|
|
108
|
+
uah: z.ZodString;
|
|
109
|
+
}, z.core.$strip>;
|
|
110
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
111
|
+
source: z.ZodEnum<{
|
|
112
|
+
dessly: "dessly";
|
|
113
|
+
cbr: "cbr";
|
|
114
|
+
nbu: "nbu";
|
|
115
|
+
cache: "cache";
|
|
116
|
+
fallback: "fallback";
|
|
117
|
+
mixed: "mixed";
|
|
118
|
+
}>;
|
|
119
|
+
fetchedAt: z.ZodString;
|
|
120
|
+
rates: z.ZodObject<{
|
|
121
|
+
usdRub: z.ZodString;
|
|
122
|
+
usdUah: z.ZodString;
|
|
123
|
+
}, z.core.$strip>;
|
|
124
|
+
}, z.core.$strip>;
|
|
125
|
+
status: z.ZodEnum<{
|
|
126
|
+
PENDING: "PENDING";
|
|
127
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
128
|
+
PAID: "PAID";
|
|
129
|
+
PROCESSING: "PROCESSING";
|
|
130
|
+
SUCCESS: "SUCCESS";
|
|
131
|
+
FAILED: "FAILED";
|
|
132
|
+
REFUNDED: "REFUNDED";
|
|
133
|
+
CANCELLED: "CANCELLED";
|
|
134
|
+
}>;
|
|
135
|
+
items: z.ZodArray<z.ZodObject<{
|
|
136
|
+
id: z.ZodNumber;
|
|
137
|
+
productId: z.ZodNumber;
|
|
138
|
+
variantId: z.ZodNumber;
|
|
139
|
+
quantity: z.ZodNumber;
|
|
140
|
+
price: z.ZodObject<{
|
|
141
|
+
usd: z.ZodString;
|
|
142
|
+
rub: z.ZodString;
|
|
143
|
+
uah: z.ZodString;
|
|
144
|
+
}, z.core.$strip>;
|
|
145
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
146
|
+
status: z.ZodEnum<{
|
|
147
|
+
PENDING: "PENDING";
|
|
148
|
+
PROCESSING: "PROCESSING";
|
|
149
|
+
FAILED: "FAILED";
|
|
150
|
+
REFUNDED: "REFUNDED";
|
|
151
|
+
DELIVERED: "DELIVERED";
|
|
152
|
+
}>;
|
|
153
|
+
}, z.core.$strip>>;
|
|
154
|
+
createdAt: z.ZodString;
|
|
155
|
+
}, z.core.$strip>>;
|
|
156
|
+
total: z.ZodNumber;
|
|
157
|
+
skip: z.ZodNumber;
|
|
158
|
+
take: z.ZodNumber;
|
|
159
|
+
}, z.core.$strip>;
|
|
160
|
+
readonly requiresAuth: true;
|
|
161
|
+
};
|
|
162
|
+
export declare const ListOrdersAdminQuerySchema: z.ZodObject<{
|
|
163
|
+
skip: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
164
|
+
take: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
165
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
166
|
+
PENDING: "PENDING";
|
|
167
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
168
|
+
PAID: "PAID";
|
|
169
|
+
PROCESSING: "PROCESSING";
|
|
170
|
+
SUCCESS: "SUCCESS";
|
|
171
|
+
FAILED: "FAILED";
|
|
172
|
+
REFUNDED: "REFUNDED";
|
|
173
|
+
CANCELLED: "CANCELLED";
|
|
174
|
+
}>>;
|
|
175
|
+
from: z.ZodOptional<z.ZodString>;
|
|
176
|
+
to: z.ZodOptional<z.ZodString>;
|
|
177
|
+
}, z.core.$strip>;
|
|
178
|
+
export declare const ListOrdersAdminEndpoint: {
|
|
179
|
+
readonly method: "GET";
|
|
180
|
+
readonly path: "/api/admin/orders";
|
|
181
|
+
readonly query: z.ZodObject<{
|
|
182
|
+
skip: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
183
|
+
take: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
184
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
185
|
+
PENDING: "PENDING";
|
|
186
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
187
|
+
PAID: "PAID";
|
|
188
|
+
PROCESSING: "PROCESSING";
|
|
189
|
+
SUCCESS: "SUCCESS";
|
|
190
|
+
FAILED: "FAILED";
|
|
191
|
+
REFUNDED: "REFUNDED";
|
|
192
|
+
CANCELLED: "CANCELLED";
|
|
193
|
+
}>>;
|
|
194
|
+
from: z.ZodOptional<z.ZodString>;
|
|
195
|
+
to: z.ZodOptional<z.ZodString>;
|
|
196
|
+
}, z.core.$strip>;
|
|
197
|
+
readonly response: z.ZodObject<{
|
|
198
|
+
items: z.ZodArray<z.ZodObject<{
|
|
199
|
+
id: z.ZodNumber;
|
|
200
|
+
email: z.ZodString;
|
|
201
|
+
displayCurrency: z.ZodEnum<{
|
|
202
|
+
USD: "USD";
|
|
203
|
+
RUB: "RUB";
|
|
204
|
+
UAH: "UAH";
|
|
205
|
+
}>;
|
|
206
|
+
subtotal: z.ZodObject<{
|
|
207
|
+
usd: z.ZodString;
|
|
208
|
+
rub: z.ZodString;
|
|
209
|
+
uah: z.ZodString;
|
|
210
|
+
}, z.core.$strip>;
|
|
211
|
+
discount: z.ZodObject<{
|
|
212
|
+
usd: z.ZodString;
|
|
213
|
+
rub: z.ZodString;
|
|
214
|
+
uah: z.ZodString;
|
|
215
|
+
}, z.core.$strip>;
|
|
216
|
+
total: z.ZodObject<{
|
|
217
|
+
usd: z.ZodString;
|
|
218
|
+
rub: z.ZodString;
|
|
219
|
+
uah: z.ZodString;
|
|
220
|
+
}, z.core.$strip>;
|
|
221
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
222
|
+
source: z.ZodEnum<{
|
|
223
|
+
dessly: "dessly";
|
|
224
|
+
cbr: "cbr";
|
|
225
|
+
nbu: "nbu";
|
|
226
|
+
cache: "cache";
|
|
227
|
+
fallback: "fallback";
|
|
228
|
+
mixed: "mixed";
|
|
229
|
+
}>;
|
|
230
|
+
fetchedAt: z.ZodString;
|
|
231
|
+
rates: z.ZodObject<{
|
|
232
|
+
usdRub: z.ZodString;
|
|
233
|
+
usdUah: z.ZodString;
|
|
234
|
+
}, z.core.$strip>;
|
|
235
|
+
}, z.core.$strip>;
|
|
236
|
+
status: z.ZodEnum<{
|
|
237
|
+
PENDING: "PENDING";
|
|
238
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
239
|
+
PAID: "PAID";
|
|
240
|
+
PROCESSING: "PROCESSING";
|
|
241
|
+
SUCCESS: "SUCCESS";
|
|
242
|
+
FAILED: "FAILED";
|
|
243
|
+
REFUNDED: "REFUNDED";
|
|
244
|
+
CANCELLED: "CANCELLED";
|
|
245
|
+
}>;
|
|
246
|
+
items: z.ZodArray<z.ZodObject<{
|
|
247
|
+
id: z.ZodNumber;
|
|
248
|
+
productId: z.ZodNumber;
|
|
249
|
+
variantId: z.ZodNumber;
|
|
250
|
+
quantity: z.ZodNumber;
|
|
251
|
+
price: z.ZodObject<{
|
|
252
|
+
usd: z.ZodString;
|
|
253
|
+
rub: z.ZodString;
|
|
254
|
+
uah: z.ZodString;
|
|
255
|
+
}, z.core.$strip>;
|
|
256
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
257
|
+
status: z.ZodEnum<{
|
|
258
|
+
PENDING: "PENDING";
|
|
259
|
+
PROCESSING: "PROCESSING";
|
|
260
|
+
FAILED: "FAILED";
|
|
261
|
+
REFUNDED: "REFUNDED";
|
|
262
|
+
DELIVERED: "DELIVERED";
|
|
263
|
+
}>;
|
|
264
|
+
}, z.core.$strip>>;
|
|
265
|
+
createdAt: z.ZodString;
|
|
266
|
+
}, z.core.$strip>>;
|
|
267
|
+
total: z.ZodNumber;
|
|
268
|
+
skip: z.ZodNumber;
|
|
269
|
+
take: z.ZodNumber;
|
|
270
|
+
}, z.core.$strip>;
|
|
271
|
+
readonly requiresAuth: true;
|
|
272
|
+
readonly requiresAdmin: true;
|
|
273
|
+
};
|
|
274
|
+
export declare const OrderQueries: {
|
|
275
|
+
readonly getById: {
|
|
276
|
+
readonly method: "GET";
|
|
277
|
+
readonly path: "/api/orders/:id";
|
|
278
|
+
readonly params: z.ZodObject<{
|
|
279
|
+
id: z.ZodCoercedNumber<unknown>;
|
|
280
|
+
}, z.core.$strip>;
|
|
281
|
+
readonly response: z.ZodObject<{
|
|
282
|
+
id: z.ZodNumber;
|
|
283
|
+
email: z.ZodString;
|
|
284
|
+
displayCurrency: z.ZodEnum<{
|
|
285
|
+
USD: "USD";
|
|
286
|
+
RUB: "RUB";
|
|
287
|
+
UAH: "UAH";
|
|
288
|
+
}>;
|
|
289
|
+
subtotal: z.ZodObject<{
|
|
290
|
+
usd: z.ZodString;
|
|
291
|
+
rub: z.ZodString;
|
|
292
|
+
uah: z.ZodString;
|
|
293
|
+
}, z.core.$strip>;
|
|
294
|
+
discount: z.ZodObject<{
|
|
295
|
+
usd: z.ZodString;
|
|
296
|
+
rub: z.ZodString;
|
|
297
|
+
uah: z.ZodString;
|
|
298
|
+
}, z.core.$strip>;
|
|
299
|
+
total: z.ZodObject<{
|
|
300
|
+
usd: z.ZodString;
|
|
301
|
+
rub: z.ZodString;
|
|
302
|
+
uah: z.ZodString;
|
|
303
|
+
}, z.core.$strip>;
|
|
304
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
305
|
+
source: z.ZodEnum<{
|
|
306
|
+
dessly: "dessly";
|
|
307
|
+
cbr: "cbr";
|
|
308
|
+
nbu: "nbu";
|
|
309
|
+
cache: "cache";
|
|
310
|
+
fallback: "fallback";
|
|
311
|
+
mixed: "mixed";
|
|
312
|
+
}>;
|
|
313
|
+
fetchedAt: z.ZodString;
|
|
314
|
+
rates: z.ZodObject<{
|
|
315
|
+
usdRub: z.ZodString;
|
|
316
|
+
usdUah: z.ZodString;
|
|
317
|
+
}, z.core.$strip>;
|
|
318
|
+
}, z.core.$strip>;
|
|
319
|
+
status: z.ZodEnum<{
|
|
320
|
+
PENDING: "PENDING";
|
|
321
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
322
|
+
PAID: "PAID";
|
|
323
|
+
PROCESSING: "PROCESSING";
|
|
324
|
+
SUCCESS: "SUCCESS";
|
|
325
|
+
FAILED: "FAILED";
|
|
326
|
+
REFUNDED: "REFUNDED";
|
|
327
|
+
CANCELLED: "CANCELLED";
|
|
328
|
+
}>;
|
|
329
|
+
items: z.ZodArray<z.ZodObject<{
|
|
330
|
+
id: z.ZodNumber;
|
|
331
|
+
productId: z.ZodNumber;
|
|
332
|
+
variantId: z.ZodNumber;
|
|
333
|
+
quantity: z.ZodNumber;
|
|
334
|
+
price: z.ZodObject<{
|
|
335
|
+
usd: z.ZodString;
|
|
336
|
+
rub: z.ZodString;
|
|
337
|
+
uah: z.ZodString;
|
|
338
|
+
}, z.core.$strip>;
|
|
339
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
340
|
+
status: z.ZodEnum<{
|
|
341
|
+
PENDING: "PENDING";
|
|
342
|
+
PROCESSING: "PROCESSING";
|
|
343
|
+
FAILED: "FAILED";
|
|
344
|
+
REFUNDED: "REFUNDED";
|
|
345
|
+
DELIVERED: "DELIVERED";
|
|
346
|
+
}>;
|
|
347
|
+
}, z.core.$strip>>;
|
|
348
|
+
createdAt: z.ZodString;
|
|
349
|
+
}, z.core.$strip>;
|
|
350
|
+
readonly requiresAuth: true;
|
|
351
|
+
};
|
|
352
|
+
readonly listForUser: {
|
|
353
|
+
readonly method: "GET";
|
|
354
|
+
readonly path: "/api/orders";
|
|
355
|
+
readonly query: z.ZodObject<{
|
|
356
|
+
skip: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
357
|
+
take: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
358
|
+
}, z.core.$strip>;
|
|
359
|
+
readonly response: z.ZodObject<{
|
|
360
|
+
items: z.ZodArray<z.ZodObject<{
|
|
361
|
+
id: z.ZodNumber;
|
|
362
|
+
email: z.ZodString;
|
|
363
|
+
displayCurrency: z.ZodEnum<{
|
|
364
|
+
USD: "USD";
|
|
365
|
+
RUB: "RUB";
|
|
366
|
+
UAH: "UAH";
|
|
367
|
+
}>;
|
|
368
|
+
subtotal: z.ZodObject<{
|
|
369
|
+
usd: z.ZodString;
|
|
370
|
+
rub: z.ZodString;
|
|
371
|
+
uah: z.ZodString;
|
|
372
|
+
}, z.core.$strip>;
|
|
373
|
+
discount: z.ZodObject<{
|
|
374
|
+
usd: z.ZodString;
|
|
375
|
+
rub: z.ZodString;
|
|
376
|
+
uah: z.ZodString;
|
|
377
|
+
}, z.core.$strip>;
|
|
378
|
+
total: z.ZodObject<{
|
|
379
|
+
usd: z.ZodString;
|
|
380
|
+
rub: z.ZodString;
|
|
381
|
+
uah: z.ZodString;
|
|
382
|
+
}, z.core.$strip>;
|
|
383
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
384
|
+
source: z.ZodEnum<{
|
|
385
|
+
dessly: "dessly";
|
|
386
|
+
cbr: "cbr";
|
|
387
|
+
nbu: "nbu";
|
|
388
|
+
cache: "cache";
|
|
389
|
+
fallback: "fallback";
|
|
390
|
+
mixed: "mixed";
|
|
391
|
+
}>;
|
|
392
|
+
fetchedAt: z.ZodString;
|
|
393
|
+
rates: z.ZodObject<{
|
|
394
|
+
usdRub: z.ZodString;
|
|
395
|
+
usdUah: z.ZodString;
|
|
396
|
+
}, z.core.$strip>;
|
|
397
|
+
}, z.core.$strip>;
|
|
398
|
+
status: z.ZodEnum<{
|
|
399
|
+
PENDING: "PENDING";
|
|
400
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
401
|
+
PAID: "PAID";
|
|
402
|
+
PROCESSING: "PROCESSING";
|
|
403
|
+
SUCCESS: "SUCCESS";
|
|
404
|
+
FAILED: "FAILED";
|
|
405
|
+
REFUNDED: "REFUNDED";
|
|
406
|
+
CANCELLED: "CANCELLED";
|
|
407
|
+
}>;
|
|
408
|
+
items: z.ZodArray<z.ZodObject<{
|
|
409
|
+
id: z.ZodNumber;
|
|
410
|
+
productId: z.ZodNumber;
|
|
411
|
+
variantId: z.ZodNumber;
|
|
412
|
+
quantity: z.ZodNumber;
|
|
413
|
+
price: z.ZodObject<{
|
|
414
|
+
usd: z.ZodString;
|
|
415
|
+
rub: z.ZodString;
|
|
416
|
+
uah: z.ZodString;
|
|
417
|
+
}, z.core.$strip>;
|
|
418
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
419
|
+
status: z.ZodEnum<{
|
|
420
|
+
PENDING: "PENDING";
|
|
421
|
+
PROCESSING: "PROCESSING";
|
|
422
|
+
FAILED: "FAILED";
|
|
423
|
+
REFUNDED: "REFUNDED";
|
|
424
|
+
DELIVERED: "DELIVERED";
|
|
425
|
+
}>;
|
|
426
|
+
}, z.core.$strip>>;
|
|
427
|
+
createdAt: z.ZodString;
|
|
428
|
+
}, z.core.$strip>>;
|
|
429
|
+
total: z.ZodNumber;
|
|
430
|
+
skip: z.ZodNumber;
|
|
431
|
+
take: z.ZodNumber;
|
|
432
|
+
}, z.core.$strip>;
|
|
433
|
+
readonly requiresAuth: true;
|
|
434
|
+
};
|
|
435
|
+
readonly listAdmin: {
|
|
436
|
+
readonly method: "GET";
|
|
437
|
+
readonly path: "/api/admin/orders";
|
|
438
|
+
readonly query: z.ZodObject<{
|
|
439
|
+
skip: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
440
|
+
take: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
441
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
442
|
+
PENDING: "PENDING";
|
|
443
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
444
|
+
PAID: "PAID";
|
|
445
|
+
PROCESSING: "PROCESSING";
|
|
446
|
+
SUCCESS: "SUCCESS";
|
|
447
|
+
FAILED: "FAILED";
|
|
448
|
+
REFUNDED: "REFUNDED";
|
|
449
|
+
CANCELLED: "CANCELLED";
|
|
450
|
+
}>>;
|
|
451
|
+
from: z.ZodOptional<z.ZodString>;
|
|
452
|
+
to: z.ZodOptional<z.ZodString>;
|
|
453
|
+
}, z.core.$strip>;
|
|
454
|
+
readonly response: z.ZodObject<{
|
|
455
|
+
items: z.ZodArray<z.ZodObject<{
|
|
456
|
+
id: z.ZodNumber;
|
|
457
|
+
email: z.ZodString;
|
|
458
|
+
displayCurrency: z.ZodEnum<{
|
|
459
|
+
USD: "USD";
|
|
460
|
+
RUB: "RUB";
|
|
461
|
+
UAH: "UAH";
|
|
462
|
+
}>;
|
|
463
|
+
subtotal: z.ZodObject<{
|
|
464
|
+
usd: z.ZodString;
|
|
465
|
+
rub: z.ZodString;
|
|
466
|
+
uah: z.ZodString;
|
|
467
|
+
}, z.core.$strip>;
|
|
468
|
+
discount: z.ZodObject<{
|
|
469
|
+
usd: z.ZodString;
|
|
470
|
+
rub: z.ZodString;
|
|
471
|
+
uah: z.ZodString;
|
|
472
|
+
}, z.core.$strip>;
|
|
473
|
+
total: z.ZodObject<{
|
|
474
|
+
usd: z.ZodString;
|
|
475
|
+
rub: z.ZodString;
|
|
476
|
+
uah: z.ZodString;
|
|
477
|
+
}, z.core.$strip>;
|
|
478
|
+
exchangeRateSnapshot: z.ZodObject<{
|
|
479
|
+
source: z.ZodEnum<{
|
|
480
|
+
dessly: "dessly";
|
|
481
|
+
cbr: "cbr";
|
|
482
|
+
nbu: "nbu";
|
|
483
|
+
cache: "cache";
|
|
484
|
+
fallback: "fallback";
|
|
485
|
+
mixed: "mixed";
|
|
486
|
+
}>;
|
|
487
|
+
fetchedAt: z.ZodString;
|
|
488
|
+
rates: z.ZodObject<{
|
|
489
|
+
usdRub: z.ZodString;
|
|
490
|
+
usdUah: z.ZodString;
|
|
491
|
+
}, z.core.$strip>;
|
|
492
|
+
}, z.core.$strip>;
|
|
493
|
+
status: z.ZodEnum<{
|
|
494
|
+
PENDING: "PENDING";
|
|
495
|
+
AWAITING_PAYMENT: "AWAITING_PAYMENT";
|
|
496
|
+
PAID: "PAID";
|
|
497
|
+
PROCESSING: "PROCESSING";
|
|
498
|
+
SUCCESS: "SUCCESS";
|
|
499
|
+
FAILED: "FAILED";
|
|
500
|
+
REFUNDED: "REFUNDED";
|
|
501
|
+
CANCELLED: "CANCELLED";
|
|
502
|
+
}>;
|
|
503
|
+
items: z.ZodArray<z.ZodObject<{
|
|
504
|
+
id: z.ZodNumber;
|
|
505
|
+
productId: z.ZodNumber;
|
|
506
|
+
variantId: z.ZodNumber;
|
|
507
|
+
quantity: z.ZodNumber;
|
|
508
|
+
price: z.ZodObject<{
|
|
509
|
+
usd: z.ZodString;
|
|
510
|
+
rub: z.ZodString;
|
|
511
|
+
uah: z.ZodString;
|
|
512
|
+
}, z.core.$strip>;
|
|
513
|
+
deliveredAt: z.ZodNullable<z.ZodString>;
|
|
514
|
+
status: z.ZodEnum<{
|
|
515
|
+
PENDING: "PENDING";
|
|
516
|
+
PROCESSING: "PROCESSING";
|
|
517
|
+
FAILED: "FAILED";
|
|
518
|
+
REFUNDED: "REFUNDED";
|
|
519
|
+
DELIVERED: "DELIVERED";
|
|
520
|
+
}>;
|
|
521
|
+
}, z.core.$strip>>;
|
|
522
|
+
createdAt: z.ZodString;
|
|
523
|
+
}, z.core.$strip>>;
|
|
524
|
+
total: z.ZodNumber;
|
|
525
|
+
skip: z.ZodNumber;
|
|
526
|
+
take: z.ZodNumber;
|
|
527
|
+
}, z.core.$strip>;
|
|
528
|
+
readonly requiresAuth: true;
|
|
529
|
+
readonly requiresAdmin: true;
|
|
530
|
+
};
|
|
531
|
+
};
|
|
532
|
+
//# sourceMappingURL=queries.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../src/domains/orders/queries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAMI,CAAC;AAEtC,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAMD,CAAC;AAEtC,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;iBAIrC,CAAC;AACH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOC,CAAC;AAEtC,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIf,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.OrderQueries = exports.ListOrdersAdminEndpoint = exports.ListOrdersAdminQuerySchema = exports.ListOrdersForUserEndpoint = exports.GetOrderByIdEndpoint = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const common_1 = require("../../shared/common");
|
|
6
|
+
const pagination_1 = require("../../shared/pagination");
|
|
7
|
+
const dtos_1 = require("./dtos");
|
|
8
|
+
exports.GetOrderByIdEndpoint = {
|
|
9
|
+
method: "GET",
|
|
10
|
+
path: "/api/orders/:id",
|
|
11
|
+
params: common_1.IdParamSchema,
|
|
12
|
+
response: dtos_1.OrderResponseSchema,
|
|
13
|
+
requiresAuth: true,
|
|
14
|
+
};
|
|
15
|
+
exports.ListOrdersForUserEndpoint = {
|
|
16
|
+
method: "GET",
|
|
17
|
+
path: "/api/orders",
|
|
18
|
+
query: pagination_1.PaginationQuerySchema,
|
|
19
|
+
response: (0, pagination_1.PaginatedResponseSchema)(dtos_1.OrderResponseSchema),
|
|
20
|
+
requiresAuth: true,
|
|
21
|
+
};
|
|
22
|
+
exports.ListOrdersAdminQuerySchema = pagination_1.PaginationQuerySchema.extend({
|
|
23
|
+
status: dtos_1.OrderStatusSchema.optional(),
|
|
24
|
+
from: zod_1.z.string().optional(),
|
|
25
|
+
to: zod_1.z.string().optional(),
|
|
26
|
+
});
|
|
27
|
+
exports.ListOrdersAdminEndpoint = {
|
|
28
|
+
method: "GET",
|
|
29
|
+
path: "/api/admin/orders",
|
|
30
|
+
query: exports.ListOrdersAdminQuerySchema,
|
|
31
|
+
response: (0, pagination_1.PaginatedResponseSchema)(dtos_1.OrderResponseSchema),
|
|
32
|
+
requiresAuth: true,
|
|
33
|
+
requiresAdmin: true,
|
|
34
|
+
};
|
|
35
|
+
exports.OrderQueries = {
|
|
36
|
+
getById: exports.GetOrderByIdEndpoint,
|
|
37
|
+
listForUser: exports.ListOrdersForUserEndpoint,
|
|
38
|
+
listAdmin: exports.ListOrdersAdminEndpoint,
|
|
39
|
+
};
|
|
40
|
+
//# sourceMappingURL=queries.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queries.js","sourceRoot":"","sources":["../../../src/domains/orders/queries.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,gDAAoD;AACpD,wDAAyF;AACzF,iCAAgE;AAEnD,QAAA,oBAAoB,GAAG;IACnC,MAAM,EAAE,KAAK;IACb,IAAI,EAAE,iBAAiB;IACvB,MAAM,EAAE,sBAAa;IACrB,QAAQ,EAAE,0BAAmB;IAC7B,YAAY,EAAE,IAAI;CACkB,CAAC;AAEzB,QAAA,yBAAyB,GAAG;IACxC,MAAM,EAAE,KAAK;IACb,IAAI,EAAE,aAAa;IACnB,KAAK,EAAE,kCAAqB;IAC5B,QAAQ,EAAE,IAAA,oCAAuB,EAAC,0BAAmB,CAAC;IACtD,YAAY,EAAE,IAAI;CACkB,CAAC;AAEzB,QAAA,0BAA0B,GAAG,kCAAqB,CAAC,MAAM,CAAC;IACtE,MAAM,EAAE,wBAAiB,CAAC,QAAQ,EAAE;IACpC,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC3B,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACzB,CAAC,CAAC;AACU,QAAA,uBAAuB,GAAG;IACtC,MAAM,EAAE,KAAK;IACb,IAAI,EAAE,mBAAmB;IACzB,KAAK,EAAE,kCAA0B;IACjC,QAAQ,EAAE,IAAA,oCAAuB,EAAC,0BAAmB,CAAC;IACtD,YAAY,EAAE,IAAI;IAClB,aAAa,EAAE,IAAI;CACiB,CAAC;AAEzB,QAAA,YAAY,GAAG;IAC3B,OAAO,EAAE,4BAAoB;IAC7B,WAAW,EAAE,iCAAyB;IACtC,SAAS,EAAE,+BAAuB;CACzB,CAAC"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const PaymentProviderSchema: z.ZodEnum<{
|
|
3
|
+
antilopay: "antilopay";
|
|
4
|
+
cryptopayo: "cryptopayo";
|
|
5
|
+
}>;
|
|
6
|
+
export type PaymentProvider = z.infer<typeof PaymentProviderSchema>;
|
|
7
|
+
export declare const InitiatePaymentRequestSchema: z.ZodObject<{
|
|
8
|
+
orderId: z.ZodNumber;
|
|
9
|
+
}, z.core.$strip>;
|
|
10
|
+
export type InitiatePaymentRequest = z.infer<typeof InitiatePaymentRequestSchema>;
|
|
11
|
+
export declare const InitiatePaymentResponseSchema: z.ZodObject<{
|
|
12
|
+
paymentUrl: z.ZodString;
|
|
13
|
+
providerPaymentId: z.ZodString;
|
|
14
|
+
}, z.core.$strip>;
|
|
15
|
+
export type InitiatePaymentResponse = z.infer<typeof InitiatePaymentResponseSchema>;
|
|
16
|
+
export declare const InitiatePaymentEndpoint: {
|
|
17
|
+
readonly method: "POST";
|
|
18
|
+
readonly path: "/api/payments/:provider/initiate";
|
|
19
|
+
readonly params: z.ZodObject<{
|
|
20
|
+
provider: z.ZodEnum<{
|
|
21
|
+
antilopay: "antilopay";
|
|
22
|
+
cryptopayo: "cryptopayo";
|
|
23
|
+
}>;
|
|
24
|
+
}, z.core.$strip>;
|
|
25
|
+
readonly request: z.ZodObject<{
|
|
26
|
+
orderId: z.ZodNumber;
|
|
27
|
+
}, z.core.$strip>;
|
|
28
|
+
readonly response: z.ZodObject<{
|
|
29
|
+
paymentUrl: z.ZodString;
|
|
30
|
+
providerPaymentId: z.ZodString;
|
|
31
|
+
}, z.core.$strip>;
|
|
32
|
+
readonly requiresAuth: true;
|
|
33
|
+
readonly rateLimit: {
|
|
34
|
+
readonly limit: 5;
|
|
35
|
+
readonly ttlSec: 60;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
export declare const PaymentWebhookEndpoint: {
|
|
39
|
+
readonly method: "POST";
|
|
40
|
+
readonly path: "/api/payments/webhook/:provider";
|
|
41
|
+
readonly params: z.ZodObject<{
|
|
42
|
+
provider: z.ZodEnum<{
|
|
43
|
+
antilopay: "antilopay";
|
|
44
|
+
cryptopayo: "cryptopayo";
|
|
45
|
+
}>;
|
|
46
|
+
}, z.core.$strip>;
|
|
47
|
+
readonly response: z.ZodObject<{
|
|
48
|
+
ok: z.ZodLiteral<true>;
|
|
49
|
+
}, z.core.$strip>;
|
|
50
|
+
readonly rateLimit: {
|
|
51
|
+
readonly limit: 60;
|
|
52
|
+
readonly ttlSec: 60;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
export declare const PaymentEndpoints: {
|
|
56
|
+
readonly initiate: {
|
|
57
|
+
readonly method: "POST";
|
|
58
|
+
readonly path: "/api/payments/:provider/initiate";
|
|
59
|
+
readonly params: z.ZodObject<{
|
|
60
|
+
provider: z.ZodEnum<{
|
|
61
|
+
antilopay: "antilopay";
|
|
62
|
+
cryptopayo: "cryptopayo";
|
|
63
|
+
}>;
|
|
64
|
+
}, z.core.$strip>;
|
|
65
|
+
readonly request: z.ZodObject<{
|
|
66
|
+
orderId: z.ZodNumber;
|
|
67
|
+
}, z.core.$strip>;
|
|
68
|
+
readonly response: z.ZodObject<{
|
|
69
|
+
paymentUrl: z.ZodString;
|
|
70
|
+
providerPaymentId: z.ZodString;
|
|
71
|
+
}, z.core.$strip>;
|
|
72
|
+
readonly requiresAuth: true;
|
|
73
|
+
readonly rateLimit: {
|
|
74
|
+
readonly limit: 5;
|
|
75
|
+
readonly ttlSec: 60;
|
|
76
|
+
};
|
|
77
|
+
};
|
|
78
|
+
readonly webhook: {
|
|
79
|
+
readonly method: "POST";
|
|
80
|
+
readonly path: "/api/payments/webhook/:provider";
|
|
81
|
+
readonly params: z.ZodObject<{
|
|
82
|
+
provider: z.ZodEnum<{
|
|
83
|
+
antilopay: "antilopay";
|
|
84
|
+
cryptopayo: "cryptopayo";
|
|
85
|
+
}>;
|
|
86
|
+
}, z.core.$strip>;
|
|
87
|
+
readonly response: z.ZodObject<{
|
|
88
|
+
ok: z.ZodLiteral<true>;
|
|
89
|
+
}, z.core.$strip>;
|
|
90
|
+
readonly rateLimit: {
|
|
91
|
+
readonly limit: 60;
|
|
92
|
+
readonly ttlSec: 60;
|
|
93
|
+
};
|
|
94
|
+
};
|
|
95
|
+
};
|
|
96
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/domains/payments/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,qBAAqB;;;EAAsC,CAAC;AACzE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,4BAA4B;;iBAEvC,CAAC;AACH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAElF,eAAO,MAAM,6BAA6B;;;iBAGxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAEpF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;CAQC,CAAC;AAEtC,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;CAME,CAAC;AAEtC,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGnB,CAAC"}
|