Skip to content

Add API endpoint to re-run an existing script on a single host #9998

Open
@lukeheath

Description

@lukeheath

Tasks

  • Create POST endpoint to run a script on a single host.
  1. POST /mdm/apple/scripts/{id}/run
  • Fleet Premium feature
  • Required host_id query parameter accepts a single integer.
  • If the host doesn't belong to the same team (or no team) as the script, return this error: Error: The targeted host isn't assigned to the same team as the script. Please provide a host id that is assigned to the same team.

Parameters

Name Type In Description
host_id integer query The host id to run the script on.

Example response

{
    "script_id": 1337
    "team_id": 0,
    "name": "Example script"
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    #g-mdmMDM product group~backendBackend-related issue.~sub-taskA technical sub-task that is part of a story. (Not QA'd. Not estimated.)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions