Marketplace →
Security & Authentication

Authentication & API Keys

All programmatic requests to protected TTX developer endpoints require a cryptographically generated API key with explicitly scoped permissions.


API Key Format

TTX API keys are generated using 16 cryptographically secure random bytes prefixed with ttx_live_:

ttx_live_3f9a7c2b5e1d4a8f096238b97a2c140e

The plaintext key secret is displayed strictly once upon creation in the Developer Console. The platform never exposes or logs this raw key again.

SHA-256 Storage Security

The TTX database never stores plaintext API secrets. Only the SHA-256 hash of the key is persisted:

keyHash = sha256(rawSecret) // Stored in database keyPrefix = rawSecret.substring(0, 16) // Used for dashboard identification

Authentication Headers

Pass your API key using the X-TTX-API-KEY header on every request:

# Example cURL request

curl -X GET "https://api.ttx.trade/api/v1/developer/profile" \

-H "X-TTX-API-KEY: ttx_live_3f9a7c2b..." \

-H "Accept: application/json"

Developer Scopes

Each API key is assigned granular scopes that restrict its access to specific modules:

ScopeGranted OperationsRestrictions
indicators:readQuery indicator catalogue, versions, and schemasRead-only
indicators:validateValidate parameters against data dependenciesValidation only
scripts:compileCompile TTX-IR AST and run sandbox executionMax 3,000ms execution limit
scripts:readInspect personal custom indicator source codeTenant-isolated
webhooks:manageRegister, test, and manage outbound webhooksRequires HTTPS endpoint
analytics:readRetrieve developer API usage and error logsTenant-isolated

⚠️ Zero Trading Permissions Guarantee

Developer API keys are strictly partitioned from all financial execution layers. A developer key cannot place orders, modify positions, withdraw funds, or access broker execution APIs. Any request containing an X-TTX-API-KEY on trading routes is rejected with HTTP 403 Forbidden.