cURL Issue - Attempting To Retrieve/Update iOS Extension Attributes

NerdMusk
New Contributor II

Hey Everybody,

I'm having some trouble with my scripting.  I'm attempting to view an iPad's extension attributes, and then update them if needed, but my cURL request always come back with the same error: "The request requires user authentication" -- which I'm using.  Works for everything else, but not for extension attributes.  Maybe my code is wrong?  Here's what I have:

curl -X GET -H "accept: application/xml" -H "authorization: Basic ${jssAuth}" "${jssURL}/JSSResource/mobiledeviceextensionattributes/id/$deviceID"

 

 

Thanks,
-Rob

1 ACCEPTED SOLUTION

ljcacioppo
Contributor III

Just a note, if you are trying to look up the extension attributes for a specific iPad, that's not the right API endpoint.

The ID number at the end of that api call is for extension attribute ID number, not mobile device ID.

If you were looking for the value in an extension attribute for a specific iPad, you would probably need to use the 

/JSSResource/mobiledevices/id/$deviceID/subset/extension_attributes

to see the EA values for a given iPad

View solution in original post

2 REPLIES 2

ljcacioppo
Contributor III

Just a note, if you are trying to look up the extension attributes for a specific iPad, that's not the right API endpoint.

The ID number at the end of that api call is for extension attribute ID number, not mobile device ID.

If you were looking for the value in an extension attribute for a specific iPad, you would probably need to use the 

/JSSResource/mobiledevices/id/$deviceID/subset/extension_attributes

to see the EA values for a given iPad

NerdMusk
New Contributor II

Thank you very much.  That was exactly it.