- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
update /get extensibleattributedef by its reference not working
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2022 06:51 AM
hello
i want to update extensible attribute definition (add/delete possible values etc...)
but for some reason every time i try to use an extensible attribute reference that I retrieved from a GET call, in subsequent GET/PUT calls using this ref i get error message
############### get a reference
curl -k -u "aaa:bbbb" -H "Content-Type: application/json" -X GET "https://$IP/wapi/v2.11.3/extensibleattributedef?name=Site"
[
{
"_ref": "extensibleattributedef/b25lLmV4dGVuc2libGVfYXR0cmlidXRlc19kZWYkLlNpdGUite",
"default_value": null,
"name": "Site",
"type": "ENUM"
}
]
#### use it back
curl -k -u "aaa:bbb" -H "Content-Type: application/json" -X GET "https://$IP/wapi/v2.11.3/extensibleattributedef/b25lLmV4dGVuc2libGVfYXR0cmlidXRlc19kZWYkLlNpdGUite"
{ "Error": "AdmConDataNotFoundError: Reference extensibleattributedef/b25lLmV4dGVuc2libGVfYXR0cmlidXRlc19kZWYkLlNpdGUite not found",
"code": "Client.Ibap.Data.NotFound",
"text": "Reference extensibleattributedef/b25lLmV4dGVuc2libGVfYXR0cmlidXRlc19kZWYkLlNpdGUite not found"
same on PUT request to update whatever field
i use the same technique to update subnets etc... but for extensible attr i cant get it to work...
what am i missing?
thanks
Solved! Go to Solution.
Re: update /get extensibleattributedef by its reference not working
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2022 09:46 AM
fixed by myself
my account was not superadmin and just RW Admin
this RW level is enough to get all extrattributes, but not to GET/PUT a specific one
POST a new attribute gave me a proper error message, GET/PUT just leave you blind
thanks