Video Analytics

Export video metrics history

Exports recent daily metrics history for a specific video as CSV with a presigned download URL.

post/videos/{platform}/{platformVideoId}/history/export

Request

  • Base URL: https://viral.app/api/v1
  • URL: https://viral.app/api/v1/videos/{platform}/{platformVideoId}/history/export
  • Auth: API key in header x-api-key

Path parameters

platform'facebook' | 'instagram' | 'tiktok' | 'youtube' | 'snapchat' required

Social media platform (facebook, instagram, tiktok, youtube, snapchat)

Example:facebook
platformVideoIdstring required

Native platform video id found in the URL of the video

Example:7123456789012345678

Request body

daysinteger

Number of most recent days to include in the export.

Example request

{
  "days": 14
}

Response

OK

downloadUrlstring uri required

Presigned download URL for the CSV export file

expiresAtstring date-time required

Expiration timestamp for the download URL (typically 5 minutes)

rowCountnumber required

Total number of data rows included in the export file

fileNamestring required

Generated filename for the export (includes timestamp)

Example response

{
  "downloadUrl": "https://storage.cloudflare.com/exports/video-daily-gains-2025-12-20-143052.csv?signature=abc123",
  "expiresAt": "2025-12-20T14:35:52.000Z",
  "rowCount": 15420,
  "fileName": "video-daily-gains-2025-12-20-143052.csv"
}

Changes

No recorded changes to this operation across all 1 revision of this API.