recoup-api
Call the Recoupable API from the sandbox to fetch artist data, socials, organizations, research, documents and any other platform resource — and to invoke external connector actions (Google Docs / Drive / Sheets edits, Gmail, TikTok, Instagram, etc.) via Recoupable's shared connections. Use whenever you're asked for Recoup data, a Recoupable platform resource, or to read/write something outside Recoup like a Google Doc URL or a spreadsheet. Triggers on phrases like "look up artist", "fetch from recoup", "artist data", "artist socials", "organizations", "artist report", "research", "create new artist", "create artist", "onboard artist", "add artist", "edit this Google Doc", "read this doc", "update the spreadsheet", "send an email", "post on TikTok", "save to Drive", or whenever the user pastes a docs.google.com / drive.google.com / sheets.google.com URL. Always load this before writing curl calls against api.recoupable.com.
What this skill does
# Recoupable API
Call the Recoupable production API to fetch artist data, social metrics, org context, research, and to trigger platform operations.
- **Base URL:** `https://api.recoupable.com/api`
- **LLM-readable docs:** `https://developers.recoupable.com` — Mintlify site. Use `/llms.txt` for the endpoint index, `/llms-full.txt` for full content, and the OpenAPI JSONs listed below for machine-readable schemas.
## Authentication
Recoup accepts **either** credential — prefer the API key when both are present:
| Credential | Header | Where it comes from |
| --- | --- | --- |
| `RECOUP_API_KEY` (`recoup_sk_…`) | `-H "x-api-key: $RECOUP_API_KEY"` | API-key install (`recoup-setup`) / agent signup |
| `RECOUP_ACCESS_TOKEN` | `-H "Authorization: Bearer $RECOUP_ACCESS_TOKEN"` | short-lived open-agents sandbox token |
Build an `AUTH` array once and reuse it on every call:
```bash
if [ -n "$RECOUP_API_KEY" ]; then
AUTH=(-H "x-api-key: $RECOUP_API_KEY")
elif [ -n "$RECOUP_ACCESS_TOKEN" ]; then
AUTH=(-H "Authorization: Bearer $RECOUP_ACCESS_TOKEN")
else
echo "No Recoup credential set — ask the user to authenticate; do not retry blindly." >&2
fi
# Use as: curl -sS "${AUTH[@]}" "https://api.recoupable.com/api/artists/{id}/socials"
```
If neither is set, the user is not authenticated — tell them to sign in rather than retrying. (Examples further down use `Authorization: Bearer $RECOUP_ACCESS_TOKEN` directly; swap in `"${AUTH[@]}"` when you have an API key instead.)
## Working with an artist — pick the mode first
Before any artist task, decide **which of these the user means.** Guessing here is exactly what makes an agent fabricate an artist that doesn't exist (or invent a persona for one that does).
| Mode | The user means… | Trigger phrases | What to do |
| --- | --- | --- | --- |
| **A · Any artist (research)** | Look up *any* artist — not necessarily one of theirs | "research X", "how's X doing", "compare X and Y" | Use the **Research** endpoints (or the `recoup-artist-research` skill). Works off a name — no roster lookup needed. |
| **B · Browse my roster** | List the artists on *their* account | "my roster", "my artists", "who do I have", "pick one of my artists" | Run **Roster discovery** below, then present the list. |
| **C · A specific roster artist** | Act on one of *their* artists | "make content for `<name>`", "update `<name>`'s brand" | Run **Roster discovery**, match the name, capture `account_id` + row `id`. No match → they're not on the roster yet (offer Mode D). |
| **D · Add an artist** | Onboard a brand-new artist | "add / onboard / create artist X", "set up a new artist" | Use the `recoup-create-artist` skill (8-call chain). |
### Roster discovery (Modes B & C)
In an open-agents **sandbox with a populated `artists/` tree**, that filesystem is authoritative — use the `recoup-artist-workspace` skill instead of the API. Otherwise (an API-key install, or no `artists/` directory), enumerate from the API:
```bash
BASE="https://api.recoupable.com/api" # AUTH set per the Authentication section above
# 1. Whose account is this credential? Sanity-check BEFORE trusting the roster.
curl -sS "${AUTH[@]}" "$BASE/accounts/id" # -> {"accountId":"…"}
# 2. Organizations on the account
curl -sS "${AUTH[@]}" "$BASE/organizations" \
| jq -r '.organizations[] | [.organization_id, .organization_name] | @tsv'
# 3a. Artists for one org (preferred when you know the org)
curl -sS "${AUTH[@]}" "$BASE/artists?org_id=$ORG_ID" \
| jq -r '.artists[] | [.name, .account_id, .id] | @tsv'
# 3b. …or every artist the account can see (account-wide)
curl -sS "${AUTH[@]}" "$BASE/artists" \
| jq -r '.artists[] | [.name, .account_id, .id] | @tsv'
```
**Verified field shapes** (live, 2026-06-07): each **org** row has `organization_id`, `organization_name`, and its own row `id` — pass the `organization_id` value as `org_id`. Each **artist** row has `name`, `account_id`, and a row `id`. Capture both artist ids: `account_id` is what content endpoints and `/api/artists/{…}/socials` want; the row `id` is the artist's primary key.
### Stop rule — never invent a roster
If `GET /accounts/id` resolves to an account whose email is `agent+…@recoupable.com` (check `GET /api/accounts/{accountId}`), **or** `organizations` and `artists` both come back empty (`[]`), you are almost certainly on a throwaway / agent-signup key — **not** the user's real account. **Stop and say so:** name the resolved `accountId` and ask the user for a key tied to their real account (or to run `recoup-setup`). Do **not** fabricate an artist, persona, EP, or roster to keep the task moving — an empty roster is a credential problem to surface, not a blank canvas to fill.
## Org scoping (`RECOUP_ORG_ID`)
When running inside a sandbox, the environment also exposes `RECOUP_ORG_ID` — the organization the sandbox was opened for. The access token is account-scoped (it covers every org the account belongs to), so when you use it with unscoped list endpoints like `GET /api/artists` you will get results from **all** of that account's orgs, not just the one this sandbox represents. That mismatch surprises accounts.
When `RECOUP_ORG_ID` is set, scope list/query endpoints to it:
```bash
# Artists for this sandbox's org only
curl -H "Authorization: Bearer $RECOUP_ACCESS_TOKEN" \
"https://api.recoupable.com/api/organizations/$RECOUP_ORG_ID/artists"
```
For the Recoup CLI, pass `--org "$RECOUP_ORG_ID"` on commands that accept it. If `RECOUP_ORG_ID` is unset, you are not in an open-agents sandbox — fall back to account-scoped calls as normal.
**Inventory — filesystem first, API fallback:** inside an open-agents sandbox that has a populated `artists/` tree, prefer reading that local tree instead of calling the API — the filesystem is authoritative for the sandbox (see the `recoup-artist-workspace` skill). **But if there is no `artists/` directory** — e.g. an API-key install outside a sandbox — the filesystem can't answer, so fall back to **Roster discovery** above. Never conclude "the roster is empty" from an empty/missing filesystem; confirm against the API first.
## Docs Map
The full endpoint surface is organized into the sections below. Use this map to pick the right area, then pull the detailed docs for just that area (see [Finding an endpoint](#finding-an-endpoint)) instead of fetching everything.
### Account & Identity
- **Accounts** — create/get/update accounts, add artists to account
- **Organizations** — create/list orgs, add artists to org
- **Workspaces** — create workspaces
- **Subscriptions** — get subscriptions, create Stripe checkout session
- **Agents** — agent signup, email verification
- **Admins** — admin-only: agent sign-ups, coding/content agent Slack tags, Resend emails, Privy logins, sandbox stats, org repo commit stats
### Artists & Content
- **Artists** — create/get/delete, get socials, pin/unpin, get profile (across all platforms), trigger socials scrape
- **Posts** — get artist posts across platforms
- **Comments** — get comments for an artist or a specific post
- **Fans** — get social profiles of an artist's fans
- **Songs** — create/get songs by ISRC, manage catalogs (CRUD + add/remove songs), analyze songs via audio LM, list analyze presets
- **Content Creation** — pipeline trigger, video/image/caption generation, ffmpeg edits, video analysis, upscale, cost estimate, audio transcription, templates
### Research (Songstats + Web)
One section covering most music-industry lookup work. Backed by **Songstats** — entity IDs are short alphanumeric strings (e.g. `wjcgfd9i`), not numeric Chartmetric IDs:
- **Discovery**: search (`type=artists|tracks|labels`), profile, similar artists, people search, lookup by URL
- **Catalog**: albums, tracks, track detail, track playlists
- **Metrics**: platform metrics (16 sources), audience demographics, career timeline, milestones
- **Surface**: playlist placements
- **Insights**: AI insights, social URLs
- **Web**: enricRelated in Ads & Marketing
ads
IncludedMulti-platform paid advertising audit and optimization skill. Analyzes Google, Meta, YouTube, LinkedIn, TikTok, Microsoft, and Apple Ads. 250+ checks with scoring, parallel agents, industry templates, and AI creative generation.
banana
IncludedAI image generation Creative Director powered by Google Gemini Nano Banana models. Use this skill for ANY request involving image creation, editing, visual asset production, or creative direction. Triggers on: generate an image, create a photo, edit this picture, design a logo, make a banner, visual for my anything, and all /banana commands. Handles text-to-image, image editing, multi-turn creative sessions, batch workflows, and brand presets.
rpg-migration-analyzer
IncludedAnalyzes legacy RPG (Report Program Generator) programs from AS/400 and IBM i systems for migration to modern Java applications. Extracts business logic from RPG III/IV/ILE source code, identifies data structures (D-specs), file operations (F-specs), program dependencies (CALLB/CALLP), and converts RPG constructs to Java equivalents. Generates migration reports, complexity estimates, and Java implementation strategies with POJO classes, JPA entities, and service methods. Use when modernizing AS/400 or IBM i legacy systems, analyzing RPG source files (.rpg, .rpgle, .RPGLE), converting RPG to Java, mapping data specifications to Java classes, planning legacy system migration, or when user mentions RPG analysis, Report Program Generator, RPG III/IV/ILE, AS/400 modernization, IBM i migration, packed decimal conversion, or mainframe application rewrite.
brand-library-architect
IncludedBuild a complete brand library for a product — visual asset render pipeline, brand documentation set (BRAND, COPY, MANIFESTO, BIOS, FAQ, GLOSSARY, TONE, PRICING), open-source convention files (README, CONTRIBUTING, SECURITY, CODE_OF_CONDUCT), and a self-contained press kit. This skill should be used when the user asks to "build a brand library / brand kit / press kit / brand assets" for a product, "set up a brand library workflow," "create a positioning manifesto plus visual identity," or any combination of brand documentation + visual asset pipeline. Apply phase-by-phase or run end-to-end. Templates are product-agnostic and use {{TOKEN}} placeholders the skill prompts the user to fill.
writing-tech-post
IncludedAuthors engineering blog posts end-to-end: launch deep-dives, incident postmortems, architecture migrations, performance case studies, tutorials, AI/agent system writeups, security disclosures, and research-to-product translations. Picks the correct archetype, plans the abstraction ladder, enforces an evidence cadence (diagrams, benchmarks, profiles, traces, code, ablations), tunes voice against publisher house styles (Datadog, Vercel, GitHub, AWS, Meta, Cloudflare, Jane Street), and runs a pre-publish gate for narrative momentum and disclosure ethics. Use when drafting a new engineering post, restructuring a draft that feels flat, deciding which evidence form belongs where, validating that depth and product context are balanced, or preparing a postmortem, migration, or performance narrative for external publication. Do not use for API reference documentation, README authoring, marketing copy, release notes, generic SEO content, ghost-written executive thought leadership, or non-engineering long-form essays.
blog-google
IncludedGoogle API integration for blog performance: PageSpeed Insights, CrUX Core Web Vitals with 25-week history, Search Console performance, URL Inspection, Indexing API, GA4 organic traffic, NLP entity analysis for E-E-A-T, YouTube video search for embedding, and Google Ads Keyword Planner. Progressive feature availability based on credential tier (API key, OAuth/service account, GA4, Ads). Shares config with claude-seo at ~/.config/claude-seo/google-api.json. Use when user says "google data", "page speed", "core web vitals", "search console", "indexation", "GA4", "keyword research", "nlp entities", "blog performance", "youtube search", "google api setup".