data.network.scope.persist ​
Upsert a NetworkScope from sync (idempotent on provider_scope_ref)
Create, restore, or update a NetworkScope by (account, provider_scope_ref).
Overview ​
| Property | Value |
|---|---|
| Workflow type | Atomic |
| Library | App-network |
| Version | 1.0 |
Input Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
organization_uuid | uuid | Yes | — | UUID of the organization that owns the scope |
network_account_uuid | uuid | Yes | — | UUID of the parent NetworkAccount |
provider_scope_ref | string | Yes | — | Provider-side scope identifier (e.g. vpc-0abc...) |
name | string | Yes | — | Human-readable scope name |
cidr_blocks | list | No | — | List of CIDR blocks attached to the scope |
is_default | boolean | No | — | Whether the provider considers this the default scope |
provider_metadata | dict | No | — | Provider-side metadata bag (no secrets) |
actor | string | No | — | Caller (UUID or numeric user id) initiating the persist |
Output Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
scope_uuid | uuid | Yes | — | UUID of the persisted NetworkScope |
created | boolean | Yes | — | True when a new row was inserted |
restored | boolean | Yes | — | True when a soft-deleted row was restored |
updated | boolean | Yes | — | True when an existing active row was mutated |
persisted_at | string | Yes | — | ISO-8601 timestamp of the persist |
failure_reason | string | No | — | Engine-stamped human-readable failure reason |
failed_at_state | string | No | — | Engine-stamped state when the workflow failed |
failed_step | string | No | — | Engine-stamped step name (DAG path) |
failed_layer | integer | No | — | Engine-stamped layer index (DAG path) |
error | string | No | — | Engine-stamped exception message |
error_type | string | No | — | Engine-stamped exception class name |
States ​
| State | Initial | Terminal | Success | Auto-advance | Description |
|---|---|---|---|---|---|
pending | Yes | No | — | complete | Persist scope |
completed | No | Yes | Yes | — | Persisted |
failed | No | Yes | No | — | Persist failed |
State Diagram ​
Transitions ​
| From | Action | To | Description |
|---|---|---|---|
pending | complete | completed | — |
pending | fail | failed | — |
Outcomes ​
| Outcome | Type | Description | State Data Keys |
|---|---|---|---|
persisted | SUCCESS | Upsert a NetworkScope from sync (idempotent on provider_scope_ref) | — |
failed | FAILURE | Network workflow failed | failure_reason |
API Usage ​
bash
POST /api/workflows/start
Content-Type: application/json
{
"workflow_type": "data.network.scope.persist",
"initial_data": {
"organization_uuid": "value",
"network_account_uuid": "value",
"provider_scope_ref": "value",
"name": "value"
}
}