REST API v1
Integrate your POS, ERP, or custom software with Logbooks for Guns. Full CRUD for firearms records with ATF-compliant audit trails.
Getting Started
API access is included with Dealer, Manufacturer, and Importer accounts at no extra cost.
| Base URL | https://www.logbooksforguns.com/rest/v1 |
| Format | JSON |
| Rate Limit | 60 requests/minute per token |
| Auth | Bearer token |
Authentication
Generate API keys at Dashboard > API Keys. Each key has granular permissions:
| Permission | Allows |
|---|---|
read | GET requests (list, view, search, inventory) |
write | POST/PUT requests (create, update, dispose) |
delete | DELETE requests |
Include your token in the Authorization header:
curl -H "Authorization: Bearer YOUR_API_KEY" \
https://www.logbooksforguns.com/rest/v1/books
Endpoints
GET /rest/v1/receipts
List receipts (paginated). Filter by book, status, serial number, manufacturer, or date.
| Param | Type | Description |
|---|---|---|
book | string | Filter by book name |
status | string | on_hand or disposed |
serial_number | string | Partial match |
manufacturer | string | Partial match |
since | datetime | Records updated after this date |
per_page | int | Results per page (max 200) |
GET /rest/v1/receipts/{id}
Get a single receipt with disposition, documents, and E4473 data.
POST /rest/v1/receipts
Create a new receipt (acquisition). Requires write permission.
{
"book": "Handguns",
"serial_number": "ABC123456",
"manufacturer": "Smith & Wesson",
"importer": "",
"model": "M&P 9",
"type": "Pistol",
"caliber": "9mm",
"receipt_date": "2026-03-22",
"purchase_amount": 499.99,
"received_from": "Johns Gun Store",
"ffl_license": "5-29-902-90-0J-09909",
"address": "559 S Park Place",
"city": "Phoenix",
"state": "AZ",
"zip": "85268"
}
importer and country_of_origin are required per 27 CFR 478.122.PUT /rest/v1/receipts/{id}
Update a receipt. All fields optional. Creates ATF audit trail.
POST /rest/v1/receipts/{id}/dispose
Record a disposition (sale/transfer). Requires write permission.
{
"disposition_date": "2026-03-22",
"disposed_to": "John Doe",
"address": "549 S Trail Ave",
"city": "Phoenix",
"state": "AZ",
"zip": "85255",
"sold_price": 550.00,
"nics_ccw": "4209242",
"form_4473_serial": "23909119"
}
GET /rest/v1/books
List all logbooks for the authenticated user.
GET /rest/v1/inventory
Current on-hand firearms. Optional book filter.
GET /rest/v1/search
Search receipts. Params: q (search term), field (serial_number, manufacturer, model, type, caliber, received_from, book).
Webhooks
Receive real-time notifications when records change. Full webhook documentation →
| Event | Fires When |
|---|---|
receipt.created | New firearm acquired |
receipt.updated | Record edited |
receipt.disposed | Disposition recorded |
receipt.deleted | Record soft-deleted |
Error Codes
| Code | Meaning |
|---|---|
200 | Success |
201 | Created |
401 | Invalid or missing API token |
403 | Insufficient permissions or ineligible account type |
404 | Record not found |
422 | Validation error (check response body for details) |
429 | Rate limit exceeded (60 req/min) |
Sandbox Testing
Building an integration? We provide free sandbox API tokens for development and testing. Sandbox tokens work identically to production but operate on isolated test data.
Integration Support
Need help integrating? We provide free technical support for POS vendors building integrations.
- Email: api@logbooksforguns.com
- Become a Partner
- Webhook Documentation