Page cover

Journeys API

Looking for an older version? Please click this link Previous versions to view previous API versions.

Get Journey Data

get

Retrieves the data for a specific journey. Also includes the associated user in relationships.

Authorizations
Path parameters
journey_idstringRequired

The ID of the user journey whose data is being retrieved.

Query parameters
fields[journeys]string · enumOptional

The additional fields of the journey to be returned.

Example: predictionsPossible values:
Header parameters
x-scope-partner-idstringRequired

The partner id, please contact Yofi to get the partner id

Responses
200

Successful response with journey data and associated user in relationships.

application/json
get
/journeys/{journey_id}
GET /data-api/v3/journeys/{journey_id} HTTP/1.1
Host: server.telemetry.services.yofi.ai
Authorization: Bearer YOUR_SECRET_TOKEN
x-scope-partner-id: text
Accept: */*
{
  "trace_id": "text",
  "data": [
    {
      "type": "journey",
      "id": "text",
      "attributes": {
        "journey_id": "text",
        "feature": {
          "journeyMetadata": {},
          "cloudBehavioral": {}
        },
        "custom_events": [
          {
            "created_at": "2025-10-29T12:20:50.189Z",
            "events": [
              {
                "level": 0,
                "name": "text",
                "time": 1,
                "type": 0
              }
            ],
            "sid": "text",
            "url": "text"
          }
        ],
        "created_at": "2025-10-29T12:20:50.189Z",
        "updated_at": "2025-10-29T12:20:50.189Z",
        "app_id": "text",
        "predictions": [
          {
            "prediction_id": "c545c017598956b55df7811f0fdb2164681557447481c159a4b93ec0f4503734",
            "entity_id": "jid-e90328e0-1be9-540e-8671-41acd5cc9a5d",
            "entity_type": "journey",
            "app_id": "77b395e7-3c13-4121-9894-f8d21e3e597f",
            "model_name": "RuleBasedBotDetector",
            "model_type": "rule_based",
            "model_level": "journey",
            "model_version": "0.0.1",
            "prediction_category": "bot",
            "prediction_subcategory": "botd_detect",
            "label_name": "Bot - BotD Detect",
            "is_public_model": true,
            "predicted_value": 1,
            "severity": "high",
            "value_type": "number",
            "indicators": [
              {
                "indicatorName": "botd sessions count",
                "indicatorDescription": "This journey contains sessions that are detected by botd.",
                "indicatorRiskLevel": "high",
                "value": "3"
              },
              {
                "indicatorName": "suspicious behavior patterns",
                "indicatorDescription": "Detected automated navigation patterns typical of bots",
                "indicatorRiskLevel": "medium",
                "value": "true"
              },
              {
                "indicatorName": "session frequency",
                "indicatorDescription": "Unusually high number of sessions in short time period",
                "indicatorRiskLevel": "medium",
                "value": "high"
              }
            ],
            "justification": "This journey is flagged by BotD due to multiple suspicious sessions and automated navigation patterns.",
            "prediction_source": "stream",
            "created_at": "2025-09-10T03:45:29.113091Z",
            "updated_at": "2025-09-10T03:45:29.113101Z"
          }
        ]
      }
    }
  ]
}

Get Journey Predictions

get

Retrieves the predictions for a specific journey.

Authorizations
Path parameters
journey_idstringRequired

The ID of the user journey whose data is being retrieved.

Query parameters
isForceboolean · enumOptional

Whether to force calculate the features.

Possible values:
Header parameters
x-scope-partner-idstringRequired

The partner id, please contact Yofi to get the partner id

Responses
200

Successful response with journey predictions.

application/json
get
/journeys/{journey_id}/predictions
GET /data-api/v3/journeys/{journey_id}/predictions HTTP/1.1
Host: server.telemetry.services.yofi.ai
Authorization: Bearer YOUR_SECRET_TOKEN
x-scope-partner-id: text
Accept: */*
{
  "trace_id": "text",
  "data": [
    {
      "type": "prediction",
      "id": "text",
      "attributes": {
        "prediction_id": "c545c017598956b55df7811f0fdb2164681557447481c159a4b93ec0f4503734",
        "entity_id": "jid-e90328e0-1be9-540e-8671-41acd5cc9a5d",
        "entity_type": "journey",
        "app_id": "77b395e7-3c13-4121-9894-f8d21e3e597f",
        "model_name": "RuleBasedBotDetector",
        "model_type": "rule_based",
        "model_level": "journey",
        "model_version": "0.0.1",
        "prediction_category": "bot",
        "prediction_subcategory": "botd_detect",
        "label_name": "Bot - BotD Detect",
        "is_public_model": true,
        "predicted_value": 1,
        "severity": "high",
        "value_type": "number",
        "indicators": [
          {
            "indicatorName": "botd sessions count",
            "indicatorDescription": "This journey contains sessions that are detected by botd.",
            "indicatorRiskLevel": "high",
            "value": "3"
          },
          {
            "indicatorName": "suspicious behavior patterns",
            "indicatorDescription": "Detected automated navigation patterns typical of bots",
            "indicatorRiskLevel": "medium",
            "value": "true"
          },
          {
            "indicatorName": "session frequency",
            "indicatorDescription": "Unusually high number of sessions in short time period",
            "indicatorRiskLevel": "medium",
            "value": "high"
          }
        ],
        "justification": "This journey is flagged by BotD due to multiple suspicious sessions and automated navigation patterns.",
        "prediction_source": "stream",
        "created_at": "2025-09-10T03:45:29.113091Z",
        "updated_at": "2025-09-10T03:45:29.113101Z"
      }
    }
  ]
}

Last updated

Was this helpful?