Skip to navigation

API Keys

View as Markdown

Secure API key authentication for server-to-server communication and automated trading systems, providing high-performance access to the NinjaTrader Partner API.

Overview

API keys provide a secure, efficient authentication method for server-to-server integrations, automated trading systems, and backend applications. API keys don’t require user interaction, making them ideal for automated workflows and risk management.

You will be provided with a Staging API key to use for development and testing. Once you are ready to go live, you will be provided with a Production API key to use for real users in production. Your Production API key should be beta tested for at least one week before going live. This helps ensure the prop firm application you build works with the Production API key and the production URLs.

API Key Types

Production API Keys

  • Use Case: Real users and production

Staging API Keys

  • Use Case: Development and testing

API Key Structure

When you receive an API key, it will include the following fields:

{
"name": "string",
"password": "string",
"appId": "string",
"appVersion": "1.0",
"sec": "string",
"cid": 0
}

appId and appVersion are free-form strings you choose; they are shown to end users in the trading UI.

When you request an access token, you can also include a deviceId: a string of up to 64 characters that uniquely and permanently identifies the device. It’s optional but recommended.