pmxtjs 2.33.5 → 2.34.1

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 (82) hide show
  1. package/dist/esm/generated/src/apis/DefaultApi.d.ts +72 -7
  2. package/dist/esm/generated/src/apis/DefaultApi.js +107 -6
  3. package/dist/esm/generated/src/models/ArbitrageOpportunity.d.ts +23 -0
  4. package/dist/esm/generated/src/models/ArbitrageOpportunity.js +14 -0
  5. package/dist/esm/generated/src/models/CompareMarketPricesRequest.d.ts +3 -3
  6. package/dist/esm/generated/src/models/CompareMarketPricesRequest.js +3 -3
  7. package/dist/esm/generated/src/models/FetchArbitrageParams.d.ts +17 -0
  8. package/dist/esm/generated/src/models/FetchArbitrageParams.js +12 -0
  9. package/dist/esm/generated/src/models/FetchEventMatchesParams.d.ts +7 -0
  10. package/dist/esm/generated/src/models/FetchEventMatchesParams.js +3 -0
  11. package/dist/esm/generated/src/models/FetchMarketMatches200Response.d.ts +46 -0
  12. package/dist/esm/generated/src/models/{FetchMatches200Response.js → FetchMarketMatches200Response.js} +8 -8
  13. package/dist/esm/generated/src/models/FetchMarketMatchesParams.d.ts +86 -0
  14. package/dist/esm/generated/src/models/{FetchMatchesParams.js → FetchMarketMatchesParams.js} +12 -9
  15. package/dist/esm/generated/src/models/UnifiedEvent.d.ts +6 -0
  16. package/dist/esm/generated/src/models/UnifiedEvent.js +2 -0
  17. package/dist/esm/generated/src/models/UnifiedMarket.d.ts +6 -0
  18. package/dist/esm/generated/src/models/UnifiedMarket.js +2 -0
  19. package/dist/esm/generated/src/models/index.d.ts +2 -2
  20. package/dist/esm/generated/src/models/index.js +2 -2
  21. package/dist/esm/index.d.ts +3 -0
  22. package/dist/esm/index.js +3 -0
  23. package/dist/esm/pmxt/client.js +2 -0
  24. package/dist/esm/pmxt/models.d.ts +66 -0
  25. package/dist/esm/pmxt/router.d.ts +133 -0
  26. package/dist/esm/pmxt/router.js +338 -0
  27. package/dist/generated/src/apis/DefaultApi.d.ts +72 -7
  28. package/dist/generated/src/apis/DefaultApi.js +108 -7
  29. package/dist/generated/src/models/ArbitrageOpportunity.d.ts +23 -0
  30. package/dist/generated/src/models/ArbitrageOpportunity.js +15 -0
  31. package/dist/generated/src/models/CompareMarketPricesRequest.d.ts +3 -3
  32. package/dist/generated/src/models/CompareMarketPricesRequest.js +3 -3
  33. package/dist/generated/src/models/FetchArbitrageParams.d.ts +17 -0
  34. package/dist/generated/src/models/FetchArbitrageParams.js +13 -0
  35. package/dist/generated/src/models/FetchEventMatchesParams.d.ts +7 -0
  36. package/dist/generated/src/models/FetchEventMatchesParams.js +3 -0
  37. package/dist/generated/src/models/FetchMarketMatches200Response.d.ts +46 -0
  38. package/dist/generated/src/models/{FetchMatches200Response.js → FetchMarketMatches200Response.js} +13 -13
  39. package/dist/generated/src/models/FetchMarketMatchesParams.d.ts +86 -0
  40. package/dist/generated/src/models/{FetchMatchesParams.js → FetchMarketMatchesParams.js} +18 -15
  41. package/dist/generated/src/models/UnifiedEvent.d.ts +6 -0
  42. package/dist/generated/src/models/UnifiedEvent.js +2 -0
  43. package/dist/generated/src/models/UnifiedMarket.d.ts +6 -0
  44. package/dist/generated/src/models/UnifiedMarket.js +2 -0
  45. package/dist/generated/src/models/index.d.ts +2 -2
  46. package/dist/generated/src/models/index.js +2 -2
  47. package/dist/index.d.ts +3 -0
  48. package/dist/index.js +5 -1
  49. package/dist/pmxt/client.js +2 -0
  50. package/dist/pmxt/models.d.ts +66 -0
  51. package/dist/pmxt/router.d.ts +133 -0
  52. package/dist/pmxt/router.js +375 -0
  53. package/generated/.openapi-generator/FILES +4 -4
  54. package/generated/docs/ArbitrageOpportunity.md +4 -0
  55. package/generated/docs/CompareMarketPricesRequest.md +1 -1
  56. package/generated/docs/DefaultApi.md +112 -10
  57. package/generated/docs/FetchArbitrageParams.md +2 -0
  58. package/generated/docs/FetchEventMatchesParams.md +2 -0
  59. package/generated/docs/{FetchMatches200Response.md → FetchMarketMatches200Response.md} +4 -4
  60. package/generated/docs/{FetchMatchesParams.md → FetchMarketMatchesParams.md} +6 -4
  61. package/generated/docs/UnifiedEvent.md +2 -0
  62. package/generated/docs/UnifiedMarket.md +2 -0
  63. package/generated/package.json +1 -1
  64. package/generated/src/apis/DefaultApi.ts +159 -10
  65. package/generated/src/models/ArbitrageOpportunity.ts +30 -0
  66. package/generated/src/models/CompareMarketPricesRequest.ts +11 -11
  67. package/generated/src/models/FetchArbitrageParams.ts +22 -0
  68. package/generated/src/models/FetchEventMatchesParams.ts +16 -0
  69. package/generated/src/models/{FetchMatches200Response.ts → FetchMarketMatches200Response.ts} +13 -13
  70. package/generated/src/models/{FetchMatchesParams.ts → FetchMarketMatchesParams.ts} +36 -20
  71. package/generated/src/models/UnifiedEvent.ts +8 -0
  72. package/generated/src/models/UnifiedMarket.ts +8 -0
  73. package/generated/src/models/index.ts +2 -2
  74. package/index.ts +3 -0
  75. package/package.json +2 -2
  76. package/pmxt/client.ts +2 -0
  77. package/pmxt/models.ts +97 -0
  78. package/pmxt/router.ts +385 -0
  79. package/dist/esm/generated/src/models/FetchMatches200Response.d.ts +0 -46
  80. package/dist/esm/generated/src/models/FetchMatchesParams.d.ts +0 -79
  81. package/dist/generated/src/models/FetchMatches200Response.d.ts +0 -46
  82. package/dist/generated/src/models/FetchMatchesParams.d.ts +0 -79
