Skip to main content

Check out Port for yourself ➜ 

Configuration and outputs

Action nodes perform operations in your workflow. They execute after trigger nodes and can be chained together to create complex automation flows.

Common configuration

All action nodes share these common fields:

FieldDescription
identifierUnique identifier for the node within the workflow
titleDisplay name for the node
iconOptional icon for the node
descriptionOptional description of what the node does
configThe action configuration (type-specific)
variablesOptional key-value pairs for reusable expressions

Referencing outputs

Action nodes can reference outputs from previous nodes using bracket notation .outputs["<node_identifier>"].<field>:

ContextDescription
.outputs["<node_identifier>"].<field>Output from any previous node (including trigger)
.secrets["<name>"]Organization secrets

For self-service triggers, the user inputs are stored directly at .outputs["<trigger-node-identifier>"].<input_key>.

For event triggers, the event data is stored at .outputs["<trigger-node-identifier>"].diff.after, .outputs["<trigger-node-identifier>"].action, etc.

Example

Chaining node outputs

This example demonstrates how to pass data between nodes. A self-service trigger collects a resource name from the user, passes it to a webhook that creates the resource, and then sends a Slack notification with the newly created resource ID.

Chaining node outputs (click to expand)
{
"nodes": [
{
"identifier": "trigger",
"title": "Start",
"config": {
"type": "SELF_SERVE_TRIGGER",
"userInputs": {
"properties": {
"resourceName": { "type": "string" }
}
}
}
},
{
"identifier": "create_resource",
"title": "Create Resource",
"config": {
"type": "WEBHOOK",
"url": "https://api.example.com/resources",
"method": "POST",
"body": {
"name": "{{ .outputs.trigger.resourceName }}"
}
}
},
{
"identifier": "notify",
"title": "Send Notification",
"config": {
"type": "WEBHOOK",
"url": "https://hooks.slack.com/xxx",
"method": "POST",
"body": {
"text": "Created resource with ID: {{ .outputs.create_resource.response.body.resourceId }}"
}
}
}
],
"connections": [
{
"sourceIdentifier": "trigger",
"targetIdentifier": "create_resource"
},
{
"sourceIdentifier": "create_resource",
"targetIdentifier": "notify"
}
]
}

Condition nodes

In addition to action nodes, workflows support condition nodes for branching logic:

{
"identifier": "check-environment",
"title": "Check Environment",
"config": {
"type": "CONDITION",
"options": [
{
"identifier": "production",
"title": "Production",
"expression": ".outputs.trigger.environment == \"production\""
},
{
"identifier": "staging",
"title": "Staging",
"expression": ".outputs.trigger.environment == \"staging\""
}
]
}
}

Connections from condition nodes must specify which option they're connected to:

{
"connections": [
{
"sourceIdentifier": "check-environment",
"targetIdentifier": "production-deploy",
"sourceOptionIdentifier": "production"
},
{
"sourceIdentifier": "check-environment",
"targetIdentifier": "staging-deploy",
"sourceOptionIdentifier": "staging"
},
{
"sourceIdentifier": "check-environment",
"targetIdentifier": "default-deploy",
"fallback": true
}
]
}