GunSpec

Calibers

Resource class for interacting with the GunSpec Calibers API. Wraps all /v1/calibers endpoints. Instantiated internally by the GunSpec client and exposed as client.calibers.

Authentifizierung erforderlichBuilder+

Compare up to 5 calibers side by side.

compare(params: CompareCalibersParams): Promise<APIResponse<Caliber[]>>
GET/v1/calibers/compare

  • stringHeadererforderlich

    Ihr API-Schlüssel. Authorization: Bearer <key> wird ebenfalls akzeptiert.

  • stringerforderlich

    Comma-separated caliber slugs, maximum 5

    Beispiel

  • object

    The response payload.

  • Caliber[]

    The compared cartridges, in the order their ids were given.

  • string

    URL-safe slug identifying the cartridge, e.g. 9x19mm-parabellum.

  • string

    Display name, as the maker writes it.

  • string | null

    JSON array of aliases

  • string | null

    NATO designation where the cartridge has one, e.g. 9mm NATO. Null otherwise.

  • number | null

    Bullet diameter in millimetres.

  • number | null

    Case neck outside diameter in millimetres.

  • number | null

    Bottleneck cases only.

  • number | null

    Case base diameter in millimetres, ahead of the extractor groove.

  • number | null

    Rim diameter in millimetres.

  • number | null

    Rim thickness in millimetres.

  • number | null

    Case length in millimetres.

  • number | null

    Overall length in millimetres, stock extended where it folds or collapses.

  • object[]

    Per-field differences across the compared cartridges, one entry per numeric field.

  • string

    Which column the row is about, named as the database names it.

  • number | null[]

    This field on each compared cartridge, in the order the ids were given. Null where that record does not carry the field.

  • number | null

    Lowest value across the compared cartridges. Null when fewer than two carry the field.

  • number | null

    Highest value across the compared cartridges. Null when fewer than two carry the field.

  • number | null

    Spread from the lowest value, as a percentage of it. Null when the minimum is zero or fewer than two carry the field.

  • 400VALIDATION_ERRORValidation error
  • 401UNAUTHORIZEDAPI key required
  • 403FORBIDDENValid key, not permitted
  • 429RATE_LIMITEDRate limit exceeded
  • 500INTERNAL_ERRORUnexpected server error

Mindeststufe
Builder+
Monatskontingent
25,000/mo
Anfragerate
60/min
Tageslimit
2,000

Die Werte gelten für die Mindeststufe dieses Endpunkts. Höhere Stufen erhöhen alle Limits.

Dieser Aufruf beantwortet bedingte Anfragen. Speichern Sie das ETag einer Antwort und senden Sie es als If-None-Match zurueck: ein unveraenderter Datensatz liefert 304 Not Modified ohne Body. Das zaehlt auf Ihr Minutenlimit, aber nicht auf Ihr Tageskontingent.