[ZBXNEXT-4358] Metrics for easy RestAPI data retrieval (Z4rc1) Created: 2018 Jan 24  Updated: 2024 Apr 10  Resolved: 2018 Apr 24

Status: Closed
Project: ZABBIX FEATURE REQUESTS
Component/s: None
Affects Version/s: None
Fix Version/s: 4.0.0alpha6, 4.0 (plan)

Type: New Feature Request Priority: Trivial
Reporter: Rostislav Palivoda Assignee: Vladislavs Sokurenko
Resolution: Fixed Votes: 2
Labels: http, httpcheck
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: Not Specified Time Spent: Not Specified
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Issue Links:
Causes
causes ZBX-22231 Internal macro {HOST.*} is not workin... Closed
caused by ZBXNEXT-3190 Add new REST API simple check with JS... Closed
Duplicate
is duplicated by ZBXNEXT-4436 REST Plugin for network monitoring Closed
Sub-task
depends on ZBXNEXT-4492 Add all request type in web monitoring Open
part of ZBXNEXT-1816 Use Curl for the agent's web.page items Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
ZBXNEXT-4359 Frontend: Metrics for easy RestAPI da... Specification change (Sub-task) Closed Gregory Chalenko  
Team: Team A
Sprint: Sprint 26, Sprint 27, Sprint 28, Sprint 29, Sprint 30, Sprint 31, Sprint 36
Story Points: 7

 Description   

A new item type should be introduced to allow data retrieval using HTTP/HTTPS protocol:

  1. Both HTTP and HTTPS protocols must be supported
  2. URL must be configurable on item level
  3. HTTP headers must be configurable
  4. Both GET and POST optional payload must be fully configurable
  5. POST payload must support data in JSON format
  6. Zabbix macros
    (user macros, {HOST.IP}, {HOST.CONN}, {HOST.DNS}, {HOST.HOST}, {HOST.NAME}, {ITEM.ID}, {ITEM.KEY}, {ITEM.NAME})

    must be allowed in URL and JSON object values

  7. Existing Zabbix front-end and API methods must be enhanced to support new item type
  8. Accepted comma delimited response code ranges (by default, "200") must be supported. If response code differs, the item will be treated as unsupported
  9. Options to allow following redirects must be supported
  10. HTTP/HTTPS items must support configurable timeout with reasonable default value


 Comments   
Comment by Vladislavs Sokurenko [ 2018 Feb 19 ]

Implemented in development branch:
svn://svn.zabbix.com/branches/dev/ZBXNEXT-4358

Comment by Sergejs Paskevics [ 2018 Mar 06 ]

Successfully tested

Comment by Gregory Chalenko [ 2018 Apr 11 ]

Implemented in:

  • 4.0.0alpha6 (trunk) r79565
Comment by Alex Tomasello [ 2018 May 23 ]

I suggest to remove, from UI, Request body type and Request body if user selects GET or HEAD as Request type . What do you think about?

Comment by Vladislavs Sokurenko [ 2018 May 23 ]

Some services might require request body with GET request, this is not prohibited by HTTP and also allowed in curl, it's better to allow this flexibility.

Comment by Dimitri Bellini [ 2019 Feb 21 ]

On most of our cases we use persistent token for authentication but not all devices/apps support this method.
For example using HTTP Agent with Zabbix API is not possible.
I would like to suggest an enhancement of this great new "check" to support persistent cookies or more in general a specific login session before the real "check" request.
Thanks

Comment by Dimitri Bellini [ 2019 Mar 13 ]

Hi DevTeam,
before is to late for the upcoming 4.2, I would like to suggest to extend the Header Input box to suite some very big token coming from "OpenShift" (https://docs.openshift.com/container-platform/3.5/rest_api/index.html).
As i could see Openshift could generate token with a length of 800-900 characters.
I think is not so huge modification.
Thanks very much

Generated at Thu Apr 25 09:59:33 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.