Returns
Update Return
Updates an existing Return’s ticket and/or its Return Shipment. Both body objects are optional — send what changes.
Identification (query parameters): standard flow — return_uuid,
return_id, or shipment_uuid; preprinted-label flow — shipment_id
or shipment_uuid.
Rules:
- Write-once fields:
return_id,cost_of_return,requested_date,shipment_id. - Do not send
tracking_numberorcarrier_reference— the Return Booking Service sets them when the return label is generated. - Ticket fields and most shipment fields replace their stored values
entirely (whole arrays, whole address objects);
tags,events,linked_shipments,documentsare add-only, as on Update Shipment. - A Return Shipment cannot be updated after a successful carrier booking.
Identical update requests are deduplicated for 30 seconds.
POST
/
v5
/
return
/
update
/
Update Return
curl --request POST \
--url https://api.perform.ai/v5/return/update/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"return_ticket": {
"internal_notes": "Customer confirmed drop-off point."
}
}
'import requests
url = "https://api.perform.ai/v5/return/update/"
payload = { "return_ticket": { "internal_notes": "Customer confirmed drop-off point." } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({return_ticket: {internal_notes: 'Customer confirmed drop-off point.'}})
};
fetch('https://api.perform.ai/v5/return/update/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.perform.ai/v5/return/update/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'return_ticket' => [
'internal_notes' => 'Customer confirmed drop-off point.'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.perform.ai/v5/return/update/"
payload := strings.NewReader("{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.perform.ai/v5/return/update/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.perform.ai/v5/return/update/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"api_response": "<string>",
"data": {
"shipment": {
"shipment_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_uuid": "<string>",
"documents": [
{}
],
"created_date": "<string>"
},
"return_ticket": {
"return_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"return_id": "<string>",
"return_status": "<string>",
"requested_date": "<string>",
"created_date": "<string>",
"updated_date": "<string>"
}
}
}{
"api_response": "<string>",
"warnings": {},
"data": {}
}{
"api_response": "<string>",
"message": "<string>",
"errors": {}
}{
"api_response": 403,
"message": "Key not authorized"
}{
"api_response": 429,
"message": "Throttled"
}{
"api_response": "500",
"message": "System error"
}Authorizations
Query Parameters
Body
application/json
⌘I
Update Return
curl --request POST \
--url https://api.perform.ai/v5/return/update/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"return_ticket": {
"internal_notes": "Customer confirmed drop-off point."
}
}
'import requests
url = "https://api.perform.ai/v5/return/update/"
payload = { "return_ticket": { "internal_notes": "Customer confirmed drop-off point." } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({return_ticket: {internal_notes: 'Customer confirmed drop-off point.'}})
};
fetch('https://api.perform.ai/v5/return/update/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.perform.ai/v5/return/update/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'return_ticket' => [
'internal_notes' => 'Customer confirmed drop-off point.'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.perform.ai/v5/return/update/"
payload := strings.NewReader("{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.perform.ai/v5/return/update/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.perform.ai/v5/return/update/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"return_ticket\": {\n \"internal_notes\": \"Customer confirmed drop-off point.\"\n }\n}"
response = http.request(request)
puts response.read_body{
"api_response": "<string>",
"data": {
"shipment": {
"shipment_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_uuid": "<string>",
"documents": [
{}
],
"created_date": "<string>"
},
"return_ticket": {
"return_uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"return_id": "<string>",
"return_status": "<string>",
"requested_date": "<string>",
"created_date": "<string>",
"updated_date": "<string>"
}
}
}{
"api_response": "<string>",
"warnings": {},
"data": {}
}{
"api_response": "<string>",
"message": "<string>",
"errors": {}
}{
"api_response": 403,
"message": "Key not authorized"
}{
"api_response": 429,
"message": "Throttled"
}{
"api_response": "500",
"message": "System error"
}