Categories
List firearms in a category
Returns the firearms belonging to a category.
Available on every plan. Requires an API key; Explorer keys receive a reduced field set.
get/v1/categories/{slug}/firearms
Request
- Base URL: https://api.gunspec.io
- URL: https://api.gunspec.io/v1/categories/{slug}/firearms
- Auth: one of:
- API key in header X-API-Key
- HTTP bearer
Path parameters
slugstring required
Category slug
Query parameters
pageinteger
Page number, from 1 to 10,000
per_pageinteger
Items per page (max 100)
Response
List firearms in a category
Example response
{
"success": true,
"data": [
{
"id": "glock-g17-gen5",
"name": "Glock 17 Gen5",
"manufacturerId": "glock",
"yearIntroduced": 2017,
"actionType": "short_recoil",
"countryOfOrigin": "AT",
"images": [
{
"id": 2572,
"url": "https://api.gunspec.io/v1/firearms/ak-47/images/2572",
"alt": "AK-47 right profile",
"width": 1536,
"height": 1024
}
]
}
],
"pagination": {
"page": 1,
"per_page": 20,
"limit": 20,
"total": 42,
"totalPages": 3
}
}Changes
No recorded changes to this operation across all 1 revision of this API.