Upload an organization logo (owner-only)
const url = 'http://localhost:8000/api/me/branding/logo/';const form = new FormData();form.append('file', 'file');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:8000/api/me/branding/logo/ \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: multipart/form-data' \ --form file=@fileMultipart upload of an org logo for the active team. Owner-only (403 for members). Accepts PNG / JPG / SVG up to 2 MB; wrong type or oversize → 400. Stores the object in the media bucket under teams/<id>/branding/ and returns its public logo_url. The URL is NOT persisted by this call — PATCH it into /api/me/branding/ as logo_url to save it (mirrors the Client.avatar_url two-step).
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Multipart body for POST /api/me/branding/logo/.
object
Logo image — PNG / JPG / SVG, ≤ 2 MB. Validated server-side.
Responses
Section titled “Responses”object
Public URL of the stored logo. PATCH it into /api/me/branding/ as logo_url to persist.
Examples
Uploaded logo URL
{ "logo_url": "https://media.example/aikynetix-media/teams/2648a781/branding/logo-9f3ab2c1.svg"}object
Human-readable message, or a stable machine code for the cases a client branches on. The standard envelope for 400 (validation — a field-keyed object may appear instead), 401 (missing / invalid credentials), 403 (authenticated but not permitted), and 404 (absent — cross-team records are collapsed to 404 so the API never leaks the existence of another team’s data).
Examplegenerated
{ "detail": "example"}object
Human-readable message, or a stable machine code for the cases a client branches on. The standard envelope for 400 (validation — a field-keyed object may appear instead), 401 (missing / invalid credentials), 403 (authenticated but not permitted), and 404 (absent — cross-team records are collapsed to 404 so the API never leaks the existence of another team’s data).
Examplegenerated
{ "detail": "example"}object
Human-readable message, or a stable machine code for the cases a client branches on. The standard envelope for 400 (validation — a field-keyed object may appear instead), 401 (missing / invalid credentials), 403 (authenticated but not permitted), and 404 (absent — cross-team records are collapsed to 404 so the API never leaks the existence of another team’s data).
Examplegenerated
{ "detail": "example"}