# Demo Pulse

## Start synthetic event emission for an internal demo workspace

> Start a synthetic pulse on the workspace.\
> \
> Guardrails: admin/owner role + workspace must be in the allowlist env.\
> Replaces any currently-running pulse on the same workspace.

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"servers":[{"url":"https://api.platform.amigo.ai","description":"Production"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","description":"API key issued via `POST /v1/{workspace_id}/api-keys`. Pass the returned `api_key` value as a Bearer token."}},"schemas":{"DemoPulseStartRequest":{"properties":{"duration_seconds":{"type":"integer","maximum":3600,"minimum":1,"title":"Duration Seconds","description":"How long to emit events before auto-terminating (max 3600).","default":600},"events_per_minute":{"type":"integer","maximum":120,"minimum":1,"title":"Events Per Minute","description":"Emission rate per minute, 1 to 120.","default":30}},"type":"object","title":"DemoPulseStartRequest"},"DemoPulseTaskResponse":{"properties":{"task_id":{"type":"string","title":"Task Id"},"workspace_id":{"type":"string","title":"Workspace Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"events_per_minute":{"type":"integer","title":"Events Per Minute"},"events_attempted":{"type":"integer","title":"Events Attempted"},"active":{"type":"boolean","title":"Active"}},"type":"object","required":["task_id","workspace_id","started_at","expires_at","events_per_minute","events_attempted","active"],"title":"DemoPulseTaskResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}},"paths":{"/v1/{workspace_id}/demo-pulse/start":{"post":{"tags":["Demo Pulse"],"summary":"Start synthetic event emission for an internal demo workspace","description":"Start a synthetic pulse on the workspace.\n\nGuardrails: admin/owner role + workspace must be in the allowlist env.\nReplaces any currently-running pulse on the same workspace.","operationId":"start-demo-pulse","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoPulseStartRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoPulseTaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}}}
```

## Stop the synthetic pulse on a workspace

> Stop the pulse on this workspace.\
> \
> \`\`body.task\_id\`\` is optional; if provided, only that task is stopped (useful\
> for idempotence after a background race). Otherwise the workspace's\
> current task (if any) is stopped.

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"servers":[{"url":"https://api.platform.amigo.ai","description":"Production"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","description":"API key issued via `POST /v1/{workspace_id}/api-keys`. Pass the returned `api_key` value as a Bearer token."}},"schemas":{"DemoPulseStopRequest":{"properties":{"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Optional task_id to stop. When set, only a matching active task is stopped — useful for idempotent retries after a background race. Omit to stop whatever pulse is currently active on the workspace."}},"type":"object","title":"DemoPulseStopRequest"},"DemoPulseStopResponse":{"properties":{"stopped":{"type":"boolean","title":"Stopped"},"task":{"anyOf":[{"$ref":"#/components/schemas/DemoPulseTaskResponse"},{"type":"null"}]}},"type":"object","required":["stopped"],"title":"DemoPulseStopResponse"},"DemoPulseTaskResponse":{"properties":{"task_id":{"type":"string","title":"Task Id"},"workspace_id":{"type":"string","title":"Workspace Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"events_per_minute":{"type":"integer","title":"Events Per Minute"},"events_attempted":{"type":"integer","title":"Events Attempted"},"active":{"type":"boolean","title":"Active"}},"type":"object","required":["task_id","workspace_id","started_at","expires_at","events_per_minute","events_attempted","active"],"title":"DemoPulseTaskResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}},"paths":{"/v1/{workspace_id}/demo-pulse/stop":{"post":{"tags":["Demo Pulse"],"summary":"Stop the synthetic pulse on a workspace","description":"Stop the pulse on this workspace.\n\n``body.task_id`` is optional; if provided, only that task is stopped (useful\nfor idempotence after a background race). Otherwise the workspace's\ncurrent task (if any) is stopped.","operationId":"stop-demo-pulse","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoPulseStopRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoPulseStopResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}}}
```

## GET /v1/{workspace\_id}/demo-pulse/status

> Inspect the active pulse on a workspace

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"servers":[{"url":"https://api.platform.amigo.ai","description":"Production"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","description":"API key issued via `POST /v1/{workspace_id}/api-keys`. Pass the returned `api_key` value as a Bearer token."}},"schemas":{"DemoPulseStatusResponse":{"properties":{"tasks":{"items":{"$ref":"#/components/schemas/DemoPulseTaskResponse"},"type":"array","title":"Tasks"}},"type":"object","required":["tasks"],"title":"DemoPulseStatusResponse"},"DemoPulseTaskResponse":{"properties":{"task_id":{"type":"string","title":"Task Id"},"workspace_id":{"type":"string","title":"Workspace Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"events_per_minute":{"type":"integer","title":"Events Per Minute"},"events_attempted":{"type":"integer","title":"Events Attempted"},"active":{"type":"boolean","title":"Active"}},"type":"object","required":["task_id","workspace_id","started_at","expires_at","events_per_minute","events_attempted","active"],"title":"DemoPulseTaskResponse"}}},"paths":{"/v1/{workspace_id}/demo-pulse/status":{"get":{"tags":["Demo Pulse"],"summary":"Inspect the active pulse on a workspace","operationId":"get-demo-pulse-status","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoPulseStatusResponse"}}}}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.amigo.ai/api-reference/readme/platform/demo-pulse.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
