Skip to content

Commit c641d5e

Browse files
realfishsamclaude
andcommitted
Update changelog.md
v2.0.4 Release v2.0.3: Fix TypeScript SDK prebuild step - Run fix-generated.js in prebuild to ensure generated code is patched before compilation - Apply instanceOf function fix to committed generated files - Bump version to 2.0.3 for core and TypeScript SDK - Update changelog to reflect v2.0.2 & v2.0.3 combined release notes Revert "Release v2.0.3: Fix TypeScript SDK prebuild step" This reverts commit a691a48. Release v2.0.2: Fix TypeScript SDK build issues - Fix TypeScript SDK compilation errors caused by missing instanceOf function - Add automatic post-processing script for OpenAPI-generated code - Resolve isolatedModules errors in exchange WebSocket config exports - Bump version to 2.0.2 for core and TypeScript SDK - Update changelog with v2.0.2 release notes Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 8185bea commit c641d5e

File tree

79 files changed

+1610
-288
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

79 files changed

+1610
-288
lines changed

changelog.md

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,139 @@
22

33
All notable changes to this project will be documented in this file.
44

5+
## [2.0.2] & [2.0.3] - 2026-02-05
6+
7+
### Fixed
8+
9+
- **TypeScript SDK Build**: Fixed TypeScript compilation errors in generated SDK code caused by missing `instanceOf` function exports.
10+
- Added automatic post-processing script to patch OpenAPI-generated code.
11+
- Resolved `isolatedModules` TypeScript errors in core exchange modules (Kalshi, Limitless, Polymarket).
12+
- Changed `export` to `export type` for WebSocket config type re-exports.
13+
- **CI/CD Pipeline**: Resolved build failures in GitHub Actions for npm package publishing.
14+
15+
### Note
16+
17+
- Version 2.0.1 remains valid for Python SDK (`pmxt`). This release (2.0.2) specifically addresses TypeScript SDK (`pmxtjs`) build issues.
18+
19+
## [2.0.1] - 2026-02-05
20+
21+
### Breaking Changes
22+
23+
- **Removed Deprecated Methods**: All previously deprecated methods have been removed as part of the v2.0.0 cleanup.
24+
- `searchMarkets(query, params)`: Use `fetchMarkets({ query, ...params })` instead.
25+
- `getMarketsBySlug(slug)`: Use `fetchMarkets({ slug })` instead.
26+
- `searchEvents(query, params)`: Use `fetchEvents({ query, ...params })` instead.
27+
- **Removed Deprecated Fields**: Removed the deprecated `.id` field from `UnifiedMarket` and `MarketOutcome` models. Use `.marketId` and `.outcomeId` instead.
28+
- **Python SDK Signature Changes**: Refactored Python SDK to use direct keyword arguments instead of params dictionary.
29+
- `fetch_ohlcv` and `fetch_trades` now use kwargs for cleaner API calls.
30+
- All methods now follow the pattern: `method(arg1, arg2, key1=value1, key2=value2)` instead of `method(arg1, arg2, params={'key1': value1})`.
31+
32+
### Added
33+
34+
- **Limitless WebSocket Support**: Implemented real-time WebSocket streaming for Limitless exchange.
35+
- Added `watchOrderBook` and `watchTrades` support for live market data.
36+
- WebSocket connection management with automatic reconnection.
37+
- **Limitless On-Chain Balances**: Added on-chain balance fetching capability for Limitless exchange.
38+
- Queries blockchain directly for accurate balance information.
39+
- Integrated with Limitless SDK for seamless balance retrieval.
40+
- **Unified Error Handling System**: Implemented a comprehensive error handling system across all exchanges.
41+
- Consistent error messages and status codes across Polymarket, Kalshi, and Limitless.
42+
- Improved error mapping for better debugging and troubleshooting.
43+
- More robust compliance tests with proper error detection.
44+
- **Polymarket Signing Updates**: Enhanced Polymarket initialization with new authentication options.
45+
- Added `proxyAddress` parameter for explicit proxy wallet configuration.
46+
- Added `signatureType` parameter with support for "gnosis-safe" (default), "polyproxy", and "eoa".
47+
- Updated examples to demonstrate new signing methods.
48+
49+
### Changed
50+
51+
- **Migration to Unified API**: Completed migration to CCXT-style API patterns as outlined in `MIGRATION.md`.
52+
- All exchanges now use consistent parameter patterns with unified `params` objects (TypeScript) or keyword arguments (Python).
53+
- Improved API consistency across all supported exchanges.
54+
- **Updated Examples**: Refactored all examples in `examples/` directory to use v2.0.0 API patterns.
55+
- Removed legacy method calls and deprecated patterns.
56+
- Added examples demonstrating new Polymarket signing configuration.
57+
- Updated models and data structures throughout.
58+
- **OpenAPI Documentation**: Updated OpenAPI specification to include:
59+
- Limitless WebSocket endpoints and methods.
60+
- Missing methods from previous versions.
61+
- Corrected parameter definitions and response schemas.
62+
- **Limitless Documentation**: Improved Limitless exchange documentation with clearer setup instructions and API usage examples.
63+
64+
### Fixed
65+
66+
- **TypeScript Build Errors**: Resolved TypeScript compilation errors related to Limitless WebSocket implementation and server bundle generation.
67+
- **Python Error Parsing**: Fixed error parsing issues in the Python SDK that were causing incorrect error messages.
68+
- **Limitless Search Functionality**: Fixed semantic search parameters and query handling for Limitless markets.
69+
- Corrected parameter mapping for search endpoints.
70+
- Improved search result relevance and accuracy.
71+
- **Compliance Test Improvements**: Enhanced compliance test suite across all exchanges.
72+
- Replaced deprecated `.id` with `.outcomeId` and `.marketId` in all tests.
73+
- Improved error status and message detection for Kalshi `fetchOrder` tests.
74+
- Updated `fetchOrderBook` tests and reduced Limitless logging noise.
75+
- Increased `fetchMarkets` timeout to 120s for Kalshi to handle slower API responses.
76+
- Changed market fetch limit to 25 for better test reliability.
77+
- Fixed `fetchMarket` tests to properly handle Kalshi's data structure.
78+
- **Verbose Logging**: Removed excessive verbose logging from sidecar API, providing cleaner console output during normal operations.
79+
80+
### Improved
81+
82+
- **Error Handling Robustness**: Significantly improved error detection, mapping, and reporting across all exchanges.
83+
- **Test Reliability**: Enhanced compliance test suite with better timeout handling and more robust assertions.
84+
- **Code Quality**: Removed all deprecated code paths, resulting in cleaner and more maintainable codebase.
85+
- **Documentation Quality**: Updated README with authentication introduction and clearer getting started instructions.
86+
87+
### Migration Guide
88+
89+
For TypeScript users upgrading from v1.7.0:
90+
```typescript
91+
// v1.7.0 (deprecated methods)
92+
const markets = await exchange.searchMarkets("Trump", { limit: 10 });
93+
const market = await exchange.getMarketsBySlug("trump-wins-2024");
94+
95+
// v2.0.0 (unified API)
96+
const markets = await exchange.fetchMarkets({ query: "Trump", limit: 10 });
97+
const market = await exchange.fetchMarkets({ slug: "trump-wins-2024" });
98+
99+
// v1.7.0 (deprecated field)
100+
console.log(market.id);
101+
102+
// v2.0.0 (use specific ID fields)
103+
console.log(market.marketId);
104+
console.log(outcome.outcomeId);
105+
```
106+
107+
For Python users upgrading from v1.7.0:
108+
```python
109+
# v1.7.0 (params dictionary)
110+
candles = exchange.fetch_ohlcv(market_id, timeframe, params={'start': start_time})
111+
112+
# v2.0.0 (keyword arguments)
113+
candles = exchange.fetch_ohlcv(market_id, timeframe, start=start_time)
114+
115+
# v1.7.0 (deprecated field)
116+
print(market.id)
117+
118+
# v2.0.0 (use specific ID fields)
119+
print(market.market_id)
120+
print(outcome.outcome_id)
121+
```
122+
123+
Polymarket initialization with new signing options:
124+
```typescript
125+
// v2.0.0 (explicit proxy configuration)
126+
const poly = new Polymarket({
127+
credentials: {
128+
privateKey: "0x...",
129+
proxyAddress: "0x...", // Optional: your proxy wallet address
130+
signatureType: "gnosis-safe" // Optional: "gnosis-safe" (default), "polyproxy", or "eoa"
131+
}
132+
});
133+
```
134+
135+
## [2.0.0] - 2026-02-05
136+
Invalid
137+
5138
## [1.7.0] - 2026-02-03
6139

