---
title: "Cancel a prospective intention"
method: POST
path: "/api/agent/intentions/{id}/cancel"
tags: ["Agent"]
---

# Cancel a prospective intention

`POST /api/agent/intentions/{id}/cancel`

## Request

- Base URL: `http://localhost:38200`
- URL: `http://localhost:38200/api/agent/intentions/{id}/cancel`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `token`

## Path parameters

- `id` integer, required

## Response `200`

Cancelled intention.

- AgentProspectiveIntention: T374 - a future-triggered "remember to remember" (`prospective_intentions` row).
  - `id` integer
  - `tenantId` integer
  - `agentId` integer, nullable: Null = fires for any agent's boot in this tenant.
  - `triggerType` 'event' | 'condition' | 'time'
  - `triggerSpec` object
  - `payloadContextId` integer
  - `reason` string, nullable
  - `createdBy` integer, nullable
  - `status` 'active' | 'fired' | 'delivered' | 'expired' | 'cancelled'
  - `createdAt` string, date-time
  - `firedAt` string, date-time, nullable
  - `deliveredAt` string, date-time, nullable
  - `expiresAt` string, date-time, nullable

## Other responses

- `401`: Missing or invalid credentials.
- `404`: Not found, or not cancellable (must be active).

---

[API](https://skmtc.dev/contextq/apis/contextq-api.md) · [All operations](https://skmtc.dev/contextq/apis/contextq-api/llms.txt) · [OpenAPI document](https://skmtc.dev/contextq/apis/contextq-api/revisions/7afc44056a22?raw)
