Is it possible to delete or add scripts to a policy through API call?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 07-17-2024 06:17 AM
I see update or create policy documentation on Classic API. This API is getting a policy object in xml format, without its scripts property (unlike the response from GET on this api that returns xml of policy including its scripts).
There is a way to link or unlink a script to a policy instance through API call?
Thanks in advance

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 07-17-2024 06:25 AM
I think you can only create new policy with PUT, EDIT looks to be limited to adjusting the scope of a policy. I am anything but an API expert, but I don't think you can do what you are wanting with API unless you just deleted the script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 07-22-2024 12:21 AM
Thanks @AJPinto.
I have another problem with updating | creating a configuration profile with its payloads.
I can see a pattern that all types from the classic API (and not pro API) are supporting only 3 entities: general, scope and self_service. Is this observation correct? Is there any other API I can use to adjust other properties? Is there a plan the extend pro API to more types?
Appreciate any comment :)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 07-22-2024 06:14 AM
- I have another problem with updating | creating a configuration profile with its payloads: Are you trying to create a Configuration Profile with API?
- I can see a pattern that all types from the classic API (and not pro API) are supporting only 3 entities: general, scope and self_service: These are the 3 tabs in a configuration profile in Jamfs GUI
- Is there any other API I can use to adjust other properties: Are you trying to Adjust Jamfs GUI elements?
- Is there a plan the extend pro API to more types? I can't speak for Jamf, but I have not seen any significant changes in API ability in the 6 years I have worked with Jamf.
Parting thoughts: Jamfs API is very robust, but is designed for system integration, reporting, with the occasional simplifying of repeated processes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 07-22-2024 06:18 AM
1. Yes create and also update an existing one
2. You are right, my misunderstanding
3. Exactly
4. Thanks
Updating that I manage to update scripts on a policy through API call. Will summarize here how to do it later
