Journeys

Get journey run counts (Preview)

Preview · Available to selected organizations. Counts one published version's runs by status, and per node the live runs there now and the runs that have entered it. Defaults to the newest published version.

GET
/v1/journeys/{id}/stats

Counts one published version's runs by status, and per node the live runs there now and the runs that have entered it. Defaults to the newest published version.

Authorization

apiKey
headerx-api-key<token>

Path Parameters

id*string
Match^jrny_[0-9a-hjkmnp-tv-z]{16,24}$

Query Parameters

version?|null

Response Body

JourneyStats

application/json
  1. response
journeyId*JourneyId
Match^jrny_[0-9a-hjkmnp-tv-z]{16,24}$
version*integer
Range-9007199254740991 <= value <= 9007199254740991
runs*
nodes*array<>
Example Request
import { createClient } from "samva";const samva = createClient({ apiKey: process.env.SAMVA_API_KEY! });const result = await samva.journeys.stats({  "id": "example"});
Example Response
{  "journeyId": "string",  "version": -9007199254740991,  "runs": {    "active": -9007199254740991,    "paused": -9007199254740991,    "exited": -9007199254740991,    "failed": -9007199254740991  },  "nodes": [    {      "nodeId": "string",      "current": -9007199254740991,      "entered": -9007199254740991    }  ]}

Related documentation