@targoninc/lyda-shared 0.0.42 → 0.0.44

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.
@@ -0,0 +1,5 @@
1
+ export declare enum OrderStatus {
2
+ Started = "started",
3
+ Fulfilled = "fulfilled",
4
+ Cancelled = "cancelled"
5
+ }
@@ -0,0 +1,5 @@
1
+ export declare enum PaymentProvider {
2
+ paypal = "paypal",
3
+ stripe = "stripe",
4
+ mollie = "mollie"
5
+ }
@@ -0,0 +1,12 @@
1
+ import * as z from "zod";
2
+ import { PaymentProvider } from "../Enums/PaymentProvider.ts";
3
+ export declare const CreateOrderRequest: z.ZodObject<{
4
+ type: z.ZodEnum<{
5
+ track: "track";
6
+ album: "album";
7
+ }>;
8
+ paymentProvider: z.ZodEnum<typeof PaymentProvider>;
9
+ entityId: z.ZodBigIntFormat;
10
+ priceInUsd: z.ZodOptional<z.ZodNumber>;
11
+ }, z.core.$strip>;
12
+ export type CreateOrderRequest = z.infer<typeof CreateOrderRequest>;
@@ -0,0 +1,11 @@
1
+ export interface Order {
2
+ id: string;
3
+ payment_provider: string;
4
+ item_type: string;
5
+ provider_request_id: string;
6
+ provider_order_id: string;
7
+ provider_status: string;
8
+ status: string;
9
+ user_id: string;
10
+ item_id: string;
11
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@targoninc/lyda-shared",
3
3
  "type": "module",
4
- "version": "0.0.42",
4
+ "version": "0.0.44",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "files": [
@@ -22,7 +22,8 @@
22
22
  },
23
23
  "dependencies": {
24
24
  "@targoninc/jess": "^0.0.11",
25
- "@targoninc/ts-search": "^0.0.5"
25
+ "@targoninc/ts-search": "^0.0.5",
26
+ "zod": "^4.1.12"
26
27
  },
27
28
  "devDependencies": {
28
29
  "@passwordless-id/webauthn": "^2.3.0",
@@ -0,0 +1,5 @@
1
+ export enum OrderStatus {
2
+ Started = "started",
3
+ Fulfilled = "fulfilled",
4
+ Cancelled = "cancelled",
5
+ }
@@ -0,0 +1,5 @@
1
+ export enum PaymentProvider {
2
+ paypal = "paypal",
3
+ stripe = "stripe",
4
+ mollie = "mollie",
5
+ }
@@ -0,0 +1,11 @@
1
+ import * as z from "zod";
2
+ import {PaymentProvider} from "../Enums/PaymentProvider.ts";
3
+
4
+ export const CreateOrderRequest = z.object({
5
+ type: z.enum(["album", "track"]),
6
+ paymentProvider: z.enum(PaymentProvider),
7
+ entityId: z.uint64(),
8
+ priceInUsd: z.number().min(0.01).max(100).optional(),
9
+ });
10
+
11
+ export type CreateOrderRequest = z.infer<typeof CreateOrderRequest>;
@@ -0,0 +1,11 @@
1
+ export interface Order {
2
+ id: string;
3
+ payment_provider: string;
4
+ item_type: string;
5
+ provider_request_id: string;
6
+ provider_order_id: string;
7
+ provider_status: string;
8
+ status: string;
9
+ user_id: string;
10
+ item_id: string;
11
+ }