netbox-community / pynetbox

Python API client library for Netbox.
Apache License 2.0
567 stars 168 forks source link

link peers on a cable termination are not cast to a specific model but are left as a generic record. #519

Open arthanson opened 1 year ago

arthanson commented 1 year ago

link peers on a cable termination are not cast to a specific model but are left as a generic record. The return for link_peers is somewhat different format then for things like a_terminations:

        "a_terminations": [
            {
                "object_type": "circuits.circuittermination",
                "object_id": 15,
                "object": {

For link_peers the return is:

            "link_peers": [
                {
                    "id": 1,
            "link_peers_type": "circuits.circuittermination",

It would make it easier on the API side if these were consistent (would require a change on the NetBox side):

        "link_peers": [
            {
                "object_type": "circuits.circuittermination",
                "object_id": 1,
                "object": {