Expand Value Maps in history.get

XMLWordPrintable

    • Type: New Feature Request
    • Resolution: Unresolved
    • Priority: Trivial
    • None
    • Affects Version/s: 3.0.0alpha2
    • Component/s: API (A)

      ZBXNEXT-1424 implements the possibility to read, create and adjust valuemaps via the API.

      It would be logical to now have history.get output value mapped information as well.

      My suggestion is the following solution:

      We should be able to set a flag on the history.get call, expandValueMap feels logical to me.

      {
          "jsonrpc": "2.0",
          "method": "history.get",
          "params": {
              "output": "extend",
              "history": 3,
              "itemids": "23296",
              "sortfield": "clock",
              "sortorder": "DESC",
              "limit": 1,
              "expandValueMap": 1
          },
          "auth": "038e1d7b1735c6a5436ee9eae095879e",
          "id": 1
      }
      

      The output would look something like this then:

      {
          "jsonrpc": "2.0",
          "result": [
              {
                  "itemid": "23296",
                  "clock": "1351090456",
                  "value": "5",
                  "mappedvalue": "Some string representing this value",
                  "ns": "435307141"
              }
          ],
          "id": 1
      }
      

            Assignee:
            Unassigned
            Reporter:
            Raymond Kuiper
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: