Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions api-reference/artists/update.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: 'Update Artist'
description: 'Update the settings for an artist.'
openapi: "/api-reference/openapi/releases.json PATCH /api/artists/{id}"
---
230 changes: 230 additions & 0 deletions api-reference/openapi/releases.json
Original file line number Diff line number Diff line change
Expand Up @@ -515,6 +515,77 @@
}
},
"/api/artists/{id}": {
"patch": {
"description": "Update an artist's settings. This updates profile fields, artist account info, and any provided socials, then returns the merged artist payload.",
"parameters": [
{
"name": "id",
"in": "path",
"description": "Artist account ID to update.",
"required": true,
"schema": {
"type": "string",
"format": "uuid"
}
}
],
"requestBody": {
"description": "Artist fields to update",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateArtistRequest"
}
}
}
},
"responses": {
"200": {
"description": "Artist updated successfully",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateArtistResponse"
}
}
}
},
"400": {
"description": "Bad request - invalid artist id or invalid update payload",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateArtistErrorResponse"
}
}
}
},
"401": {
"description": "Unauthorized - missing or invalid authentication"
},
"403": {
"description": "Forbidden - the authenticated account cannot update this artist",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateArtistErrorResponse"
}
}
}
},
"404": {
"description": "Artist not found",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateArtistErrorResponse"
}
}
}
}
}
},
"delete": {
"description": "Delete an artist accessible to the authenticated account. This removes the caller's direct artist link and, if no owner links remain, deletes the artist account itself.",
"parameters": [
Expand Down Expand Up @@ -3481,6 +3552,165 @@
"example": true
}
}
},
"UpdateArtistErrorResponse": {
"type": "object",
"required": [
"status",
"error"
],
"properties": {
"status": {
"type": "string",
"enum": [
"error"
],
"description": "Status of the request"
},
"missing_fields": {
"type": "array",
"items": {
"type": "string"
},
"description": "List of missing or invalid field names"
},
Comment thread
coderabbitai[bot] marked this conversation as resolved.
"error": {
"type": "string",
"description": "Error message describing what went wrong"
}
}
},
"ArtistKnowledge": {
"type": "object",
"required": [
"name",
"url",
"type"
],
"properties": {
"name": {
"type": "string",
"description": "Display name of the knowledge file"
},
"url": {
"type": "string",
"format": "uri",
"description": "Resolvable URL for the knowledge file"
},
"type": {
"type": "string",
"description": "MIME type of the knowledge file"
}
}
},
"UpdateArtistProfileUrls": {
"type": "object",
"additionalProperties": {
"type": "string",
"format": "uri"
},
"description": "Social profile URLs keyed by platform slug, for example INSTAGRAM or SPOTIFY."
},
"UpdateArtistRequest": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "Artist display name"
},
"image": {
"type": "string",
"format": "uri",
"description": "Artist profile image URL"
},
"instruction": {
"type": "string",
"description": "Manual instruction text for the artist"
},
"label": {
"type": "string",
"description": "Record label name"
},
"knowledges": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ArtistKnowledge"
},
"description": "Knowledge files attached to the artist"
},
"profileUrls": {
"$ref": "#/components/schemas/UpdateArtistProfileUrls"
},
"pinned": {
"type": "boolean",
"description": "Pin or unpin this artist for the authenticated account"
}
}
},
"UpdatedArtist": {
"type": "object",
"required": [
"account_id",
"name",
"account_socials",
"pinned"
],
"properties": {
"account_id": {
"type": "string",
"format": "uuid",
"description": "UUID of the artist account"
},
"name": {
"type": "string",
"description": "Artist name"
},
"image": {
"type": "string",
"nullable": true,
"description": "Artist profile image URL"
},
"instruction": {
"type": "string",
"nullable": true,
"description": "Artist instruction text"
},
"knowledges": {
"type": "array",
"nullable": true,
"items": {
"$ref": "#/components/schemas/ArtistKnowledge"
},
"description": "Knowledge files stored on the artist profile"
},
"label": {
"type": "string",
"nullable": true,
"description": "Record label name"
},
"account_socials": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ArtistSocial"
},
"description": "Linked artist socials"
},
"pinned": {
"type": "boolean",
"description": "Whether the artist is pinned for the authenticated account"
}
}
},
"UpdateArtistResponse": {
"type": "object",
"required": [
"artist"
],
"properties": {
"artist": {
"$ref": "#/components/schemas/UpdatedArtist"
}
}
}
}
}
Expand Down
1 change: 1 addition & 0 deletions docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"pages": [
"api-reference/artists/list",
"api-reference/artists/create",
"api-reference/artists/update",
"api-reference/artists/pin",
"api-reference/artists/unpin",
"api-reference/artists/delete",
Expand Down