recurringaction

Description

Provides methods to handle Recurring Actions for Minions, Groups and Organizations.

Namespace:

recurringaction

Method: create

Description:

Create a new recurring action.

Parameters:

  • string sessionKey

  • struct - actionProps

    • string "entity_type" - The type of the target entity. One of the following:

    • MINION

    • GROUP

    • ORG

    • int "entity_id" - The id of the target entity

    • string "name" - The name of the action

    • string "cron_expr" - The execution frequency of the action

    • boolean "test" - Whether the action should be executed in test mode (optional)

Returns:

  • int id - The id of the recurring action

Method: delete

Description:

Delete recurring action with given action id.

Parameters:

  • string sessionKey

  • int actionId - Id of the action

Returns:

  • int id - The id of the recurring action

Method: listByEntity

Description:

Return a list of recurring actions for a given entity.

Parameters:

  • string sessionKey

  • string entityType - Type of the target entity. Can be MINION, GROUP or ORG.

  • int entityId - Id of the target entity

Returns:

  • array :

  • struct - Recurring Action information

    • int "id"

    • string "name"

    • int "entity_id"

    • string "entity_type"

    • string "cron_expr"

    • dateTime.iso8601 "created"

    • string "creator"

    • boolean "test"

    • boolean "active"

Method: lookupById

Description:

Return recurring action with given action id.

Parameters:

  • string sessionKey

  • int actionId - Id of the action

Returns:

  • * struct - Recurring Action information

    • int "id"

    • string "name"

    • int "entity_id"

    • string "entity_type"

    • string "cron_expr"

    • dateTime.iso8601 "created"

    • string "creator"

    • boolean "test"

    • boolean "active"

Method: update

Description:

Update a recurring action.

Parameters:

  • string sessionKey

  • struct - actionProps

    • int "id" - The id of the action to update

    • string "name" - The name of the action (optional)

    • string "cron_expr" - The execution frequency of the action (optional)

    • boolean "test" - Whether the action should be executed in test mode (optional)

    • boolean "active" - Whether the action should be active (optional)

Returns:

  • int id - The id of the recurring action