openapi-auth

An authentication helper for the Openapi marketplace, which provides APIs for services such as company data or messaging. It manages OAuth access tokens used to call those services.

In plain words
What is it for?
Use it to obtain scoped Bearer tokens, discover available permissions, and check account credit, subscriptions, and API usage.
Why use it?
It removes the need to manually create, renew, inspect, and revoke tokens or track which permissions they have.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/openapi/openapi-skills/openapi-auth
Any agent
npx skills add openapi/openapi-skills --skill openapi-auth
Clone the repo
git clone --depth 1 https://github.com/openapi/openapi-skills

Made for: Claude Code, Codex.

Per session 55 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 726 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00055 $0.00726
Opus 5 $0.00028 $0.00363
Sonnet 5 $0.00011 $0.00145
Haiku 4.5 $0.00006 $0.00073

Measured yesterday against content hash 1fab5d516652, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

openapi-auth scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s -u "$OPENAPI_EMAIL:$OPENAPI_API_KEY" https://oauth.openapi.com/tokens \
skills/openapi-auth/SKILL.md · 58 lines

How it starts

The opening of the file, as written. The whole thing — 58 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Openapi authentication (OAuth v2)

All Openapi services require a Bearer token created through OAuth v2. This skill manages that token lifecycle.

Credentials

Two layers — never confuse them:

  1. Account credentials (email + API key) → used only against https://oauth.openapi.com, as HTTP Basic auth (username = email, password = API key).
  2. Bearer token (created here, with scopes) → used against every service API as Authorization: Bearer <token>.

Expect credentials in the environment as OPENAPI_EMAIL, OPENAPI_API_KEY (and optionally a ready-made OPENAPI_TOKEN). Never print or commit them.

Create a token

curl -s -u "$OPENAPI_EMAIL:$OPENAPI_API_KEY" https://oauth.openapi.com/tokens \
  -H 'Content-Type: application/json' \
  -d '{
    "scopes": ["GET:company.openapi.com/IT-start"],
    "name": "agent token",
    "ttl": 86400
  }'
  • Scope format: METHOD:host/path-prefix (e.g. POST:sms.openapi.com/IT-messages). Request only the scopes the task needs, with a short ttl (max 1 year).
  • Discover valid scopes: GET https://oauth.openapi.com/scopes (Basic auth).
  • Optional limits object restricts token usage further.
  • A refresh token can renew a token: PATCH /tokens/{id} with the refresh token as Bearer.
  • Tokens can also be created from the console UI (Authentication → "+New Token") at https://console.openapi.com.

Management endpoints (Basic auth)

Endpoint Purpose
GET /tokens, GET|PATCH|DELETE /tokens/{token} Token lifecycle
GET /scopes, GET /scopes/{id} Available scopes
GET /wallet, GET /wallet/transactions Credit balance — check before expensive paid calls
GET /subscriptions, GET /subscriptions/{id} Active plans and remaining requests
GET /stats, GET /stats/apis, GET /stats/apis/{domain}, GET /stats/ips Usage analytics
GET /errors, GET /callbacks Error log and callback monitoring

Billing model (affects every service)

  • Requests are paid from the wallet (per request) or from a subscription (monthly: 30 days no rollover; annual: 365 days, any pace). Both can coexist; the wallet is the fallback when subscription requests run out.
  • Some APIs have free daily/monthly tiers; rate limits, when present, are stated in each API's description.
  • Sandbox: free test requests, but "sandbox credit" must be enabled in the console first; responses are illustrative.

Read the full file on GitHub · 58 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 58 lines · 55 tokens per session scan A 1fab5d516652

Subscribe to this mod's changes

openapi-auth is a skill published in the GitHub repository openapi/openapi-skills (2 stars, last pushed 2mo ago), licensed MIT. It adds 55 tokens to every session and 726 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.