API Documentation
Learn how to integrate with the Lunar Container Tracking API
Quick Start
- Create an account and get your API key
- Make your first API request
- Add containers to tracking with optional email notifications
Base URL
https://lunar.pauz.digital/api
Authentication
All API requests require authentication using an API key in the Authorization header.
API Key Format
API keys are UUID format tokens (e.g., 550e8400-e29b-41d4-a716-446655440000).
Authorization: Bearer your-api-key-uuid
Example Request
curl -X GET \-H "Authorization: Bearer your-api-key-uuid" \"https://lunar.pauz.digital/api/tracking"
Container Tracking
Add containers to continuous tracking. The system syncs every 15 minutes and can notify you via email when status changes occur.
Email Notifications
Get notified via email when your container status changes or when the Last Free Day is approaching.
Notification Types
Adding Notification Emails
You can add up to 5 email addresses when creating tracking or update them later:
// When creating tracking{"terminalCode": "MAH","containerNumber": "BEAU5371613","notifyEmails": ["dispatch@company.com", "logistics@company.com"]}// Update emails laterPATCH /tracking/:trackingId/notify{"notifyEmails": ["new@company.com"]}
Auto-Stop Notifications
Notifications automatically stop when the container is gated out, picked up, or delivered. The system detects this from the transitState field.
Terminal Codes
The API supports 150+ terminal codes across ports and rail yards in North America.
Port Terminals (90+)
Major container ports across North America.
MAH, PNCT, LALB-LBCT, POV-NIT, GPA-GCT...Rail Terminals (60+)
Intermodal rail yards across the country.
NS-ATLANTA, NS-CHICAGO_47TH, CSX-CHARLOTTE...Get Terminal List
GET https://lunar.pauz.digital/api/terminalsResponse:{"success": true,"count": 156,"terminals": [{"code": "MAH","name": "Maher Terminal","location": "New Jersey","port": "NY/NJ"},...]}
Error Handling
The API returns standard HTTP status codes and JSON error responses.
Error Response Format
{"success": false,"error": {"code": "TRACKING_LIMIT_EXCEEDED","message": "You have reached your tracking limit. Current: 20, Limit: 20","current": 20,"limit": 20,"upgradeUrl": "/api/auth/plans","timestamp": "2026-01-16T10:30:00Z"}}
Common Error Codes
| Code | HTTP | Description |
|---|---|---|
| INVALID_API_KEY | 401 | API key is invalid or expired |
| AUTHENTICATION_REQUIRED | 401 | No API key provided |
| TRACKING_LIMIT_EXCEEDED | 429 | Maximum tracked containers reached |
| INVALID_TERMINAL_CODE | 400 | Terminal code not found |
| INVALID_CONTAINER_FORMAT | 400 | Container doesn't match ISO 6346 format |
| INVALID_EMAIL | 400 | Invalid email format in notifyEmails |
| TOO_MANY_EMAILS | 400 | Maximum 5 notification emails allowed |
| TRACKING_NOT_FOUND | 404 | Tracking ID not found or not owned by user |
