Reject deliverable
putapi.bunnystudio.com/deliverables/{id}
This endpoint rejects a specific deliverable using its UUID.
Requirements
Authentication
Scope
Path parameters
id
string
Bunny Studio UUID of the deliverable you want to reject
Bunny Studio UUID of the deliverable you want to reject
Request body
status
string
Should send the string "rejected"
Should send the string "rejected"
reason
<optional> string
The reason for the rejection of the deliverable.
The reason for the rejection of the deliverable.
reasonCode
newGenderAndAge
<conditional required> string
If the rejection reason is "genderAndAgeChange" this field is required, See the available option with the Get Attributes Values Values endpoint.
If the rejection reason is "genderAndAgeChange" this field is required, See the available option with the Get Attributes Values Values endpoint.
Request example
- Console
- JavaScript
- Python
- PHP - CURL
curl --request PUT \
--url https://api.bunnystudio.com/deliverables/DELIVERABLE_ID \
--header "Content-Type: application/json" \
--header "x-access-token: YOUR_TOKEN" \
--data '{
"status": "rejected",
"reason": Reasons to reject the deliverable,
"reasonCode": REASON_CODE,
"newGenderAndAge": genderAndAgeId,
}'
const url = 'https://api.bunnystudio.com/deliverables/DELIVERABLE_ID';
const options = {
method: 'PUT',
headers: {
'content-type': 'application/json',
'x-access-token': 'YOUR_TOKEN',
}
body: JSON.stringify(
{
"status": "rejected",
"reason": Reasons to reject the deliverable,
"reasonCode": REASON_CODE,
"newGenderAndAge": genderAndAgeId,
}
)
};
fetch(url, options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import requests
import json
api_url = "https://api.bunnystudio.com/deliverables/DELIVERABLE_ID"
headers = {
"Content-Type": "application/json; charset=utf-8",
'x-access-token': 'YOUR_TOKEN',
}
body = {
"status": "rejected",
"reason": "Reasons to reject the deliverable",
"reasonCode": "REASON_CODE",
"newGenderAndAge": "genderAndAgeId",
}
response = requests.put(api_url, headers=headers, json=body)
print(response.text)
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://api.bunnystudio.com/deliverables/DELIVERABLE_ID',
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => array(
'content-type': 'application/json',
'x-access-token': 'YOUR_TOKEN',
),
CURLOPT_POSTFIELDS => '{
"status": "rejected",
"reason": "Reasons to reject the deliverable",
"reasonCode": "REASON_CODE",
"newGenderAndAge": "genderAndAgeId",
}'
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
Response format
id
string
A UUID (Universal Unique Identifier) that identifies the deliverable on Bunny Studio's database. You should use this ID for all API actions related to a specific deliverable.
A UUID (Universal Unique Identifier) that identifies the deliverable on Bunny Studio's database. You should use this ID for all API actions related to a specific deliverable.
serviceSubCategory
string
The category of this deliverable
The category of this deliverable
name
string
The name of the deliverable. If it consists of multiple parts, the string will usually represent the part number (e.g. "Part 2").
The name of the deliverable. If it consists of multiple parts, the string will usually represent the part number (e.g. "Part 2").
status
string
You should use the string "rejected", on the response it will show the current status of the deliverable
You should use the string "rejected", on the response it will show the current status of the deliverable
reason
<optional> string
The reason for the rejection of the deliverable.
The reason for the rejection of the deliverable.
reasonCode
newGenderAndAge
<conditional required> string
If the rejection reason is "genderAndAgeChange" this field is required, See the available option with the Get Attributes Values Values endpoint.
If the rejection reason is "genderAndAgeChange" this field is required, See the available option with the Get Attributes Values Values endpoint.
Response example
{
"id": "671e74ab-ca44-4d87-9346-ae8318c44774",
"serviceSubCategory": "voice_over",
"name": "part1",
"status": "rejected",
"reason": Reasons to reject the deliverable,
"reasonCode": REASON_CODE,
"newGenderAndAge": genderAndAgeId,
}
Error responses
500 Error rejecting project
{
status: 500,
type: 'ERROR_REJECTING_DELIVERABLE',
message: 'There was an error rejecting the deliverable with id \"DELIVERABLE_ID\", please talk with our support team',
}
400 Deliverable not exist
{
status: 404,
type: 'DELIVERABLE_NO_EXIST',
message: 'Deliverable with id \"DELIVERABLE_ID\" not found',
}
400 Deliverable already rejected
{
status: 404,
type: 'DELIVERABLE_ALREADY_REJECTED',
message: 'Deliverable with id \"DELIVERABLE_ID\" is already rejected',
}
403 Forbidden
{
status: 403,
type: 'FORBIDDEN',
message: 'You do not have permission to do this action',
}
422 Id required
{
status: 422,
type: 'ID_REQUIRED',
message: 'The field "\id\" is required',
}