How tasks work
- Client sends
POST /v1/agents/{name}/invokewith input - Agent processes the input and returns output
- No state is stored — each call is independent
Request format
The input payload passed to the agent handler. Shape depends on the agent type.
Optional execution context passed to the agent handler.
Response format
The agent’s response. Type depends on the agent type —
prompt and chat agents return strings, task agents return objects.Using the SDK
Context
The optionalcontext object is passed through to the agent handler. Use it for identity, metadata, or any execution context your agent needs.
- Available in the handler’s
contextparameter - Not stored or persisted — only available during execution
- Use
context.identityto scope behavior per user
Idempotency
Pass anIdempotency-Key header to prevent duplicate processing. If the same key is sent within a window, Reminix returns the cached result instead of re-executing the agent.
Idempotency keys are scoped to your project. The same key used across different agents will still be treated as separate requests.
Best for
- Prompt agents (
type: "prompt") — single prompt to response - Task agents (
type: "task") — structured input/output operations - Any stateless, single-shot operation