Skip to main content
POST
/
v1
/
accounts
/
{account_id}
/
users
/
{user_id}
/
apiKeys
Create API Key
curl --request POST \
  --url https://api.fireworks.ai/v1/accounts/{account_id}/users/{user_id}/apiKeys \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "apiKey": {
    "displayName": "<string>",
    "expireTime": "2023-11-07T05:31:56Z",
    "annotations": {}
  }
}
'
{
  "keyId": "<string>",
  "displayName": "<string>",
  "key": "<string>",
  "createTime": "2023-11-07T05:31:56Z",
  "secure": true,
  "email": "<string>",
  "prefix": "<string>",
  "expireTime": "2023-11-07T05:31:56Z",
  "annotations": {},
  "lastUsed": "2023-11-07T05:31:56Z"
}

Documentation Index

Fetch the complete documentation index at: https://fireworks.ai/docs/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication using your Fireworks API key. Format: Bearer <API_KEY>

Path Parameters

account_id
string
required

The Account Id

user_id
string
required

The User Id

Body

application/json
apiKey
object
required

The API key to be created.

Response

200 - application/json

A successful response.

keyId
string
read-only

Unique identifier (Key ID) for the API key, used primarily for deletion.

displayName
string

Display name for the API key, defaults to "default" if not specified.

key
string
read-only

The actual API key value, only available upon creation and not stored thereafter.

createTime
string<date-time>
read-only

Timestamp indicating when the API key was created.

secure
boolean
read-only

Indicates whether the plaintext value of the API key is unknown to Fireworks. If true, Fireworks does not know this API key's plaintext value. If false, Fireworks does know the plaintext value.

email
string
read-only

Email of the user who owns this API key.

prefix
string
read-only
expireTime
string<date-time>

Timestamp indicating when the API key will expire. If not set, the key never expires.

annotations
object

Optional key-value annotations for this API key.

lastUsed
string<date-time>
read-only

Timestamp indicating when the API key was last used. Not set if the key has never been used.