Skip to main content
PATCH
/
profiles
/
{profileId}
Update a profile
const options = {
  method: 'PATCH',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: JSON.stringify({name: 'Action Movie Fan', avatarUrl: 'https://example.com/new-avatar.jpg'})
};

fetch('https://api.discovr.media/profiles/{profileId}', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "id": "profile_abc123xyz",
  "name": "Action Movie Fan",
  "avatarUrl": "https://example.com/new-avatar.jpg",
  "createdAt": "2023-01-01T00:00:00.000Z"
}

Documentation Index

Fetch the complete documentation index at: https://docs.discovr.media/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer token authentication.

  • Identity-tier endpoints (/profiles, /auth/session-token, /auth/session) accept a long-lived refresh token (rt_<hex>).
  • Session-tier endpoints (/pages/*, /profile/*) accept a short-lived session JWT.

SDK clients use two typed API accessors (identityApi() with the refresh token vs sessionApi() with the session JWT) — see the SDK DiscovrAuth helper.

Format: Authorization: Bearer {token}

Path Parameters

profileId
string
required

The unique identifier of the profile to update

Body

application/json
name
string

The new display name for the profile. Must be a non-empty string if provided. At least one field (name or avatarUrl) must be provided.

Example:

"Action Movie Fan"

avatarUrl
string<uri>

The new URL of the profile avatar image. Must be a non-empty string if provided. At least one field (name or avatarUrl) must be provided.

Example:

"https://example.com/new-avatar.jpg"

Response

Profile updated successfully

id
string
required

The unique identifier of the profile

Example:

"profile_abc123xyz"

name
string
required

The display name of the profile

Example:

"Sci-Fi Lover"

avatarUrl
string<uri>
required

The URL of the profile avatar image

Example:

"https://example.com/avatar.jpg"

createdAt
string<date-time>
required

ISO 8601 timestamp indicating when the profile was created. Format: YYYY-MM-DDTHH:mm:ss.sssZ

Example:

"2023-01-01T00:00:00.000Z"