Skip to main content

Inventory Parameter

The Inventory Parameter API provides access to configuration parameters used throughout the inventory system. These endpoints allow you to retrieve and manage parameter definitions,definitions theirthat alloweddescribe values,the configurable and group-basedmonitorable filteringattributes of devices in your inventory. These endpoints are essential for organizingunderstanding configurationwhat optionsparameters are available for device configuration, monitoring, and data collection across your inventorymanaged management workflows.infrastructure.

Base URL: https://control.zequenze.com/api/v1

Authentication: All endpoints require a Bearer token:

Authorization: Bearer <your-api-token>

Overview

The Inventory Parameter endpointsAPI manageprovides access to parameter definitions that serve as templates for device configuration parameters that define how inventory items are categorized, configured, and managed within the system.monitoring. These parameters serve asdefine the foundationstructure and behavior of data fields that can be applied to devices in your inventory system.

Each inventory parameter includes essential metadata such as:

    Parameter identification (name, variable name, short name) Data type specification (string, integer, boolean, select, etc.) Behavioral flags (required, read-only, metric tracking) Group association for inventorylogical itemorganization attributes, validationPosition rules,ordering andfor organizationalconsistent structures.UI presentation

    Key Concepts:

    • ParametersParameter Types: -Determine Configurationhow settingsdata thatis definedisplayed inventoryand item propertiesvalidated (e.g.,string, deviceinteger, types,boolean, statusselect, options, location categories)etc.)
    • GroupsMetric Parameters: -When Logicalenabled, collectionsthe ofsystem relatedstores parametershistorical data for bettertrend organizationanalysis
    and filteringRead-only Parameters: Used for storing data captured from devices, not for configuration Parameter ValuesGroups: -Logical Thecollections allowedthat valuesorganize orrelated constraintsparameters fortogether each parameterDiscovery Groups: Special groups containing parameters automatically discovered by the system

    Common UseIntegration Cases:Scenarios:

    • Retrieving available device types when creating new inventory items
    Getting status options for inventory item workflows Building dynamic configuration forms withbased parameter-drivenon fieldavailable optionsparameters Validating inventory data against definedRetrieving parameter constraintsdefinitions before creating device configurations OrganizingUnderstanding which parameters support historical tracking for monitoring dashboards Filtering parameters by functionalgroup groupsto (hardware,organize software,configuration location, etc.)workflows

    How These Endpoints Work Together: Use the list endpoint to browse all available parameters with optional group filtering, then use the detail endpoint to get comprehensive information about specific parameters including their validation rules and allowed values.


    Endpoints

    GET /inventory_parameter/

    Description: Retrieves a paginated list of all inventory parameters with optional filtering by parameter group.definitions. This endpoint is essentialtypically forused discoveringto build dynamic configuration interfaces, understand available configurationparameter optionstypes, andor buildingsync dynamicparameter inventorydefinitions managementwith interfaces.external systems.

    Use Cases:

    • LoadingBuilding dynamic device configuration forms in a web application
    Synchronizing parameter optionsdefinitions forwith inventoryexternal itemconfiguration creationmanagement formssystems DiscoveringAuditing available parameters across different device types, status options, or location categoriesgroups BuildingCreating administrativeparameter selection interfaces for parameterreporting management Filtering parameters by functional groups (e.g., only hardware-related parameters)tools

    Full URL Example:

    https://control.zequenze.com/api/v1/inventory_parameter/?group=15&limit=2050&offset=0
    

    Parameters:

    Parameter Type In Required Description
    group integer query No Filter parameters by group ID to getretrieve only parameters belonging to a specific functionalparameter group
    limit integer query No Number of results to return per page (default:default 20,pagination max:applies 100)if not specified)
    offset integer query No The initial index from which to return results for pagination

    cURL Example:

    curl -X GET "https://control.zequenze.com/api/v1/inventory_parameter/?group=15&limit=10"20&offset=0" \
      -H "Authorization: Bearer YOUR_API_TOKEN" \
      -H "Content-Type: application/json"
    

    Example Response:

    {
      "count": 45,
      "next": "https://control.zequenze.com/api/v1/inventory_parameter/?group=15&limit=1020&offset=10"20",
      "previous": null,
      "results": [
        {
          "id": 1,12,
          "name": "device_type"Device Hostname",
          "display_name"short_name": "Device Type"hostname",
          "description"variable_name": "Categorizesdevice_hostname",
          inventory"type": items"string",
          by"position": device1,
          type","required": true,
          "read_only": false,
          "metric": false,
          "group": {
            "id": 1,5,
            "name": "hardware"Network Configuration",
            "display_name"service": "Hardware Parameters"
          }network-mgmt",
            "data_type"discovery_group": false,
            "title": "choice",Network "required":Settings"
          true,
          "allowed_values": ["laptop", "desktop", "server", "network_device", "mobile"],
          "default_value": null,
          "created_at": "2024-01-15T10:30:00Z",
          "updated_at": "2024-01-20T14:45:00Z"}
        },
        {
          "id": 2,13,
          "name": "device_status"DHCP Enabled",
          "display_name"short_name": "Device Status"dhcp-enabled",
          "description"variable_name": "Currentdhcp_enabled",
          operational"type": status"boolean",
          of"position": the2,
          device","required": false,
          "read_only": false,
          "metric": true,
          "group": {
            "id": 1,5,
            "name": "hardware"Network Configuration",
            "display_name"service": "Hardwarenetwork-mgmt",
            Parameters""discovery_group": false,
            "title": "Network Settings"
          }
        },
        {
          "data_type"id": 14,
          "name": "choice"CPU Usage",
          "short_name": "cpu-usage",
          "variable_name": "cpu_usage_percent",
          "type": "decimal",
          "position": 3,
          "required": false,
          "read_only": true,
          "allowed_values"metric": [true,
          "active"group": {
            "id": 5,
            "name": "Network Configuration",
            "inactive"service": "network-mgmt",
            "maintenance",discovery_group": false,
            "retired", "pending"],
          "default_value"title": "pending",Network "created_at":Settings"
          "2024-01-15T10:31:00Z",
          "updated_at": "2024-01-18T09:20:00Z"}
        }
      ]
    }
    

    Response Codes:

    Status Description
    200 Success - Returns paginated list of inventory parameters
    401
    Unauthorized - Invalid or missing API token 400 Bad Request - Invalid query parameters (e.g., invalidgroup401 ID)Unauthorized - Invalid or missing authentication token 403 Forbidden - Insufficient permissions to access inventory parameters

    GET /inventory_parameter/{id}/

    Description: Retrieves detailed information about a specific inventory parameter by its ID. This endpoint provides comprehensivecomplete parameter detailsdefinition including validationall rules,metadata, allowedtype values,information, and usagegroup constraints.associations needed for implementation.

    Use Cases:

    • GettingRetrieving completedetailed parameter definitionspecifications before usingcreating itdevice in inventory operationsconfigurations
    • Validating parameter configurationconstraints and allowedtypes valuesduring form validation
    • BuildingUnderstanding parameter relationships and group associations
    Implementing parameter-specific validationUI logiccomponents inbased clienton applicationstype Retrievingand parameter metadata for administrative interfacesflags

    Full URL Example:

    https://control.zequenze.com/api/v1/inventory_parameter/1/12/?group=15
    

    Parameters:

    Parameter Type In Required Description
    id integer path Yes UniqueThe unique identifier of the inventory parameter to retrieve
    group integer query No Filter parameters by group nameID field- (additionaluseful contextfor filtering)validation when working within specific parameter groups

    cURL Example:

    curl -X GET "https://control.zequenze.com/api/v1/inventory_parameter/1/12/" \
      -H "Authorization: Bearer YOUR_API_TOKEN" \
      -H "Content-Type: application/json"
    

    Example Response:

    {
      "id": 1,12,
      "name": "device_type"Device Hostname",
      "display_name"short_name": "Device Type"hostname",
      "description"variable_name": "Categorizesdevice_hostname",
      inventory"type": items"string",
      by"position": device1,
      type"required": fortrue,
      proper"read_only": managementfalse,
      and"metric": reporting",false,
      "group": {
        "id": 1,5,
        "name": "hardware"Network Configuration",
        "display_name"service": "Hardware Parameters"network-mgmt",
        "description"discovery_group": false,
        "title": "ParametersNetwork related to physical hardware configuration"Settings"
      },
      "data_type": "choice",
      "required": true,
      "allowed_values": [
        "laptop",
        "desktop", 
        "server",
        "network_device",
        "mobile",
        "tablet",
        "printer",
        "monitor"
      ],
      "default_value": null,
      "validation_rules": {
        "min_length": null,
        "max_length": null,
        "pattern": null,
        "custom_validation": "device_type_validator"
      },
      "usage_count": 1247,
      "is_active": true,
      "created_by": {
        "id": 5,
        "username": "admin",
        "email": "admin@company.com"
      },
      "created_at": "2024-01-15T10:30:00Z",
      "updated_at": "2024-01-20T14:45:00Z",
      "last_used": "2024-01-22T16:20:00Z"
    }
    

    Response Codes:

    Status Description
    200 Success - Returns detailedthe requested inventory parameter informationdetails
    401 Unauthorized - Invalid or missing APIauthentication token
    403 Forbidden - Insufficient permissions to access this parameter 404 Not Found - Parameter with specified ID does not exist 400 Bad Request - Invalid parameter ID format

    Common Use Cases

    Use Case 1: Building Dynamic InventoryConfiguration Forms

    Retrieve all parameters for a specific group to populatedynamically formgenerate fieldsdevice whenconfiguration creatingforms newwith inventoryproper items,field ensuringtypes, usersvalidation canrules, onlyand selectrequired validfield parameter values.indicators.

    # Get all hardware parameters for devicenetwork creationconfiguration formgroup
    curl -X GET "https://control.zequenze.com/api/v1/inventory_parameter/?group=1&limit=505" \
      -H "Authorization: Bearer YOUR_API_TOKEN"
    

    Use Case 2: Parameter Validation Before Device Updates

    Before submittingupdating inventorydevice data,configurations, fetchretrieve specific parameter details to validate userdata inputtypes, againstrequired allowed valuesfields, and requirements.read-only restrictions.

    # Validate deviceparameter typeconstraints parameterbefore configuration update
    curl -X GET "https://control.zequenze.com/api/v1/inventory_parameter/1/12/" \
      -H "Authorization: Bearer YOUR_API_TOKEN"
    

    Use Case 3: AdministrativeMonitoring ParameterDashboard ManagementSetup

    List allIdentify parameters withmarked paginationas metrics to build administrativemonitoring interfacesdashboards forand managinghistorical inventorytrend configurationanalysis options.interfaces.

    # GetFilter paginatedand listidentify of allmetric parameters for admindashboard panelcreation
    curl -X GET "https://control.zequenze.com/api/v1/inventory_parameter/?limit=25&offset=0100" \
      -H "Authorization: Bearer YOUR_API_TOKEN"
    

    Use Case 4: Group-BasedConfiguration Template Creation

    Retrieve parameter definitions to create reusable configuration templates that can be applied across multiple devices of the same type.

    Use Case 5: Discovery Parameter DiscoveryManagement

    FilterIdentify parameters byin specificdiscovery groups that contain automatically detected device information, which can be promoted to load only relevantregular configuration options for different inventory workflows.groups.

    # Get only software-related parameters
    GET https://control.zequenze.com/api/v1/inventory_parameter/?group=2
    

    Best Practices

    • Use Group Filtering: FilterWhen building configuration interfaces, filter parameters by parameter groupsgroup to reduceorganize responserelated sizesettings and improve performanceuser whenexperience
    you Respect Parameter Types: Always validate input data according to the parameter's type field before submitting configuration changes Handle Read-Only Parameters: Parameters with read_only: true should be displayed for information only needand specificexcluded typesfrom ofconfiguration parametersforms Implement CachingMetric Tracking: Parameters with metric: true are suitable for historical data collection and trend monitoring Cache parameterParameter listsDefinitions: onParameter the client side since theydefinitions change infrequently, butmaking refreshthem whenexcellent inventorycandidates configurationfor isclient-side updatedcaching to improve performance ValidatePagination Before Submission: Always fetch current parameter details to validate data before submitting inventory items, as allowed values may change Handle PaginationStrategy: Use appropriate limit values (20-50 items)100) when listingretrieving parameterslarge parameter sets to balance performance and usability ErrorRequired HandlingField Validation: ImplementAlways retrycheck logicthe forrequired network failures and graceful fallbacksflag when parametersbuilding areforms temporarilyto unavailableensure proper validation before submission SecurityPosition-Based Ordering: NeverUse exposethe position field to maintain consistent parameter validationordering logicacross thatdifferent could reveal business rules; use these endpoints to get current constraints dynamicallyinterfaces