Skip to main content
POST
/
manage-api-keys
curl -X POST https://api.magpipe.ai/functions/v1/manage-api-keys \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"action": "list"}'
{
  "keys": [
    {
      "id": "b007638d-9550-4cc4-b35f-d11632d77d08",
      "name": "Production",
      "key_prefix": "mgp_0357",
      "webhook_url": "https://your-server.com/webhook",
      "webhook_secret": "whsec_example00000000000000000000...",
      "is_active": true,
      "created_at": "2026-02-18T06:09:30.462859+00:00",
      "last_used_at": "2026-02-18T10:05:06.609+00:00"
    },
    {
      "id": "3a08acc2-ff3b-40db-83b5-53840e802da5",
      "name": "Testing",
      "key_prefix": "mgp_c232",
      "webhook_url": null,
      "webhook_secret": null,
      "is_active": true,
      "created_at": "2026-02-11T23:28:20.111629+00:00",
      "last_used_at": null
    }
  ]
}
Retrieve all API keys for your account, including webhook configuration.

Request Body

action
string
required
Must be list.

Response

keys
array
Array of API key objects.
curl -X POST https://api.magpipe.ai/functions/v1/manage-api-keys \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"action": "list"}'
{
  "keys": [
    {
      "id": "b007638d-9550-4cc4-b35f-d11632d77d08",
      "name": "Production",
      "key_prefix": "mgp_0357",
      "webhook_url": "https://your-server.com/webhook",
      "webhook_secret": "whsec_example00000000000000000000...",
      "is_active": true,
      "created_at": "2026-02-18T06:09:30.462859+00:00",
      "last_used_at": "2026-02-18T10:05:06.609+00:00"
    },
    {
      "id": "3a08acc2-ff3b-40db-83b5-53840e802da5",
      "name": "Testing",
      "key_prefix": "mgp_c232",
      "webhook_url": null,
      "webhook_secret": null,
      "is_active": true,
      "created_at": "2026-02-11T23:28:20.111629+00:00",
      "last_used_at": null
    }
  ]
}