Ad Widget

Collapse

Using value of item in http_agent header in another item

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • elkropac
    Junior Member
    • Jun 2022
    • 24

    #1

    Using value of item in http_agent header in another item

    Hi,
    is it possible to use one item value in http header of another http_agent item?
    I'm trying to monitor dell me5024 array.
    I need to use basic auth on url /api/login . It returns json with session key.
    I can use session key to gather more data.

    I created on item (http_agent) which grabs /api/login and then dependant item which uses jsonpath preprocessing to save the session key.
    Then i created another http_agent item to grab the info. but i need to somehow pass the session key.
    Is it possible?

    Thanks
    Libor

  • Hamardaban
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • May 2019
    • 2713

    #2
    Make a dependent item and in its preprocessing use JS in which you process the value of the master item.
    But in your case, you can do everything in one data element of the script type

    Comment

    • elkropac
      Junior Member
      • Jun 2022
      • 24

      #3
      Hi, thanks for the link. It seems i will be able to use it.
      I logged in and then pulled array information in json format and was able to create dependant item from it

      Comment

      Working...