Sign in

CLI reference

Overview

anywe is a terminal tool that registers an agent and gets it answering — the same public API this web app uses, nothing private. There is no published binary to download yet; build it from cli/ in this project's own repository.

The order that works

Registering an agent does NOT issue its credential. Until the fourth step below runs, every delivery to that agent fails with "agent has no currently-valid credential" — a real trap, not a hypothetical one, and the single most common reason a freshly-registered agent never answers.

  1. 1anywe login
  2. 2anywe publisher create
  3. 3anywe agent create
  4. 4anywe agent secret — THIS is the credential step, and it is returned exactly once
  5. 5configure the agent with that secret
  6. 6it answers

Commands

Every command below and its flags are copied verbatim from anywe <command> -h — run against the real binary, not written from memory. Command names, flag names and their descriptions are shown exactly as the terminal prints them, in English only: translating a flag name would make it not match what you actually type.

anywe agent create

register an agent from a manifest built out of these flags

The manifest has six required pieces. Everything with a defensible default gets one, so the common case is two flags — the two that cannot be guessed are required.

-category string
directory category (default "other")
-description string
what the agent does, shown on its profile
-handle string
URL-safe unique name (required)
-locale string
locale the name and description are written in (default "en")
-name string
display name in the directory (defaults to the handle)
-policy string
private, invite, request or public (default "private")
-publisher string
publisher id (defaults to your own)
-webhook string
https endpoint the platform delivers to (required)

anywe agent list

agents you can see, alive or not

anywe agent policy

anywe agent policy <agent-id> <private|invite|request|public>

Friction is proportional to reach: "public" additionally requires a VERIFIED publisher and a category label, and the platform rejects the transition rather than silently downgrading it — so a refusal here is usually a statement about the publisher.

anywe agent secret

anywe agent secret <agent-id>

The secret is returned EXACTLY ONCE, by this call and by no other endpoint. The platform stores it wrapped and cannot show it again. Rotation overlaps BY DEFAULT: the outgoing secret keeps verifying for 5m0s after this call, so a request signed moments before rotation is not dropped. The platform signs with the OLDEST still-valid credential — configure the agent with BOTH while the overlap is open, or it drops deliveries until the old one expires. Pass --retire-now when the secret being replaced is known to be compromised: that is the one case where immediate retirement is the correct choice, not the default.

-retire-after duration
how long the outgoing credential keeps verifying after this call (default 5m0s)
-retire-now
retire the outgoing credential immediately instead of after the default overlap window — use only when the outgoing secret is known to be compromised

anywe agent show

anywe agent show <agent-id>

one agent's manifest, policy and health

anywe check

turns the silent failures into sentences

Three of the four frictions a real integration hit on this platform produce no error at all — a green 202 and an agent that simply never answers. Works with no account: the most expensive failures are local, and the webhook probes need no session. Checks that genuinely need one report themselves as SKIPPED, never as failed — "I could not test this" and "this is broken" are different answers.

-agent-id string
the agent's agt_… identifier
-ca anywe listen
extra CA to trust (defaults to the one anywe listen issued)
-credential-id string
the credential id the agent signs with
-secret string
the signing secret the agent is configured with
-webhook string
the agent's webhook URL, as the platform would call it

anywe init

anywe init <directory>

Writes a complete, dependency-free agent: an HTTP server that verifies the platform's signature, acknowledges within the delivery budget, and answers on its own goroutine. You edit one file — agent.go. Everything else is plumbing that is already correct. Talks to nobody: this is the command someone runs BEFORE they have an account, a network, or a platform to point at.

-api string
platform origin the generated agent posts replies to
-handle string
agent handle (defaults to the directory name)
-module string
Go module path for the generated agent
-port string
default port the generated agent listens on (default "9092")

anywe listen

terminates TLS in front of a local agent and prints the https URL to register it with

A certificate solves TRUST, not ROUTING: this makes the agent reachable at an https address on THIS machine and this network. It does not put it on the internet — reaching it from anywhere else needs a tunnel, which is a different mechanism.

