Reference example
# Fixed reference example. Playground inputs do not update this sample.
curl --request POST \
--url https://api.aisa.one/apis/v1/trade/shipments/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"hs_code": "847130",
"importer_country": "US",
"limit": 1
}'curl --request POST \
--url https://api.aisa.one/apis/v1/trade/shipments/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"hs_code": "847130"
}
'import requests
url = "https://api.aisa.one/apis/v1/trade/shipments/search"
payload = { "hs_code": "847130" }
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({hs_code: '847130'})
};
fetch('https://api.aisa.one/apis/v1/trade/shipments/search', 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.aisa.one/apis/v1/trade/shipments/search",
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([
'hs_code' => '847130'
]),
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.aisa.one/apis/v1/trade/shipments/search"
payload := strings.NewReader("{\n \"hs_code\": \"847130\"\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.aisa.one/apis/v1/trade/shipments/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"hs_code\": \"847130\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/trade/shipments/search")
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 \"hs_code\": \"847130\"\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"bill_of_lading": "<string>",
"brand": "<string>",
"date": "<string>",
"description": "<string>",
"description_full": "<string>",
"description_truncated": true,
"exporter": {
"country": "<string>",
"id": "<string>",
"name": "<string>"
},
"hs_code": "<string>",
"importer": {
"country": "<string>",
"id": "<string>",
"name": "<string>"
},
"incoterm": "<string>",
"loading_port": "<string>",
"origin_country": "<string>",
"quantity": 123,
"quantity_unit": "<string>",
"reported_by": {
"country": "<string>",
"flow": "import"
},
"transport": "sea",
"unit_price_usd": 123,
"unloading_port": "<string>",
"value_usd": 123,
"weight_kg": 123
}
],
"has_more": true,
"next_cursor": "<string>",
"notice": "<string>",
"query": {
"data_through": "<string>"
},
"total": 123
}Global Trade & Customs
Search customs shipment declarations and bills of lading
Global Trade & Customs API (trade.shipments.search)
POST
https://api.aisa.one
/
apis
/
v1
/
trade
/
shipments
/
search
Reference example
# Fixed reference example. Playground inputs do not update this sample.
curl --request POST \
--url https://api.aisa.one/apis/v1/trade/shipments/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"hs_code": "847130",
"importer_country": "US",
"limit": 1
}'curl --request POST \
--url https://api.aisa.one/apis/v1/trade/shipments/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"hs_code": "847130"
}
'import requests
url = "https://api.aisa.one/apis/v1/trade/shipments/search"
payload = { "hs_code": "847130" }
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({hs_code: '847130'})
};
fetch('https://api.aisa.one/apis/v1/trade/shipments/search', 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.aisa.one/apis/v1/trade/shipments/search",
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([
'hs_code' => '847130'
]),
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.aisa.one/apis/v1/trade/shipments/search"
payload := strings.NewReader("{\n \"hs_code\": \"847130\"\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.aisa.one/apis/v1/trade/shipments/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"hs_code\": \"847130\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/trade/shipments/search")
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 \"hs_code\": \"847130\"\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"bill_of_lading": "<string>",
"brand": "<string>",
"date": "<string>",
"description": "<string>",
"description_full": "<string>",
"description_truncated": true,
"exporter": {
"country": "<string>",
"id": "<string>",
"name": "<string>"
},
"hs_code": "<string>",
"importer": {
"country": "<string>",
"id": "<string>",
"name": "<string>"
},
"incoterm": "<string>",
"loading_port": "<string>",
"origin_country": "<string>",
"quantity": 123,
"quantity_unit": "<string>",
"reported_by": {
"country": "<string>",
"flow": "import"
},
"transport": "sea",
"unit_price_usd": 123,
"unloading_port": "<string>",
"value_usd": 123,
"weight_kg": 123
}
],
"has_more": true,
"next_cursor": "<string>",
"notice": "<string>",
"query": {
"data_through": "<string>"
},
"total": 123
}请求规范
- 方法与路径: POST /apis/v1/trade/shipments/search
- 可用状态: enabled
- 请求 URL 模板:
https://api.aisa.one/apis/v1/trade/shipments/search
{
"operationId": "trade.shipments.search",
"method": "POST",
"path": "/apis/v1/trade/shipments/search",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"default": {
"value": {
"hs_code": "847130",
"importer_country": "US",
"limit": 1
}
},
"minimal": {
"value": {
"hs_code": "847130",
"importer_country": "US",
"limit": 1
}
}
},
"schema": {
"additionalProperties": false,
"allOf": [
{
"anyOf": [
{
"properties": {
"exporter": {}
},
"required": [
"exporter"
]
},
{
"properties": {
"hs_code": {}
},
"required": [
"hs_code"
]
},
{
"properties": {
"importer": {}
},
"required": [
"importer"
]
},
{
"properties": {
"product": {}
},
"required": [
"product"
]
}
]
}
],
"properties": {
"cursor": {
"maxLength": 200,
"minLength": 1,
"type": "string"
},
"exporter": {
"maxLength": 200,
"minLength": 2,
"type": "string"
},
"exporter_country": {
"maxLength": 80,
"minLength": 2,
"type": "string"
},
"fields": {
"items": {
"type": "string"
},
"maxItems": 40,
"minItems": 1,
"type": "array"
},
"hs_code": {
"maxLength": 10,
"minLength": 6,
"pattern": "^[0-9]{6,10}$",
"type": "string"
},
"importer": {
"maxLength": 200,
"minLength": 2,
"type": "string"
},
"importer_country": {
"maxLength": 80,
"minLength": 2,
"type": "string"
},
"limit": {
"default": 10,
"maximum": 100,
"minimum": 1,
"type": "integer"
},
"product": {
"maxLength": 100,
"minLength": 2,
"type": "string"
},
"since": {
"maxLength": 10,
"minLength": 10,
"pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$",
"type": "string"
},
"sort": {
"default": "date_desc",
"enum": [
"date_asc",
"date_desc"
],
"type": "string"
},
"until": {
"maxLength": 10,
"minLength": 10,
"pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$",
"type": "string"
}
},
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
费用与请求规则
按实际用量收费。 公开参考价格:每计费单位 $0.005 USD。 默认请求预估费用:$0.005 USD。 最终费用以实际用量为准。 账户适用价格可能不同;支持报价的接口可按实际请求获取报价。授权
请求体
application/json
- Option 1
- Option 2
- Option 3
- Option 4
响应
Normalized successful response