Documentation on AI Warp's REST API.
For information on authentication, see here.
For information on rate limiting, see here
Prompt the AI Provider and receive the full response.
Body
{ "prompt": "What's 1+1?" }
Response
{ "response": "..." }
Prompt the AI Provider and receive a streamed response. This endpoint supports Server Side Events.
Event types:
content
- Response chunkerror
- An error has occured and the stream is closed.
Body
{ "prompt": "What's 1+1?" }
Success response
event: content
data: {"response": "..."}
event: content
data: {"response": "..."}
Error response
event: error
data: {"code":"...","message":"..."}
When there is no more chunks to return or an error occurs, the stream is closed.