Skip to content

docs: document /api/artist/create endpoint#10

Merged
sweetmantech merged 10 commits intomainfrom
sweetmantech/myc-3925-docs-document-the-apiartistcreateroutets-api
Jan 15, 2026
Merged

docs: document /api/artist/create endpoint#10
sweetmantech merged 10 commits intomainfrom
sweetmantech/myc-3925-docs-document-the-apiartistcreateroutets-api

Conversation

@sweetmantech
Copy link
Copy Markdown
Collaborator

@sweetmantech sweetmantech commented Jan 15, 2026

Summary

  • Documents the /api/artist/create API endpoint in OpenAPI spec
  • Adds endpoint documentation for creating new artist accounts

Test plan

  • Verify OpenAPI spec is valid
  • Check Mintlify generates API reference page correctly

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added POST /api/artists endpoint to create artist profiles, returning full profile data including onboarding, account metadata, socials, and optional organization linkage.
  • Documentation

    • New API reference page for the Create Artist endpoint and navigation updated to include the new Artists create doc.

✏️ Tip: You can customize this high-level summary in your review settings.

sweetmantech and others added 2 commits January 15, 2026 09:56
Add documentation for the POST /api/artist endpoint that creates a new
artist account and associates it with an owner account.

Changes:
- Add POST /api/artist endpoint with requestBody schema
- Add CreateArtistRequest schema (name, account_id)
- Add CreateArtistResponse schema with artist wrapper
- Add CreatedArtist schema with full artist model
- Add CreateArtistError schema for validation errors

Returns 201 on success with the created artist object.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jan 15, 2026

Warning

Rate limit exceeded

@sweetmantech has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 20 minutes and 51 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 40e495f and 9dc4f2a.

📒 Files selected for processing (1)
  • api-reference/openapi.json
📝 Walkthrough

Walkthrough

Added a new OpenAPI endpoint POST /api/artists to create artists (optionally linked to an account or organization), plus public schemas for request, response, created-artist payload, and error; documentation page and navigation entry were added.

Changes

Cohort / File(s) Summary
OpenAPI spec
api-reference/openapi.json
Added POST /api/artists operation with request schema CreateArtistRequest and responses: 201 -> CreateArtistResponse (contains CreatedArtist), 400 validation error, 500 server error. Introduced schemas: CreateArtistRequest, CreateArtistResponse, CreatedArtist, CreateArtistError.
API docs page
api-reference/artists/create.mdx
New documentation page for "Create Artist" describing POST /api/artists (YAML front matter added).
Navigation / site config
docs.json
Added the new artists create page to the API Reference navigation (expanded Artists group) and removed a duplicated Chat group block.

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant API as API Server
  participant DB as Database

  Client->>API: POST /api/artists (CreateArtistRequest)
  API->>DB: INSERT artist record (with account_id / organization_id)
  DB-->>API: OK + created artist row (id, timestamps, metadata)
  API-->>Client: 201 Created (CreateArtistResponse with CreatedArtist)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 I hopped a path where artists grow,

POSTing dreams where names can go.
IDs and timestamps in a row,
A little hop — the API says "go!" 🎨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Title check ⚠️ Warning The PR title references '/api/artist/create' (singular), but the actual endpoint implemented is '/api/artists' (plural) with POST method, creating a mismatch with the documentation. Update the PR title to accurately reflect the actual endpoint: 'docs: document POST /api/artists endpoint' or similar.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

