@longdotxyz/shared 0.0.131 → 0.0.133

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.
Files changed (37) hide show
  1. package/dist/contracts/asset.contract.d.ts +3519 -3547
  2. package/dist/contracts/asset.contract.js +57 -94
  3. package/dist/contracts/asset.contract.js.map +1 -1
  4. package/dist/contracts/auction-template.contract.d.ts +208 -186
  5. package/dist/contracts/auction-template.contract.js +54 -64
  6. package/dist/contracts/auction-template.contract.js.map +1 -1
  7. package/dist/contracts/auction.contract.d.ts +113 -133
  8. package/dist/contracts/auction.contract.js +31 -51
  9. package/dist/contracts/auction.contract.js.map +1 -1
  10. package/dist/contracts/charts.contract.d.ts +91 -119
  11. package/dist/contracts/charts.contract.js +13 -32
  12. package/dist/contracts/charts.contract.js.map +1 -1
  13. package/dist/contracts/community.contract.d.ts +73 -86
  14. package/dist/contracts/community.contract.js +7 -27
  15. package/dist/contracts/community.contract.js.map +1 -1
  16. package/dist/contracts/github-activity.contract.d.ts +507 -0
  17. package/dist/contracts/github-activity.contract.js +43 -0
  18. package/dist/contracts/github-activity.contract.js.map +1 -0
  19. package/dist/contracts/index.d.ts +6071 -6159
  20. package/dist/contracts/index.js +5 -4
  21. package/dist/contracts/index.js.map +1 -1
  22. package/dist/contracts/ipfs.contract.d.ts +66 -83
  23. package/dist/contracts/ipfs.contract.js +30 -49
  24. package/dist/contracts/ipfs.contract.js.map +1 -1
  25. package/dist/contracts/market.contract.d.ts +1268 -1418
  26. package/dist/contracts/market.contract.js +69 -132
  27. package/dist/contracts/market.contract.js.map +1 -1
  28. package/dist/contracts/pathfinding.contract.d.ts +191 -202
  29. package/dist/contracts/pathfinding.contract.js +13 -23
  30. package/dist/contracts/pathfinding.contract.js.map +1 -1
  31. package/dist/contracts/sponsorship.contract.d.ts +230 -331
  32. package/dist/contracts/sponsorship.contract.js +78 -138
  33. package/dist/contracts/sponsorship.contract.js.map +1 -1
  34. package/dist/contracts/tokens.contract.d.ts +62 -61
  35. package/dist/contracts/tokens.contract.js +42 -51
  36. package/dist/contracts/tokens.contract.js.map +1 -1
  37. package/package.json +4 -3
@@ -107,59 +107,50 @@ declare const AuctionTemplateEncodeResponseSchema: z.ZodObject<{
107
107
  }>;
108
108
  type AuctionTemplateEncodeResponse = z.output<typeof AuctionTemplateEncodeResponseSchema>;
