Skip to main content
POST
/
api_keys
Create API Key
curl --request POST \
  --url https://api.elections.kalshi.com/trade-api/v2/api_keys \
  --header 'Content-Type: application/json' \
  --header 'KALSHI-ACCESS-KEY: <api-key>' \
  --header 'KALSHI-ACCESS-SIGNATURE: <api-key>' \
  --header 'KALSHI-ACCESS-TIMESTAMP: <api-key>' \
  --data '{
  "name": "<string>",
  "public_key": "<string>"
}'
{
  "api_key_id": "<string>"
}

Authorizations

KALSHI-ACCESS-KEY
string
header
required

Your API key ID

KALSHI-ACCESS-SIGNATURE
string
header
required

RSA-PSS signature of the request

KALSHI-ACCESS-TIMESTAMP
string
header
required

Request timestamp in milliseconds

Body

application/json
name
string
required

Name for the API key. This helps identify the key's purpose

public_key
string
required

RSA public key in PEM format. This will be used to verify signatures on API requests

Response

API key created successfully

api_key_id
string
required

Unique identifier for the newly created API key

I