Identify the account, user, and credential behind this connection, with plan, credit balance, rate limits, and the tools available. Only needed to troubleshoot the connection or check credits and limits — other tools already act on this account.
Takes no parameters.
List what a script can call: the Crevio API (crevioApi), Crevio's own tools (platform), and every integration you can use, each as a namespace under `tools`, plus the account's other connected apps and their status. Then list a namespace's functions with list_integration_tools.
Takes no parameters.
List one namespace's functions — the name a script calls, its parameters, whether it only reads, whether it needs approval, and a snippet run_script accepts. crevioApi has hundreds of operations: narrow it with `search`.
Parameterslimitoffsetsearchnamespacerequired
Run JavaScript on the account's computer with bun — no agent turn — and wait for its result. `tools.<namespace>.<function>(args)` calls anything list_integration_tools shows (every call returns its result and throws on failure; top-level await works), and the script's last expression is its result. Chain calls and transform data in one run, e.g. `const { data } = await tools.crevioApi.listOrders({ status: "succeeded" }); data.length`. Runs as you, and only for account admins. If the wait ends first the reply has wait_timed_out: true and the run id: continue with wait_for_script_run — calling run_script again runs it twice unless you reuse the idempotency_key. Run ids do not expire, and only the user who started a run can read it. At most 4 runs in flight per user. `args` reach the script as the global `args` (and process.argv). Files the script writes into the directory named by the global `outputDir` (20 at most, 50 MB each) come back as `artifacts`; get a download link with get_file_download_url.
Parametersargscoderequiredwait_secondsidempotency_keytimeout_seconds
Wait for a script run to finish and return its result. If it is still running when the wait ends, the reply has wait_timed_out: true — call again.
Parametersrun_idrequiredwait_seconds
Read a script run's status, and its result once it has finished.
Parametersrun_idrequired
Cancel a script run that has not started yet. A running script runs to its end or its timeout.
Parametersrun_idrequired
Delegate a job to the Crevio agent and wait for the result. The agent works your account through the Crevio API and every connected integration (products, customers, orders, email, socials, sites, research) and replies in `result`. Each job is a full agent run that takes from half a minute to several minutes, so use it for work that needs judgement or writing. If the run is still going when the wait ends, the reply has wait_timed_out: true — then call wait_for_run with its id and never call ask_crevio again, which would do the job twice. Run ids do not expire, and only the user who started a run can read it.
Parametersspeedmessagerequiredapproval_modeidempotency_keyresponse_formattimeout_seconds
Open a chat with the Crevio agent and queue a run, without waiting. Returns the run immediately — its `chat_id` is the conversation to continue with send_message. Follow the run with wait_for_run or get_run.
Parametersspeedmessagerequiredapproval_modeidempotency_keyresponse_format
List the account's chats, newest first.
Parameterslimitsearchending_beforestarting_after
Get a chat's title, kind, and latest run.
Parameterschat_idrequired
Continue a chat with follow-up instructions or answers — the agent keeps its context. Resumes a run waiting in needs_input, or queues a new run when the last one finished. Returns run_busy while a run is still in progress. Optionally waits for the reply.
Parameterschat_idrequiredmessagerequiredidempotency_keyresponse_formattimeout_seconds
Read a chat's messages, oldest first. Returns the most recent `limit` messages; page back through older ones with starting_after.
Parameterslimitchat_idrequiredending_before
Wait for a run to settle (completed, failed, cancelled, or needs_input) and return it with the agent's final reply. If it is still running when the wait ends, the reply has wait_timed_out: true — call wait_for_run again.
Parametersrun_idrequiredtimeout_seconds
Fetch a run's current status, summary, pending approvals, and (once settled) the agent's final reply.
Parametersrun_idrequired
List the account's task runs, newest first — delegated jobs and scheduled tasks alike. Filter by status, task, or chat.
Parameterslimitstatuschat_idtask_idending_beforestarting_after
Approve or deny the integration actions a run is paused on (status needs_input with pending_approval_ids). Submit a decision for every pending id at once; the run resumes in the background.
Parametersrun_idrequiredapprovalsrequired
Stop a run that is pending, running, or waiting for input, and its media generations still in flight. A run mid-step finishes that step first: it returns with cancel_requested_at set and settles as cancelled moments later (wait_for_run to confirm). Repeating it is harmless.
Parametersrun_idrequired
Exchange an artifact id (art_...) from a run's or script run's `artifacts` for a download link. The link needs no credentials and expires after 15 minutes; ask again for a fresh one.
Parametersfile_idrequired
List the account's audit events, newest first: access and configuration changes, approvals, API key use, and (at the full capture level) the agent's tool calls.
Parametersafterlimitactionentity_idactor_typeentity_typeending_beforestarting_after