API keys

POST /me/api-keys Session only

Create a key; returns the plaintext token once.

Body

name string required
Label to tell keys apart.Example cli-laptop
expires_at string (RFC3339)
Optional expiry; omit for no expiry.
curl
curl -X POST "https://freehire.dev/api/v1/me/api-keys" \
  -H 'Content-Type: application/json' \
  -b cookies.txt \
  -d '{"name":"cli-laptop"}'
json — response
{ "data": { "id": 7, "name": "cli-laptop", "token_prefix": "fh_ab12", "token": "fh_ab12...REDACTED...full-token-shown-once" } }