Skip to main content
POST
Decline a secret request
Declines a secret request as the web app’s card’s Not now does: only the member it was issued to (for_user_id), no value is stored, and the Session’s waiting turn continues told the request was declined. When someone has written in the Session since the request, the request reads moved_past and is refused with 409 input_request_not_pending; when the value is already stored, nothing is declined and the call is refused with 409 input_request_not_waiting. Calling it again on a declined request returns it; a request that ended another way is refused with 409 input_request_not_pending. Returns the request as getSessionInputRequest reads it afterwards. Scope: run

Authorizations

Authorization
string
header
required

Your Reason API key from Settings › API keys. New keys use reason_; legacy ara_ keys remain accepted. Keys are capability-scoped: run, mcp:read, mcp:write, secrets:read, secrets:write, sessions:read, sessions:debug, devices:read, devices:write, devices:use, computers:read, computers:write, ssh:write, knowledge:read, memory:read, memory:write, skills:read, skills:write, pages:read, pages:write, repos:read, repos:write, reviews:read, reviews:write, deployment:read, analytics:read, org:read, org:write, attachments:read, attachments:write, guardrails:read, guardrails:write, network:read, network:write, automations:read, automations:write, agent_auth:read. devices:write, devices:use, computers:read, computers:write, ssh:write, network:read and network:write are opt-in, excluded from default keys. computers:read lists visible cloud and connected computers without waking them or granting execution access. devices:read discovers local Device targets; devices:use separately consents to local execution, so a discover-and-run local workflow needs both. devices:write manages enrollment and device grants; computers:write creates or deletes cloud computers; ssh:write manages retained SSH access. network:read reads the saved workspace network policy; network:write replaces custom allowed hosts and requires a current organization owner/admin. Legacy project PATCH requests containing network_allowed_hosts also require network:write plus their existing run scope and project management permission; saved project hosts do not affect current session egress. Only owners/admins can mint or manage keys with network:write; keys cannot grant themselves more authority. See /docs/network-policies for replacement semantics and runtime applicability. mcp:write manages MCP server configuration only; it does not authorize remote MCP-tool execution. sessions:read reads sessions, including the assistant, reasoning and tool activity in their events. sessions:debug is privileged: only for organization owners/admins, it expands session events to the full diagnostic projection (diagnostic event kinds, status text and raw event metadata).

Scopes

run

Path Parameters

orgId
string
required

Organization id or slug. Resolve it with GET /v3/self.

sessionId
string
required

The session id, returned as session_id by createSession and listSessions.

requestId
string
required

An input request id returned as id by listSessionInputRequests or listInputRequests: a question's operation id or a request card's id.

Pattern: ^(?:[0-9a-fA-F]{64}|[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$

Response

The request after declining it.

id
string
required

The request's id: a question's 64-character hex operation id, or a request card's id (a UUID). A copy shown in a Reason's conversation has its source request's id.

type
enum<string>
required
Available options:
question,
secret,
network_hosts,
permission_rules,
installed_connector,
endpoint_connector,
registry_connector,
connector,
native_connector,
source_control,
device_plugin,
personal_connector_grant
status
enum<string>
required

pending: still waiting on a person. Questions: answered, moved_past (a person's later message in the Session settled it without answering it), cancelled, withdrawn (the agent took it back), timed_out (its wait or decision timeout ended it) or closed (any other end). network_hosts: allowed, declined, completed (every host was allowed elsewhere) or expired. permission_rules: applied, declined or expired. secret: completed (a value was saved and the Session resumed), declined (its member's Not now), moved_past (a person wrote in the Session since it: a value still continues it, but it can no longer be declined) or expired. Other connection types: completed (a connection resumed the Session), expired (after their receipt or 24 hours) or closed (the Session was cancelled or archived); their pending state is best effort, because the server records no answer for them.

Available options:
pending,
answered,
moved_past,
cancelled,
withdrawn,
timed_out,
closed,
allowed,
declined,
applied,
completed,
expired
session_id
string
required

The Session this copy is shown in.

asked_in_session_id
string
required

The Session whose agent asked.

resumes_session_id
string
required

The Session that continues once the request is completed.

for_user_id
string | null
required

The only member who may answer it (a question for one teammate, a personal connection grant, a secret card); null when anyone who can open the Session may.

requires_role
enum<string> | null
required

owner_or_admin: only a workspace owner or admin can complete it.

Available options:
owner_or_admin
origin
object | null
required

Set on a copy of the request shown in a Reason's conversation (a request card copied there, or a question relayed to the member it is for); null on the asking Session's own request.

created_at
string
required
expires_at
string | null
required

When the request's signed receipt ends, or for a secret or connection request without one the end of its 24-hour window; null for a question and for a network_hosts or permission_rules card without a receipt.

reason
string | null
required

Why the agent asks, in its words.

label
string
required

A short name for the request.

question
object | null
required
secret_request
object | null
required

type secret: the secret the agent asks for (its name and how it is used), never a value.

network_hosts
object | null
required
permission_rules
object | null
required
connector
object | null
required

Display fields of a connection request (every type but question, secret, network_hosts and permission_rules); a field a type does not use is null.

actions
enum<string>[]
required

What this caller can do with it through the API now. Only actions an API route serves are listed: answer (a pending question this caller may answer; answerSessionInputRequest), approve and deny (a network_hosts or permission_rules request, for an owner or admin; approve also on a network_hosts request that reads completed, to record the answer), secret (provide the value of the member's own pending or moved_past secret request; REST provideInputRequestSecret, not an MCP tool), and cancel (the member's own pending secret request whose value is not stored yet: declining continues its Session). approve and secret are REST and web app only, never MCP tools: a person decides an approval and types a secret value in their own client. Empty when the request is settled or must be completed in the web app: open app_url. A hint: every action checks again, so an action listed here can still be refused if the request changed since it was read.

Available options:
answer,
approve,
deny,
secret,
cancel
app_url
string
required

The Session in the web app, where every request can be completed.