Skip to content
SarvexDocs
Esc
↑↓navigate↵open⌘Jpreview

List tasks (the task spine)

The single feed behind the merchant Path, the operator board counts, and notifications.

GET/tasks
Authorization
AuthorizationBearer token (JWT) · headerrequired

JWT issued by the external IdP via the OAuth 2.0 authorization-code flow (Kinde in production; a simulator in test). The client obtains it and sends it as a Bearer token on every authenticated call. Sarvex's services verify it — issuer, audience, signature (IdP JWKS), expiry — and read identity and tenant from its claims. Sarvex does not issue or revoke these tokens. merchant_id/store_id are read from the verified claims (and the merchant→store mapping), never from the URL. The operator scope is required for /operator/*. Operators acting on a specific merchant pass the X-Operate-As header, which is recorded in the audit log.

Query parameters
cursorstring

Opaque pagination cursor from the previous page's page.cursor.

limitinteger

Maximum items per page.

min 1 · max 100 · default: 25
ownertask_owner
Allowed:merchantsarvexexternal
statetask_state
Allowed:openin_progressblockeddone
store_idstring

Restrict to tasks for one of the caller's own stores. Omit to list across all of the merchant's stores.

Responses
200

Tasks.

datatask[]required
Show properties
Array of task
task_idstring
store_idstring

The store this task belongs to.

titlestring

Plain-language, merchant vocabulary.

why_it_mattersstring
ownertask_owner
Allowed:merchantsarvexexternal
resolutiontask_resolution
Allowed:one_clickguidedautomaticexternal_wait
statetask_state
Allowed:openin_progressblockeddone
blocks_checkoutboolean
sourcestring

Emitting domain; the task spine unifies all of these.

Allowed:readinesschecklistvalidationconsistencymonitoringcatalog_import
source_refstring | null

Id of the underlying issue/item/finding for drill-in.

remediationsremediation[]

Typed drill-in payload for source=readiness tasks: the rule-based fixes available for the task's product (source_ref = sku). Absent or empty for other sources, or when no unapplied fix exists.

Show properties
Array of remediation
remediation_idstring
skustring
fieldstring
from_valuestring
to_valuestring
typestring
Allowed:rulemanual
truststring
Allowed:highlow
findingobject | null

Typed drill-in payload for source=monitoring tasks: the consistency finding that raised this task, snapshotted at raise time (not re-evaluated live). Absent for other sources.

Show properties
finding_idstring
skustring
fieldstring
sourcesobject
severityseverity
Allowed:infowarningcritical
detected_atstring<date-time>
issuesproduct_issue[]

Typed drill-in payload for source=readiness tasks: the product's open issues that have no rule-based fix (remediable=manual), so a merchant must edit the value directly. Absent or empty for other sources, or when every blocking issue on the product has an automatic remediation covered by remediations.

Show properties
Array of product_issue
issue_idstring
fieldstring
problemstring
Allowed:missingfree_textnon_standard_enuminconsistent
blocks_checkoutboolean
revenue_impact_monthlymoney
Show properties
amount_minorintegerrequired

Amount in minor units (cents).

currencystringrequired
remediablestring
Allowed:rulemanual
created_atstring<date-time>
updated_atstring<date-time>
pagepagerequired
Show properties
cursorstring | nullrequired
has_morebooleanrequired
Try it
Server
Authorization
Parameters
Request
curl -X GET "https://api.sarvex.example.com/v1/tasks" \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "data": [
    {
      "task_id": "string",
      "store_id": "string",
      "title": "string",
      "why_it_matters": "string",
      "owner": "merchant",
      "resolution": "one_click",
      "state": "open",
      "blocks_checkout": true,
      "source": "readiness",
      "source_ref": "string",
      "remediations": [
        {
          "remediation_id": "string",
          "sku": "string",
          "field": "string",
          "from_value": "string",
          "to_value": "string",
          "type": "rule",
          "trust": "high"
        }
      ],
      "finding": {
        "finding_id": "string",
        "sku": "string",
        "field": "price",
        "sources": {
          "storefront": "29.99",
          "feed": "34.99",
          "served": "29.99"
        },
        "severity": "info",
        "detected_at": "2019-08-24T14:15:22Z"
      },
      "issues": [
        {
          "issue_id": "string",
          "field": "string",
          "problem": "missing",
          "blocks_checkout": true,
          "revenue_impact_monthly": {
            "amount_minor": 0,
            "currency": "AUD"
          },
          "remediable": "rule"
        }
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ],
  "page": {
    "cursor": "string",
    "has_more": true
  }
}