package/pmxt/router.ts ADDED
@@ -0,0 +1,385 @@
1
+ /**
2
+ * Router — cross-venue intelligence layer.
3
+ *
4
+ * Search, match, compare prices, find hedges, and detect arbitrage across
5
+ * every venue PMXT supports. Only requires a PMXT API key.
6
+ */
7
+
8
+ import { Exchange, ExchangeOptions } from "./client.js";
9
+ import {
10
+ MatchResult,
11
+ MatchRelation,
12
+ EventMatchResult,
13
+ PriceComparison,
14
+ ArbitrageOpportunity,
15
+ UnifiedMarket,
16
+ UnifiedEvent,
17
+ } from "./models.js";
18
+
19
+ function convertMarket(raw: any): UnifiedMarket {
20
+ const outcomes = (raw.outcomes || []).map((o: any) => ({
21
+ outcomeId: o.outcomeId,
22
+ marketId: o.marketId,
23
+ label: o.label,
24
+ price: o.price,
25
+ priceChange24h: o.priceChange24h,
26
+ metadata: o.metadata,
27
+ }));
28
+
29
+ const convertOutcome = (o: any) => o ? ({
30
+ outcomeId: o.outcomeId,
31
+ marketId: o.marketId,
32
+ label: o.label,
33
+ price: o.price,
34
+ priceChange24h: o.priceChange24h,
35
+ metadata: o.metadata,
36
+ }) : undefined;
37
+
38
+ return {
39
+ marketId: raw.marketId,
40
+ title: raw.title,
41
+ slug: raw.slug,
42
+ outcomes,
43
+ volume24h: raw.volume24h || 0,
44
+ liquidity: raw.liquidity || 0,
45
+ url: raw.url,
46
+ description: raw.description,
47
+ resolutionDate: raw.resolutionDate ? new Date(raw.resolutionDate) : undefined,
48
+ volume: raw.volume,
49
+ openInterest: raw.openInterest,
50
+ image: raw.image,
51
+ category: raw.category,
52
+ tags: raw.tags,
53
+ tickSize: raw.tickSize,
54
+ status: raw.status,
55
+ contractAddress: raw.contractAddress,
56
+ sourceExchange: raw.sourceExchange,
57
+ eventId: raw.eventId,
58
+ yes: convertOutcome(raw.yes),
59
+ no: convertOutcome(raw.no),
60
+ up: convertOutcome(raw.up),
61
+ down: convertOutcome(raw.down),
62
+ };
63
+ }
64
+
65
+ function convertEvent(raw: any): UnifiedEvent {
66
+ return {
67
+ id: raw.id,
68
+ title: raw.title,
69
+ description: raw.description,
70
+ slug: raw.slug,
71
+ markets: (raw.markets || []).map(convertMarket),
72
+ volume24h: raw.volume24h,
73
+ volume: raw.volume,
74
+ url: raw.url,
75
+ image: raw.image,
76
+ category: raw.category,
77
+ tags: raw.tags,
78
+ sourceExchange: raw.sourceExchange,
79
+ };
80
+ }
81
+
82
+ function parseMatchResult(raw: any): MatchResult {
83
+ const marketData = raw.market || {};
84
+ return {
85
+ market: convertMarket(marketData),
86
+ relation: raw.relation || 'identity',
87
+ confidence: raw.confidence || 0,
88
+ reasoning: raw.reasoning,
89
+ bestBid: raw.bestBid ?? marketData.bestBid,
90
+ bestAsk: raw.bestAsk ?? marketData.bestAsk,
91
+ };
92
+ }
93
+
94
+ /** Options for creating a Router. */
95
+ export interface RouterOptions {
96
+ /** PMXT API key (required for hosted mode). */
97
+ pmxtApiKey?: string;
98
+
99
+ /** Override the base URL (defaults to hosted API). */
100
+ baseUrl?: string;
101
+
102
+ /** Start local sidecar (default: false). */
103
+ autoStartServer?: boolean;
104
+ }
105
+
106
+ /**
107
+ * Cross-venue intelligence layer.
108
+ *
109
+ * Search markets and events across every venue, find semantically
110
+ * equivalent markets on other platforms, compare prices, discover
111
+ * hedges, and scan for arbitrage — all from a single PMXT API key.
112
+ *
113
+ * @example
114
+ * ```typescript
115
+ * import pmxt from "pmxtjs";
116
+ *
117
+ * const router = new pmxt.Router({ pmxtApiKey: "pmxt_live_..." });
118
+ * const markets = await router.fetchMarkets({ query: "election" });
119
+ * const matches = await router.fetchMarketMatches({ market: markets[0] });
120
+ * ```
121
+ */
122
+ export class Router extends Exchange {
123
+ constructor(options: RouterOptions = {}) {
124
+ super("router", options as ExchangeOptions);
125
+ }
126
+
127
+ // ------------------------------------------------------------------
128
+ // Matching
129
+ // ------------------------------------------------------------------
130
+
131
+ /**
132
+ * Find markets on other venues that correspond to a given market.
133
+ *
134
+ * @param params.market - A UnifiedMarket object (extracts marketId automatically).
135
+ * @param params.marketId - PMXT market ID.
136
+ * @param params.slug - Market slug (alternative to marketId).
137
+ * @param params.url - Market URL on the source venue.
138
+ * @param params.relation - Filter to a specific relation type.
139
+ * @param params.minConfidence - Minimum confidence threshold (0–1).
140
+ * @param params.limit - Maximum number of matches to return.
141
+ * @param params.includePrices - Attach live bestBid/bestAsk to each match.
142
+ */
143
+ async fetchMarketMatches(params: {
144
+ market?: UnifiedMarket;
145
+ marketId?: string;
146
+ slug?: string;
147
+ url?: string;
148
+ relation?: MatchRelation;
149
+ minConfidence?: number;
150
+ limit?: number;
151
+ includePrices?: boolean;
152
+ } = {}): Promise<MatchResult[]> {
153
+ await this.initPromise;
154
+ const query: Record<string, unknown> = {};
155
+ const marketId = params.marketId ?? params.market?.marketId;
156
+ if (marketId) query.marketId = marketId;
157
+ if (params.slug) query.slug = params.slug;
158
+ if (params.url) query.url = params.url;
159
+ if (params.relation) query.relation = params.relation;
160
+ if (params.minConfidence !== undefined) query.minConfidence = params.minConfidence;
161
+ if (params.limit !== undefined) query.limit = params.limit;
162
+ if (params.includePrices) query.includePrices = true;
163
+
164
+ try {
165
+ const json = await this.sidecarReadRequest('fetchMatches', query, [query]);
166
+ const data = this.handleResponse(json);
167
+ if (!data) return [];
168
+ return (data as any[]).map(parseMatchResult);
169
+ } catch (error) {
170
+ if (error instanceof Error) throw error;
171
+ throw new Error(`Failed to fetchMarketMatches: ${error}`);
172
+ }
173
+ }
174
+
175
+ /**
176
+ * @deprecated Use {@link fetchMarketMatches} instead.
177
+ */
178
+ async fetchMatches(params: {
179
+ market?: UnifiedMarket;
180
+ marketId?: string;
181
+ slug?: string;
182
+ url?: string;
183
+ relation?: MatchRelation;
184
+ minConfidence?: number;
185
+ limit?: number;
186
+ includePrices?: boolean;
187
+ } = {}): Promise<MatchResult[]> {
188
+ console.warn('[pmxt] fetchMatches is deprecated, use fetchMarketMatches instead');
189
+ return this.fetchMarketMatches(params);
190
+ }
191
+
192
+ /**
193
+ * Match an entire event across venues.
194
+ *
195
+ * @param params.event - A UnifiedEvent object (extracts id automatically).
196
+ * @param params.eventId - PMXT event ID.
197
+ * @param params.slug - Event slug.
198
+ * @param params.relation - Filter market matches to a specific relation type.
199
+ * @param params.minConfidence - Minimum confidence threshold (0–1).
200
+ * @param params.limit - Maximum number of event matches to return.
201
+ * @param params.includePrices - Attach live prices to each market match.
202
+ */
203
+ async fetchEventMatches(params: {
204
+ event?: UnifiedEvent;
205
+ eventId?: string;
206
+ slug?: string;
207
+ relation?: MatchRelation;
208
+ minConfidence?: number;
209
+ limit?: number;
210
+ includePrices?: boolean;
211
+ } = {}): Promise<EventMatchResult[]> {
212
+ await this.initPromise;
213
+ const query: Record<string, unknown> = {};
214
+ const eventId = params.eventId ?? params.event?.id;
215
+ if (eventId) query.eventId = eventId;
216
+ if (params.slug) query.slug = params.slug;
217
+ if (params.relation) query.relation = params.relation;
218
+ if (params.minConfidence !== undefined) query.minConfidence = params.minConfidence;
219
+ if (params.limit !== undefined) query.limit = params.limit;
220
+ if (params.includePrices) query.includePrices = true;
221
+
222
+ try {
223
+ const json = await this.sidecarReadRequest('fetchEventMatches', query, [query]);
224
+ const data = this.handleResponse(json);
225
+ if (!data) return [];
226
+ return (data as any[]).map((entry) => ({
227
+ event: convertEvent(entry.event || {}),
228
+ marketMatches: (entry.marketMatches || []).map(parseMatchResult),
229
+ }));
230
+ } catch (error) {
231
+ if (error instanceof Error) throw error;
232
+ throw new Error(`Failed to fetchEventMatches: ${error}`);
233
+ }
234
+ }
235
+
236
+ // ------------------------------------------------------------------
237
+ // Price comparison
238
+ // ------------------------------------------------------------------
239
+
240
+ /**
241
+ * Compare prices for the same market across venues.
242
+ *
243
+ * @param params.market - A UnifiedMarket object (extracts marketId automatically).
244
+ * @param params.marketId - PMXT market ID.
245
+ * @param params.slug - Market slug.
246
+ * @param params.url - Market URL.
247
+ */
248
+ async compareMarketPrices(params: {
249
+ market?: UnifiedMarket;
250
+ marketId?: string;
251
+ slug?: string;
252
+ url?: string;
253
+ } = {}): Promise<PriceComparison[]> {
254
+ await this.initPromise;
255
+ const query: Record<string, unknown> = {};
256
+ const marketId = params.marketId ?? params.market?.marketId;
257
+ if (marketId) query.marketId = marketId;
258
+ if (params.slug) query.slug = params.slug;
259
+ if (params.url) query.url = params.url;
260
+
261
+ try {
262
+ const url = `${this.config.basePath}/api/${this.exchangeName}/compareMarketPrices`;
263
+ const response = await fetch(url, {
264
+ method: 'POST',
265
+ headers: { 'Content-Type': 'application/json', ...this.getAuthHeaders() },
266
+ body: JSON.stringify({ args: [query], credentials: this.getCredentials() }),
267
+ });
268
+ if (!response.ok) {
269
+ const body = await response.json().catch(() => ({}));
270
+ if (body.error && typeof body.error === 'object') {
271
+ const { fromServerError } = await import('./errors.js');
272
+ throw fromServerError(body.error);
273
+ }
274
+ throw new Error(body.error?.message || response.statusText);
275
+ }
276
+ const json = await response.json();
277
+ const data = this.handleResponse(json);
278
+ if (!data) return [];
279
+ return (data as any[]).map((r) => ({
280
+ market: convertMarket(r.market || {}),
281
+ relation: r.relation || 'identity',
282
+ confidence: r.confidence || 0,
283
+ reasoning: r.reasoning,
284
+ bestBid: r.bestBid,
285
+ bestAsk: r.bestAsk,
286
+ venue: r.venue || '',
287
+ }));
288
+ } catch (error) {
289
+ if (error instanceof Error) throw error;
290
+ throw new Error(`Failed to compareMarketPrices: ${error}`);
291
+ }
292
+ }
293
+
294
+ // ------------------------------------------------------------------
295
+ // Hedging
296
+ // ------------------------------------------------------------------
297
+
298
+ /**
299
+ * Find markets that partially hedge a position.
300
+ *
301
+ * @param params.market - A UnifiedMarket object (extracts marketId automatically).
302
+ * @param params.marketId - PMXT market ID.
303
+ * @param params.slug - Market slug.
304
+ * @param params.url - Market URL.
305
+ */
306
+ async fetchHedges(params: {
307
+ market?: UnifiedMarket;
308
+ marketId?: string;
309
+ slug?: string;
310
+ url?: string;
311
+ } = {}): Promise<PriceComparison[]> {
312
+ await this.initPromise;
313
+ const query: Record<string, unknown> = {};
314
+ const marketId = params.marketId ?? params.market?.marketId;
315
+ if (marketId) query.marketId = marketId;
316
+ if (params.slug) query.slug = params.slug;
317
+ if (params.url) query.url = params.url;
318
+
319
+ try {
320
+ const json = await this.sidecarReadRequest('fetchHedges', query, [query]);
321
+ const data = this.handleResponse(json);
322
+ if (!data) return [];
323
+ return (data as any[]).map((r) => ({
324
+ market: convertMarket(r.market || {}),
325
+ relation: r.relation || 'identity',
326
+ confidence: r.confidence || 0,
327
+ reasoning: r.reasoning,
328
+ bestBid: r.bestBid,
329
+ bestAsk: r.bestAsk,
330
+ venue: r.venue || '',
331
+ }));
332
+ } catch (error) {
333
+ if (error instanceof Error) throw error;
334
+ throw new Error(`Failed to fetchHedges: ${error}`);
335
+ }
336
+ }
337
+
338
+ // ------------------------------------------------------------------
339
+ // Arbitrage
340
+ // ------------------------------------------------------------------
341
+
342
+ /**
343
+ * Scan for cross-venue arbitrage opportunities.
344
+ *
345
+ * @param params.minSpread - Only return pairs with spread >= this value.
346
+ * @param params.category - Filter source markets by category.
347
+ * @param params.limit - Max source markets to scan (default: 50).
348
+ * @param params.relations - Relation types to include (default: ['identity']).
349
+ */
350
+ async fetchArbitrage(params: {
351
+ minSpread?: number;
352
+ category?: string;
353
+ limit?: number;
354
+ relations?: MatchRelation[];
355
+ } = {}): Promise<ArbitrageOpportunity[]> {
356
+ await this.initPromise;
357
+ const query: Record<string, unknown> = {};
358
+ if (params.minSpread !== undefined) query.minSpread = params.minSpread;
359
+ if (params.category) query.category = params.category;
360
+ if (params.limit !== undefined) query.limit = params.limit;
361
+ if (params.relations && params.relations.length > 0) {
362
+ query.relations = params.relations.join(',');
363
+ }
364
+
365
+ try {
366
+ const json = await this.sidecarReadRequest('fetchArbitrage', query, [query]);
367
+ const data = this.handleResponse(json);
368
+ if (!data) return [];
369
+ return (data as any[]).map((r) => ({
370
+ marketA: convertMarket(r.marketA || {}),
371
+ marketB: convertMarket(r.marketB || {}),
372
+ spread: r.spread || 0,
373
+ buyVenue: r.buyVenue || '',
374
+ sellVenue: r.sellVenue || '',
375
+ buyPrice: r.buyPrice || 0,
376
+ sellPrice: r.sellPrice || 0,
377
+ relation: r.relation,
378
+ confidence: r.confidence,
379
+ }));
380
+ } catch (error) {
381
+ if (error instanceof Error) throw error;
382
+ throw new Error(`Failed to fetchArbitrage: ${error}`);
383
+ }
384
+ }
385
+ }
@@ -1,46 +0,0 @@
1
- /**
2
- * PMXT Sidecar API
3
- * A unified local sidecar API for prediction markets (Polymarket, Kalshi, Limitless). This API acts as a JSON-RPC-style gateway. Each endpoint corresponds to a specific method on the generic exchange implementation.
4
- *
5
- * The version of the OpenAPI document: 0.4.4
6
- *
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- import type { ErrorDetail } from './ErrorDetail.js';
13
- import type { MatchResult } from './MatchResult.js';
14
- /**
15
- *
16
- * @export
17
- * @interface FetchMatches200Response
18
- */
19
- export interface FetchMatches200Response {
20
- /**
21
- *
22
- * @type {boolean}
23
- * @memberof FetchMatches200Response
24
- */
25
- success?: boolean;
26
- /**
27
- *
28
- * @type {ErrorDetail}
29
- * @memberof FetchMatches200Response
30
- */
31
- error?: ErrorDetail;
32
- /**
33
- *
34
- * @type {Array<MatchResult>}
35
- * @memberof FetchMatches200Response
36
- */
37
- data?: Array<MatchResult>;
38
- }
39
- /**
40
- * Check if a given object implements the FetchMatches200Response interface.
41
- */
42
- export declare function instanceOfFetchMatches200Response(value: object): value is FetchMatches200Response;
43
- export declare function FetchMatches200ResponseFromJSON(json: any): FetchMatches200Response;
44
- export declare function FetchMatches200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FetchMatches200Response;
45
- export declare function FetchMatches200ResponseToJSON(json: any): FetchMatches200Response;
46
- export declare function FetchMatches200ResponseToJSONTyped(value?: FetchMatches200Response | null, ignoreDiscriminator?: boolean): any;
@@ -1,79 +0,0 @@
1
- /**
2
- * PMXT Sidecar API
3
- * A unified local sidecar API for prediction markets (Polymarket, Kalshi, Limitless). This API acts as a JSON-RPC-style gateway. Each endpoint corresponds to a specific method on the generic exchange implementation.
4
- *
5
- * The version of the OpenAPI document: 0.4.4
6
- *
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- /**
13
- *
14
- * @export
15
- * @interface FetchMatchesParams
16
- */
17
- export interface FetchMatchesParams {
18
- /**
19
- *
20
- * @type {string}
21
- * @memberof FetchMatchesParams
22
- */
23
- marketId?: string;
24
- /**
25
- *
26
- * @type {string}
27
- * @memberof FetchMatchesParams
28
- */
29
- slug?: string;
30
- /**
31
- *
32
- * @type {string}
33
- * @memberof FetchMatchesParams
34
- */
35
- url?: string;
36
- /**
37
- *
38
- * @type {string}
39
- * @memberof FetchMatchesParams
40
- */
41
- relation?: FetchMatchesParamsRelationEnum;
42
- /**
43
- *
44
- * @type {number}
45
- * @memberof FetchMatchesParams
46
- */
47
- minConfidence?: number;
48
- /**
49
- *
50
- * @type {number}
51
- * @memberof FetchMatchesParams
52
- */
53
- limit?: number;
54
- /**
55
- *
56
- * @type {boolean}
57
- * @memberof FetchMatchesParams
58
- */
59
- includePrices?: boolean;
60
- }
61
- /**
62
- * @export
63
- */
64
- export declare const FetchMatchesParamsRelationEnum: {
65
- readonly Identity: "identity";
66
- readonly Subset: "subset";
67
- readonly Superset: "superset";
68
- readonly Overlap: "overlap";
69
- readonly Disjoint: "disjoint";
70
- };
71
- export type FetchMatchesParamsRelationEnum = typeof FetchMatchesParamsRelationEnum[keyof typeof FetchMatchesParamsRelationEnum];
72
- /**
73
- * Check if a given object implements the FetchMatchesParams interface.
74
- */
75
- export declare function instanceOfFetchMatchesParams(value: object): value is FetchMatchesParams;
76
- export declare function FetchMatchesParamsFromJSON(json: any): FetchMatchesParams;
77
- export declare function FetchMatchesParamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): FetchMatchesParams;
78
- export declare function FetchMatchesParamsToJSON(json: any): FetchMatchesParams;
79
- export declare function FetchMatchesParamsToJSONTyped(value?: FetchMatchesParams | null, ignoreDiscriminator?: boolean): any;
@@ -1,46 +0,0 @@
1
- /**
2
- * PMXT Sidecar API
3
- * A unified local sidecar API for prediction markets (Polymarket, Kalshi, Limitless). This API acts as a JSON-RPC-style gateway. Each endpoint corresponds to a specific method on the generic exchange implementation.
4
- *
5
- * The version of the OpenAPI document: 0.4.4
6
- *
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- import type { ErrorDetail } from './ErrorDetail';
13
- import type { MatchResult } from './MatchResult';
14
- /**
15
- *
16
- * @export
17
- * @interface FetchMatches200Response
18
- */
19
- export interface FetchMatches200Response {
20
- /**
21
- *
22
- * @type {boolean}
23
- * @memberof FetchMatches200Response
24
- */
25
- success?: boolean;
26
- /**
27
- *
28
- * @type {ErrorDetail}
29
- * @memberof FetchMatches200Response
30
- */
31
- error?: ErrorDetail;
32
- /**
33
- *
34
- * @type {Array<MatchResult>}
35
- * @memberof FetchMatches200Response
36
- */
37
- data?: Array<MatchResult>;
38
- }
39
- /**
40
- * Check if a given object implements the FetchMatches200Response interface.
41
- */
42
- export declare function instanceOfFetchMatches200Response(value: object): value is FetchMatches200Response;
43
- export declare function FetchMatches200ResponseFromJSON(json: any): FetchMatches200Response;
44
- export declare function FetchMatches200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FetchMatches200Response;
45
- export declare function FetchMatches200ResponseToJSON(json: any): FetchMatches200Response;
46
- export declare function FetchMatches200ResponseToJSONTyped(value?: FetchMatches200Response | null, ignoreDiscriminator?: boolean): any;
@@ -1,79 +0,0 @@
1
- /**
2
- * PMXT Sidecar API
3
- * A unified local sidecar API for prediction markets (Polymarket, Kalshi, Limitless). This API acts as a JSON-RPC-style gateway. Each endpoint corresponds to a specific method on the generic exchange implementation.
4
- *
5
- * The version of the OpenAPI document: 0.4.4
6
- *
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- /**
13
- *
14
- * @export
15
- * @interface FetchMatchesParams
16
- */
17
- export interface FetchMatchesParams {
18
- /**
19
- *
20
- * @type {string}
21
- * @memberof FetchMatchesParams
22
- */
23
- marketId?: string;
24
- /**
25
- *
26
- * @type {string}
27
- * @memberof FetchMatchesParams
28
- */
29
- slug?: string;
30
- /**
31
- *
32
- * @type {string}
33
- * @memberof FetchMatchesParams
34
- */
35
- url?: string;
36
- /**
37
- *
38
- * @type {string}
39
- * @memberof FetchMatchesParams
40
- */
41
- relation?: FetchMatchesParamsRelationEnum;
42
- /**
43
- *
44
- * @type {number}
45
- * @memberof FetchMatchesParams
46
- */
47
- minConfidence?: number;
48
- /**
49
- *
50
- * @type {number}
51
- * @memberof FetchMatchesParams
52
- */
53
- limit?: number;
54
- /**
55
- *
56
- * @type {boolean}
57
- * @memberof FetchMatchesParams
58
- */
59
- includePrices?: boolean;
60
- }
61
- /**
62
- * @export
63
- */
64
- export declare const FetchMatchesParamsRelationEnum: {
65
- readonly Identity: "identity";
66
- readonly Subset: "subset";
67
- readonly Superset: "superset";
68
- readonly Overlap: "overlap";
69
- readonly Disjoint: "disjoint";
70
- };
71
- export type FetchMatchesParamsRelationEnum = typeof FetchMatchesParamsRelationEnum[keyof typeof FetchMatchesParamsRelationEnum];
72
- /**
73
- * Check if a given object implements the FetchMatchesParams interface.
74
- */
75
- export declare function instanceOfFetchMatchesParams(value: object): value is FetchMatchesParams;
76
- export declare function FetchMatchesParamsFromJSON(json: any): FetchMatchesParams;
77
- export declare function FetchMatchesParamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): FetchMatchesParams;
78
- export declare function FetchMatchesParamsToJSON(json: any): FetchMatchesParams;
79
- export declare function FetchMatchesParamsToJSONTyped(value?: FetchMatchesParams | null, ignoreDiscriminator?: boolean): any;