Quickstart

Give agents access to PostgreSQL or MySQL so they work from real tables and columns for more accurate results, without sharing the password. Or add an HTTPS API as a source the same way. For Cursor or Claude, add https://swarmvia.com/mcp and follow Agents. The steps below walk an HTTPS origin with curl.

Prerequisites

  • A swarmvia account (sign up at swarmvia.com)
  • An upstream API URL you are allowed to call
  • A tool that can send HTTP requests (curl is enough)

Create a source

  1. Open the dashboard and select Sources → New source.
  2. Choose a subdomain (this becomes ‹subdomain›.swarmvia.cloud).
  3. Add at least one origin (the upstream base URL).
  4. Pick Pass-through if your client already authenticates to the upstream, or Managed if swarmvia should attach credentials for you.
  5. Save. The source goes live within a few seconds.

Create a test key

  1. Open the source → Access.
  2. Select Create test key, name it, and pick how long it lasts: 1 hour (the default) or 24 hours.
  3. Copy the key (sv_at_…). It is shown once.

A test key is for trying things out. For a script or integration that runs on its own, mint keys with a Control API token instead; see Refresh access tokens before they expire.

Send a request

Replace the placeholders and call your source's endpoint. The path after the host is forwarded to the selected origin.

export ACCESS_KEY='sv_at_…'
export SOURCE_HOST='https://your-source.swarmvia.cloud'

curl -sS "$SOURCE_HOST/your/api/path" \
  -H "X-Swarmvia-Key: $ACCESS_KEY"

On a managed source you may also send Authorization: Bearer $ACCESS_KEY. On a pass-through source, keep the access key in X-Swarmvia-Key and put the upstream credential in Authorization (or whatever the upstream expects).

If the source has multiple origins, pick one explicitly:

curl -sS "$SOURCE_HOST/your/api/path" \
  -H "X-Swarmvia-Key: $ACCESS_KEY" \
  -H "X-Swarmvia-Origin: https://api.example.com"

Confirm admission

A successful response includes headers such as x-swarmvia-remaining-slots and x-swarmvia-effective-limit. Open the source's Logs page to see the request in access logs, or Metrics for admit/queue/reject proof (not the same as Billing allowance).

Next steps