If receive an error "Authorization Denied", check policy Action / Create in Access Management.
const newAction = await Resources.actions.create({
name: "My Action",
type: "condition",
action: {
script: ["analysis-id"],
type: "script"
},
tags: [{ key: "type", value: "notification" }]
});
console.log(newAction.action); // action-id-123
Deletes an action from your application.
Modifies an existing action.
Retrieves detailed information about a specific action.
Lists all actions from the application with pagination support. Use this to retrieve and manage actions in your application.
Optional
queryObj: ActionQueryIf receive an error "Authorization Denied", check policy Action / Access in Access Management.
const list = await Resources.actions.list({
page: 1,
fields: ["id", "name"],
amount: 10,
orderBy: ["name", "asc"]
});
console.log(list); // [ { id: '66ab7c62e5f0db000998ce42', name: 'Action Test', ...} ]
Creates a new action in your application.