Check pickup availability
curl --request POST \
--url https://api.example.com/v1/pickups/availability \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connection": "<string>",
"contact": {
"name": "<string>",
"company": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"tax_ids": [
{
"value": "<string>",
"country": "<string>"
}
],
"instructions": "<string>",
"access_point": {
"carrier": "<string>",
"id": "<string>"
}
},
"date": "2023-12-25",
"handling_unit_count": 123
}
'import requests
url = "https://api.example.com/v1/pickups/availability"
payload = {
"connection": "<string>",
"contact": {
"name": "<string>",
"company": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"tax_ids": [
{
"value": "<string>",
"country": "<string>"
}
],
"instructions": "<string>",
"access_point": {
"carrier": "<string>",
"id": "<string>"
}
},
"date": "2023-12-25",
"handling_unit_count": 123
}
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({
connection: '<string>',
contact: {
name: '<string>',
company: '<string>',
email: 'jsmith@example.com',
phone: '<string>',
tax_ids: [{value: '<string>', country: '<string>'}],
instructions: '<string>',
access_point: {carrier: '<string>', id: '<string>'}
},
date: '2023-12-25',
handling_unit_count: 123
})
};
fetch('https://api.example.com/v1/pickups/availability', 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.example.com/v1/pickups/availability",
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([
'connection' => '<string>',
'contact' => [
'name' => '<string>',
'company' => '<string>',
'email' => 'jsmith@example.com',
'phone' => '<string>',
'tax_ids' => [
[
'value' => '<string>',
'country' => '<string>'
]
],
'instructions' => '<string>',
'access_point' => [
'carrier' => '<string>',
'id' => '<string>'
]
],
'date' => '2023-12-25',
'handling_unit_count' => 123
]),
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.example.com/v1/pickups/availability"
payload := strings.NewReader("{\n \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\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.example.com/v1/pickups/availability")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/pickups/availability")
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 \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\n}"
response = http.request(request)
puts response.read_body{
"object": "pickup_availability",
"connection": "<string>",
"dates": [
{
"date": "2023-12-25",
"windows": [
{
"ready_at": "<string>",
"close_at": "<string>"
}
],
"cutoff_at": 123,
"fee": {
"amount": 123,
"currency": "usd"
}
}
],
"messages": [
{
"level": "info",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"carrier": "<string>"
}
]
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}Pickups
Check pickup availability
POST
/
v1
/
pickups
/
availability
Check pickup availability
curl --request POST \
--url https://api.example.com/v1/pickups/availability \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connection": "<string>",
"contact": {
"name": "<string>",
"company": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"tax_ids": [
{
"value": "<string>",
"country": "<string>"
}
],
"instructions": "<string>",
"access_point": {
"carrier": "<string>",
"id": "<string>"
}
},
"date": "2023-12-25",
"handling_unit_count": 123
}
'import requests
url = "https://api.example.com/v1/pickups/availability"
payload = {
"connection": "<string>",
"contact": {
"name": "<string>",
"company": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"tax_ids": [
{
"value": "<string>",
"country": "<string>"
}
],
"instructions": "<string>",
"access_point": {
"carrier": "<string>",
"id": "<string>"
}
},
"date": "2023-12-25",
"handling_unit_count": 123
}
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({
connection: '<string>',
contact: {
name: '<string>',
company: '<string>',
email: 'jsmith@example.com',
phone: '<string>',
tax_ids: [{value: '<string>', country: '<string>'}],
instructions: '<string>',
access_point: {carrier: '<string>', id: '<string>'}
},
date: '2023-12-25',
handling_unit_count: 123
})
};
fetch('https://api.example.com/v1/pickups/availability', 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.example.com/v1/pickups/availability",
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([
'connection' => '<string>',
'contact' => [
'name' => '<string>',
'company' => '<string>',
'email' => 'jsmith@example.com',
'phone' => '<string>',
'tax_ids' => [
[
'value' => '<string>',
'country' => '<string>'
]
],
'instructions' => '<string>',
'access_point' => [
'carrier' => '<string>',
'id' => '<string>'
]
],
'date' => '2023-12-25',
'handling_unit_count' => 123
]),
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.example.com/v1/pickups/availability"
payload := strings.NewReader("{\n \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\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.example.com/v1/pickups/availability")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/pickups/availability")
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 \"connection\": \"<string>\",\n \"contact\": {\n \"name\": \"<string>\",\n \"company\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"tax_ids\": [\n {\n \"value\": \"<string>\",\n \"country\": \"<string>\"\n }\n ],\n \"instructions\": \"<string>\",\n \"access_point\": {\n \"carrier\": \"<string>\",\n \"id\": \"<string>\"\n }\n },\n \"date\": \"2023-12-25\",\n \"handling_unit_count\": 123\n}"
response = http.request(request)
puts response.read_body{
"object": "pickup_availability",
"connection": "<string>",
"dates": [
{
"date": "2023-12-25",
"windows": [
{
"ready_at": "<string>",
"close_at": "<string>"
}
],
"cutoff_at": 123,
"fee": {
"amount": 123,
"currency": "usd"
}
}
],
"messages": [
{
"level": "info",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"carrier": "<string>"
}
]
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>",
"carrier": {
"id": "<string>",
"connection": "<string>",
"code": "<string>",
"message": "<string>"
},
"shipment": "<string>",
"details": [
{
"code": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}
}Authorizations
apiKeyoauth2
sk_test_ / sk_live_ / rk_test_ / rk_live_ keys
Headers
Act on behalf of a connected account (acct_...)
Body
application/json