Tools and operations

MCP server

Connect Claude, ChatGPT, Cursor and other MCP clients to Ephemeral over Streamable HTTP with an API key or OAuth, then start runs and manage workflows.

Ephemeral runs a Model Context Protocol (MCP) server, so AI agents such as Claude, ChatGPT and the agents in your editor can start runs, wait for results and read your workflows directly. It uses the same API keys, roles, budgets and validation as the REST API. They can also save and delete workflows, manage schedules, read the files runs save, keep state between runs and ask what runs will cost, so an agent can set up a recurring job end to end.

Use Ephemeral from Claude, ChatGPT, Cursor and other MCP clients

The server URL is https://app.ephemer.al/mcp. It speaks the Streamable HTTP transport and accepts either a bearer API key or OAuth sign-in. Pick your client below; each section has the exact configuration.

  1. Create an API key under Keys in the dashboard, or choose a client that supports OAuth and sign in when it asks.
  2. Add https://app.ephemer.al/mcp as a remote MCP server (Claude Code, Cursor and VS Code below; Claude Desktop through the bridge).
  3. Ask the agent to call create_run with a prompt, then wait_for_run with the run ID it returns.

Sign in with OAuth

Clients that support MCP authorization need only the URL https://app.ephemer.al/mcp. The client finds Ephemeral’s sign-in from the server’s 401 answer and its protected resource metadata, registers itself, and opens a page where you sign in, choose an organization and approve. It then holds an access token valid for one hour and a refresh token, so you are not asked again until you revoke it.

  • Access is for the organization you pick, with the role you approve: member or admin. Only organization owners and admins can grant admin, and member is enough for everything except creating, changing or deleting schedules, which needs admin.
  • Tokens work only for Ephemeral’s API (https://app.ephemer.al), never for other services.
  • Review or revoke every connected app under Authorized apps on your account page.
  • The authorization server’s metadata is at https://ephemer.al/.well-known/oauth-authorization-server. Clients must use PKCE (S256).
A self-hosted installation accepts API keys only.

Connect with an API key

Create an API key under Keys in the dashboard. A member key covers runs, workflows and files; use an admin key if the agent should also create, change or delete schedules. The server is at https://app.ephemer.al/mcp and speaks the Streamable HTTP transport; every request carries the key as a bearer token.

Claude Code

Add the server once; it is then available in every session.

Terminal
claude mcp add --transport http ephemeral https://app.ephemer.al/mcp \
  --header "Authorization: Bearer $EPHEMERAL_API_KEY"

Cursor, VS Code and other clients with HTTP support

Most clients accept a remote server with headers, in their MCP settings:

JSON
{
  "mcpServers": {
    "ephemeral": {
      "url": "https://app.ephemer.al/mcp",
      "headers": { "Authorization": "Bearer YOUR_API_KEY" }
    }
  }
}

Claude Desktop

Claude Desktop starts local servers from its configuration file (claude_desktop_config.json). The mcp-remote bridge connects it to a remote server and passes the header:

JSON
{
  "mcpServers": {
    "ephemeral": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://app.ephemer.al/mcp", "--header", "Authorization:${EPHEMERAL_AUTH}"],
      "env": { "EPHEMERAL_AUTH": "Bearer YOUR_API_KEY" }
    }
  }
}
A self-hosted installation serves the same endpoint at its engine URL, for example https://ephemeral.example.com/mcp, with a key of that installation.

Tools

Each tool has an input schema, which clients show to the model, and a result with both text and structured content. Failures that the REST API reports as errors come back as tool errors with the same message.

