au update schema

This commit is contained in:
TheJuze
2024-05-30 17:37:51 +03:00
parent 761a9cc180
commit 2613e4a80d
2 changed files with 5 additions and 1 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "@orionprotocol/sdk",
"version": "0.22.0-rc13",
"version": "0.22.0-rc14",
"description": "Orion Protocol SDK",
"main": "./lib/index.cjs",
"module": "./lib/index.js",

View File

@@ -84,6 +84,8 @@ export const fullOrderSchema = z.object({
E: z.enum(executionTypes).optional(),
C: z.string().optional(), // trigger condition
ro: z.boolean().optional(), // is reversed order
sc: z.boolean().optional(), // source chain
tc: z.boolean().optional(), // target chain
}).transform((val) => ({
...val,
k: 'full' as const,
@@ -105,6 +107,8 @@ export const fullOrderSchema = z.object({
executionType: o.E,
triggerCondition: o.C,
isReversedOrder: o.ro,
sorceChain: o.sc,
targetChain: o.tc,
subOrders: o.c.map((so) => ({
pair: so.P,
exchange: so.e,