- Add api-reference/artists/create.mdx for POST /api/artist
- Add endpoint to navigation in docs.json under Artists group

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@api-reference/openapi.json`:
- Around line 323-370: The OpenAPI POST /api/artist description mentions
optional organization linkage but the CreateArtistRequest schema lacks an
organization_id field; either add an optional organization_id property to the
CreateArtistRequest schema so the request supports linking an artist to an
organization, or edit the /api/artist operation description to remove/clarify
the organization linkage and instead document the correct flow (e.g., that
organization linking is done via a separate endpoint such as
/api/organizations/artists); update CreateArtistRequest (symbol:
CreateArtistRequest) or the /api/artist operation description accordingly so the
contract and description are consistent.
🧹 Nitpick comments (3)
api-reference/openapi.json (3)

2965-2972: Array schemas missing items definition.

The account_info and account_socials array properties lack items definitions, which will cause issues with OpenAPI client generators and schema validators. Consider adding the item schema or referencing an existing schema.

📝 Suggested fix
          "account_info": {
            "type": "array",
+           "items": {
+             "type": "object"
+           },
            "description": "Account info records"
          },
          "account_socials": {
            "type": "array",
+           "items": {
+             "type": "object"
+           },
            "description": "Linked social media accounts"
          }

If these have a known structure, define proper schemas (e.g., reference existing ArtistSocial for account_socials).


2961-2964: Missing type for onboarding_data property.

The onboarding_data field lacks a type specification. For better client code generation and documentation clarity, consider specifying the expected type (e.g., object with additionalProperties: true for arbitrary JSON data).

📝 Suggested fix
          "onboarding_data": {
+           "type": "object",
+           "additionalProperties": true,
            "nullable": true,
            "description": "Onboarding data"
          },

2975-2999: Consider adding required array to error schema for consistency.

The CreateArtistError schema doesn't specify required fields, unlike other error schemas in this spec (e.g., ArtistsErrorResponse requires ["status", "message"]). Adding a required array improves client-side error handling predictability.

📝 Suggested fix
      "CreateArtistError": {
        "type": "object",
+       "required": ["status"],
        "properties": {
          "status": {
📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7aa3c06 and c236135.

📒 Files selected for processing (1)
  • api-reference/openapi.json
🔇 Additional comments (2)
api-reference/openapi.json (2)

2859-2874: LGTM!

The CreateArtistRequest schema is well-defined with appropriate validation constraints (minLength: 1 for name, format: uuid for account_id) and clear descriptions.


2875-2883: LGTM!

The response schema follows the established pattern of wrapping the created entity in a named property.

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.

Comment thread api-reference/openapi.json Outdated
- Move POST method from /api/artist to /api/artists for consistency
- Update MDX file to reference plural endpoint

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
sweetmantech and others added 3 commits January 15, 2026 10:23
- Consolidate artist-related endpoints under single Artists group
- Remove redundant Artist navigation group

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add optional organization_id field to CreateArtistRequest schema
- Allows linking new artist to an organization on creation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Make account_id optional in POST /api/artists with org API key note
- Move Chat endpoints to top of API reference navigation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
sweetmantech and others added 2 commits January 15, 2026 10:45
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Links to quickstart#api-keys section for API key creation instructions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@sweetmantech sweetmantech merged commit 81918ff into main Jan 15, 2026
2 checks passed
sidneyswift added a commit that referenced this pull request May 7, 2026
Triaged all 22 line-level comments (cubic-dev-ai + coderabbit). 7
implemented, 10 rejected with reason, 5 already-resolved by earlier
PR commits. Implemented:

#4 (skills/music-industry-research.mdx) — corrected `/research/*` to
`/api/research/*` so the path matches the rest of the docs.

#5 / #8 (api-reference/openapi/content.json:619) — POST
/api/content/create description said "Returns `{run_id}`" but the
202 response and schema return `runIds` (an array). Brought the
description into sync with the response shape so generated clients
and readers stop targeting the wrong field name.

#6 (authentication.mdx) — Bearer-token guidance was scoped to Privy
JWTs only, but MCP clients also pass an API key as a Bearer token
(per /mcp). Broadened the guidance and the comparison table row to
cover both cases.

#7 (agents.mdx Authenticate section) — auth steps walked through
the email-verification flow as if it applied universally, but the
documented throwaway agent+...@recoupable.com path returns the API
key immediately on signup with no code. Added an explicit note up
front and inline in step 1 that the agent+ path skips steps 2 and 3.

#9 (api-reference/openapi/content.json POST /api/content/video
description) — the description listed `prompt` as a mode for
"create a video from a text description", but the
ContentCreateVideoRequest schema requires `image_url` and explicitly
says "text-only prompt mode is not supported." Rewrote the
description to lead with the image_url requirement and updated each
mode's gloss to reflect what the model actually does (uses the image
as first frame / style ref / etc.).

#15 (quickstart.mdx) — `jq -r .api_key` silently returns "null" on
error responses (invalid code, expired code, rate limit) and
exports RECOUP_API_KEY=null, which fails confusingly downstream.
Switched to `jq -er '.api_key'` so the pipeline exits non-zero when
the field is missing or null.

#21 (credits.mdx Check your tier section) — documented
`GET /api/subscription/status` and an `isPro` field. Verified live:
endpoint returns 404 on api.recoupable.com AND on chat.recoupable.com,
and isPro doesn't appear in any OpenAPI spec. The handler exists in
chat/app/api/subscription/status/route.ts but isn't reachable as
documented. Replaced the curl block with guidance to check the
chat dashboard, with a note that a programmatic status endpoint is
on the roadmap.

Rejected with reason (10 comments):
- #1, #3 (mcp.mdx, agents.mdx > 100 lines): an arbitrary lint rule
  that doesn't apply to docs pages whose value is enumeration (tool
  catalogs, decision trees)
- #10 (releases.json profileUrls schema): real engineering question
  about whether to encode constraints in the schema; not a docs-only
  fix
- #11 (docs.json primary color #0a0a0a): intentional brand refresh
  per merged PR #168
- #13 (docs.json primary CTA /keys subpath): matches the "Get API
  Key" CTA copy, not a generic app entrypoint
- #16-#20 (kebab-case skill titles): explicit user choice; titles
  match URL slugs and the npx-skills `--skill <name>` install command

Already resolved by earlier PR commits (5 comments):
- #2, #12 (Instagram nav entries): removed in 318a555
- #14 (MCP host vs REST host): resolved in 1634ba6 — both on
  api.recoupable.com now
- #22 (credits.mdx host): resolved in 1634ba6 — bot's recommended
  direction would have been backwards
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant