Carriers
Add carrier note
Add an internal note to a carrier from your own system, with an optional Idempotency-Key so a retry never adds the note twice.
POST
/
api
/
p
/
v
{version}
/
carriers
/
{carrierId}
/
notes
Add carrier note
curl --request POST \
--url https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"Description": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({Description: '<string>'})
};
fetch('https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes"
payload = { "Description": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes",
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([
'Description' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+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://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes"
payload := strings.NewReader("{\n \"Description\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+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://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"Description\": \"<string>\"\n}")
.asString();{
"Id": "<string>",
"Description": "<string>",
"NoteType": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"CreatedBy": "<string>",
"CreatedById": "<string>"
}{
"Id": "<string>",
"Description": "<string>",
"NoteType": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"CreatedBy": "<string>",
"CreatedById": "<string>"
}{
"Errors": {},
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}The Add Carrier Note endpoint adds a note to a carrier. The note is listed with the carrier’s notes in Alvys and is not shown to the carrier. For more information on how versioning works and how to include it in your requests, please refer to the Versioning page.
Alvys generates the note’s
This endpoint requires the
carrier:update scope. See Authentication.Request parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
| version | path | String | Yes | API version to use. |
| carrierId | path | String | Yes | The carrier’s Id, as returned by Search carriers. |
| Idempotency-Key | header | String | No | 1 to 100 characters. Makes a retry safe: see Retry safely. |
Request body
| Name | Type | Required | Description |
|---|---|---|---|
| Description | string | Yes | The note text, 1 to 4000 characters of plain text. Markup is refused: see Plain text only. |
Id, saves it with NoteType General, and records your credential as CreatedBy. Notes added here cannot be edited or deleted through the API.
Plain text only
A< followed by a letter, !, / or ?, such as <b>, </p> or <!--, reads as markup and returns 400 Bad Request. Any other <, such as rate < 2.00 or <5 loads, is kept as sent.
Retry safely
Without anIdempotency-Key, every call adds a new note, so a retry after a timeout can leave two.
With an Idempotency-Key, the key is tied to this carrier:
- The first call adds the note and returns
201 Created. - The same key with the same
Descriptionreturns that note with200 OKand adds nothing. - The same key with a different
Descriptionreturns409 Conflictwith atypeending inIdempotencyKeyReused. Send a new key to add another note. The same applies when the note was edited in Alvys after it was added. - If the note was deleted in Alvys, the same key adds it again.
400 Bad Request.
MacroPoint
When the MacroPoint integration is on, Alvys sends a carrier’s first note to MacroPoint with the carrier’s details. A note added to a carrier that has no notes can reach MacroPoint.Response
201 Created with the new note, or 200 OK with the existing note on a replay of the same Idempotency-Key.
| Name | Type | Description |
|---|---|---|
| Id | string | The note’s id. |
| Description | string | The note text. |
| NoteType | string | General for notes added through the API. |
| CreatedAt | string | When the note was added (ISO 8601). |
| CreatedBy | string | Who added the note. |
| CreatedById | string | The id of who added the note. |
Errors
| Status | When |
|---|---|
400 Bad Request | Description is missing, empty, over 4000 characters or contains markup, the body is missing or malformed, or the Idempotency-Key is empty or over 100 characters. The field at fault is named under errors. |
401 Unauthorized | The access token is missing, invalid or expired. |
403 Forbidden | Your credential does not have the carrier:update scope. |
404 Not Found | The carrier does not exist, was deleted, or is an owner-operator. |
409 Conflict | The type ends in IdempotencyKeyReused: the key already added a note with a different Description. The type ends in CarrierChanged: the carrier kept changing while the note was being saved, and the note was not saved. Retry the request. |
413 Content Too Large | The request body is over 32 KB. |
429 Too Many Requests | You are rate limited. See Rate limits. |
Example cURL request
curl --location --request POST 'https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
--header 'Idempotency-Key: crm-note-58213' \
--data-raw '{
"Description": "Prefers loads out of Dallas. Call dispatch before 9 AM."
}'
Example response (201 Created)
{
"Id": "3f6d2a1c9b8e4f0a8d7c6b5a4e3d2c1b",
"Description": "Prefers loads out of Dallas. Call dispatch before 9 AM.",
"NoteType": "General",
"CreatedAt": "2026-12-02T15:04:11+00:00",
"CreatedBy": "Example Integration",
"CreatedById": "a1b2c3d4e5f60718293a4b5c6d7e8f90"
}
Rate limits
All endpoints are subject to rate limits to protect the API from traffic spikes. For detailed information, see the Rate Limits section.Authorizations
OAuth 2.0 client-credentials access token. Obtain one from https://auth.alvys.com/oauth/token (grant_type=client_credentials, audience=https://api.alvys.com/public/), then paste it here. The playground sends it as Authorization: Bearer <token>.
Path Parameters
Body
application/json-patch+jsonapplication/jsontext/jsonapplication/*+json
⌘I
Add carrier note
curl --request POST \
--url https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"Description": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({Description: '<string>'})
};
fetch('https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes"
payload = { "Description": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes",
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([
'Description' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+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://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes"
payload := strings.NewReader("{\n \"Description\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+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://integrations.alvys.com/api/p/v{version}/carriers/{carrierId}/notes")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"Description\": \"<string>\"\n}")
.asString();{
"Id": "<string>",
"Description": "<string>",
"NoteType": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"CreatedBy": "<string>",
"CreatedById": "<string>"
}{
"Id": "<string>",
"Description": "<string>",
"NoteType": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"CreatedBy": "<string>",
"CreatedById": "<string>"
}{
"Errors": {},
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}