curl example
Get your API key
Register and create an API key before running this example.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Call Rock API with curl.
curl https://rockapi.ai/v1/chat/completions \
-H "Authorization: Bearer $ROCK_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"gpt-4o-mini","messages":[{"role":"user","content":"Hello"}]}'
