Project Actions
Project actions are run on Constellation events (which are triggered by revisioning the Constellation) and consist of rules and a job. Action plans are like templates which decide how the action should be run and what it should do. Actions can be re-run if needed.
Decide what nodes and in which way they’re collected from Constellation events. The nodes can then be filtered, ordered, and selected to be used as a way to determine what nodes should be included in the special variables.
Jobs are what define what the action should do, such as sending an email or calling an API. Each action can only have one job. Jobs are context-aware, that is, they can have variables in the different inputs in order to tailor your payloads.
Email job
Section titled “Email job”Email jobs can be configured with the following inputs:
- Recipients (project accounts)
- Subject
- Content
API job
Section titled “API job”API jobs can be configured with the following inputs:
- Method (
GET,POST,PUT,PATCH, andDELETE) - URL
- Headers (key-value pairs)
- Body (sent in UTF8 encoding with media type
application/json)
Variables
Section titled “Variables”Variables can be added to context-aware places, such as in jobs. Variables can be in either open ($MY_VARIABLE) or closed (${MY_VARIABLE}) format. Read more here.
Special variables
Section titled “Special variables”The following variables are available in context-aware spaces, such as in jobs.
| Name | Description |
|---|---|
PROJECT_ID | Project ID (UUID) |
PROJECT_NAME | Project name (string) |
CONSTELLATION_HASH | Target revision’s hash, see revisions |
CONSTELLATION_VERSION | Target revision’s root node’s version value |
CONSTELLATION_STATUS | Target revision’s root node’s status result |
CONSTELLATION_ALL_NODES_JSON | All nodes in the target revision in JSON format, see types |
CONSTELLATION_ALL_DIFFS_JSON | All diffs from the targeted revision in JSON format, see types |
CONSTELLATION_NODES_JSON | Targeted nodes based on rules in the target revision in JSON format, see types |
CONSTELLATION_DIFFS_JSON | Targeted node diffs from the targeted revision in JSON format, see types |
CONSTELLATION_ALL_NODES_HTML | All nodes in the target revision in a styled HTML table |
CONSTELLATION_ALL_DIFFS_HTML | All diffs from the targeted revision in a styled HTML table |
CONSTELLATION_NODES_HTML | Targeted nodes based on rules in the target revision in a styled HTML table |
CONSTELLATION_DIFFS_HTML | Targeted node diffs from the targeted revision in a styled HTML table |