/systems/{id}/inventory/{inventory_id} - Get a specific inventory record

GET /systems/{id}/inventory/{inventory_id}

Get a specific inventory record by its ID, scoped to the system.

Path parameters

  • id string Required

    System ID

  • inventory_id integer(int64) Required

    Inventory record ID

Responses

  • 200 application/json

    Inventory record retrieved successfully

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object

      A snapshot of a system's inventory data at a point in time

      Hide data attributes Show data attributes object
      • id integer(int64)

        Auto-incrementing record ID

      • system_id string

        ID of the system that sent the inventory

      • timestamp string(date-time)

        When the inventory was collected on the system

      • data object

        Complete raw inventory JSON. Contains the full system inventory payload (facts, modules, nodes, network, etc.). The structure varies by system type and can contain hundreds of fields.

      • data_hash string

        SHA-256 hash of the inventory data for deduplication

      • data_size integer(int64)

        Size of the inventory data in bytes

      • processed_at string(date-time) | null

        When diff processing completed for this record. Null if not yet processed.

      • has_changes boolean

        Whether changes were detected compared to the previous inventory

      • change_count integer

        Number of significant changes detected

      • created_at string(date-time)

        When the record was created in the database

      • updated_at string(date-time)

        When the record was last updated

  • 400 application/json

    Bad request - validation error

    Hide response attributes Show response attributes object
    • code integer

      HTTP error code

    • message string

      Error message

    • data object
      Hide data attributes Show data attributes object
      • type string

        Type of error

        Values are validation_error or external_api_error.

      • errors array[object]
        Hide errors attributes Show errors attributes object
        • key string

          Field name that failed validation

        • message string

          Error code or message

        • value string

          Value that failed validation

      • details

        Additional error details

  • 401 application/json

    Unauthorized - invalid or missing token

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
  • 403 application/json

    Forbidden - insufficient permissions

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
  • 404 application/json

    Resource not found

    Hide response attributes Show response attributes object
    • code integer

      HTTP error code

    • message string

      Error message

    • data object
      Hide data attributes Show data attributes object
      • type string

        Type of error

        Values are validation_error or external_api_error.

      • errors array[object]
        Hide errors attributes Show errors attributes object
        • key string

          Field name that failed validation

        • message string

          Error code or message

        • value string

          Value that failed validation

      • details

        Additional error details

GET /systems/{id}/inventory/{inventory_id}
curl \
 --request GET 'https://api.your-domain.com/api/systems/sys_123456789/inventory/42' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "code": 200,
  "message": "inventory record retrieved successfully",
  "data": {
    "id": 42,
    "system_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "timestamp": "2026-02-20T14:30:00Z",
    "data": {
      "facts": {
        "distro": {
          "name": "NethServer",
          "version": "8.2.0"
        },
        "memory": {
          "total_bytes": 17179869184
        },
        "network": {
          "hostname": "ns8.example.com",
          "public_ip": "203.0.113.10"
        }
      }
    },
    "data_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
    "data_size": 24576,
    "processed_at": "2026-02-20T14:31:00Z",
    "has_changes": true,
    "change_count": 5,
    "created_at": "2026-02-20T14:30:05Z",
    "updated_at": "2026-02-20T14:31:00Z"
  }
}
Response examples (400)
{
  "code": 400,
  "message": "validation failed",
  "data": {
    "type": "validation_error",
    "errors": [
      {
        "key": "username",
        "message": "required",
        "value": "string"
      }
    ]
  }
}
Response examples (401)
{
  "code": 401,
  "message": "invalid token",
  "data": {}
}
Response examples (403)
{
  "code": 403,
  "message": "insufficient permissions",
  "data": {}
}
Response examples (404)
{
  "code": 400,
  "message": "validation failed",
  "data": {
    "type": "validation_error",
    "errors": [
      {
        "key": "username",
        "message": "required",
        "value": "string"
      }
    ]
  }
}