---
title: "Get Video Graph"
method: GET
path: "/api/dashboard/creator/videos/{video_id}/graph"
tags: ["Creator Dashboard", "dashboard"]
---

# Get Video Graph

`GET /api/dashboard/creator/videos/{video_id}/graph`

T5-4 (BILLING_RULES.md §5): per-video baseline-vs-actual graph payload.

Returns the data the frontend needs to render the per-video click-through
view: baseline-vs-actual daily revenue series with optimization-event
markers. Authorization: video must belong to a channel owned by user_id.

Shape:
  {
    "video_id": int,
    "youtube_video_id": str,
    "title": str,
    "baseline_period_start": date,
    "baseline_period_end": date,
    "baseline_avg_daily_revenue": float,
    "daily_dates": [date, ...],          # one entry per day post-baseline
    "actual_daily_revenue": [float, ...],
    "projected_daily_revenue": [float, ...],  # slope-line projection from baseline
    "opt_event_markers": [{"applied_at": iso, "optimization_id": int}, ...],
    "incremental_total": float,
  }

Sources:
  - baseline: video_baselines (one row per video; T3-1)
  - actual: revenue_snapshots (one row per video per day)
  - projected: linear extrapolation from baseline.slope/intercept across
    the actual-data date range
  - markers: video_optimizations.applied_at where status='applied'

## Path parameters

- `video_id` integer, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/primetime/apis/primetime-media-api.md) · [All operations](https://skmtc.dev/primetime/apis/primetime-media-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/primetime/primetime-media-api/revisions/9da9a9f64e11/schema)