ToolWhat it does
create_runStarts a run from a prompt or a saved workflow, with optional input, model, files, connections, web access, shell, timeout, cost cap and zero data retention. Returns the queued run. An idempotency_key makes a retry safe.
create_runsStarts up to 100 runs of one task in one call: the definition once, and one input per run. Every input is checked against the input_schema before any run starts. Returns the batch_id and the run IDs in order. Each run keeps its own cost cap; max_total_cost_micros refuses a batch that could cost more.
get_runReads a run: status, output, error, cost and whether billing is still pending. While billing is pending, cost_micros is provisional and usually higher than the final cost, and the result says cost_final: false; quote the cost only when cost_final is true.
wait_for_runWaits up to 60 seconds for a run to finish and returns it. Call it again if the run is still going. Once the run has finished it also waits for billing to settle, so the returned cost is final (cost_final: true); if the time runs out first, the cost is provisional.
wait_for_runsWaits up to 60 seconds for several runs, given as IDs or as the batch_id from create_runs, and returns them all in order with a summary: counts by status, the total cost, whether it is final, and the runs still pending. Like wait_for_run it waits for billing to settle. With mode any it returns as soon as one run has finished. If the time runs out, call it again with the pending runs.
list_runsLists runs, newest first, with a status filter and a cursor.
cancel_runCancels a run that has not finished.
delete_runsDeletes finished runs (up to 100): their events, output and definition. Their saved files stay unless delete_files is true.
list_workflowsLists the saved workflows with their description, input_schema and output_schema, so an agent can see what each expects and returns without reading its prompt.
get_workflowReads one workflow definition, without credentials.
list_modelsFinds models. Returns a compact list (id, name, context length, input and output price per million tokens, zero data retention) and the total. Arguments: query (part of the id or name, any case), limit (25 by default, at most 100), zero_data_retention (only models that support it) and model (the full details of one model).
list_connectionsThe saved connections a run can use, without URLs or secrets.
get_accountReads the organization behind the key: its name, your role, the default model, how many runs it can have in progress at once and how many are running and queued now, the prices, and the credit available for new runs. Call it before starting many runs.
save_workflowCreates a workflow or replaces the one with that name: prompt, model, files, connections, web access, shell, timeout and zero data retention. Connections are references to saved ones only. Also takes a description and JSON Schemas for the input and output.
delete_workflowDeletes a saved workflow.
list_schedulesLists the schedules, optionally for one workflow, with the next start and the last outcome.
get_scheduleReads one schedule.
create_scheduleStarts a saved workflow on a cron timetable and time zone, with optional input and cost cap. Needs an admin key.
update_scheduleChanges a schedule, or pauses and resumes it with enabled. Needs an admin key.
delete_scheduleDeletes a schedule. Needs an admin key.
preview_scheduleChecks a cron expression and returns the next five start times, without saving.
run_scheduleStarts a schedule’s workflow now and returns the queued run.
list_filesLists the organization's files, newest first, with their source (upload, or output saved by a run), run_id, expiry and keep setting. Filters: run_id, source, prefix and limit. It answers a page at a time: pass next_cursor as cursor for the next.
read_fileReads a file, such as a chart or report a run saved: text as text, an image as an image, anything else as an embedded resource. Up to max_bytes (default 1 MiB, at most 5 MiB).
upload_fileSaves a file of up to 1 MiB, as text or base64, with an optional expiry (expires_in_days) or keep.
update_fileRenames a file or changes when it is deleted: expires_in_days, keep or use_policy.
delete_fileDeletes a file.
get_run_eventsReads a run's recorded events, oldest first, to see what it did and why it failed. Long strings are cut to max_string_bytes. Page with after and next_after; filter with types.
estimate_costEstimates what a number of runs of a workflow or prompt will cost before starting them: typical, high and cap, per run and in total, from your settled runs. Nothing is started or charged.
list_workflow_versionsLists a workflow's saved versions, newest first. Read one in full with get_workflow and its version.
restore_workflow_versionMakes an earlier version the current definition, saved as the newest version.
add_example_workflowsSaves the example workflows the organization lacks: summarize a page, make a chart report as output files, and report only what is new on a page with state.
list_stateLists the state stores, or one store's entries (no values), with prefix and cursor.
get_stateReads one state entry: its value, version and expiry.
set_stateWrites one state entry, with optional ttl_seconds and if_version for a safe compare-and-set.
delete_stateDeletes one state entry, with if_version only at that version.
get_storageReads the organization's storage: usage, retention policy, limits and, on the hosted service, billing.
set_storage_policySets how long run output files, uploaded files and state entries are kept. Needs an admin key.

Try it

The endpoint takes JSON-RPC 2.0 messages by POST. A client does this for you; with curl, one call looks like this:

Terminal
curl -sS https://app.ephemer.al/mcp \
  -H "Authorization: Bearer $EPHEMERAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"create_run","arguments":{"prompt":"Summarize https://example.com","web":true,"max_cost_micros":200000}}}'

Save a workflow and schedule it

An agent can turn a task into a recurring job with two calls. First save_workflow, with these arguments:

JSON
{
  "name": "weekly-report",
  "prompt": "Summarize last week's support tickets from the helpdesk connection and list the three biggest themes.",
  "connections": { "helpdesk": { "ref": "helpdesk", "allowed_methods": ["GET"] } },
  "timeout_seconds": 600
}

Then create_schedule (admin key), here every Monday at 09:00 in Madrid; preview_schedule shows the next start times first:

JSON
{
  "workflow": "weekly-report",
  "cron": "0 9 * * 1",
  "timezone": "Europe/Madrid",
  "max_cost_micros": 500000
}

Roles

Most tools are operations that a member key can already perform in the REST API, and the schedule tools follow the same rule as the REST API: reading, previewing and running a schedule now need only a member key, while create_schedule, update_schedule and delete_schedule need an admin or owner key and answer with a tool error (status 403) otherwise. There is no tool to create keys, change connections or manage billing. The key also decides the organization; runs are billed to it and appear in its run history.

Safety

  • Nothing runs without a key. Anyone can initialize and list the tools, which are public anyway; every tool call needs a valid key, and gets 401 without one.
  • OAuth access tokens expire after an hour, are limited to one organization and the approved role, and can be revoked at any time on your account page.
  • Budgets apply. Every run has a cost cap, from max_cost_micros or the organization default, and the same balance checks as the API.
  • Connections are saved references. An agent can only name a connection that your organization saved, and can narrow it with allowed_methods (for example GET only) or allowed_tools. It can never supply a URL or a credential.
  • Zero data retention is available per run. The output of such a run is released on its first read. Zero data retention covers what Ephemeral records about a run: its events, output and definition. Files and state a run is told to save are your storage, kept as your retention settings say.
  • Only POST is accepted. There are no sessions and no server-initiated messages.

Protocol

Protocol versions 2025-11-25, 2025-06-18 and 2025-03-26 are supported; the server answers with the version the client asks for. GET and DELETE return 405. A discovery document is published at /.well-known/mcp/server-card.json.

esc

Nothing matches “”.