7140
### Added

core/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "pmxt-core",
3-
"version": "1.7.0",
3+
"version": "2.0.2",
44
"description": "pmxt is a unified prediction market data API. The ccxt for prediction markets.",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",
@@ -30,7 +30,7 @@
3030
"server": "tsx watch src/server/index.ts",
3131
"server:prod": "node dist/server/index.js",
3232
"generate:sdk:python": "npx @openapitools/openapi-generator-cli generate -i src/server/openapi.yaml -g python -o ../sdks/python/generated --package-name pmxt_internal --additional-properties=projectName=pmxt-internal,packageVersion=1.0.2,library=urllib3",
33-
"generate:sdk:typescript": "npx @openapitools/openapi-generator-cli generate -i src/server/openapi.yaml -g typescript-fetch -o ../sdks/typescript/generated --additional-properties=npmName=pmxtjs,npmVersion=1.0.2,supportsES6=true,typescriptThreePlus=true",
33+
"generate:sdk:typescript": "npx @openapitools/openapi-generator-cli generate -i src/server/openapi.yaml -g typescript-fetch -o ../sdks/typescript/generated --additional-properties=npmName=pmxtjs,npmVersion=1.0.2,supportsES6=true,typescriptThreePlus=true && node ../sdks/typescript/scripts/fix-generated.js",
3434
"generate:docs": "node ../scripts/generate-api-docs.js",
3535
"generate:sdk:all": "npm run generate:sdk:python && npm run generate:sdk:typescript && npm run generate:docs"
3636
},

core/src/exchanges/kalshi/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import { kalshiErrorMapper } from './errors';
1212
import { AuthenticationError } from '../../errors';
1313

1414
// Re-export for external use
15-
export { KalshiWebSocketConfig };
15+
export type { KalshiWebSocketConfig };
1616

1717
export interface KalshiExchangeOptions {
1818
credentials?: ExchangeCredentials;

core/src/exchanges/limitless/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ import { PortfolioFetcher, getContractAddress } from '@limitless-exchange/sdk';
3232
import { Contract, providers } from 'ethers';
3333

3434
// Re-export for external use
35-
export { LimitlessWebSocketConfig };
35+
export type { LimitlessWebSocketConfig };
3636

3737
export interface LimitlessExchangeOptions {
3838
credentials?: ExchangeCredentials;

core/src/exchanges/polymarket/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { polymarketErrorMapper } from './errors';
1313
import { AuthenticationError } from '../../errors';
1414

1515
// Re-export for external use
16-
export { PolymarketWebSocketConfig };
16+
export type { PolymarketWebSocketConfig };
1717

1818
export interface PolymarketExchangeOptions {
1919
credentials?: ExchangeCredentials;

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)