Command reference: OpenPort
Read workspaces and transactions with an Agent Key, propose or execute actions, and review drafts and audit exports.
Overview
OpenPort commands let an automation read workspace data and propose or execute actions within the permissions of its Agent Key. Data commands need an Agent Key; review commands need a person’s browser sign-in. All of them need a server that supports OpenPort, and review commands also need approvals support.
Read data (Agent Key)
figena openport manifest
Shows the tool manifest: the actions and data available to your Agent Key.
figena openport workspaces
Lists the workspaces your Agent Key can reach.
figena openport transactions
Lists transactions in a workspace. The workspace comes from --workspace <id> (or --org <id>) or the profile’s orgId.
--kind <kind>and--search <text>: filter the list.--from <date>and--to <date>: limit the date range.--sort <order>,--page <n>, and--page-size <n>: order and page through results.
Propose and execute actions (Agent Key)
figena openport preflight
Checks an action before you submit it and returns its expected impact with an impactHash. --action <name> is required; pass the payload with --payload <file> or --payload-json '<json>'.
figena openport action
Creates an action from --action <name> and a payload. Every action is recorded as a draft first. Add --execute to ask Figena to run it right away, together with --justification "<reason>", which is saved with the action. Whether it runs depends on the auto-execute settings your workspace has for the Agent Key; when execution isn’t allowed, the action stays a draft for review and the result explains why.
--preflight-hash <hash>: theimpactHashfromopenport preflight. High-risk actions usually need it to execute, and it must still match the impact when you submit.--force-draft: submit the action as a draft for review.--request-id <id>and--idempotency-key <key>: identify the request. With an idempotency key, a request that doesn’t execute may be retried once after a temporary failure; executed actions are never retried by the CLI.
figena openport preflight --action <action-name> --payload ./payload.jsonfigena openport action --action <action-name> --payload ./payload.json --force-draftfigena openport draft get <draftId>
Shows one draft.
Review drafts and export audits (browser sign-in)
figena openport drafts list
Lists drafts awaiting review. Filter with --app <appId>, --org <id>, and --status <status>, and page with --page-size <n> (or --limit) and --cursor <cursor>. Add --all to follow every page, and --max-items <n> to stop after that many drafts. The result includes items, nextCursor, and the number of pages read.
figena openport draft approve <draftId>
Approves a draft. Add --note "<text>" to record why.
figena openport draft reject <draftId>
Rejects a draft. Add --note "<text>" to record why.
figena openport audit export
Exports the OpenPort audit log as CSV. Filter with --app, --org, --from, --to, and --limit. With --file <path>, the CLI writes the CSV to that file and prints “Exported audit CSV to” followed by the path, together with the number of rows; without it, the CSV is returned in the result data.
figena openport audit export --org <workspace-id> --from <date> --to <date> --file ./openport-audit.csv