gunspec-io · Schema
FamilyTree
The firearm plus its ancestor and descendant variants, walked recursively.
FirearmsDatabaseSpecificationSDKMCP
Properties
| Name | Type | Description |
|---|---|---|
| ancestors | array | The parent chain, nearest first, up to 20 deep. |
| current | object | |
| descendants | array | Everything derived from it, breadth-first, up to 50 rows. |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://artifacts.apis.io/gunspec-io/json-schema/gunspec-io-family-tree-schema.json",
"title": "FamilyTree",
"description": "The firearm plus its ancestor and descendant variants, walked recursively.",
"x-generated": "2026-11-10",
"x-method": "derived",
"x-generator": "derive-json-schema.py",
"x-source": "openapi/gunspec-io-firearm-analysis-api-openapi.yml#/components/schemas/FamilyTree",
"type": "object",
"properties": {
"ancestors": {
"type": "array",
"description": "The parent chain, nearest first, up to 20 deep.",
"items": {
"$ref": "#/$defs/FamilyMember"
}
},
"current": {
"$ref": "#/$defs/FirearmRecord"
},
"descendants": {
"type": "array",
"description": "Everything derived from it, breadth-first, up to 50 rows.",
"items": {
"$ref": "#/$defs/FamilyMember"
}
}
},
"required": [
"ancestors",
"current",
"descendants"
],
"$defs": {
"FamilyMember": {
"type": "object",
"description": "One firearm in a family walk. A named projection rather than the whole row: the walk is a recursive CTE, so its rows come back as raw columns, and returning them meant this endpoint answered snake_case for its relatives and camelCase for `current`, with `content_hash` and `console_edited_by` along for the ride.",
"properties": {
"id": {
"type": "string",
"description": "URL-safe slug identifying the related firearm, e.g. `type-58`."
},
"name": {
"type": "string",
"description": "Display name, as the maker writes it."
},
"manufacturerId": {
"type": [
"string",
"null"
],
"description": "Slug of the manufacturer that makes it. Resolve against `/v1/manufacturers/{id}`."
},
"categoryId": {
"type": [
"string",
"null"
],
"description": "Slug of the category it belongs to. Resolve against `/v1/categories`."
},
"parentFirearmId": {
"type": [
"string",
"null"
],
"description": "The firearm this one is a variant of, or null when it is not a variant. Variant relationships are what `firearm.variant.updated` webhooks and `/v1/firearms/{id}/variants` follow."
},
"variantType": {
"type": [
"string",
"null"
],
"description": "How this record differs from its parent: `optics_ready`, `compact`, `threaded` and so on. Null when the record has no parent."
},
"yearIntroduced": {
"type": [
"integer",
"null"
],
"description": "Year it entered production or service. Null where the date is disputed or unknown."
},
"status": {
"anyOf": [
{
"$ref": "#/$defs/FirearmStatus"
},
{
"type": "null"
}
],
"description": "Production status, one of `in_production`, `discontinued`, `out_of_production`, `in_service`, `limited_production`, `prototype`. Discontinued records are kept deliberately: a rifle built in 2004 wears parts nobody sells today."
},
"countryOfOrigin": {
"type": [
"string",
"null"
],
"description": "ISO 3166-1 alpha-2 code of where it was designed, e.g. `AT`."
},
"svgLineArtUrl": {
"type": [
"string",
"null"
],
"description": "Line-art silhouette, or null where none has been drawn."
},
"updatedAt": {
"type": "string",
"description": "When a field we serve last changed. Maintained by the database rather than by whatever wrote the row, so it moves for a corrected specification and does not move for a re-run of the importer."
},
"version": {
"type": [
"string",
"null"
],
"description": "Opaque fingerprint of this record. It changes when and only when a field we serve changes, so a client holding the same value already has the record and need not fetch it. Equality is the only supported operation: do not parse it, and do not assume how it is computed. Null means the record has not been written since versioning began, not that it is unchanged."
}
},
"required": [
"id",
"name"
]
},
"FirearmRecord": {
"type": "object",
"description": "A firearm as stored: every specification column we serve, with no nested relations. `FirearmDetail` is this plus them, and `/v1/firearms/{id}/family-tree` returns this shape for `current`, since the walk reads the row and does not load the relations.",
"properties": {
"has3dModel": {
"type": "integer",
"description": "Integer flag, `1` when a 3D model is on file. Stored as the database holds it rather than as a boolean."
},
"svgLineArtUrl": {
"type": [
"string",
"null"
],
"description": "Line-art silhouette, or null where none has been drawn."
},
"model3dUrl": {
"type": [
"string",
"null"
],
"description": "GLB model, or null where none is on file."
},
"defaultAmmoId": {
"type": [
"string",
"null"
],
"description": "The ammunition load ballistics figures are quoted against, where one is nominated."
},
"sourceMuzzleVelocityMps": {
"type": [
"number",
"null"
],
"description": "Muzzle velocity in metres per second **exactly as the source stated it**, kept beside our own figure so a reader can see what was quoted and what was derived."
},
"sourceMuzzleEnergyJ": {
"type": [
"number",
"null"
],
"description": "Muzzle energy in joules exactly as the source stated it."
},
"sourceEffectiveRangeM": {
"type": [
"number",
"null"
],
"description": "Effective range in metres exactly as the source stated it."
},
"sourceMaxRangeM": {
"type": [
"number",
"null"
],
"description": "Maximum range in metres exactly as the source stated it."
},
"ballisticsSource": {
"type": [
"string",
"null"
],
"description": "Where the ballistics figures came from, named in prose."
},
"ballisticsSourceUrl": {
"type": [
"string",
"null"
],
"description": "URL of the ballistics source, where it is a page rather than a book."
},
"id": {
"type": "string",
"description": "URL-safe slug identifying the firearm, e.g. `glock-g17-gen5`. Stable: it is what a mirror keys on."
},
"name": {
"type": "string",
"description": "Display name, as the maker writes it."
},
"manufacturerId": {
"type": "string",
"description": "Slug of the manufacturer that makes it. Resolve against `/v1/manufacturers/{id}`."
},
"categoryId": {
"type": "string",
"description": "Slug of the category it belongs to. Resolve against `/v1/categories`."
},
"parentFirearmId": {
"type": [
"string",
"null"
],
"description": "The firearm this one is a variant of, or null when it is not a variant. Variant relationships are what `firearm.variant.updated` webhooks and `/v1/firearms/{id}/variants` follow."
},
"variantType": {
"type": [
"string",
"null"
],
"description": "How this record differs from its parent: `optics_ready`, `compact`, `threaded` and so on. Null when the record has no parent."
},
"yearIntroduced": {
"type": [
"integer",
"null"
],
"description": "Year it entered production or service. Null where the date is disputed or unknown."
},
"yearDiscontinued": {
"type": [
"integer",
"null"
],
"description": "Year production ended, or null while it is still made."
},
"status": {
"anyOf": [
{
"$ref": "#/$defs/FirearmStatus"
},
{
"type": "null"
}
],
"description": "Production status, one of `in_production`, `discontinued`, `out_of_production`, `in_service`, `limited_production`, `prototype`. Discontinued records are kept deliberately: a rifle built in 2004 wears parts nobody sells today."
},
"countryOfOrigin": {
"type": [
"string",
"null"
],
"description": "ISO 3166-1 alpha-2 code of where it was designed, e.g. `AT`."
},
"weightEmptyG": {
"type": [
"number",
"null"
],
"description": "Unloaded weight in grams, without magazine."
},
"weightLoadedG": {
"type": [
"number",
"null"
],
"description": "Loaded weight in grams, with a full magazine."
},
"overallLengthMm": {
"type": [
"number",
"null"
],
"description": "Overall length in millimetres, stock extended where it folds or collapses."
},
"barrelLengthMm": {
"type": [
"number",
"null"
],
"description": "Barrel length in millimetres, measured from the breech face."
},
"heightMm": {
"type": [
"number",
"null"
],
"description": "Height in millimetres, including sights and a fitted magazine."
},
"widthMm": {
"type": [
"number",
"null"
],
"description": "Width in millimetres at the widest point."
},
"sightRadiusMm": {
"type": [
"number",
"null"
],
"description": "Distance between front and rear iron sights in millimetres. Null on a record with no iron sights."
},
"actionType": {
"type": [
"string",
"null"
],
"x-gunspec-vocabulary": [
"short_recoil",
"bolt_action",
"blowback",
"break_action",
"gas_operated",
"gas_operated_long_stroke",
"gas_operated_direct_impingement",
"revolving",
"gas_operated_short_stroke",
"muzzleloader",
"pump_action",
"lever_action",
"double_action",
"falling_block",
"roller_delayed_blowback",
"single_action",
"gas_operated_short_stroke_piston",
"single_action_revolver",
"double_action_revolver",
"inertia_operated",
"recoil_operated",
"delayed_blowback",
"long_recoil",
"gas_operated_rotating_bolt",
"breech_loading",
"rolling_block",
"straight_pull",
"trapdoor",
"spring_piston",
"hinged_breechblock",
"lever_delayed_blowback",
"blow_forward",
"electric_gatling",
"double_action_only",
"rotating_barrel",
"pneumatic",
"gas_operated_dual_mode",
"delayed_blowback_rotating_barrel",
"gas_delayed_blowback",
"radial_delayed_blowback",
"short_recoil_rotating_barrel",
"gas_operated_balanced_automatics",
"gas_operated_balanced_recoil",
"gas_operated_blow_forward",
"gas_operated_open_bolt",
"gas_operated_tilting_bolt"
],
"description": "How the action cycles: `short_recoil`, `gas_operated`, `blowback`, `bolt_action` and so on. An open vocabulary: the values in use are published on the schema as `x-gunspec-vocabulary`, and `GET /v1/firearms/action-types` is the live list."
},
"firingMechanism": {
"type": [
"string",
"null"
],
"description": "What releases the striker or hammer: `striker_fired`, `hammer_fired`."
},
"triggerType": {
"type": [
"string",
"null"
],
"description": "Trigger arrangement: `single_action`, `double_action`, `safe_action`."
},
"triggerPullN": {
"type": [
"number",
"null"
],
"description": "Trigger pull weight in newtons. Divide by 4.448 for pounds-force."
},
"magazineCapacity": {
"type": [
"integer",
"null"
],
"description": "Rounds in the standard magazine. Null where the firearm is not magazine-fed."
},
"magazineType": {
"type": [
"string",
"null"
],
"description": "Magazine pattern: `detachable_box`, `internal`, `drum`, `belt`."
},
"muzzleVelocityMps": {
"type": [
"number",
"null"
],
"description": "Muzzle velocity in metres per second, for the default load."
},
"muzzleEnergyJ": {
"type": [
"number",
"null"
],
"description": "Muzzle energy in joules, for the default load."
},
"effectiveRangeM": {
"type": [
"number",
"null"
],
"description": "Effective range in metres against a point target."
},
"maxRangeM": {
"type": [
"number",
"null"
],
"description": "Maximum range in metres. Where the projectile lands, not where it is useful."
},
"rateOfFireRpm": {
"type": [
"integer",
"null"
],
"description": "Cyclic rate in rounds per minute. Null on anything that is not automatic."
},
"barrelRifling": {
"type": [
"string",
"null"
],
"description": "Rifling description, e.g. `6 grooves, right-hand twist`."
},
"riflingTwistMm": {
"type": [
"number",
"null"
],
"description": "Rifling twist rate in millimetres per turn. Divide by 25.4 for inches."
},
"numberOfGrooves": {
"type": [
"integer",
"null"
],
"description": "Number of grooves cut in the bore."
},
"frameMaterial": {
"type": [
"string",
"null"
],
"description": "What the frame or receiver is made of."
},
"slideMaterial": {
"type": [
"string",
"null"
],
"description": "What the slide is made of. Null on anything without one."
},
"barrelMaterial": {
"type": [
"string",
"null"
],
"description": "What the barrel is made of."
},
"stockMaterial": {
"type": [
"string",
"null"
],
"description": "What the stock or furniture is made of."
},
"finish": {
"type": [
"string",
"null"
],
"description": "Surface finish, e.g. `nitride`, `parkerized`, `cerakote`."
},
"safetyMechanisms": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "Safety mechanisms the design carries."
},
"features": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "Notable features of the design."
},
"feedSystems": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "How the firearm is fed."
},
"gameDamage": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. **Not a measured figure.** These are balance numbers for game use and are not derived from the ballistics above."
},
"gameAccuracy": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameRange": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameFireRate": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameMobility": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameRecoilControl": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameReloadSpeed": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"gameConcealment": {
"type": [
"integer",
"null"
],
"description": "Editorial game statistic, 0-100. Not a measured figure."
},
"description": {
"type": [
"string",
"null"
],
"description": "Prose summary of the record, where one has been written."
},
"notes": {
"type": [
"string",
"null"
],
"description": "Free-text notes that do not belong in a specific field."
},
"designer": {
"type": [
"string",
"null"
],
"description": "Person or team credited with the design, where it is known."
},
"foldedLengthMm": {
"type": [
"number",
"null"
],
"description": "Length with stock folded (mm)"
},
"alternateNames": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "Other names and designations the same firearm is known by."
},
"firingModes": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "Firing modes the selector offers."
},
"conflicts": {
"type": [
"array",
"null"
],
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "The conflict."
},
"years": {
"type": "string",
"description": "When it ran, as written."
},
"sides": {
"type": "array",
"items": {
"type": "string"
},
"description": "The belligerents."
}
}
},
"description": "Conflicts the firearm saw service in."
},
"productionNumbers": {
"type": [
"object",
"null"
],
"properties": {
"estimated_total": {
"type": [
"integer",
"null"
],
"description": "Units believed produced."
},
"production_years": {
"type": [
"string",
"null"
],
"description": "The production run, as written."
},
"notes": {
"type": [
"string",
"null"
],
"description": "What the estimate covers."
}
},
"description": "How many were made, and over what period."
},
"lore": {
"type": [
"string",
"null"
],
"description": "Historical trivia / game-dev flavor text"
},
"sources": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "Source URLs the record was compiled from. Check a specific figure against these rather than against `dataConfidence`. The same list is in `provenance.sources`."
},
"verifiedAt": {
"type": [
"string",
"null"
],
"description": "When a source was last read against the record's figures. Null until one has been. The same value is in `provenance.verifiedAt`."
},
"verifiedFields": {
"type": [
"array",
"null"
],
"items": {
"type": "string"
},
"description": "The figures a source confirmed: read off the manufacturer's own page, within the published tolerance, and accepted by a person. The same list is in `provenance.verifiedFields`."
},
"dataConfidence": {
"type": [
"number",
"null"
],
"description": "How completely the record is specified and how well it is sourced, 0 to 1. A record-level completeness and provenance measure, **not** a per-field probability of correctness. Use it to rank and triage; use `sources` to verify an individual number."
},
"createdAt": {
"type": "string",
"description": "When the record was first added, `YYYY-MM-DD HH:MM:SS` in UTC."
},
"updatedAt": {
"type": "string",
"description": "When a field we serve last changed. Maintained by the database rather than by whatever wrote the row, so it moves for a corrected specification and does not move for a re-run of the importer."
},
"version": {
"type": [
"string",
"null"
],
"description": "Opaque fingerprint of this record. It changes when and only when a field we serve changes, so a client holding the same value already has the record and need not fetch it. Equality is the only supported operation: do not parse it, and do not assume how it is computed. Null means the record has not been written since versioning began, not that it is unchanged."
},
"provenance": {
"$ref": "#/$defs/Provenance"
}
}
},
"FirearmStatus": {
"type": "string",
"enum": [
"in_production",
"discontinued",
"out_of_production",
"in_service",
"limited_production",
"prototype"
],
"description": "Production status of a firearm. Closed: these are every value the catalog holds."
},
"Provenance": {
"type": "object",
"description": "Where a record's figures came from and how far they have been checked, in one place. `sources` are the pages consulted; check a specific figure against those. `sourceKinds` says what each page is and `bestSourceKind` the strongest of them, on the hierarchy `SourceKind` defines: a maker or standards-body page is evidence for a figure, a retailer or forum page is evidence the item exists. `dataConfidence` is the 0 to 1 score set from what was actually sourced and never raised by hand. `verifiedAt` and `verifiedFields` say when a source was last read against the record and which fields it stated; null means the row is still seed knowledge. `updatedAt` and `version` are the same cache signals the record carries at the top level.",
"properties": {
"sources": {
"type": "array",
"items": {
"type": "string"
},
"description": "The pages consulted when the record was compiled, as an array. Check a specific figure against these rather than against `dataConfidence`."
},
"sourceKinds": {
"type": "array",
"items": {
"type": "object",
"properties": {
"url": {
"type": "string",
"description": "Absolute, directly fetchable URL."
},
"kind": {
"$ref": "#/$defs/SourceKind"
},
"archivedFrom": {
"type": [
"string",
"null"
],
"description": "The original address when `url` is a Wayback Machine capture of it. A cited page that no longer answers is replaced by its last capture that answered 200, so the citation still shows what its author read; `kind` is the original page's."
},
"rank": {
"type": "integer",
"description": "The kind's place in the source hierarchy: 0 is the maker, the strongest; higher is weaker."
},
"tier": {
"type": "string",
"enum": [
"authority",
"classified",
"unclassified"
],
"description": "Where the site stands in the source registry (`/v1/data/sources`): an authority (the maker, a standards body, a government), a classified site, or one not yet classed."
},
"basis": {
"type": "string",
"enum": [
"declared",
"maker",
"rule",
"unclassified"
],
"description": "What the class rests on: classed by a person, a catalogued maker's own site, a .gov or .mil domain, or nothing yet."
},
"evidence": {
"type": [
"string",
"null"
],
"description": "The words the site was classed on, where a person recorded them."
}
},
"required": [
"url",
"kind",
"archivedFrom",
"rank",
"tier",
"basis",
"evidence"
]
},
"description": "What each cited page is, in `sources` order, on the `SourceKind` hierarchy. A host not in the source map is `other`, never guessed."
},
"bestSourceKind": {
"anyOf": [
{
"$ref": "#/$defs/SourceKind"
},
{
"type": "null"
}
],
"description": "The strongest kind among the citations, or null when nothing is cited. `manufacturer` or `standards_body` means a figure can be checked against an authority; `retailer` or `community` alone means the record is still supported by copies of copies."
},
"makerSource": {
"type": [
"string",
"null"
],
"description": "The first cited page on the record's own manufacturer's website, or null when it cites none. A page on another maker's site does not count. Cited from the maker is not the same as checked against it: `verifiedFields` names the figures that were read against a source."
},
"evidence": {
"type": "string",
"enum": [
"verified",
"maker",
"authority",
"secondary",
"none"
],
"description": "How far the record's figures are backed, strongest first, for a badge: `verified` when at least one figure was read against a source (`verifiedFields`), `maker` when it cites a page on its own manufacturer's site (`makerSource`), `authority` when it cites a maker, standards body or government page, `secondary` when it cites only press, retailers, references or forums, `none` when it cites nothing. Derived from the fields beside it."
},
"checks": {
"type": "object",
"description": "The checks the record has been through, on a single record's response only: every task the data agent (Redback) or a person was given about it, what each proposed, the pages it read, and whether a person accepted it. Nothing an agent proposes reaches the record until a person accepts it, so this is the trail behind `verifiedFields`. Who reviewed is not published; an agent's instance name is.",
"properties": {
"raised": {
"type": "integer",
"description": "Every task ever raised on the record, answered or not."
},
"open": {
"type": "integer",
"description": "Tasks still waiting to be worked."
},
"history": {
"type": "array",
"description": "The latest twenty, newest first.",
"items": {
"type": "object",
"properties": {
"task": {
"type": "string",
"description": "The task id, stable across runs; the same id `/v1/data/tasks/{taskKey}` answers for."
},
"number": {
"type": [
"integer",
"null"
],
"description": "The task's number; `/v1/data/tasks/{number}` loads it as its key does."
},
"check": {
"type": [
"string",
"null"
],
"description": "The check that raised it, where one did."
},
"kind": {
"type": "string",
"description": "`verify` reads the record against its maker's page, `gap` researches an empty field, `contradiction` judges fields that disagree, `vocabulary` a value outside a list."
},
"agent": {
"type": [
"string",
"null"
],
"description": "`redback` when the agent worked it, `staff` when a person did, null when nobody has."
},
"worker": {
"type": [
"string",
"null"
],
"description": "The agent instance that worked it; null for a person."
},
"status": {
"type": "string",
"description": "`resolved` (a proposal was filed), `unverifiable` (nothing could be established; retried after a cooldown), `not_a_fault`, or open."
},
"decidedAt": {
"type": [
"string",
"null"
],
"description": "When the task was answered; null while it is open."
},
"proposed": {
"type": [
"string",
"null"
],
"description": "What it proposed, in its own words; null while it is o
# --- truncated at 32 KB (37 KB total) ---
# Full source: https://artifacts.apis.io/gunspec-io/json-schema/gunspec-io-family-tree-schema.json
Work with this as data
Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for schemas
4 MCP tools reach this
find_json_schemasBrowse and filter every JSON Schema in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/gunspec-io-family-tree"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.