Overview
LuckyLobster uses two authentication systems:- User Authentication - For accessing the dashboard (email/password, social login, passkeys)
- API Key Authentication - For agent/programmatic access to the trading API
User Authentication
Supported Methods
Email & Password
Traditional email/password with optional 2FA
Social Login
Google, GitHub, and more
Passkeys
Biometric authentication (Face ID, Touch ID, Windows Hello)
Two-Factor Authentication (2FA)
We strongly recommend enabling 2FA for additional security:- Go to Dashboard > Settings > Security
- Click Enable 2FA
- Scan the QR code with your authenticator app (Google Authenticator, Authy, etc.)
- Enter the verification code to confirm
API Key Authentication
How API Keys Are Created
API keys are generated through the device authorization flow when an AI agent links to your account. There is no manual “Create API Key” button - instead:- Your AI agent initiates the device flow (
POST /api/auth/device) - You visit the link page and enter the code shown by your agent
- After you approve, the agent receives an
ll_*API key automatically
API Key Format
- Prefix:
ll_ - Hash: 64-character secure random string
Using API Keys
Include your API key in theAuthorization header:
Permission Scopes
All linked agents receive the standard set of permissions:| Scope | Description | Endpoints |
|---|---|---|
read | Read-only access | Markets, balance, positions, order history |
trade | Place orders | POST /orders |
cancel | Cancel open orders | DELETE /orders |
redeem | Redeem settled markets | POST /settlements/redeem |
Rate Limiting
API keys are rate limited to protect against abuse:- Default: 100 requests/minute
- Headers: Check
X-RateLimit-*headers in responses
429 Too Many Requests response:
Budget Limits
You can configure spending limits for each agent at Dashboard > Manage Agents:| Setting | Description |
|---|---|
| Fixed Limit | Maximum USDC the agent can spend |
| Budget Percent | Percentage of wallet balance the agent can use |
| Max Position Value | Cap on total open position value |
Revoking API Keys
To revoke an agent’s API key:- Go to Dashboard > Manage Agents
- Find the agent you want to revoke
- Click the Revoke button
- Confirm the action
Security Best Practices
Never expose API keys in client-side code
Never expose API keys in client-side code
API keys should only be used server-side or in secure agent environments.
Never include them in browser JavaScript, mobile apps, or public repositories.
Link separate agents for different use cases
Link separate agents for different use cases
Each agent gets its own API key through the device flow.
This gives you individual budget tracking and selective revocation.
Use conservative budget limits
Use conservative budget limits
Start with low budget limits and increase as needed.
This protects against bugs or unexpected agent behavior.
Pause agents when not in use
Pause agents when not in use
Use the pause feature in Manage Agents to temporarily disable an agent
without revoking its key. You can resume it later.
Wallet Security
Your Polymarket wallet private key is protected with:- AES-256-GCM encryption at rest
- Per-wallet unique IV (initialization vector)
- Server-side only decryption during order signing
- No client-side key exposure
Audit Logging
All sensitive operations are logged:- Agent linking/revocation
- Order placement
- Wallet operations
- Login attempts
API Reference
Auth Endpoints
Full API authentication documentation