Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-18653

Add script item/webhook parameter name restriction to the documentation

    XMLWordPrintable

Details

    • Problem report
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 5.0.5, 5.2.1
    • 5.4 (plan)
    • Documentation (D)
    • None
    • Team D
    • Sprint 70 (Nov 2020)

    Description

      Steps to reproduce:

      1. Create script item type
      2. Set 'some-api-variable' parameter:
      request.AddHeader('x-api-key: '+params.some-api-parameter);
      

      Result:

      Cannot execute script: ReferenceError: identifier 'api' undefined
              at [anon] (duktape.c:81729) internal
              at [anon] (function:7) preventsyield
      

      Expected in documentation:

      The names of variables, called identifiers, conform to certain rules. A JavaScript identifier must start with a letter, underscore ( _ ), or dollar sign ( $ ). Subsequent characters can also be digits ( 0 – 9 ).

      https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Grammar_and_types

      Attachments

        Activity

          People

            martins-v Martins Valkovskis
            edgar.akhmetshin Edgar Akhmetshin
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: