Menu

Reference

Trial key for agents

One call, no account, and an agent has a key that works for 24 hours.

Copy as MarkdownOpen in ChatGPT (opens in a new tab)Open in Claude (opens in a new tab)

Text
POST https://api.millionshort.com/v1/keys/agent

Returns a short-lived API key with a small credit grant. It is the only /v1 call that needs no key, and it is meant for an agent that wants to try the API with no person at hand to sign up. For anything lasting, create a key in the dashboard.

Request

FieldTypeNotes
agentstring, up to 60 charactersRequired. The agent's name.
purposestring, up to 200 characters or null
Example
Shell
curl https://api.millionshort.com/v1/keys/agent \
  -H "Content-Type: application/json" \
  -d '{ "agent": "my-agent", "purpose": "trying the search API" }'

Response

data holds the key. It is shown once: keep it for the session, and do not write it into a file.

FieldTypeNotes
api_keystringThe ms-... key, shown exactly once.
tiertrial
rate_limitstring
expires_in_daysintegerexpires_in_hours rounded up to whole days.
expires_in_hoursinteger
expires_atstringWhen the key stops working.
team_idstring

What a trial key can do

Credits25. They cannot be topped up
Lifetime24 hours. expires_at gives the exact time
EndpointsEverything a normal key can call: search, sources, domain info
Sources per searchUp to 5
Results per searchUp to 50
explainYes
RenewalNone. When it ends, create a key in the dashboard

Limits

Trial keys are limited per network address and in total per day. Past a limit the call answers 429. All free and trial use together also has a daily ceiling; when it is reached, trial keys get 429 CAPACITY until midnight UTC, and paid keys are not affected.

The exact numbers are not published and can change. An agent that is refused should stop and ask its person for a key.

Cost

Free. Searches made with the key draw on its 25 credits at the usual rates.

Errors

400 INVALID_PARAM (no agent, or a value that is too long), 404 when trial keys are switched off, and 429 past a limit. See Errors.

For the agent reading this

  1. Call this endpoint once. Keep the key in memory or in an environment variable for the session.
  2. Send it as Authorization: Bearer <key> on every other call.
  3. Watch usage.credits on each response; you have 25.
  4. When you get 401 AUTH_INVALID_KEY after it worked before, the key has expired. Tell your person; do not ask for another in a loop.

The plain-text version of these steps is auth.md.

This page as Markdown ยท llms.txt