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

host.create api perl

XMLWordPrintable

    • Icon: Incident report Incident report
    • Resolution: Duplicate
    • Icon: Critical Critical
    • None
    • 2.0.5
    • API (A)
    • ubuntu 12.04

      trying to create host by api
      $json = {
      jsonrpc => '2.0',
      method => 'host.create',
      params => {
      host => 'test_from_api',
      output => 'extend',
      interfaces =>

      { dns => '', hostid => '25', ip => '127.0.0.1', main => '1', port => '10050', type => '1', useip => '1', }

      ,
      groups =>

      { groupid => '2', }

      ,
      },
      auth => "$authID",
      id => '21',
      };
      all ok.. but if change groupid to 11 or 12 or 23 or 34 etc.. (2 digits)
      have this answer
      "code":-32500,"message":"Application error.","data":"No permissions to referred object or it does not exist!"

            Unassigned Unassigned
            flezzz Bogdan Lobachevsky
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: