Create an instruction

View as Markdown

Create a new instruction for a node. This operation is only permitted when the simulation is in the ACTIVE or INACTIVE state.

Required scope: air:simulation_edit (roles: air_org_admin, air_user)

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

This endpoint expects an object.
InitInstructionCreateRequestobjectRequired
Payload required to set the hostname of a node.
OR
FileInstructionCreateRequestobjectRequired
Payload required to write arbitrary files to a node.
OR
ShellInstructionCreateRequestobjectRequired
Payload required to run arbitrary shell commands on a node.

Response

InitInstructionReadobject
Representation of a hostname assignment instruction.
OR
FileInstructionReadobject
Representation of an instruction that writes files to a node.
OR
ShellInstructionReadobject
Representation of an arbitrary shell execution instruction.

Errors

400
Bad Request Error
403
Forbidden Error
500
Internal Server Error