Skip to main content
Question

Jamf API not removing Apple TVs in classes via API


Forum|alt.badge.img+9

We're having an issue where we cannot remove Apple TVs from classes via the API. (Adding them works fine.) Here's some different command lines I've tried. Both run successfully, but do not remove the Apple TVs. Does anyone see anything wrong, or is this another API bug in Jamf?

curl -k -s -u $jss_user:$jss_pass -X PUT -H "Content-Type: application/xml" -d "<class><apple_tvs></apple_tvs></class>" https://jss.domain.com:8443/JSSResource/classes/id/$class_id

curl -k -s -u $jss_user:$jss_pass -X PUT -H "Content-Type: application/xml" -d "<class><apple_tvs/></class>" https://jss.domain.com:8443/JSSResource/classes/id/$class_id

3 replies

tguyers360
Forum|alt.badge.img+4
  • Contributor
  • 17 replies
  • March 26, 2019

Hi I’m just beginning my API journey and am no expert . I think you are trying to remove ? therefore you need to use the delete not put in your command


Forum|alt.badge.img+9
  • Author
  • Contributor
  • 79 replies
  • March 26, 2019

Thanks for the idea, @tguyers360 , but I'm actually modifying the entry. The modification is to only remove the Apple TV. In the live environment, the API call also has XML for modifying the users/groups in the the class. This example is just the part relevant to the Apple TV. :)


Forum|alt.badge.img+9
  • Author
  • Contributor
  • 79 replies
  • April 1, 2019

After talking to Jamf Support, they believe it's a bug in the API. We'll see if they can get it fixed.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings