-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add URL field on API responses that provides the NetBox UI URL to an object #15156
Comments
@ITJamie could you please make another pass over your original request for readability. I think I get the gist, but we need to uphold a minimum standard for grammar and punctuation. (Please rewrite the issue title as well.) Additionally, "feature branch" is not a valid version. Please indicate a specific NetBox release. |
updated further with an example of possible API response |
Thanks for the update @ITJamie. Since this work will involve adding new API response fields, we'll need to schedule it for a minor-version boundary, hence |
NetBox version
4.0.2
Feature type
New functionality
Proposed functionality
When using the Rest API the URL field on objects has direct API URLs.
It would be great if there was a
display_url
orui_url
to use when referencing the object in external tools.Removing
/api
from the the existingurl
field on API response doesn't always work to get to a valid UI URL.This could be an optional non-default field that could be requested if needed now that #15087 is possible.
examples of what this could look like:
VM API response:
VM Disk response:
Use case
When using the API sometimes we send slack alerts or emails for specific issues we find with data for a human to visit and interfact with / fix.
With most objects we can strip
/api
from the URL and give that URL to users, however not all objects follow that (e.g. virtual disks on VMs)Example:
http://netbox_instance/virtualization/disks/1/
http://netbox_instance/api/virtualization/virtual-disks/1/
Database changes
N/A
External dependencies
N/A
The text was updated successfully, but these errors were encountered: