Skip to content

Update an artist

PUT
/api/v1/artists/{artistId}

Update the information of a legendary Argentine Rock artist. Make sure to provide accurate data.

Authorizations

Parameters

Path Parameters

artistId*
Typeinteger
Required
Example1

Request Body

JSON
[
{
"id": 1,
"name": "1",
"description": "2",
"image": "3",
"band": "4"
},
"Charly García",
"One of the most influential rock musicians in Argentine history.",
"https://cdn.rock-legends.com/photos/charly.jpg",
"Sui Generis"
]

Responses

OK
JSON
[
{
"id": 1,
"name": "1",
"description": "2",
"image": "3",
"band": "4"
},
"Charly García",
"One of the most influential rock musicians in Argentine history.",
"https://cdn.rock-legends.com/photos/charly.jpg",
"Sui Generis"
]

Samples

cURL
curl -X PUT https://stoplight.io/mocks/enzonotario/argentine-rock/122547792/api/v1/artists/{artistId}
JavaScript
fetch("https://stoplight.io/mocks/enzonotario/argentine-rock/122547792/api/v1/artists/{artistId}", { method: "PUT" })
  .then(response => response.json())
  .then(data => console.log(data));
PHP
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://stoplight.io/mocks/enzonotario/argentine-rock/122547792/api/v1/artists/{artistId}");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "PUT");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
Python
import requests
response = requests.put("https://stoplight.io/mocks/enzonotario/argentine-rock/122547792/api/v1/artists/{artistId}")
print(response.json())
Powered by VitePress OpenAPI