Skip to content

nb_lookup: Can't query IP-Address by id #370

@ghost

Description

ISSUE TYPE
  • Bug Report
SOFTWARE VERSIONS
Ansible:

2.9.13

Netbox:

2.9.4

Collection:

netbox collection version 1.1.0

SUMMARY

I need to query netbox for a specific ip address. I would like to filter this with the id of the ip-address.
This results in an error.

STEPS TO REPRODUCE
- name: "Get ip-address by id"
  debug:
    msg:  "{{ query('netbox.netbox.nb_lookup', 'ip-addresses',
                    api_endpoint=netbox_url,
                    api_filter='id=6293',
                    token=netbox_token) }}"
EXPECTED RESULTS

I expect to get a dict of the queried ip address.

ACTUAL RESULTS
An unhandled exception occurred while running the lookup plugin 'netbox.netbox.nb_lookup'. Error was a <class 'ValueError'>, original message: A reserved ('id', 'pk', 'limit', 'offset') kwarg was passed. Please remove it try again.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions