Update Polymarket documentation - March 30, 2026

Updated 229 documentation pages reflecting latest official docs changes:
- API Reference: authentication, rate-limits, clients-sdks, market-data endpoints
- Developers: CLOB, Gamma Markets, RTDS, Sports Websocket, Builders, CTF
- Trading: fees, bridge, orders, orderbook, clients
- Polymarket Learn: get-started guides, deposits, trading
- Builders: tiers, api-keys, profile, examples, order-attribution
- Quickstart: overview, first-order, websocket guides
- Concepts: markets-events, prices-orderbook, resolution
- Market Makers: getting-started, trading, liquidity-rewards
- Resources: error-codes, contract-addresses, blockchain-data
This commit is contained in:
Etherdrake
2026-03-30 12:53:20 +02:00
parent 240ece03cc
commit 50a13414c0
229 changed files with 7322 additions and 935 deletions
@@ -2,91 +2,72 @@
> Fetch the complete documentation index at: https://docs.polymarket.com/llms.txt
> Use this file to discover all available pages before exploring further.
# Contract Addresses
# Data Resources
> All Polymarket smart contract addresses on Polygon
> Access Polymarket on-chain activity for data & analytics
All Polymarket contracts are deployed on **Polygon mainnet** (Chain ID: 137). This is the single source of truth for all contract addresses used across the platform.
Polymarket data that lands on the blockchain, such as trades, balances, positions, and redeems, is available through various on-chain analytics platforms and blockchain data providers. Polymarket also provides its own APIs and WebSockets. See the [API Endpoints reference](/quickstart/reference/endpoints) for more information.
The purpose of this page is to serve as a public good for Polymarket builders, researches, and analysts alike.
***
## Core Trading Contracts
## Data
| Contract | Address | Description |
| ------------------------ | -------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| CTF Exchange | [`0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E`](https://polygonscan.com/address/0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E) | Standard market order matching and settlement |
| Neg Risk CTF Exchange | [`0xC5d563A36AE78145C45a50134d48A1215220f80a`](https://polygonscan.com/address/0xC5d563A36AE78145C45a50134d48A1215220f80a) | Order matching for [neg risk](/advanced/neg-risk) (multi-outcome) markets |
| Neg Risk Adapter | [`0xd91E80cF2E7be2e162c6513ceD06f1dD0dA35296`](https://polygonscan.com/address/0xd91E80cF2E7be2e162c6513ceD06f1dD0dA35296) | Converts No tokens between outcomes in neg risk markets |
| Conditional Tokens (CTF) | [`0x4D97DCd97eC945f40cF65F87097ACe5EA0476045`](https://polygonscan.com/address/0x4D97DCd97eC945f40cF65F87097ACe5EA0476045) | ERC1155 token storage — split, merge, and redeem operations |
### Goldsky
***
[Goldsky](https://docs.goldsky.com/chains/polymarket) provides real-time streaming pipelines for Polymarket on-chain activity (i.e. trades, balances, positions, etc...) into your own database/data warehouse.
## Token Contracts
Goldsky also partnered with [ClickHouse](https://clickhouse.com) to create [CryptoHouse](https://crypto.clickhouse.com), where you can query Polymarket on-chain data using SQL.
| Contract | Address | Description |
| --------------------- | -------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------- |
| USDC.e (Bridged USDC) | [`0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174`](https://polygonscan.com/address/0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174) | Collateral token used for all Polymarket trading (6 decimals) |
### Dune
***
[Dune](https://dune.com) is a blockchain analytics platform that has Polymarket on-chain activity (i.e. trades, balances, positions, etc...). Query Polymarket data using SQL, create custom dashboards, and more.
## Wallet Factory Contracts
Here are a few simple queries to get started:
| Contract | Address | Description |
| ------------------------ | -------------------------------------------------------------------------------------------------------------------------- | --------------------- |
| Gnosis Safe Factory | [`0xaacfeea03eb1561c4e67d661e40682bd20e3541b`](https://polygonscan.com/address/0xaacfeea03eb1561c4e67d661e40682bd20e3541b) | Deploys Safe wallets |
| Polymarket Proxy Factory | [`0xaB45c5A4B0c941a2F231C04C3f49182e1A254052`](https://polygonscan.com/address/0xaB45c5A4B0c941a2F231C04C3f49182e1A254052) | Deploys proxy wallets |
| Query | Description | Link |
| ------------- | --------------------------------------------- | --------------------------------------------------- |
| Volume | Notional Volume and Maker & Taker USDC Volume | [View Dune Query](https://dune.com/queries/6545441) |
| TVL | USDC locked in Polymarket smart contracts | [View Dune Query](https://dune.com/queries/6588784) |
| Open Interest | Estimated market open interest, and over time | [View Dune Query](https://dune.com/queries/6555478) |
***
### Allium
## Resolution Contracts
[Allium](https://docs.allium.so/historical-data/predictions) is a blockchain analytics platform that has Polymarket on-chain activity (i.e. trades, balances, positions, etc...). Query Polymarket data using SQL, create custom dashboards, and more.
| Contract | Address | Description |
| --------------------- | -------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- |
| UMA Adapter | [`0x6A9D222616C90FcA5754cd1333cFD9b7fb6a4F74`](https://polygonscan.com/address/0x6A9D222616C90FcA5754cd1333cFD9b7fb6a4F74) | Adapter connecting Polymarket to the UMA Optimistic Oracle |
| UMA Optimistic Oracle | [`0xCB1822859cEF82Cd2Eb4E6276C7916e692995130`](https://polygonscan.com/address/0xCB1822859cEF82Cd2Eb4E6276C7916e692995130) | Handles market resolution proposals and disputes |
\--
***
## Dashboards
## Liquidity
Third-party blockchain analytics platforms that aggregate and visualize Polymarket data:
| Contract | Address | Description |
| --------------------------- | -------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------- |
| Uniswap v3 USDC.e/USDC Pool | [`0xd36ec33c8bed5a9f7b6630855f1533455b98a418`](https://polygonscan.com/address/0xd36ec33c8bed5a9f7b6630855f1533455b98a418) | Used for USDC.e ↔ USDC conversion during withdrawals |
<CardGroup cols={4}>
<Card title="Blockworks" img="https://pbs.twimg.com/profile_images/1651677302634483712/7s2FxV2K_400x400.jpg" href="https://blockworks.com/analytics/polymarket" />
***
<Card title="Artemis" img="https://pbs.twimg.com/profile_images/1896982195723546624/2XeO9mPb_400x400.png" href="https://app.artemisanalytics.com/asset/polymarket?from=assets" />
## Source Code
<Card title="Dune" img="https://pbs.twimg.com/profile_images/1986458079248986112/qq80s3hx_400x400.jpg" href="https://dune.com/discover/content/popular?q=polymarket&resource-type=dashboards" />
<CardGroup cols={2}>
<Card title="CTF Exchange" icon="github" href="https://github.com/Polymarket/ctf-exchange">
Order matching and settlement contracts
</Card>
<Card title="DeFiLlama" img="https://pbs.twimg.com/profile_images/1915756547705036800/rAeLzZqs_400x400.jpg" href="https://defillama.com/protocol/polymarket" />
<Card title="Conditional Tokens" icon="github" href="https://github.com/gnosis/conditional-tokens-contracts">
Gnosis Conditional Token Framework (ERC1155)
</Card>
<Card title="The Block" img="https://pbs.twimg.com/profile_images/1944749695525425152/9babG7Df_400x400.jpg" href="https://www.theblock.co/data/decentralized-finance/prediction-markets-and-betting" />
<Card title="Token Terminal" img="https://pbs.twimg.com/profile_images/1594678659222306817/SMum_RcQ_400x400.jpg" href="https://tokenterminal.com/explorer/projects/polymarket" />
<Card title="Allium" img="https://pbs.twimg.com/profile_images/1778926940407132160/UEwR3lHt_400x400.jpg" href="https://predictions.allium.so" />
</CardGroup>
***
### Community Dashboards
## Usage in Code
Community-created Dune dashboards of Polymarket on-chain analytics:
<CodeGroup>
```typescript TypeScript theme={null}
const ADDRESSES = {
USDC_E: "0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174",
CTF: "0x4D97DCd97eC945f40cF65F87097ACe5EA0476045",
CTF_EXCHANGE: "0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E",
NEG_RISK_CTF_EXCHANGE: "0xC5d563A36AE78145C45a50134d48A1215220f80a",
};
```
| Dashboard | Created By | Link |
| ------------------------------------------------- | ----------------------------------------------- | ---------------------------------------------------------------------------- |
| Polymarket Overview | [@datadashboards](https://x.com/datadashboards) | [View Dashboard](https://dune.com/datadashboards/polymarket-overview) |
| Polymarket Volume, OI, Markets, Addresses and TVL | [@hildobby](https://x.com/hildobby) | [View Dashboard](https://dune.com/hildobby/polymarket) |
| Polymarket Historical Accuracy | [@alexmccullaaa](https://x.com/alexmccullaaa) | [View Dashboard](https://dune.com/alexmccullough/how-accurate-is-polymarket) |
| Polymarket Builders Dashboard | [@defioasis](https://x.com/defioasis) | [View Dashboard](https://dune.com/gateresearch/pmbuilders) |
```python Python theme={null}
ADDRESSES = {
"USDC_E": "0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174",
"CTF": "0x4D97DCd97eC945f40cF65F87097ACe5EA0476045",
"CTF_EXCHANGE": "0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E",
"NEG_RISK_CTF_EXCHANGE": "0xC5d563A36AE78145C45a50134d48A1215220f80a",
}
```
</CodeGroup>
Built with [Mintlify](https://mintlify.com).
+4 -6
View File
@@ -20,17 +20,12 @@ A **builder** is a person, group, or organization that routes orders from users
</Card>
</CardGroup>
<Card title="Revenue Share" icon="percent">
Earn a share of fees on orders you route
</Card>
### What You Get
| Benefit | Description |
| ------------------- | ------------------------------------------------------------------------------- |
| **Relayer Access** | Gas-free wallet deployment, approvals, order execution and CTF operations |
| **Volume Tracking** | All orders attributed to your builder profile |
| **Weekly Rewards** | USDC rewards program based on volume (Verified+) |
| **Leaderboard** | Public visibility on [builders.polymarket.com](https://builders.polymarket.com) |
| **Support** | Telegram channel and engineering support (Verified+) |
@@ -88,7 +83,7 @@ A **builder** is a person, group, or organization that routes orders from users
</Step>
</Steps>
## SDKs & Libraries
## SDKs and Libraries
<CardGroup cols={2}>
<Card title="CLOB Client (TypeScript)" icon="github" href="https://github.com/Polymarket/clob-client">
@@ -216,3 +211,6 @@ For existing Magic Link users from Polymarket.com:
Set up gasless transactions for your users.
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).
+4 -6
View File
@@ -20,17 +20,12 @@ A **builder** is a person, group, or organization that routes orders from users
</Card>
</CardGroup>
<Card title="Revenue Share" icon="percent">
Earn a share of fees on orders you route
</Card>
### What You Get
| Benefit | Description |
| ------------------- | ------------------------------------------------------------------------------- |
| **Relayer Access** | Gas-free wallet deployment, approvals, order execution and CTF operations |
| **Volume Tracking** | All orders attributed to your builder profile |
| **Weekly Rewards** | USDC rewards program based on volume (Verified+) |
| **Leaderboard** | Public visibility on [builders.polymarket.com](https://builders.polymarket.com) |
| **Support** | Telegram channel and engineering support (Verified+) |
@@ -88,7 +83,7 @@ A **builder** is a person, group, or organization that routes orders from users
</Step>
</Steps>
## SDKs & Libraries
## SDKs and Libraries
<CardGroup cols={2}>
<Card title="CLOB Client (TypeScript)" icon="github" href="https://github.com/Polymarket/clob-client">
@@ -216,3 +211,6 @@ For existing Magic Link users from Polymarket.com:
Set up gasless transactions for your users.
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).
+40 -51
View File
@@ -6,53 +6,45 @@
> Rate limits, rewards, and how to upgrade
The Builder Program uses a tiered system to manage rate limits while rewarding high-performing integrations. Higher tiers unlock increased limits, weekly rewards, revenue sharing, and priority support.
The Builder Program uses a tiered system to manage rate limits while rewarding high-performing integrations. Higher tiers unlock increased limits, weekly rewards, and priority support.
## Feature Definitions
| Feature | Description |
| --------------------------- | -------------------------------------------------------------------------- |
| **Daily Relayer Txn Limit** | Maximum Relayer transactions per day for Safe/Proxy wallet operations |
| **API Rate Limits** | Rate limits for non-relayer endpoints (CLOB, Gamma, etc.) |
| **Subsidized Transactions** | Gas fees subsidized for Relayer and CLOB operations via Safe/Proxy wallets |
| **Order Attribution** | Orders tracked and attributed to your Builder profile |
| **RevShare Protocol** | Infrastructure allowing Builders to charge fees |
| **Leaderboard Visibility** | Visibility on the [Builder Leaderboard](https://builders.polymarket.com/) |
| **Weekly Rewards** | Weekly USDC rewards program for visible builders based on volume |
| **Grants** | Builder grants subject to approval, awarded based on innovation and impact |
| **Telegram Channel** | Private Builders channel for announcements and support |
| **Badge** | Verified Builder affiliate badge on your Builder profile |
| **Engineering Support** | Direct access to engineering team |
| **Marketing Support** | Promotion via official Polymarket social accounts |
| **Weekly Reward Boosts** | Multiplier on the weekly USDC rewards program for visible builders |
| **Priority Access** | Early access to new features and products |
| Feature | Description |
| --------------------------- | ------------------------------------------------------------------------- |
| **Daily Relayer Txn Limit** | Maximum Relayer transactions per day for Safe/Proxy wallet operations |
| **API Rate Limits** | Rate limits for non-relayer endpoints (CLOB, Gamma, etc.) |
| **Gasless Trading** | Gas fees subsidized for trading via Safe/Proxy wallets |
| **Order Attribution** | Orders tracked and attributed to your Builder profile |
| **Builder Fees** | Builders who route orders can charge fees and monetize on flow |
| **Leaderboard Visibility** | Visibility on the [Builder Leaderboard](https://builders.polymarket.com/) |
| **Telegram Channel** | Private Builders channel for announcements and support |
| **Engineering Support** | Direct access to engineering team |
| **Marketing Support** | Promotion via official Polymarket social accounts |
| **Priority Access** | Early access to new features and products |
***
## Tier Comparison
| Feature | Unverified | Verified | Partner |
| --------------------------- | :-----------------: | :-----------------: | :-----------------: |
| **Daily Relayer Txn Limit** | 100/day | 3,000/day | Unlimited |
| **API Rate Limits** | Standard | Standard | Highest |
| **Subsidized Transactions** | Yes | Yes | Yes |
| **Order Attribution** | Yes | Yes | Yes |
| **RevShare Protocol** | | Yes | Yes |
| **Leaderboard Visibility** | — | Yes | Yes |
| **Weekly Rewards** | — | Yes | Yes |
| **Grants** | Subject to approval | Subject to approval | Subject to approval |
| **Telegram Channel** | | Yes | Yes |
| **Badge** | — | Yes | Yes |
| **Engineering Support** | — | Standard | Elevated |
| **Marketing Support** | — | Standard | Elevated |
| **Weekly Reward Boosts** | — | — | Yes |
| **Priority Access** | — | — | Yes |
| Feature | Unverified | Verified | Partner |
| --------------------------- | :--------: | :-------: | :-------: |
| **Daily Relayer Txn Limit** | 100/day | 3,000/day | Unlimited |
| **API Rate Limits** | Standard | Standard | Highest |
| **Gasless Trading**\* | Yes | Yes | Yes |
| **Order Attribution** | Yes | Yes | Yes |
| **Builder Fees** | Yes | Yes | Yes |
| **Leaderboard Visibility** | — | Yes | Yes |
| **Telegram Channel** | — | Yes | Yes |
| **Engineering Support** | | Standard | Elevated |
| **Marketing Support** | | Standard | Elevated |
| **Priority Access** | — | — | Yes |
***
## Unverified
<Card title="100 transactions/day" icon="seedling">
<Card title="100 Relay transactions/day" icon="seedling">
The default tier for all new builders. Start immediately with no approval
required.
</Card>
@@ -68,48 +60,42 @@ The Builder Program uses a tiered system to manage rate limits while rewarding h
* Gasless trading on all CLOB orders through Safe/Proxy wallets
* Gas subsidized on all Relayer transactions up to daily limit (through Safe/Proxy wallets)
* Order attribution to your builder profile
* Access to all client libraries and documentation
***
## Verified
<Card title="3,000 transactions/day" icon="badge-check">
<Card title="3,000 Relay transactions/day" icon="badge-check">
For builders who need higher throughput. Requires manual approval.
</Card>
**How to upgrade:**
Contact us with:
Contact us at [builder@polymarket.com](mailto:builder@polymarket.com) with:
* Your Builder API Key
* Use case description
* Expected volume
* Links to your app, docs, or X profile
* Other relevant information (links, docs, decks, etc.)
**Unlocks over Unverified:**
* 30x daily Relayer transaction limit
* RevShare Protocol access
* Monetize with Builder fees
* Leaderboard visibility at [builders.polymarket.com](https://builders.polymarket.com)
* Weekly USDC rewards based on volume
* Private Telegram channel for announcements and support
* Verified affiliate badge and promotion from [@PolymarketBuild](https://x.com/PolymarketBuild)
* Weekly USDC rewards based on volume (subject to approval)
* Grants (subject to approval)
***
## Partner
<Card title="Unlimited transactions/day" icon="handshake">
<Card title="Unlimited Relay transactions/day" icon="handshake">
Enterprise tier for high-volume integrations and strategic partners.
</Card>
**How to apply:**
Reach out to [builder@polymarket.com](mailto:builder@polymarket.com) to discuss partnership opportunities.
**Unlocks over Verified:**
* Unlimited Relayer transactions
@@ -117,7 +103,6 @@ Reach out to [builder@polymarket.com](mailto:builder@polymarket.com) to discuss
* Elevated engineering support
* Elevated and coordinated marketing support
* Priority access to new features and products
* Multiplier on the Weekly Rewards Program
***
@@ -154,18 +139,19 @@ Ready to upgrade or have questions?
## FAQ
<AccordionGroup>
<Accordion title="How do I know if I'm verified?">
<Accordion title="How do I know if I am verified">
Verification is displayed in your [Builder Profile](https://polymarket.com/settings?tab=builder) settings.
</Accordion>
<Accordion title="What happens if I exceed my daily limit?">
<Accordion title="What happens if I exceed my daily limit">
Relayer requests beyond your daily limit will be rate-limited and return an
error. Consider upgrading to Verified or Partner tier if you're hitting
limits.
</Accordion>
<Accordion title="Can I get a temporary limit increase?">
For special events or product launches, contact [builder@polymarket.com](mailto:builder@polymarket.com).
<Accordion title="What if I just need more daily Relay transaction limits for my own wallet">
If you're not routing orders for other users (wallets), you can get unlimited
daily Relay transactions by obtaining a [Relayer API key](https://polymarket.com/settings?tab=api-keys).
</Accordion>
</AccordionGroup>
@@ -182,3 +168,6 @@ Ready to upgrade or have questions?
Configure your client to credit trades to your account.
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).
+4 -6
View File
@@ -20,17 +20,12 @@ A **builder** is a person, group, or organization that routes orders from users
</Card>
</CardGroup>
<Card title="Revenue Share" icon="percent">
Earn a share of fees on orders you route
</Card>
### What You Get
| Benefit | Description |
| ------------------- | ------------------------------------------------------------------------------- |
| **Relayer Access** | Gas-free wallet deployment, approvals, order execution and CTF operations |
| **Volume Tracking** | All orders attributed to your builder profile |
| **Weekly Rewards** | USDC rewards program based on volume (Verified+) |
| **Leaderboard** | Public visibility on [builders.polymarket.com](https://builders.polymarket.com) |
| **Support** | Telegram channel and engineering support (Verified+) |
@@ -88,7 +83,7 @@ A **builder** is a person, group, or organization that routes orders from users
</Step>
</Steps>
## SDKs & Libraries
## SDKs and Libraries
<CardGroup cols={2}>
<Card title="CLOB Client (TypeScript)" icon="github" href="https://github.com/Polymarket/clob-client">
@@ -216,3 +211,6 @@ For existing Magic Link users from Polymarket.com:
Set up gasless transactions for your users.
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).
+56 -1
View File
@@ -33,7 +33,7 @@ Each builder receives API credentials from their [Builder Profile](https://polym
***
## Remote Signing (Recommended)
## Remote Signing
Remote signing keeps your builder credentials secure on a server you control. The user's client sends order details to your server, which adds the builder headers before forwarding to the CLOB.
@@ -165,6 +165,27 @@ Point the CLOB client to your signing server:
# Orders automatically include builder headers
response = client.create_and_post_order(...)
```
```rust Rust theme={null}
use polymarket_client_sdk::auth::builder::Config as BuilderConfig;
use polymarket_client_sdk::clob::types::SignatureType;
// First, authenticate as a normal user
let client = Client::new("https://clob.polymarket.com", Config::default())?
.authentication_builder(&signer)
.signature_type(SignatureType::GnosisSafe)
.authenticate()
.await?;
// Then promote to builder with remote signing
let builder_config = BuilderConfig::remote(
"https://your-server.com/sign",
Some("optional-auth-token".to_owned()),
)?;
let client = client.promote_to_builder(builder_config).await?;
// Orders automatically include builder headers
```
</CodeGroup>
***
@@ -235,6 +256,21 @@ Sign orders locally when you control the entire order placement flow (e.g., your
# Orders automatically include builder headers
response = client.create_and_post_order(...)
```
```rust Rust theme={null}
use polymarket_client_sdk::auth::{Credentials, builder::Config as BuilderConfig};
let builder_creds = Credentials::new(
std::env::var("POLY_BUILDER_API_KEY")?.parse()?,
std::env::var("POLY_BUILDER_SECRET")?,
std::env::var("POLY_BUILDER_PASSPHRASE")?,
);
let builder_config = BuilderConfig::local(builder_creds);
let client = client.promote_to_builder(builder_config).await?;
// Orders automatically include builder headers
```
</CodeGroup>
***
@@ -281,6 +317,18 @@ Query trades attributed to your builder account to verify attribution is working
market="0xbd31dc8a..."
)
```
```rust Rust theme={null}
use polymarket_client_sdk::clob::types::request::TradesRequest;
let trades = client.builder_trades(&TradesRequest::default(), None).await?;
// Filtered by market
let request = TradesRequest::builder()
.market("0xbd31dc8a...".parse()?)
.build();
let market_trades = client.builder_trades(&request, None).await?;
```
</CodeGroup>
Each `BuilderTrade` includes: `id`, `market`, `assetId`, `side`, `size`, `price`, `status`, `outcome`, `owner`, `maker`, `transactionHash`, `matchTime`, `fee`, and `feeUsdc`.
@@ -297,6 +345,10 @@ If your credentials are compromised, revoke them immediately:
```python Python theme={null}
client.revoke_builder_api_key()
```
```rust Rust theme={null}
client.revoke_builder_api_key().await?;
```
</CodeGroup>
After revoking, generate new credentials from your [Builder Profile](https://polymarket.com/settings?tab=builder).
@@ -337,3 +389,6 @@ After revoking, generate new credentials from your [Builder Profile](https://pol
Build, sign, and submit orders
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).
+46 -21
View File
@@ -19,11 +19,10 @@ The relayer acts as a transaction sponsor:
5. The transaction executes from the user's wallet
<Note>
Gasless transactions require **Builder Program** membership. You'll need
Builder API credentials to authenticate with the relayer.
Gasless transactions require authentication with **Builder API Keys** or **Relayer API Keys**.
</Note>
## What's Covered
## What Is Covered
Polymarket pays gas for all operations routed through the relayer:
@@ -34,15 +33,51 @@ Polymarket pays gas for all operations routed through the relayer:
| **CTF operations** | Split, merge, and redeem positions |
| **Transfers** | Move tokens between addresses |
## Authentication
The relayer supports two authentication methods. Choose the one that fits your use case.
### Using Builder API Keys
Builder API Keys are for [Builder Program](/builders/overview) members. They authenticate via HMAC-SHA256 signed headers and are required to use the relayer SDKs.
All requests must include these headers:
| Header | Description |
| ------------------------- | ----------------------- |
| `POLY_BUILDER_API_KEY` | Your Builder API key |
| `POLY_BUILDER_TIMESTAMP` | Unix timestamp |
| `POLY_BUILDER_PASSPHRASE` | Your Builder passphrase |
| `POLY_BUILDER_SIGNATURE` | HMAC-SHA256 signature |
The SDKs handle header generation automatically when you provide your credentials via `BuilderConfig`.
### Using Relayer API Keys
Relayer API Keys are for market makers and anyone who needs a simpler alternative. You can create them from [Settings > API Keys](https://polymarket.com/settings?tab=api-keys) on the Polymarket website.
Include these headers with your requests:
| Header | Description |
| ------------------------- | ----------------------------- |
| `RELAYER_API_KEY` | Your Relayer API key |
| `RELAYER_API_KEY_ADDRESS` | The address that owns the key |
<Info>
If you want to use the Relayer API Key directly without the SDK, see the [Relayer API Reference](/api-reference/relayer).
</Info>
## Prerequisites
Before using the relayer, you need:
| Requirement | Source |
| ---------------------------- | -------------------------------------------------------------- |
| Builder API credentials | [Builder Profile](https://polymarket.com/settings?tab=builder) |
| User's private key or signer | Your wallet integration |
| USDC.e balance | For trading (not for gas) |
| Requirement | Source |
| ---------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- |
| Builder API credentials **or** Relayer API key | [Builder Profile](https://polymarket.com/settings?tab=builder) or [Settings > API Keys](https://polymarket.com/settings?tab=api-keys) |
| User's private key or signer | Your wallet integration |
| USDC.e balance | For trading (not for gas) |
> The below section is for the Builder SDKs only. If you want to use the Relayer API Key directly without the SDK, see the [Relayer API Reference](/api-reference/relayer).
## Installation
@@ -238,19 +273,6 @@ Initialize the relayer client with your signing configuration:
variables or a secrets manager.
</Warning>
### Relayer Authentication Headers
All requests to the relayer must include these authentication headers:
| Header | Description |
| ------------------------- | ----------------------- |
| `POLY_BUILDER_API_KEY` | Your Builder API key |
| `POLY_BUILDER_TIMESTAMP` | Unix timestamp |
| `POLY_BUILDER_PASSPHRASE` | Your Builder passphrase |
| `POLY_BUILDER_SIGNATURE` | HMAC-SHA256 signature |
The SDKs handle header generation automatically when you provide your credentials via `BuilderConfig`.
## Wallet Types
Choose a wallet type when initializing the client:
@@ -553,3 +575,6 @@ See [Contract Addresses](/resources/contract-addresses) for all Polymarket smart
Understand token operations like split, merge, and redeem.
</Card>
</CardGroup>
Built with [Mintlify](https://mintlify.com).