ONE Record uses a RESTful API with standard HTTP methods. Here's how it works.
HTTP Methods:
GET - Retrieve Data
GET /logistics-objects/{id}
- Retrieve a Logistics Object
- Get current state of shipment, piece, etc.
- Read events and tracking data
POST - Create Objects
POST /logistics-objects
Content-Type: application/ld+json
- Create new Logistics Objects
- Publish events
- Submit data
PATCH - Update Objects
PATCH /logistics-objects/{id}
- Update existing objects
- Partial modifications
- Status changes
DELETE - Remove Objects
DELETE /logistics-objects/{id}
- Remove objects (with restrictions)
- Cancel bookings
- Archive data
Key Endpoints:
π¦ Logistics Objects:
- /logistics-objects - Collection
- /logistics-objects/{id} - Single object
- /logistics-objects/{id}/events - Events for object
π Subscriptions:
- /subscriptions - Subscribe to updates
- Push notifications when data changes
- Webhook-based updates
π Authentication:
- OAuth 2.0
- Bearer tokens
- Role-based access control
Data Format (JSON-LD):
{
"@context": {
"cargo": "https://onerecord.iata.org/ns/cargo#"
},
"@type": "cargo:Shipment",
"@id": "https://api.carrier.com/shipments/123",
"cargo:totalGrossWeight": {
"@type": "cargo:Value",
"cargo:numericalValue": 25.5,
"cargo:unit": "KGM"
}
}
Benefits Over EDI:
| EDI (Legacy) | ONE Record |
|---|---|
| Fixed format messages | Flexible linked data |
| Point-to-point | Network sharing |
| Batch processing | Real-time updates |
| Text-based | JSON-LD/API |
| Manual mapping | Semantic web |