109
109
  declare const auctionTemplateContract: {
110
- listAuctionTemplates: {
111
- description: "List all auction templates for an integrator";
112
- query: z.ZodObject<{
113
- chainId: z.ZodDefault<z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>>;
110
+ listAuctionTemplates: import("@orpc/contract", { with: { "resolution-mode": "import" } }).ContractProcedureBuilderWithInputOutput<z.ZodObject<{
111
+ chainId: z.ZodDefault<z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>>;
112
+ }, "strip", z.ZodTypeAny, {
113
+ chainId: number;
114
+ }, {
115
+ chainId?: number | undefined;
116
+ }>, z.ZodObject<{
117
+ result: z.ZodArray<z.ZodObject<{
118
+ id: z.ZodString;
119
+ name: z.ZodString;
120
+ description: z.ZodNullable<z.ZodString>;
121
+ type: z.ZodString;
122
+ integrator_id: z.ZodString;
114
123
  }, "strip", z.ZodTypeAny, {
115
- chainId: number;
124
+ type: string;
125
+ name: string;
126
+ description: string | null;
127
+ id: string;
128
+ integrator_id: string;
116
129
  }, {
117
- chainId?: number | undefined;
118
- }>;
119
- method: "GET";
120
- path: "/auction-templates/";
121
- responses: {
122
- 200: z.ZodObject<{
123
- result: z.ZodArray<z.ZodObject<{
124
- id: z.ZodString;
125
- name: z.ZodString;
126
- description: z.ZodNullable<z.ZodString>;
127
- type: z.ZodString;
128
- integrator_id: z.ZodString;
129
- }, "strip", z.ZodTypeAny, {
130
- type: string;
131
- name: string;
132
- description: string | null;
133
- id: string;
134
- integrator_id: string;
135
- }, {
136
- type: string;
137
- name: string;
138
- description: string | null;
139
- id: string;
140
- integrator_id: string;
141
- }>, "many">;
142
- }, "strip", z.ZodTypeAny, {
143
- result: {
144
- type: string;
145
- name: string;
146
- description: string | null;
147
- id: string;
148
- integrator_id: string;
149
- }[];
150
- }, {
151
- result: {
152
- type: string;
153
- name: string;
154
- description: string | null;
155
- id: string;
156
- integrator_id: string;
157
- }[];
158
- }>;
159
- };
160
- };
161
- encodeAuctionTemplate: {
162
- description: "Encode a auction template and return the payload to be signed and sent raw to the blockchain";
130
+ type: string;
131
+ name: string;
132
+ description: string | null;
133
+ id: string;
134
+ integrator_id: string;
135
+ }>, "many">;
136
+ }, "strip", z.ZodTypeAny, {
137
+ result: {
138
+ type: string;
139
+ name: string;
140
+ description: string | null;
141
+ id: string;
142
+ integrator_id: string;
143
+ }[];
144
+ }, {
145
+ result: {
146
+ type: string;
147
+ name: string;
148
+ description: string | null;
149
+ id: string;
150
+ integrator_id: string;
151
+ }[];
152
+ }>, Record<never, never>, Record<never, never>>;
153
+ encodeAuctionTemplate: import("@orpc/contract", { with: { "resolution-mode": "import" } }).ContractProcedureBuilderWithInputOutput<z.ZodObject<{
163
154
  query: z.ZodObject<{
164
155
  chainId: z.ZodDefault<z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>>;
165
156
  }, "strip", z.ZodTypeAny, {
@@ -167,7 +158,6 @@ declare const auctionTemplateContract: {
167
158
  }, {
168
159
  chainId?: number | undefined;
169
160
  }>;
170
- method: "POST";
171
161
  body: z.ZodObject<{
172
162
  template_id: z.ZodString;
173
163
  debug: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
@@ -206,6 +196,8 @@ declare const auctionTemplateContract: {
206
196
  }[] | undefined;
207
197
  }>;
208
198
  }, "strip", z.ZodTypeAny, {
199
+ template_id: string;
200
+ debug: boolean;
209
201
  metadata: {
210
202
  token_name: string;
211
203
  token_symbol: string;
@@ -216,9 +208,8 @@ declare const auctionTemplateContract: {
216
208
  shares: string;
217
209
  }[];
218
210
  };
219
- template_id: string;
220
- debug: boolean;
221
211
  }, {
212
+ template_id: string;
222
213
  metadata: {
223
214
  token_name: string;
224
215
  token_symbol: string;
@@ -229,143 +220,174 @@ declare const auctionTemplateContract: {
229
220
  shares: string;
230
221
  }[] | undefined;
231
222
  };
232
- template_id: string;
233
223
  debug?: boolean | undefined;
234
224
  }>;
235
- path: "/auction-templates";
236
- responses: {
237
- 200: z.ZodObject<{
238
- result: z.ZodObject<{
239
- params: z.ZodOptional<z.ZodObject<{
240
- governance_factory: z.ZodEffects<z.ZodString, `0x${string}`, string>;
241
- governance_factory_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
242
- pool_initializer: z.ZodEffects<z.ZodString, `0x${string}`, string>;
243
- pool_initializer_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
244
- liquidity_migrator: z.ZodEffects<z.ZodString, `0x${string}`, string>;
245
- liquidity_migrator_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
246
- integrator: z.ZodEffects<z.ZodString, `0x${string}`, string>;
247
- salt: z.ZodEffects<z.ZodString, `0x${string}`, string>;
248
- initial_supply: z.ZodString;
249
- num_tokens_to_sell: z.ZodString;
250
- numeraire: z.ZodEffects<z.ZodString, `0x${string}`, string>;
251
- token_factory: z.ZodEffects<z.ZodString, `0x${string}`, string>;
252
- token_factory_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
253
- }, "strip", z.ZodTypeAny, {
254
- governance_factory: `0x${string}`;
255
- governance_factory_data: `0x${string}`;
256
- pool_initializer: `0x${string}`;
257
- pool_initializer_data: `0x${string}`;
258
- liquidity_migrator: `0x${string}`;
259
- liquidity_migrator_data: `0x${string}`;
260
- integrator: `0x${string}`;
261
- salt: `0x${string}`;
262
- initial_supply: string;
263
- num_tokens_to_sell: string;
264
- numeraire: `0x${string}`;
265
- token_factory: `0x${string}`;
266
- token_factory_data: `0x${string}`;
267
- }, {
268
- governance_factory: string;
269
- governance_factory_data: string;
270
- pool_initializer: string;
271
- pool_initializer_data: string;
272
- liquidity_migrator: string;
273
- liquidity_migrator_data: string;
274
- integrator: string;
275
- salt: string;
276
- initial_supply: string;
277
- num_tokens_to_sell: string;
278
- numeraire: string;
279
- token_factory: string;
280
- token_factory_data: string;
281
- }>>;
282
- hook_address: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
283
- token_address: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
284
- encoded_payload: z.ZodEffects<z.ZodString, `0x${string}`, string>;
285
- }, "strip", z.ZodTypeAny, {
286
- encoded_payload: `0x${string}`;
287
- params?: {
288
- governance_factory: `0x${string}`;
289
- governance_factory_data: `0x${string}`;
290
- pool_initializer: `0x${string}`;
291
- pool_initializer_data: `0x${string}`;
292
- liquidity_migrator: `0x${string}`;
293
- liquidity_migrator_data: `0x${string}`;
294
- integrator: `0x${string}`;
295
- salt: `0x${string}`;
296
- initial_supply: string;
297
- num_tokens_to_sell: string;
298
- numeraire: `0x${string}`;
299
- token_factory: `0x${string}`;
300
- token_factory_data: `0x${string}`;
301
- } | undefined;
302
- token_address?: `0x${string}` | undefined;
303
- hook_address?: `0x${string}` | undefined;
304
- }, {
305
- encoded_payload: string;
306
- params?: {
307
- governance_factory: string;
308
- governance_factory_data: string;
309
- pool_initializer: string;
310
- pool_initializer_data: string;
311
- liquidity_migrator: string;
312
- liquidity_migrator_data: string;
313
- integrator: string;
314
- salt: string;
315
- initial_supply: string;
316
- num_tokens_to_sell: string;
317
- numeraire: string;
318
- token_factory: string;
319
- token_factory_data: string;
320
- } | undefined;
321
- token_address?: string | undefined;
322
- hook_address?: string | undefined;
323
- }>;
225
+ }, "strip", z.ZodTypeAny, {
226
+ query: {
227
+ chainId: number;
228
+ };
229
+ body: {
230
+ template_id: string;
231
+ debug: boolean;
232
+ metadata: {
233
+ token_name: string;
234
+ token_symbol: string;
235
+ token_uri: string;
236
+ user_address: `0x${string}`;
237
+ beneficiaries: {
238
+ beneficiary: `0x${string}`;
239
+ shares: string;
240
+ }[];
241
+ };
242
+ };
243
+ }, {
244
+ query: {
245
+ chainId?: number | undefined;
246
+ };
247
+ body: {
248
+ template_id: string;
249
+ metadata: {
250
+ token_name: string;
251
+ token_symbol: string;
252
+ user_address: string;
253
+ token_uri?: string | undefined;
254
+ beneficiaries?: {
255
+ beneficiary: string;
256
+ shares: string;
257
+ }[] | undefined;
258
+ };
259
+ debug?: boolean | undefined;
260
+ };
261
+ }>, z.ZodObject<{
262
+ result: z.ZodObject<{
263
+ params: z.ZodOptional<z.ZodObject<{
264
+ governance_factory: z.ZodEffects<z.ZodString, `0x${string}`, string>;
265
+ governance_factory_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
266
+ pool_initializer: z.ZodEffects<z.ZodString, `0x${string}`, string>;
267
+ pool_initializer_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
268
+ liquidity_migrator: z.ZodEffects<z.ZodString, `0x${string}`, string>;
269
+ liquidity_migrator_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
270
+ integrator: z.ZodEffects<z.ZodString, `0x${string}`, string>;
271
+ salt: z.ZodEffects<z.ZodString, `0x${string}`, string>;
272
+ initial_supply: z.ZodString;
273
+ num_tokens_to_sell: z.ZodString;
274
+ numeraire: z.ZodEffects<z.ZodString, `0x${string}`, string>;
275
+ token_factory: z.ZodEffects<z.ZodString, `0x${string}`, string>;
276
+ token_factory_data: z.ZodEffects<z.ZodString, `0x${string}`, string>;
324
277
  }, "strip", z.ZodTypeAny, {
325
- result: {
326
- encoded_payload: `0x${string}`;
327
- params?: {
328
- governance_factory: `0x${string}`;
329
- governance_factory_data: `0x${string}`;
330
- pool_initializer: `0x${string}`;
331
- pool_initializer_data: `0x${string}`;
332
- liquidity_migrator: `0x${string}`;
333
- liquidity_migrator_data: `0x${string}`;
334
- integrator: `0x${string}`;
335
- salt: `0x${string}`;
336
- initial_supply: string;
337
- num_tokens_to_sell: string;
338
- numeraire: `0x${string}`;
339
- token_factory: `0x${string}`;
340
- token_factory_data: `0x${string}`;
341
- } | undefined;
342
- token_address?: `0x${string}` | undefined;
343
- hook_address?: `0x${string}` | undefined;
344
- };
278
+ governance_factory: `0x${string}`;
279
+ governance_factory_data: `0x${string}`;
280
+ pool_initializer: `0x${string}`;
281
+ pool_initializer_data: `0x${string}`;
282
+ liquidity_migrator: `0x${string}`;
283
+ liquidity_migrator_data: `0x${string}`;
284
+ integrator: `0x${string}`;
285
+ salt: `0x${string}`;
286
+ initial_supply: string;
287
+ num_tokens_to_sell: string;
288
+ numeraire: `0x${string}`;
289
+ token_factory: `0x${string}`;
290
+ token_factory_data: `0x${string}`;
345
291
  }, {
346
- result: {
347
- encoded_payload: string;
348
- params?: {
349
- governance_factory: string;
350
- governance_factory_data: string;
351
- pool_initializer: string;
352
- pool_initializer_data: string;
353
- liquidity_migrator: string;
354
- liquidity_migrator_data: string;
355
- integrator: string;
356
- salt: string;
357
- initial_supply: string;
358
- num_tokens_to_sell: string;
359
- numeraire: string;
360
- token_factory: string;
361
- token_factory_data: string;
362
- } | undefined;
363
- token_address?: string | undefined;
364
- hook_address?: string | undefined;
365
- };
366
- }>;
292
+ governance_factory: string;
293
+ governance_factory_data: string;
294
+ pool_initializer: string;
295
+ pool_initializer_data: string;
296
+ liquidity_migrator: string;
297
+ liquidity_migrator_data: string;
298
+ integrator: string;
299
+ salt: string;
300
+ initial_supply: string;
301
+ num_tokens_to_sell: string;
302
+ numeraire: string;
303
+ token_factory: string;
304
+ token_factory_data: string;
305
+ }>>;
306
+ hook_address: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
307
+ token_address: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
308
+ encoded_payload: z.ZodEffects<z.ZodString, `0x${string}`, string>;
309
+ }, "strip", z.ZodTypeAny, {
310
+ encoded_payload: `0x${string}`;
311
+ params?: {
312
+ governance_factory: `0x${string}`;
313
+ governance_factory_data: `0x${string}`;
314
+ pool_initializer: `0x${string}`;
315
+ pool_initializer_data: `0x${string}`;
316
+ liquidity_migrator: `0x${string}`;
317
+ liquidity_migrator_data: `0x${string}`;
318
+ integrator: `0x${string}`;
319
+ salt: `0x${string}`;
320
+ initial_supply: string;
321
+ num_tokens_to_sell: string;
322
+ numeraire: `0x${string}`;
323
+ token_factory: `0x${string}`;
324
+ token_factory_data: `0x${string}`;
325
+ } | undefined;
326
+ token_address?: `0x${string}` | undefined;
327
+ hook_address?: `0x${string}` | undefined;
328
+ }, {
329
+ encoded_payload: string;
330
+ params?: {
331
+ governance_factory: string;
332
+ governance_factory_data: string;
333
+ pool_initializer: string;
334
+ pool_initializer_data: string;
335
+ liquidity_migrator: string;
336
+ liquidity_migrator_data: string;
337
+ integrator: string;
338
+ salt: string;
339
+ initial_supply: string;
340
+ num_tokens_to_sell: string;
341
+ numeraire: string;
342
+ token_factory: string;
343
+ token_factory_data: string;
344
+ } | undefined;
345
+ token_address?: string | undefined;
346
+ hook_address?: string | undefined;
347
+ }>;
348
+ }, "strip", z.ZodTypeAny, {
349
+ result: {
350
+ encoded_payload: `0x${string}`;
351
+ params?: {
352
+ governance_factory: `0x${string}`;
353
+ governance_factory_data: `0x${string}`;
354
+ pool_initializer: `0x${string}`;
355
+ pool_initializer_data: `0x${string}`;
356
+ liquidity_migrator: `0x${string}`;
357
+ liquidity_migrator_data: `0x${string}`;
358
+ integrator: `0x${string}`;
359
+ salt: `0x${string}`;
360
+ initial_supply: string;
361
+ num_tokens_to_sell: string;
362
+ numeraire: `0x${string}`;
363
+ token_factory: `0x${string}`;
364
+ token_factory_data: `0x${string}`;
365
+ } | undefined;
366
+ token_address?: `0x${string}` | undefined;
367
+ hook_address?: `0x${string}` | undefined;
368
+ };
369
+ }, {
370
+ result: {
371
+ encoded_payload: string;
372
+ params?: {
373
+ governance_factory: string;
374
+ governance_factory_data: string;
375
+ pool_initializer: string;
376
+ pool_initializer_data: string;
377
+ liquidity_migrator: string;
378
+ liquidity_migrator_data: string;
379
+ integrator: string;
380
+ salt: string;
381
+ initial_supply: string;
382
+ num_tokens_to_sell: string;
383
+ numeraire: string;
384
+ token_factory: string;
385
+ token_factory_data: string;
386
+ } | undefined;
387
+ token_address?: string | undefined;
388
+ hook_address?: string | undefined;
367
389
  };
368
- };
390
+ }>, Record<never, never>, Record<never, never>>;
369
391
  };
370
392
  export { auctionTemplateContract, AuctionTemplateResponseSchema, AuctionTemplateEncodeResponseSchema };
371
393
  export type { AuctionTemplateResponse, AuctionTemplateEncodeResponse };
@@ -4,10 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.AuctionTemplateEncodeResponseSchema = exports.AuctionTemplateResponseSchema = exports.auctionTemplateContract = void 0;
7
- const core_1 = require("@ts-rest/core");
7
+ const contract_1 = require("@orpc/contract");
8
8
  const zod_1 = __importDefault(require("zod"));
9
9
  const types_1 = require("../types");
10
- const contract = (0, core_1.initContract)();
11
10
  const AuctionTemplateResponseSchema = zod_1.default.object({
12
11
  id: zod_1.default.string(),
13
12
  name: zod_1.default.string(),
@@ -39,69 +38,60 @@ const AuctionTemplateEncodeResponseSchema = zod_1.default.object({
39
38
  encoded_payload: types_1.hex.describe("The encoded payload of the auction, to be signed and sent raw to the blockchain"),
40
39
  });
41
40
  exports.AuctionTemplateEncodeResponseSchema = AuctionTemplateEncodeResponseSchema;
42
- const auctionTemplateContract = contract.router({
43
- listAuctionTemplates: {
44
- method: "GET",
45
- path: "/",
46
- query: zod_1.default.object({
47
- chainId: zod_1.default.coerce
48
- .number()
49
- .int()
50
- .refine((val) => Object.values(types_1.ChainID).includes(val), {
51
- message: "Invalid chain ID",
52
- })
53
- .optional()
54
- .default(types_1.ChainID.BASE_MAINNET)
55
- .describe("The chain ID of the auction templates to list"),
56
- }),
57
- responses: {
58
- 200: zod_1.default.object({
59
- result: zod_1.default.array(AuctionTemplateResponseSchema),
60
- }),
61
- },
62
- description: "List all auction templates for an integrator",
63
- },
64
- encodeAuctionTemplate: {
65
- method: "POST",
66
- path: "",
67
- query: zod_1.default.object({
68
- chainId: zod_1.default.coerce
69
- .number()
70
- .int()
71
- .refine((val) => Object.values(types_1.ChainID).includes(val), {
72
- message: "Invalid chain ID",
73
- })
41
+ const listAuctionTemplates = contract_1.oc
42
+ .route({ method: "GET", path: "/auction-templates", description: "List all auction templates for an integrator", tags: ["auctionTemplates"] })
43
+ .input(zod_1.default.object({
44
+ chainId: zod_1.default.coerce
45
+ .number()
46
+ .int()
47
+ .refine((val) => Object.values(types_1.ChainID).includes(val), {
48
+ message: "Invalid chain ID",
49
+ })
50
+ .optional()
51
+ .default(types_1.ChainID.BASE_MAINNET)
52
+ .describe("The chain ID of the auction templates to list"),
53
+ }))
54
+ .output(zod_1.default.object({ result: zod_1.default.array(AuctionTemplateResponseSchema) }));
55
+ const encodeAuctionTemplate = contract_1.oc
56
+ .route({
57
+ method: "POST",
58
+ path: "/auction-templates",
59
+ inputStructure: "detailed",
60
+ description: "Encode a auction template and return the payload to be signed and sent raw to the blockchain",
61
+ tags: ["auctionTemplates"],
62
+ })
63
+ .input(zod_1.default.object({
64
+ query: zod_1.default.object({
65
+ chainId: zod_1.default.coerce
66
+ .number()
67
+ .int()
68
+ .refine((val) => Object.values(types_1.ChainID).includes(val), {
69
+ message: "Invalid chain ID",
70
+ })
71
+ .optional()
72
+ .default(types_1.ChainID.BASE_MAINNET)
73
+ .describe("The chain ID of the auction to create"),
74
+ }),
75
+ body: zod_1.default.object({
76
+ template_id: zod_1.default.string().describe("The auction template ID (from the Long Team)"),
77
+ debug: zod_1.default.boolean().optional().default(false).describe("Whether to include debug information in the response"),
78
+ metadata: zod_1.default.object({
79
+ token_name: zod_1.default.string().describe("The name of the token (e.g. 'My Token')"),
80
+ token_symbol: zod_1.default.string().describe("The symbol of the token (e.g. 'MTK')"),
81
+ token_uri: zod_1.default.string().startsWith("ipfs://").default("ipfs://").describe("The URI of the token (e.g. 'ipfs://...')"),
82
+ user_address: types_1.hex.describe("The address of the owner of the token (e.g. '0x123...')"),
83
+ beneficiaries: zod_1.default
84
+ .array(zod_1.default.object({
85
+ beneficiary: types_1.hex.describe("Beneficiary address"),
86
+ shares: zod_1.default.string().describe("Shares in WAD format (1e18 = 100%)"),
87
+ }))
74
88
  .optional()
75
- .default(types_1.ChainID.BASE_MAINNET)
76
- .describe("The chain ID of the auction to create"),
89
+ .default([])
90
+ .describe("Additional beneficiaries to add to the template's beneficiaries. Will be merged and deduplicated."),
77
91
  }),
78
- body: zod_1.default.object({
79
- template_id: zod_1.default.string().describe("The auction template ID (from the Long Team)"),
80
- debug: zod_1.default.boolean().optional().default(false).describe("Whether to include debug information in the response"),
81
- metadata: zod_1.default.object({
82
- token_name: zod_1.default.string().describe("The name of the token (e.g. 'My Token')"),
83
- token_symbol: zod_1.default.string().describe("The symbol of the token (e.g. 'MTK')"),
84
- token_uri: zod_1.default.string().startsWith("ipfs://").default("ipfs://").describe("The URI of the token (e.g. 'ipfs://...')"),
85
- user_address: types_1.hex.describe("The address of the owner of the token (e.g. '0x123...')"),
86
- beneficiaries: zod_1.default
87
- .array(zod_1.default.object({
88
- beneficiary: types_1.hex.describe("Beneficiary address"),
89
- shares: zod_1.default.string().describe("Shares in WAD format (1e18 = 100%)"),
90
- }))
91
- .optional()
92
- .default([])
93
- .describe("Additional beneficiaries to add to the template's beneficiaries. Will be merged and deduplicated."),
94
- }),
95
- }),
96
- responses: {
97
- 200: zod_1.default.object({
98
- result: AuctionTemplateEncodeResponseSchema,
99
- }),
100
- },
101
- description: "Encode a auction template and return the payload to be signed and sent raw to the blockchain",
102
- },
103
- }, {
104
- pathPrefix: "/auction-templates",
105
- });
92
+ }),
93
+ }))
94
+ .output(zod_1.default.object({ result: AuctionTemplateEncodeResponseSchema }));
95
+ const auctionTemplateContract = { listAuctionTemplates, encodeAuctionTemplate };
106
96
  exports.auctionTemplateContract = auctionTemplateContract;
107
97
  //# sourceMappingURL=auction-template.contract.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"auction-template.contract.js","sourceRoot":"","sources":["../../src/contracts/auction-template.contract.ts"],"names":[],"mappings":";;;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C,OAAO,CAAC,KAAK,CAAC,CAAC,QAAQ,CAAC,sDAAsD,CAAC;YAC7G,QAAQ,EAAE,aAAC,CAAC,MAAM,CAAC;gBACf,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,yCAAyC,CAAC;gBAC1E,YAAY,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sCAAsC,CAAC;gBACzE,SAAS,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,QAAQ,CAAC,0CAA0C,CAAC;gBACnH,YAAY,EAAE,WAAG,CAAC,QAAQ,CAAC,yDAAyD,CAAC;gBACrF,aAAa,EAAE,aAAC;qBACX,KAAK,CACF,aAAC,CAAC,MAAM,CAAC;oBACL,WAAW,EAAE,WAAG,CAAC,QAAQ,CAAC,qBAAqB,CAAC;oBAChD,MAAM,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,oCAAoC,CAAC;iBACpE,CAAC,CACL;qBACA,QAAQ,EAAE;qBACV,OAAO,CAAC,EAAE,CAAC;qBACX,QAAQ,CAAC,mGAAmG,CAAC;aACrH,CAAC;SACL,CAAC;QACF,SAAS,EAAE;YACP,GAAG,EAAE,aAAC,CAAC,MAAM,CAAC;gBACV,MAAM,EAAE,mCAAmC;aAC9C,CAAC;SACL;QACD,WAAW,EAAE,8FAA8F;KAC9G;CACJ,EACD;IACI,UAAU,EAAE,oBAAoB;CACnC,CACJ,CAAC;AAEO,0DAAuB"}
1
+ {"version":3,"file":"auction-template.contract.js","sourceRoot":"","sources":["../../src/contracts/auction-template.contract.ts"],"names":[],"mappings":";;;;;;AAAA,6CAAoC;AACpC,8CAAoB;AAEpB,oCAAwC;AAExC,MAAM,6BAA6B,GAAG,aAAC,CAAC,MAAM,CAAC;IAC3C,EAAE,EAAE,aAAC,CAAC,MAAM,EAAE;IACd,IAAI,EAAE,aAA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