Run SecObserve Background Task
secobserve_run_periodic_taskTrigger background jobs on demand or list available jobs to refresh stale metrics and run housekeeping. Queues tasks instantly; check periodic_tasks for results.
Instructions
Trigger one of SecObserve's scheduled background jobs now, or list which jobs exist.
Useful when a metric looks stale or housekeeping has not run. The task is queued, not executed inline: the call returns immediately and the outcome shows up in secobserve_list(resource="periodic_tasks"). Only one instance of a task runs at a time.
Args: params (RunPeriodicTaskInput): Validated input containing: - task (Optional[str]): Registered task name. Omit to list the accepted names without running anything.
Returns: str: With no task, a JSON array of registered task names. With a task, a confirmation that it was queued and a pointer to the periodic_tasks resource for its outcome.
Examples: - Use when: "what background jobs can I run?" -> task omitted - Use when: "recalculate the metrics now" -> task="calculate_product_metrics" (confirm the exact name from the listing first). - Don't use when: you want to know whether metrics are stale (use secobserve_product_metrics with kind="status").
Error Handling: 400 means the name is not registered -- call without 'task' for the list. 409 means that task is already running; wait for it rather than retrying. Requires superuser; a product token gets 403.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |