List shipment party roles
curl --request GET \
--url https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles \
--header 'Authorization: <api-key>'import requests
url = "https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles', 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.terminal49.com/v2/shipments/{shipment_id}/party_roles",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "1d0f2a0e-5c3b-4c7e-9a52-3b6f8d2e4a11",
"type": "party_role",
"attributes": {
"role": "shipper",
"roleable_type": "Shipment",
"roleable_id": "8f0c6b1a-2d4e-4f7b-9c3a-5e6d7f8a9b0c",
"created_at": "2026-09-01T14:02:11Z",
"updated_at": "2026-09-01T14:02:11Z"
},
"relationships": {
"party": {
"data": {
"id": "ba4cb904-827f-4038-8e31-1e92b3356218",
"type": "party"
}
}
}
}
],
"included": [
{
"id": "ba4cb904-827f-4038-8e31-1e92b3356218",
"type": "party",
"attributes": {
"company_name": "ACME LOGISTICS",
"nickname": "ACME"
}
}
],
"links": {
"self": "/v2/shipments/8f0c6b1a-2d4e-4f7b-9c3a-5e6d7f8a9b0c/party_roles"
}
}{
"errors": [
{
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
},
"code": "<string>",
"status": "<string>",
"meta": {}
}
]
}Party Roles
List shipment party roles
List the parties assigned to a shipment in the Terminal49 API, with the role each party plays.
GET
/
shipments
/
{shipment_id}
/
party_roles
List shipment party roles
curl --request GET \
--url https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles \
--header 'Authorization: <api-key>'import requests
url = "https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles', 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.terminal49.com/v2/shipments/{shipment_id}/party_roles",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.terminal49.com/v2/shipments/{shipment_id}/party_roles")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "1d0f2a0e-5c3b-4c7e-9a52-3b6f8d2e4a11",
"type": "party_role",
"attributes": {
"role": "shipper",
"roleable_type": "Shipment",
"roleable_id": "8f0c6b1a-2d4e-4f7b-9c3a-5e6d7f8a9b0c",
"created_at": "2026-09-01T14:02:11Z",
"updated_at": "2026-09-01T14:02:11Z"
},
"relationships": {
"party": {
"data": {
"id": "ba4cb904-827f-4038-8e31-1e92b3356218",
"type": "party"
}
}
}
}
],
"included": [
{
"id": "ba4cb904-827f-4038-8e31-1e92b3356218",
"type": "party",
"attributes": {
"company_name": "ACME LOGISTICS",
"nickname": "ACME"
}
}
],
"links": {
"self": "/v2/shipments/8f0c6b1a-2d4e-4f7b-9c3a-5e6d7f8a9b0c/party_roles"
}
}{
"errors": [
{
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
},
"code": "<string>",
"status": "<string>",
"meta": {}
}
]
}Returns every party role on the shipment. The linked parties are returned in
included.
Path parameters
| Parameter | Required | Description |
|---|---|---|
shipment_id | Yes | The ID of the shipment |
Authorizations
Use a Terminal49 API key in the Authorization header with the Token prefix.
Authorization: Token YOUR_API_KEY
Path Parameters
Shipment ID
Was this page helpful?