TODO for AI Logo
TODOforAI API

Api Keys

Endpoint:/api/v1

API key management operations


List API keys

GET
/api/v1
/users/apikeys

Returns a list of API keys for the authenticated user

List API keys Responses

Successful operation

  • namestring
    Example: My API Key
  • idstring
    Example: apikey-123
  • createdAtinteger · int64
    Example: 1625097600000
  • isDefaultboolean
    Example: true

Create API key

POST
/api/v1
/users/apikeys

Creates a new API key for the authenticated user

Create API key Request Body

  • namestring · required
    Example: My API Key

Create API key Responses

API key created successfully

  • namestring
    Example: My API Key
  • idstring
    Example: apikey-123
  • createdAtinteger · int64
    Example: 1625097600000
  • isDefaultboolean
    Example: true

API key by name

GET
/api/v1
/users/apikeys/{name}

Returns an API key by name

API key by namepath Parameters

  • namestring · required

    Name of the API key

API key by name Responses

Successful operation

  • namestring
    Example: My API Key
  • idstring
    Example: apikey-123
  • createdAtinteger · int64
    Example: 1625097600000
  • isDefaultboolean
    Example: true

Delete API key

DELETE
/api/v1
/users/apikeys/{name}

Deletes an API key by name

Delete API keypath Parameters

  • namestring · required

    Name of the API key

Delete API key Responses

API key deleted successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully