Outcome
Run a sourcing workflow once now, paused or not, with the same logic as the schedule: add up to maxPerRun matching contacts not yet on the list. Idempotent: a second run adds only new matches. Records a run (failures carry an error code) without moving the schedule; an archived list or deleted segment pauses the workflow. The run is audited.
Before you start
- Verify the intended environment, signed-in credential, authorized organization and the action permission workspace:write.
- Discover and select an authorized canonical Engage workspace. Pass resourceType=workspace and resourceId separately from action input.
- Review the exact effects and obtain approval before CLI --confirm or MCP confirm:true. A local capture does not authorize a live mutation.
Discover the target
topolo whoami --json
topolo actions get app_topolo_engage.sourcing.workflows.run_now --json
topolo workspaces list topolo-engage --json
Set ENGAGE_WORKSPACE_ID to the identifier of the selected authorized workspace.
Input contract
| Field | Required | Declared constraints |
|---|---|---|
id | Yes | {"type":"string","minLength":1,"maxLength":128} |
Validate, plan and execute
Build payload.json from the current schema and discovered identifiers. The action description above defines its behavior, limits, side effects and declared errors.
: "${ENGAGE_WORKSPACE_ID:?Set ENGAGE_WORKSPACE_ID to your selected workspace identifier}"
topolo actions validate app_topolo_engage.sourcing.workflows.run_now --data @payload.json --json
topolo actions plan app_topolo_engage.sourcing.workflows.run_now --resource-type workspace --resource-id "$ENGAGE_WORKSPACE_ID" --data @payload.json --confirm --json
Review the plan and approve its exact effects before executing the unchanged request.
: "${ENGAGE_WORKSPACE_ID:?Set ENGAGE_WORKSPACE_ID to your selected workspace identifier}"
topolo actions call app_topolo_engage.sourcing.workflows.run_now --resource-type workspace --resource-id "$ENGAGE_WORKSPACE_ID" --data @payload.json --confirm --json
For MCP, use topolo_get_action, topolo_validate_action, topolo_plan_action and topolo_call_action. Pass resource context separately where required; confirm:true is required for mutations.
Captured successful requests and responses
Captured HTTP 200 · sourcing workflows over the published actions > reschedules from the last run when the interval changes
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_1",
"name": "Acme top-up",
"status": "active",
"pausedReason": null,
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_1",
"interval": "weekly",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 2,
"added": 2,
"alreadyMember": 0,
"skipped": 1,
"errorCode": null
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 2,
"added": 2,
"alreadyMember": 0,
"skipped": 1,
"errorCode": null
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 200 · sourcing workflows over the published actions > runs now idempotently: tops up new matches only, records runs and audits
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_1",
"name": "Acme top-up",
"status": "active",
"pausedReason": null,
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_1",
"interval": "daily",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 2,
"added": 2,
"alreadyMember": 0,
"skipped": 1,
"errorCode": null
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 2,
"added": 2,
"alreadyMember": 0,
"skipped": 1,
"errorCode": null
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 200 · sourcing workflows over the published actions > pauses itself when its list is archived or its segment deleted, and records the failure
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_1",
"name": "Acme top-up",
"status": "paused",
"pausedReason": "list_archived",
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_1",
"interval": "daily",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "failed",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": "list_archived"
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_1",
"trigger": "manual",
"status": "failed",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": "list_archived"
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 200 · sourcing workflows over the published actions > runs now idempotently: tops up new matches only, records runs and audits
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_1",
"name": "Acme top-up",
"status": "active",
"pausedReason": null,
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_1",
"interval": "daily",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_2",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 1,
"added": 1,
"alreadyMember": 0,
"skipped": 0,
"errorCode": null
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_2",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 1,
"added": 1,
"alreadyMember": 0,
"skipped": 0,
"errorCode": null
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 200 · sourcing workflows over the published actions > runs now idempotently: tops up new matches only, records runs and audits
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_1",
"name": "Acme top-up",
"status": "active",
"pausedReason": null,
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_1",
"interval": "daily",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_3",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": null
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_3",
"trigger": "manual",
"status": "succeeded",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": null
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 200 · sourcing workflows over the published actions > pauses itself when its list is archived or its segment deleted, and records the failure
Action input
{
"id": "sourcingWorkflow_2"
}
Actual local response
{
"workflow": {
"id": "sourcingWorkflow_2",
"name": "Acme top-up",
"status": "paused",
"pausedReason": "segment_missing",
"source": {
"kind": "segment",
"segmentId": "segment_1"
},
"listId": "list_2",
"interval": "daily",
"maxPerRun": 2,
"nextRunAt": "2026-10-01T09:00:00.000Z",
"lastRunAt": "2026-10-01T09:00:00.000Z",
"lastRunSummary": {
"runId": "sourcingRun_2",
"trigger": "manual",
"status": "failed",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": "segment_missing"
},
"createdBy": "user_1",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-01T09:00:00.000Z"
},
"run": {
"runId": "sourcingRun_2",
"trigger": "manual",
"status": "failed",
"startedAt": "2026-10-01T09:00:00.000Z",
"finishedAt": "2026-10-01T09:00:00.000Z",
"matched": 0,
"added": 0,
"alreadyMember": 0,
"skipped": 0,
"errorCode": "segment_missing"
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Effects and response meaning
- Run a sourcing workflow once now, paused or not, with the same logic as the schedule: add up to maxPerRun matching contacts not yet on the list. Idempotent: a second run adds only new matches. Records a run (failures carry an error code) without moving the schedule; an archived list or deleted segment pauses the workflow. The run is audited.
Verify the outcome
- Check the response against the declared output schema and the requested operation. For mutations, use the action-specific read described in the action description before any dependent operation.
Recover
For an uncertain result, inspect current retained state with a read action before retrying. Do not replay a mutation unless its contract explicitly guarantees idempotency.
Refused requests
Captured HTTP 404 · sourcing workflows over the published actions > runs now idempotently: tops up new matches only, records runs and audits
Action input
{
"id": "sourcingWorkflow_9"
}
Actual local response
{
"error": {
"code": "workflow_not_found",
"message": "Sourcing workflow was not found in this workspace."
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 403 · sourcing workflows over the published actions > lets readers read but not write
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"error": {
"code": "permission_denied",
"message": "The credential lacks workspace:write.",
"details": {
"requiredPermission": "workspace:write"
}
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Captured HTTP 404 · sourcing workflows over the published actions > keeps every workflow inside its own workspace
Action input
{
"id": "sourcingWorkflow_1"
}
Actual local response
{
"error": {
"code": "workflow_not_found",
"message": "Sourcing workflow was not found in this workspace."
}
}
Source test: sourcing-routes.test.ts. Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
Error recovery
- HTTP 404
workflow_not_found: Rediscover the identifier using the related list or get action in the same authorized resource. Do not guess identifiers or change organization context. - HTTP 403
permission_denied: Stop and inspect the current credential and selected resource. It needs workspace:write; do not broaden access or switch organization automatically.
Related actions
- List sourcing workflows
- Get sourcing workflow
- Create sourcing workflow
- Update sourcing workflow
- Pause sourcing workflow
- Resume sourcing workflow
- Delete sourcing workflow
- List sourcing runs
Evidence and limits
-
/api/sourcing/workflows/{id}/run -
sourcing-routes.test.ts -
Actual route handlers with SQLite repositories; synthetic identity/workspace grants and provider ports.
-
Widget/bootstrap use actual app handler but mocked worker runtime and app identity.
-
No gateway execution, live permissions, external delivery or deployed proof.
These are local route captures with synthetic identity and simulated dependencies. They do not prove live authorization, gateway execution, production state, or external delivery.