Skip to main content
PUT
/
product
/
{id}
/
artists
Update Product Artists
curl --request PUT \
  --url https://server26-dot-royalti-project.uc.r.appspot.com/product/{id}/artists \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "artists": [
    "artist-id-1",
    "artist-id-2"
  ]
}'
{
  "message": "Artist added to product"
}
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Code Examples

const response = await fetch('https://server26-dot-royalti-project.uc.r.appspot.com/product/example-id/artists', {
  method: 'PUT',
  headers: {
    'Authorization': `Bearer ${token}`,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "artists": [
      {}
    ]
  })
});

const data = await response.json();
console.log(data);

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Path Parameters

id
string
required

Product ID

Body

application/json
artists
string[]
required

Array of artist IDs to associate with the product

Response

Success

message
string