v1

latestOpenAPI 3.0.0AGPLv3.02026-07-14186117194.3 KB
Video

Get a video

get/api/v1/videos/{id}

Path parameters

integer required
OR
string uuid required
OR
string required

translation of a uuid v4 with a bigger alphabet to have a shorter uuid

Example:42

The object id, uuid or short uuid

Response

successful operation

blacklistedboolean nullable
blacklistedReasonstring nullable
createdAtstring date-time

time at which the video object was first drafted

descriptionstring

truncated description of the video, written in Markdown. Resolve descriptionPath to get the full description of maximum 10000 characters.

dislikesinteger
durationinteger

duration of the video in seconds

embedPathstring
idinteger
isLiveboolean
isLocalboolean
likesinteger
namestring

title of the video

nsfwboolean
originallyPublishedAtstring date-time

used to represent a date of first publication, prior to the practical publication date of publishedAt

previewPathstring
publishedAtstring date-time

time at which the video was marked as ready for playback (with restrictions depending on privacy). Usually set after a state evolution.

shortUUIDstring

translation of a uuid v4 with a bigger alphabet to have a shorter uuid

thumbnailPathstring
updatedAtstring date-time

last time the video's metadata was modified

uuidstring uuid
viewsinteger
waitTranscodingboolean nullable
commentsEnabledboolean
descriptionPathstring

path at which to get the full description of maximum 10000 characters

downloadEnabledboolean
supportstring

A text tell the audience how to support the video creator

tagsstring[]
trackerUrlsstring[]
viewersinteger

If the video is a live, you have the amount of current viewers

Example response

{
  "account": {
    "id": 42,
    "name": "chocobozzz",
    "userId": 42
  },
  "category": {
    "id": 15,
    "label": "Science & Technology"
  },
  "channel": {
    "displayName": "Videos of Framasoft",
    "id": 42,
    "name": "chocobozzz",
    "description": "Videos made with <3 by Framasoft",
    "ownerAccount": {
      "uuid": "9c9de5e8-0a1e-484a-b099-e80766180a6d"
    },
    "support": "Please support our work on https://soutenir.framasoft.org/en/ <3"
  },
  "createdAt": "2017-10-01T10:52:46.396Z",
  "description": "**[Want to help to translate this video?](https://weblate.framasoft.org/projects/what-is-peertube-video/)**\\r\\n\\r\\n\n**Take back the control of your videos! [#JoinPeertube](https://joinpeertube.org)**\\r\\n*A decentralized video hosting network, based on fr...\n",
  "dislikes": 7,
  "duration": 1419,
  "embedPath": "/videos/embed/a65bc12f-9383-462e-81ae-8207e8b434ee",
  "id": 42,
  "language": {
    "id": "en",
    "label": "English"
  },
  "licence": {
    "id": 2,
    "label": "Attribution - Share Alike"
  },
  "likes": 42,
  "name": "What is PeerTube?",
  "originallyPublishedAt": "2010-10-01T10:52:46.396Z",
  "previewPath": "/lazy-static/previews/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg",
  "publishedAt": "2018-10-01T10:52:46.396Z",
  "shortUUID": "2y84q2MQUMWPbiEcxNXMgC",
  "thumbnailPath": "/static/thumbnails/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg",
  "updatedAt": "2021-05-04T08:01:01.502Z",
  "uuid": "9c9de5e8-0a1e-484a-b099-e80766180a6d",
  "views": 1337,
  "descriptionPath": "/api/v1/videos/9c9de5e8-0a1e-484a-b099-e80766180a6d/description",
  "files": [
    {
      "id": 42,
      "resolution": {
        "id": 240,
        "label": "240p"
      }
    }
  ],
  "streamingPlaylists": [
    {
      "id": 42,
      "files": [
        {
          "id": 42,
          "resolution": {
            "id": 240,
            "label": "240p"
          }
        }
      ]
    }
  ],
  "support": "Please support our work on https://soutenir.framasoft.org/en/ <3",
  "tags": [
    "flowers",
    "gardening"
  ],
  "trackerUrls": [
    "https://peertube2.cpy.re/tracker/announce",
    "wss://peertube2.cpy.re/tracker/socket"
  ]
}