Skip to content

Create a representation

Identity module

POST/representationsrepresentations.create

One party acting for another, with scopes and expiry. The artist accepts it. Creates a representation. Requires `Idempotency-Key`; a replay returns the original response. The organization is derived from the credential or the parent row, never from the body.

  • Requires the capability me.profile.write.
  • OAuth scopes: me.
  • Send an Idempotency-Key header. A replay with the same key returns the original response.
  • Error statuses: 400, 401, 409, 422, 429. Errors are RFC 9457 problem details.

Request body: RepresentationCreate

representations.create: RepresentationCreate
FieldTypeRequiredDescription
representative_person_idstring (uuid) | nullNoIdentifier of the representative.
artist_person_idstring (uuid)YesIdentifier of the represented artist.
scopesarray of RepresentationScopeYesDelegated scopes, stored as junction rows.
expires_onstring (date)YesExpiry.
{
  "representative_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
  "artist_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
  "scopes": [
    "Offers",
    "Advance"
  ],
  "expires_on": "2026-10-08"
}

Response 201: Representation

representations.create: Representation
FieldTypeRequiredDescription
idstring (uuid)YesIdentifier of the representation.
created_atstring (date-time)YesWhen the row was created.
updated_atstring (date-time)YesWhen the row was last updated.
representative_person_idstring (uuid) | nullYesIdentifier of the representative.
artist_person_idstring (uuid)YesIdentifier of the represented artist.
scopesarray of RepresentationScopeYesDelegated scopes, stored as junction rows.
expires_onstring (date)YesExpiry.
accepted_atstring (date-time) | nullYesWhen the artist accepted.
revoked_atstring (date-time) | nullYesWhen the artist or the account revoked it.
{
  "id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
  "created_at": "2026-10-08T14:30:00Z",
  "updated_at": "2026-10-08T14:30:00Z",
  "representative_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
  "artist_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
  "scopes": [
    "Offers",
    "Advance"
  ],
  "expires_on": "2026-10-08",
  "accepted_at": "2026-10-08T14:30:00Z",
  "revoked_at": "2026-10-08T14:30:00Z"
}

Code samples

curl -X POST "$XOS_BASE_URL/representations" \
  -H "Authorization: Bearer $XOS_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"representative_person_id":"0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f","artist_person_id":"0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f","scopes":["Offers","Advance"],"expires_on":"2026-10-08"}'
const { data } = await xos.representations.create({
    "representative_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
    "artist_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f",
    "scopes": [
      "Offers",
      "Advance"
    ],
    "expires_on": "2026-10-08"
  });
response = xos.representations.create({"representative_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f", "artist_person_id": "0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f", "scopes": ["Offers", "Advance"], "expires_on": "2026-10-08"})
xos representations create --data '{"representative_person_id":"0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f","artist_person_id":"0192f1e2-7c3a-7b4d-9e8f-1a2b3c4d5e6f","scopes":["Offers","Advance"],"expires_on":"2026-10-08"}'