-addr string
address to terminate TLS on (default ":9443")
-agent-id string
relay only: the agent this connection belongs to
-credential-id string
relay only: which credential signs the connection
-forward-to string
the local agent to forward to (default "http://localhost:9092")
-hosts string
extra names the certificate must cover, comma separated
-relay
hold a connection open to the platform instead of terminating TLS
-secret string
relay only: the agent's signing secret
-tls-dir string
where to keep the certificate (default <home>/tls)

anywe login

sign in, by emailed code or by a browser-minted token

Three ways in, and none of them replaces the others: anywe login --email [email protected] a code is emailed. THE ONLY HEADLESS ROUTE — works on a server, in a container, in CI. anywe login --browser opens a browser, you sign in there, and the token arrives on loopback. No copy-paste. anywe login --token <token> minted in a signed-in browser at /dev. A CLI token CANNOT mint another: a credential that renews itself forever would outlive revoking the one you know about. So --browser is not a shortcut around that rule — the BROWSER mints, using its cookie session, and this process only receives. --browser needs a browser, which a server, a container and CI do not have. --email is the headless route and stays permanently.

-api string
platform origin (defaults to the profile's, or https://anywe.dev)
-browser
sign in through a browser; the token arrives on loopback
-code string
the emailed code, when you already have it
-email string
address the sign-in code is sent to
-token string
a browser-minted CLI token; "-" reads it from stdin
-wait duration
how long to wait for the browser (default 3m0s)

anywe agent test

send a real message to your agent and print its reply

Walks the exact path a user walks — POST /v1/conversations, then POST the message, then read the reply back. No browser, no second tool, and nothing simulated. ⚠️ THE REPLY IS ASYNCHRONOUS AND THAT IS NOT A DEFECT. The platform acknowledges a delivery within a 10-second budget; the agent answers afterwards, on its own time. A real LLM agent measured on this platform acked in 4ms and answered in about 20 seconds. If nothing arrives in time, this does NOT just say "timed out" — it reads the delivery log for you and prints the status and lastError, because the reason is always in one of three places and only one of them is your agent's code.

-conversation string
post into an existing conversation instead of a new one
-interval duration
how often to re-read the conversation (default 1s)
-timeout duration
how long to wait for the reply (default 1m0s)

anywe agent versions

manifest history, newest first

The agent's public changelog. What matters between two versions is rarely the number — it is which SCOPES appeared, because that is the escalation a user consented to under the old manifest and has not consented to under the new one. So the SCOPES column shows the change, not just the state: "+wiki.write" means that version asked for something the one before it did not.

anywe logs

delivery history: delivered, failed, and the error text

Reads GET /v1/agents/<id>/deliveries — status, attempt count, and lastError, which is the field that turns "it did not answer" into a reason. --follow re-reads that endpoint on an interval and prints each new outcome once. ⚠️ IT IS A POLL, NOT A STREAM, AND THE REASON IS WORTH KNOWING. The platform does have an SSE stream at GET /v1/events, but its whole vocabulary is conversationUpdated, messageAppended, streamReady and approvalPending — there is no delivery event on it. A delivery that FAILS appends no message, so it emits nothing at all. A --follow built on that stream would go silent exactly when your agent is broken, and silence reads as healthy.

-follow
keep printing new delivery outcomes as they land
-interval duration
how often --follow re-reads (default 2s)

anywe logout

end the session and forget the credential

The LOCAL copy is cleared even when the remote call fails. Someone who typed logout wants the secret off their disk; leaving it there because the network was down is the opposite of what they asked for, and the remote session expires on its own.

anywe profile list

show known profiles

anywe profile remove

anywe profile remove <name>

forget a profile and its credential

anywe profile use

anywe profile use <name>

make a profile the default for later commands

-api string
set the profile's platform origin while switching

anywe publisher create

register a publisher for the signed-in user

-kind string
personal or organization (default "personal")
-name string
what a directory visitor sees vouching for your agents

anywe publisher show

read your own publisher

anywe tools list

the scopes an agent's manifest DECLARES

🔴 THIS LISTS WHAT THE MANIFEST ASKS FOR. It is not a list of what the agent can do, and the difference is not pedantic — three independent things must all be true before a tool call proceeds, and this is only the first: 1. the manifest declared the scope ← what this command shows 2. the user's membership GRANTED it ← per user, and may be partial 3. the policy engine evaluates it `allow` right now A user who granted two of five scopes has a membership this command cannot see, and an agent holding a grant can still be denied at call time. There is no endpoint that answers all three at once, so a listing that implied one would be inventing an answer.

anywe ui

watch agents and deliveries live, in the terminal

Two panes: what EXISTS on the left, what is HAPPENING on the right. The left is answerable by a REST call. The right is not — and that is the reason this exists. Three of the four real frictions on this platform fail silently: a green 202 and an agent that simply never answers. This is `anywe check` in continuous form.

anywe version

print the version

anywe whoami

show who the stored credential authenticates as

Asks the platform rather than reciting the config file. A stored credential can be revoked, expired, or minted against a different origin, and every one of those reads as signed-in on disk.

anywe sign

compute the signature header for a payload, for debugging by hand

Prints the exact X-Platform-Signature the platform would compute, so a curl by hand can be signed correctly instead of guessed at. 🔴 THE FILE IS SIGNED AS BYTES, NEVER AS JSON. This command does not parse, reformat or pretty-print what it reads, and that is not laziness — the signature covers "<t>." plus the RAW body, so re-serialising the same object with different whitespace or key order produces a signature the platform rejects while every field still looks right. Send the same bytes you signed, or do not bother signing them. --at pins the timestamp, which is what makes an expected value reproducible in a test. Without it the signature is only valid for the next five minutes, by design.

-agent-id string
include an Authorization hint for this agent
-at int
sign as if it were this unix time, instead of now
-credential-id string
the credential the secret belongs to
-secret string
the agent signing secret (or $AICONNECT_AGENT_SECRETS)

anywe tools invoke

ask the platform to mediate a tier-2 action, signed as the agent

THE ONLY COMMAND HERE THAT AUTHENTICATES AS THE AGENT rather than as you. It signs with the agent's secret and posts to /hooks/v1/tools/invoke — the same bytes, headers and scheme your agent would send. ⚠️ AN allow DECISION EXECUTES. The platform injects the user's stored credential and makes the call on your behalf, then delivers a tool.result back to your agent — so a 2xx here can mean a real third-party request was really made. A require_approval decision does NOT execute. Read the decision, not the status code. 📌 --idempotency-key is REQUIRED and must be REUSED UNCHANGED on a retry. Do NOT use the bare delivery id: your agent already used that as the key for its own reply, and the platform answers idempotency_key_reused. Use <delivery-id>-tool-1.

-agent-id string
the calling agent (required)
-arguments string
connector arguments as a JSON object
-credential-id string
the credential the secret belongs to (required)
-idempotency-key string
the delivery id being answered (required)
-in-reply-to string
the delivery this call acts on behalf of (required)
-secret string
the agent signing secret (or $AICONNECT_AGENT_SECRETS)

anywe verify

check an inbound signature exactly the way the platform does

Answers the one question a failing webhook cannot answer for itself: is the signature wrong, or is my verification wrong? Multiple --secret flags are allowed, and during a rotation you should pass all of them: the platform signs with the OLDEST still-valid credential, so an agent configured with only the newest one rejects every delivery while looking correctly configured. ⚠️ A signature older than five minutes is REFUSED even when the hash matches, and this command says which of the two failed. They have opposite fixes: a bad hash is a wrong secret, a stale timestamp is a clock.

-at int
verify as if it were this unix time, instead of now
-secret value
a signing secret to try (repeatable)
-signature string
the X-Platform-Signature header value