Overview
The order attribution system allows builders to attach custom headers to their customer orders before posting them to the CLOB. These additional headers enable Polymarket to attribute orders to your specific builder account, providing visibility into which orders originate from your platform.Builder API Credentials
Each builder will receive Builder API Key Credentials that look like this:Security Notice: Your Builder API keys must be kept secure. We provide both local and remote signing methods to help you protect these credentials.
Signing Methods
There are two methods available for signing orders and adding attribution headers: Remote Signing and Local Signing.Remote Signing (Recommended)
Remote signing is the recommended approach for protecting your Builder API credentials. With this method, your credentials never leave your secure server. How it works:- Your customer signs an order payload (ready to be sent to the CLOB)
- Instead of sending directly to the CLOB, the signed payload is sent to your builder signing server
- Your builder signing server uses your Builder API keys to cryptographically sign the entire payload and adds the authentication headers
- The fully signed payload (signed by both your customer and you as the builder) is then sent to the CLOB
token parameter allows you to add an authorization header to requests sent to your signing server, providing an additional layer of security.
Local Signing
If you control the entire order placement flow (including signing for your customers), you can sign orders locally before sending them to the CLOB. How it works:- Your system creates and signs the order on behalf of your customer
- Your system uses your Builder API credentials locally to add authentication headers
- The complete signed order with builder headers is sent directly to the CLOB
Authentication Headers
The builder signing process adds the following headers to each order request:POLY_BUILDER_API_KEY: Your builder API keyPOLY_BUILDER_TIMESTAMP: Unix timestamp of when the signature was createdPOLY_BUILDER_PASSPHRASE: Your builder passphrasePOLY_BUILDER_SIGNATURE: HMAC signature of the request
Using Our SDKs
Important: We strongly recommend using our official SDKs and server implementations. You do not need to implement the signing logic yourself.
- @polymarket/builder-signing-sdk: Core signing functionality
- @polymarket/builder-signing-server: Production-ready remote signing server
- @polymarket/clob-client: Updated CLOB client with built-in builder support
Next Steps
- Set up your builder signing server for remote signing
- Review the complete examples in the CLOB client repository
- Contact support@polymarket.com if you need assistance