6 name: PeerTube Community
7 url: https://joinpeertube.org
10 url: https://github.com/Chocobozzz/PeerTube/blob/master/LICENSE
12 url: https://joinpeertube.org/img/brand.png
13 altText: PeerTube Project Homepage
15 The PeerTube API is built on HTTP(S) and is RESTful. You can use your favorite
16 HTTP/REST library for your programming language to use PeerTube. The spec API is fully compatible with
17 [openapi-generator](https://github.com/OpenAPITools/openapi-generator/wiki/API-client-generator-HOWTO)
18 which generates a client SDK in the language of your choice - we generate some client SDKs automatically:
20 - [Python](https://framagit.org/framasoft/peertube/clients/python)
21 - [Go](https://framagit.org/framasoft/peertube/clients/go)
22 - [Kotlin](https://framagit.org/framasoft/peertube/clients/kotlin)
24 See the [REST API quick start](https://docs.joinpeertube.org/api-rest-getting-started) for a few
25 examples of using with the PeerTube API.
29 When you sign up for an account on a PeerTube instance, you are given the possibility
30 to generate sessions on it, and authenticate there using an access token. Only __one
31 access token can currently be used at a time__.
35 Accounts are given permissions based on their role. There are three roles on
36 PeerTube: Administrator, Moderator, and User. See the [roles guide](https://docs.joinpeertube.org/admin-managing-users?id=roles) for a detail of their permissions.
40 The API uses standard HTTP status codes to indicate the success or failure
44 HTTP 1.1 404 Not Found
45 Content-Type: application/json
49 "error": "Account not found"
53 We provide error codes for [a growing number of cases](https://github.com/Chocobozzz/PeerTube/blob/develop/shared/models/server/server-error-code.enum.ts),
54 but it is still optional.
58 Each parameter is evaluated on its own against a set of rules before the route validator
59 proceeds with potential testing involving parameter combinations. Errors coming from Validation
60 errors appear earlier and benefit from a more detailed error type:
63 HTTP 1.1 400 Bad Request
64 Content-Type: application/json
69 "value": "a117eb-c6a9-4756-bb09-2a956239f",
70 "msg": "Should have a valid id",
78 Where `id` is the name of the field concerned by the error, within the route definition.
79 `errors.<field>.location` can be either 'params', 'body', 'header', 'query' or 'cookies', and
80 `errors.<field>.value` reports the value that didn't pass validation whose `errors.<field>.msg`
85 We are rate-limiting all endpoints of PeerTube's API. Custom values can be set by administrators:
87 | Endpoint (prefix: `/api/v1`) | Calls | Time frame |
88 |------------------------------|---------------|--------------|
89 | `/*` | 50 | 10 seconds |
90 | `POST /users/token` | 15 | 5 minutes |
91 | `POST /users/register` | 2<sup>*</sup> | 5 minutes |
92 | `POST /users/ask-send-verify-email` | 3 | 5 minutes |
94 Depending on the endpoint, <sup>*</sup>failed requests are not taken into account. A service
95 limit is announced by a `429 Too Many Requests` status code.
97 You can get details about the current state of your rate limit by reading the
100 | Header | Description |
101 |-------------------------|------------------------------------------------------------|
102 | `X-RateLimit-Limit` | Number of max requests allowed in the current time period |
103 | `X-RateLimit-Remaining` | Number of remaining requests in the current time period |
104 | `X-RateLimit-Reset` | Timestamp of end of current time period as UNIX timestamp |
105 | `Retry-After` | Seconds to delay after the first `429` is received |
109 This API features [Cross-Origin Resource Sharing (CORS)](https://fetch.spec.whatwg.org/),
110 allowing cross-domain communication from the browser for some routes:
113 |------------------------- ---|
117 | `/live/segments-sha256/*` |
118 | `/.well-known/webfinger` |
120 In addition, all routes serving ActivityPub are CORS-enabled for all origins.
122 url: https://docs.joinpeertube.org/api-rest-reference.html
126 As a visitor, you can use this API to open an account (if registrations are open on
127 that PeerTube instance). As an admin, you should use the dedicated [User creation
128 API](#operation/createUser) instead.
130 x-displayName: Login/Logout
132 Sessions deal with access tokens over time. Only __one session token can currently be used at a time__.
135 Accounts encompass remote accounts discovered across the federation,
136 and correspond to the main Actor, along with video channels a user can create, which
139 When a comment is posted, it is done with your Account's Actor.
142 Using some features of PeerTube require authentication, for which User
143 provide different levels of permission as well as associated user
144 information. Each user has a corresponding local Account for federation.
147 Operations related to your own User, when logged-in.
148 - name: My Subscriptions
150 Operations related to your subscriptions to video channels, their
151 new videos, and how to keep up to date with their latest publications!
154 Operations related to your watch history.
155 - name: My Notifications
157 Notifications following new videos, follows or reports. They allow you
158 to keep track of the interactions and overall important information that
159 concerns you. You MAY set per-notification type delivery preference, to
160 receive the info either by mail, by in-browser notification or both.
163 Each server exposes public information regarding supported videos and
167 Jobs are long-running tasks enqueued and processed by the instance
168 itself. No additional worker registration is currently available.
169 - name: Instance Follows
171 Managing servers which the instance interacts with is crucial to the
172 concept of federation in PeerTube and external video indexation. The PeerTube
173 server then deals with inter-server ActivityPub operations and propagates
174 information across its social graph by posting activities to actors' inbox
177 url: https://docs.joinpeertube.org/admin-following-instances?id=instances-follows
178 - name: Instance Redundancy
180 Redundancy is part of the inter-server solidarity that PeerTube fosters.
181 Manage the list of instances you wish to help by seeding their videos according
182 to the policy of video selection of your choice. Note that you have a similar functionality
183 to mirror individual videos, see [video mirroring](#tag/Video-Mirroring).
185 url: https://docs.joinpeertube.org/admin-following-instances?id=instances-redundancy
188 Managing plugins installed from a local path or from NPM, or search for new ones.
190 url: https://docs.joinpeertube.org/api-plugins
193 Abuses deal with reports of local or remote videos/comments/accounts alike.
196 Operations dealing with listing, uploading, fetching or modifying videos.
199 Operations dealing with adding video or audio. PeerTube supports two upload modes, and three import modes.
203 - [_legacy_](#operation/uploadLegacy), where the video file is sent in a single request
204 - [_resumable_](#operation/uploadResumableInit), where the video file is sent in chunks
206 You can upload videos more reliably by using the resumable variant. Its protocol lets
207 you resume an upload operation after a network interruption or other transmission failure,
208 saving time and bandwidth in the event of network failures.
210 Favor using resumable uploads in any of the following cases:
211 - You are transferring large files
212 - The likelihood of a network interruption is high
213 - Uploads are originating from a device with a low-bandwidth or unstable Internet connection,
214 such as a mobile device
218 - _URL_-based: where the URL points to any service supported by [youtube-dl](https://ytdl-org.github.io/youtube-dl/)
219 - _magnet_-based: where the URI resolves to a BitTorrent ressource containing a single supported video file
220 - _torrent_-based: where the metainfo file resolves to a BitTorrent ressource containing a single supported video file
222 The import function is practical when the desired video/audio is available online. It makes PeerTube
223 download it for you, saving you as much bandwidth and avoiding any instability or limitation your network might have.
224 - name: Video Captions
225 description: Operations dealing with listing, adding and removing closed captions of a video.
226 - name: Video Channels
227 description: Operations dealing with the creation, modification and listing of videos within a channel.
228 - name: Video Comments
230 Operations dealing with comments to a video. Comments are organized in threads: adding a
231 comment in response to the video starts a thread, adding a reply to a comment adds it to
232 its root comment thread.
234 description: Operations dealing with blocking videos (removing them from view and preventing interactions).
236 description: Like/dislike a video.
237 - name: Video Playlists
238 description: Operations dealing with playlists of videos. Playlists are bound to users and/or channels.
240 description: Server syndication feeds
243 The search helps to find _videos_ or _channels_ from within the instance and beyond.
244 Videos from other instances federated by the instance (that is, instances
245 followed by the instance) can be found via keywords and other criteria of
248 Administrators can also enable the use of a remote search system, indexing
249 videos and channels not could be not federated by the instance.
250 - name: Video Mirroring
252 PeerTube instances can mirror videos from one another, and help distribute some videos.
254 For importing videos as your own, refer to [video imports](#operation/importVideo).
277 - Video Ownership Change
290 - name: Instance Configuration
294 - Instance Redundancy
304 summary: Get an account
306 - $ref: '#/components/parameters/name'
309 description: successful operation
313 $ref: '#/components/schemas/Account'
315 description: account not found
316 '/accounts/{name}/videos':
321 summary: 'List videos of an account'
323 - $ref: '#/components/parameters/name'
324 - $ref: '#/components/parameters/categoryOneOf'
325 - $ref: '#/components/parameters/isLive'
326 - $ref: '#/components/parameters/tagsOneOf'
327 - $ref: '#/components/parameters/tagsAllOf'
328 - $ref: '#/components/parameters/licenceOneOf'
329 - $ref: '#/components/parameters/languageOneOf'
330 - $ref: '#/components/parameters/nsfw'
331 - $ref: '#/components/parameters/filter'
332 - $ref: '#/components/parameters/skipCount'
333 - $ref: '#/components/parameters/start'
334 - $ref: '#/components/parameters/count'
335 - $ref: '#/components/parameters/videosSort'
338 description: successful operation
342 $ref: '#/components/schemas/VideoListResponse'
346 fetch('https://peertube2.cpy.re/api/v1/accounts/{name}/videos')
347 .then(function(response) {
348 return response.json()
349 }).then(function(data) {
355 curl -s https://peertube2.cpy.re/api/v1/accounts/{name}/videos | jq
361 uri = URI.parse("https://peertube2.cpy.re/api/v1/accounts/{name}/videos")
363 http = Net::HTTP.new(uri.host, uri.port)
366 response = http.get(uri.request_uri)
368 puts JSON.parse(response.read_body)
373 r = requests.get("https://peertube2.cpy.re/api/v1//accounts/{name}/videos")
381 summary: List accounts
383 - $ref: '#/components/parameters/start'
384 - $ref: '#/components/parameters/count'
385 - $ref: '#/components/parameters/sort'
388 description: successful operation
394 $ref: '#/components/schemas/Account'
399 summary: Get instance public configuration
402 description: successful operation
406 $ref: '#/components/schemas/ServerConfig'
409 externalValue: https://peertube2.cpy.re/api/v1/config
412 summary: Get instance "About" information
417 description: successful operation
421 $ref: '#/components/schemas/ServerConfigAbout'
424 externalValue: https://peertube2.cpy.re/api/v1/config/about
427 summary: Get instance runtime configuration
435 description: successful operation
439 $ref: '#/components/schemas/ServerConfigCustom'
441 summary: Set instance runtime configuration
449 description: successful operation
451 x-summary: field inconsistencies
454 - the emailer is disabled and the instance is open to registrations
455 - webtorrent and hls are disabled with transcoding enabled - you need at least one enabled
457 summary: Delete instance runtime configuration
465 description: successful operation
468 summary: List instance jobs
478 description: The state of the job ('' for for no filter)
488 - $ref: '#/components/parameters/jobType'
489 - $ref: '#/components/parameters/start'
490 - $ref: '#/components/parameters/count'
491 - $ref: '#/components/parameters/sort'
494 description: successful operation
507 $ref: '#/components/schemas/Job'
513 summary: List instances following the server
515 - $ref: '#/components/parameters/followState'
516 - $ref: '#/components/parameters/actorType'
517 - $ref: '#/components/parameters/start'
518 - $ref: '#/components/parameters/count'
519 - $ref: '#/components/parameters/sort'
522 description: successful operation
534 $ref: '#/components/schemas/Follow'
535 '/server/followers/{nameWithHost}':
537 summary: Remove or reject a follower to your server
547 description: The remote actor handle to remove from your followers
553 description: successful operation
555 description: follower not found
556 '/server/followers/{nameWithHost}/reject':
558 summary: Reject a pending follower to your server
568 description: The remote actor handle to remove from your followers
574 description: successful operation
576 description: follower not found
577 '/server/followers/{nameWithHost}/accept':
579 summary: Accept a pending follower to your server
589 description: The remote actor handle to remove from your followers
595 description: successful operation
597 description: follower not found
603 summary: List instances followed by the server
605 - $ref: '#/components/parameters/followState'
606 - $ref: '#/components/parameters/actorType'
607 - $ref: '#/components/parameters/start'
608 - $ref: '#/components/parameters/count'
609 - $ref: '#/components/parameters/sort'
612 description: successful operation
624 $ref: '#/components/schemas/Follow'
631 summary: Follow a list of servers
634 description: successful operation
636 description: cannot follow a non-HTTPS server
649 '/server/following/{host}':
651 summary: Unfollow a server
661 description: The host to unfollow
667 description: successful operation
669 description: host not found
673 summary: Create a user
674 operationId: createUser
682 description: user created
686 $ref: '#/components/schemas/AddUserResponse'
690 operationId: getUserId
692 id: '$response.body#/user/id'
695 operationId: putUserId
697 id: '$response.body#/user/id'
700 operationId: delUserId
702 id: '$response.body#/user/id'
704 description: insufficient authority to create an admin or moderator
709 $ref: '#/components/schemas/AddUser'
711 If the smtp server is configured, you can leave the password empty and an email will be sent
712 asking the user to set it first.
722 - $ref: '#/components/parameters/usersSearch'
723 - $ref: '#/components/parameters/usersBlocked'
724 - $ref: '#/components/parameters/start'
725 - $ref: '#/components/parameters/count'
726 - $ref: '#/components/parameters/usersSort'
729 description: successful operation
735 $ref: '#/components/schemas/User'
738 - $ref: '#/components/parameters/id'
740 summary: Delete a user
746 operationId: delUserId
749 description: successful operation
756 operationId: getUserId
760 description: include statistics about the user (only available as a moderator/admin)
765 x-summary: successful operation
767 As an admin/moderator, you can request a response augmented with statistics about the user's
768 moderation relations and videos usage, by using the `withStats` parameter.
773 - $ref: '#/components/schemas/User'
774 - $ref: '#/components/schemas/UserWithStats'
776 summary: Update a user
781 operationId: putUserId
784 description: successful operation
789 $ref: '#/components/schemas/UpdateUser'
792 /oauth-clients/local:
794 summary: Login prerequisite
795 description: You need to retrieve a client id and secret before [logging in](#operation/getOauthToken).
796 operationId: getOAuthClient
801 description: successful operation
805 $ref: '#/components/schemas/OAuthClient'
807 UseOAuthClientToLogin:
808 operationId: getOAuthToken
810 client_id: '$response.body#/client_id'
811 client_secret: '$response.body#/client_secret'
815 operationId: getOAuthToken
816 description: With your [client id and secret](#operation/getOAuthClient), you can retrieve an access and refresh tokens.
821 application/x-www-form-urlencoded:
824 - $ref: '#/components/schemas/OAuthToken-password'
825 - $ref: '#/components/schemas/OAuthToken-refresh_token'
827 propertyName: grant_type
829 password: '#/components/schemas/OAuthToken-password'
830 refresh_token: '#/components/schemas/OAuthToken-refresh_token'
833 description: successful operation
844 example: 90286a0bdf0f7315d9d3fe8dabf9e1d2be9c97d0
845 description: valid for 1 day
848 example: 2e0d675df9fc96d2e4ec8a3ebbbf45eca9137bb7
849 description: valid for 2 weeks
854 refresh_token_expires_in:
861 description: Revokes your access token and its associated refresh token, destroying your current session.
862 operationId: revokeOAuthToken
869 description: successful operation
873 summary: Register a user
879 description: successful operation
884 $ref: '#/components/schemas/RegisterUser'
886 /users/{id}/verify-email:
888 summary: Verify a user
890 Following a user registration, the new user will receive an email asking to click a link
896 - $ref: '#/components/parameters/id'
912 description: successful operation
914 description: invalid verification string
916 description: user not found
917 /users/ask-send-verify-email:
919 summary: Resend user verification link
925 description: successful operation
929 summary: Get my user information
937 description: successful operation
943 $ref: '#/components/schemas/User'
945 summary: Update my user information
953 description: successful operation
958 $ref: '#/components/schemas/UpdateMe'
960 /users/me/videos/imports:
962 summary: Get video imports of my user
970 - $ref: '#/components/parameters/start'
971 - $ref: '#/components/parameters/count'
972 - $ref: '#/components/parameters/sort'
975 description: successful operation
979 $ref: '#/components/schemas/VideoImportsList'
980 /users/me/video-quota-used:
982 summary: Get my user used quota
990 description: successful operation
998 description: The user video quota used so far in bytes
1000 videoQuotaUsedDaily:
1002 description: The user video quota used today in bytes
1004 '/users/me/videos/{videoId}/rating':
1006 summary: Get rate of my user for a video
1016 description: The video id
1018 $ref: '#/components/schemas/Video/properties/id'
1021 description: successful operation
1025 $ref: '#/components/schemas/GetMeVideoRating'
1028 summary: Get videos of my user
1036 - $ref: '#/components/parameters/start'
1037 - $ref: '#/components/parameters/count'
1038 - $ref: '#/components/parameters/sort'
1041 description: successful operation
1045 $ref: '#/components/schemas/VideoListResponse'
1046 /users/me/subscriptions:
1048 summary: Get my user subscriptions
1055 - $ref: '#/components/parameters/start'
1056 - $ref: '#/components/parameters/count'
1057 - $ref: '#/components/parameters/sort'
1060 description: successful operation
1064 $ref: '#/components/schemas/VideoChannelList'
1068 summary: Add subscription to my user
1081 description: uri of the video channels to subscribe to
1087 uri: 008a0e54-375d-49d0-8379-143202e24152@video.lqdn.fr
1090 description: successful operation
1091 /users/me/subscriptions/exist:
1093 summary: Get if subscriptions exist for my user
1100 - $ref: '#/components/parameters/subscriptionsUris'
1103 description: successful operation
1108 /users/me/subscriptions/videos:
1110 summary: List videos of subscriptions of my user
1118 - $ref: '#/components/parameters/categoryOneOf'
1119 - $ref: '#/components/parameters/isLive'
1120 - $ref: '#/components/parameters/tagsOneOf'
1121 - $ref: '#/components/parameters/tagsAllOf'
1122 - $ref: '#/components/parameters/licenceOneOf'
1123 - $ref: '#/components/parameters/languageOneOf'
1124 - $ref: '#/components/parameters/nsfw'
1125 - $ref: '#/components/parameters/filter'
1126 - $ref: '#/components/parameters/skipCount'
1127 - $ref: '#/components/parameters/start'
1128 - $ref: '#/components/parameters/count'
1129 - $ref: '#/components/parameters/videosSort'
1132 description: successful operation
1136 $ref: '#/components/schemas/VideoListResponse'
1137 '/users/me/subscriptions/{subscriptionHandle}':
1139 summary: Get subscription of my user
1146 - $ref: '#/components/parameters/subscriptionHandle'
1149 description: successful operation
1153 $ref: '#/components/schemas/VideoChannel'
1155 summary: Delete subscription of my user
1162 - $ref: '#/components/parameters/subscriptionHandle'
1165 description: successful operation
1166 /users/me/notifications:
1168 summary: List my notifications
1176 description: only list unread notifications
1179 - $ref: '#/components/parameters/start'
1180 - $ref: '#/components/parameters/count'
1181 - $ref: '#/components/parameters/sort'
1184 description: successful operation
1188 $ref: '#/components/schemas/NotificationListResponse'
1189 /users/me/notifications/read:
1191 summary: Mark notifications as read by their id
1204 description: ids of the notifications to mark as read
1211 description: successful operation
1212 /users/me/notifications/read-all:
1214 summary: Mark all my notification as read
1221 description: successful operation
1222 /users/me/notification-settings:
1224 summary: Update my notification settings
1235 newVideoFromSubscription:
1236 $ref: '#/components/schemas/NotificationSettingValue'
1237 newCommentOnMyVideo:
1238 $ref: '#/components/schemas/NotificationSettingValue'
1240 $ref: '#/components/schemas/NotificationSettingValue'
1241 videoAutoBlacklistAsModerator:
1242 $ref: '#/components/schemas/NotificationSettingValue'
1244 $ref: '#/components/schemas/NotificationSettingValue'
1246 $ref: '#/components/schemas/NotificationSettingValue'
1247 myVideoImportFinished:
1248 $ref: '#/components/schemas/NotificationSettingValue'
1250 $ref: '#/components/schemas/NotificationSettingValue'
1251 newUserRegistration:
1252 $ref: '#/components/schemas/NotificationSettingValue'
1254 $ref: '#/components/schemas/NotificationSettingValue'
1255 newInstanceFollower:
1256 $ref: '#/components/schemas/NotificationSettingValue'
1257 autoInstanceFollowing:
1258 $ref: '#/components/schemas/NotificationSettingValue'
1261 description: successful operation
1262 /users/me/history/videos:
1264 summary: List watched videos history
1270 - $ref: '#/components/parameters/start'
1271 - $ref: '#/components/parameters/count'
1272 - $ref: '#/components/parameters/search'
1275 description: successful operation
1279 $ref: '#/components/schemas/VideoListResponse'
1280 /users/me/history/videos/remove:
1282 summary: Clear video history
1289 multipart/form-data:
1294 description: history before this date will be deleted
1299 description: successful operation
1300 /users/me/avatar/pick:
1302 summary: Update my user avatar
1309 description: successful operation
1316 $ref: '#/components/schemas/ActorImage'
1318 description: image file too large
1320 X-File-Maximum-Size:
1324 description: Maximum file size for the avatar
1327 multipart/form-data:
1332 description: The file to upload
1337 contentType: image/png, image/jpeg
1340 summary: Delete my avatar
1347 description: successful operation
1351 summary: List video ownership changes
1353 - Video Ownership Change
1358 description: successful operation
1359 '/videos/ownership/{id}/accept':
1361 summary: Accept ownership change request
1363 - Video Ownership Change
1367 - $ref: '#/components/parameters/idOrUUID'
1370 description: successful operation
1372 description: cannot terminate an ownership change of another user
1374 description: video owneship change not found
1375 '/videos/ownership/{id}/refuse':
1377 summary: Refuse ownership change request
1379 - Video Ownership Change
1383 - $ref: '#/components/parameters/idOrUUID'
1386 description: successful operation
1388 description: cannot terminate an ownership change of another user
1390 description: video owneship change not found
1391 '/videos/{id}/give-ownership':
1393 summary: Request ownership change
1395 - Video Ownership Change
1399 - $ref: '#/components/parameters/idOrUUID'
1403 application/x-www-form-urlencoded:
1413 description: successful operation
1415 description: changing video ownership to a remote account is not supported yet
1417 description: video not found
1420 summary: List videos
1424 - $ref: '#/components/parameters/categoryOneOf'
1425 - $ref: '#/components/parameters/isLive'
1426 - $ref: '#/components/parameters/tagsOneOf'
1427 - $ref: '#/components/parameters/tagsAllOf'
1428 - $ref: '#/components/parameters/licenceOneOf'
1429 - $ref: '#/components/parameters/languageOneOf'
1430 - $ref: '#/components/parameters/nsfw'
1431 - $ref: '#/components/parameters/filter'
1432 - $ref: '#/components/parameters/skipCount'
1433 - $ref: '#/components/parameters/start'
1434 - $ref: '#/components/parameters/count'
1435 - $ref: '#/components/parameters/videosSort'
1438 description: successful operation
1442 $ref: '#/components/schemas/VideoListResponse'
1445 summary: List available video categories
1446 operationId: getCategories
1451 description: successful operation
1460 externalValue: https://peertube2.cpy.re/api/v1/videos/categories
1463 summary: List available video licences
1464 operationId: getLicences
1469 description: successful operation
1478 externalValue: https://peertube2.cpy.re/api/v1/videos/licences
1481 summary: List available video languages
1482 operationId: getLanguages
1487 description: successful operation
1496 externalValue: https://peertube2.cpy.re/api/v1/videos/languages
1499 summary: List available video privacy policies
1500 operationId: getPrivacyPolicies
1505 description: successful operation
1514 externalValue: https://peertube2.cpy.re/api/v1/videos/privacies
1517 summary: Update a video
1523 - $ref: '#/components/parameters/idOrUUID'
1526 description: successful operation
1529 multipart/form-data:
1534 description: Video thumbnail file
1538 description: Video preview file
1542 $ref: '#/components/schemas/VideoCategorySet'
1544 $ref: '#/components/schemas/VideoLicenceSet'
1546 $ref: '#/components/schemas/VideoLanguageSet'
1548 $ref: '#/components/schemas/VideoPrivacySet'
1550 description: Video description
1553 description: Whether or not we wait transcoding before publish the video
1556 description: A text tell the audience how to support the video creator
1557 example: Please support our work on https://soutenir.framasoft.org/en/ <3
1560 description: Whether or not this video contains sensitive content
1563 description: Video name
1568 description: Video tags (maximum 5 tags each between 2 and 30 characters)
1577 description: Enable or disable comments for this video
1579 originallyPublishedAt:
1580 description: Date when the content was originally published
1584 $ref: '#/components/schemas/VideoScheduledUpdate'
1587 contentType: image/jpeg
1589 contentType: image/jpeg
1591 summary: Get a video
1595 - $ref: '#/components/parameters/idOrUUID'
1598 description: successful operation
1602 $ref: '#/components/schemas/VideoDetails'
1604 summary: Delete a video
1610 - $ref: '#/components/parameters/idOrUUID'
1613 description: successful operation
1614 '/videos/{id}/description':
1616 summary: Get complete video description
1620 - $ref: '#/components/parameters/idOrUUID'
1623 description: successful operation
1632 **[Want to help to translate this video?](https://weblate.framasoft.org/projects/what-is-peertube-video/)**\r\n\r\n**Take back the control of your videos! [#JoinPeertube](https://joinpeertube.org)**
1633 '/videos/{id}/views':
1635 summary: Add a view to a video
1639 - $ref: '#/components/parameters/idOrUUID'
1642 description: successful operation
1643 '/videos/{id}/watching':
1645 summary: Set watching progress of a video
1651 - $ref: '#/components/parameters/idOrUUID'
1656 $ref: '#/components/schemas/UserWatchingVideo'
1660 description: successful operation
1663 summary: Upload a video
1664 description: Uses a single request to upload a video.
1665 operationId: uploadLegacy
1673 description: successful operation
1677 $ref: '#/components/schemas/VideoUploadResponse'
1679 description: invalid file field, schedule date or parameter
1681 description: video didn't pass upload filter
1683 description: upload has timed out
1685 description: video file too large, due to quota or max body size limit set by the reverse-proxy
1687 X-File-Maximum-Size:
1691 description: Maximum file size for the video
1693 description: video type unsupported
1695 description: video unreadable
1698 multipart/form-data:
1700 $ref: '#/components/schemas/VideoUploadRequestLegacy'
1703 contentType: video/mp4, video/webm, video/ogg, video/avi, video/quicktime, video/x-msvideo, video/x-flv, video/x-matroska, application/octet-stream
1705 contentType: image/jpeg
1707 contentType: image/jpeg
1712 USERNAME="<your_username>"
1713 PASSWORD="<your_password>"
1714 FILE_PATH="<your_file_path>"
1715 CHANNEL_ID="<your_channel_id>"
1718 API_PATH="https://peertube2.cpy.re/api/v1"
1720 client_id=$(curl -s "$API_PATH/oauth-clients/local" | jq -r ".client_id")
1721 client_secret=$(curl -s "$API_PATH/oauth-clients/local" | jq -r ".client_secret")
1722 token=$(curl -s "$API_PATH/users/token" \
1723 --data client_id="$client_id" \
1724 --data client_secret="$client_secret" \
1725 --data grant_type=password \
1726 --data response_type=code \
1727 --data username="$USERNAME" \
1728 --data password="$PASSWORD" \
1729 | jq -r ".access_token")
1731 curl -s "$API_PATH/videos/upload" \
1732 -H "Authorization: Bearer $token" \
1734 --form videofile=@"$FILE_PATH" \
1735 --form channelId=$CHANNEL_ID \
1737 /videos/upload-resumable:
1739 summary: Initialize the resumable upload of a video
1740 description: Uses [a resumable protocol](https://github.com/kukhariev/node-uploadx/blob/master/proto.md) to initialize the upload of a video
1741 operationId: uploadResumableInit
1748 - name: X-Upload-Content-Length
1754 description: Number of bytes that will be uploaded in subsequent requests. Set this value to the size of the file you are uploading.
1755 - name: X-Upload-Content-Type
1762 description: MIME type of the file that you are uploading. Depending on your instance settings, acceptable values might vary.
1767 $ref: '#/components/schemas/VideoUploadRequestResumable'
1770 description: file already exists, send a [`resume`](https://github.com/kukhariev/node-uploadx/blob/master/proto.md) request instead
1772 description: created
1778 example: /api/v1/videos/upload-resumable?upload_id=471e97554f21dec3b8bb5d4602939c51
1784 description: invalid file field, schedule date or parameter
1786 description: video file too large, due to quota, absolute max file size or concurrent partial upload limit
1788 description: video type unsupported
1790 summary: Send chunk for the resumable upload of a video
1791 description: Uses [a resumable protocol](https://github.com/kukhariev/node-uploadx/blob/master/proto.md) to continue, pause or resume the upload of a video
1792 operationId: uploadResumable
1803 Created session id to proceed with. If you didn't send chunks in the last 12 hours, it is
1804 not valid anymore and you need to initialize a new upload.
1807 - name: Content-Range
1811 example: bytes 0-262143/2469036
1814 Specifies the bytes in the file that the request is uploading.
1816 For example, a value of `bytes 0-262143/1000000` shows that the request is sending the first
1817 262144 bytes (256 x 1024) in a 2,469,036 byte file.
1818 - name: Content-Length
1825 Size of the chunk that the request is sending.
1827 The chunk size __must be a multiple of 256 KB__, and unlike [Google Resumable](https://developers.google.com/youtube/v3/guides/using_resumable_upload_protocol)
1828 doesn't mandate for chunks to have the same size throughout the upload sequence.
1830 Remember that larger chunks are more efficient. PeerTube's web client uses chunks varying from
1831 1048576 bytes (~1MB) and increases or reduces size depending on connection health.
1834 application/octet-stream:
1840 description: last chunk received
1848 $ref: '#/components/schemas/VideoUploadResponse'
1850 description: resume incomplete
1855 example: bytes=0-262143
1861 description: video didn't pass upload filter
1863 description: video file too large, due to quota or max body size limit set by the reverse-proxy
1865 description: video unreadable
1867 summary: Cancel the resumable upload of a video, deleting any data uploaded so far
1868 description: Uses [a resumable protocol](https://github.com/kukhariev/node-uploadx/blob/master/proto.md) to cancel the upload of a video
1869 operationId: uploadResumableCancel
1880 Created session id to proceed with. If you didn't send chunks in the last 12 hours, it is
1881 not valid anymore and the upload session has already been deleted with its data ;-)
1884 - name: Content-Length
1892 description: upload cancelled
1900 summary: Import a video
1901 description: Import a torrent or magnetURI or HTTP resource (if enabled by the instance administrator)
1902 operationId: importVideo
1910 multipart/form-data:
1912 $ref: '#/components/schemas/VideoCreateImport'
1915 contentType: application/x-bittorrent
1917 contentType: image/jpeg
1919 contentType: image/jpeg
1922 description: successful operation
1926 $ref: '#/components/schemas/VideoUploadResponse'
1928 description: '`magnetUri` or `targetUrl` or a torrent file missing'
1930 description: video didn't pass pre-import filter
1932 description: HTTP or Torrent/magnetURI import not enabled
1936 summary: Create a live
1937 operationId: createLive
1945 description: successful operation
1949 $ref: '#/components/schemas/VideoUploadResponse'
1951 description: live is not enabled, allow replay is not enabled, or max instance/user live videos limit is exceeded
1954 multipart/form-data:
1959 description: Channel id that will contain this live video
1964 description: User can stream multiple times in a permanent live
1967 description: Live video/replay thumbnail file
1971 description: Live video/replay preview file
1975 $ref: '#/components/schemas/VideoPrivacySet'
1977 $ref: '#/components/schemas/VideoCategorySet'
1979 $ref: '#/components/schemas/VideoLicenceSet'
1981 $ref: '#/components/schemas/VideoLanguageSet'
1983 description: Live video/replay description
1986 description: A text tell the audience how to support the creator
1987 example: Please support our work on https://soutenir.framasoft.org/en/ <3
1990 description: Whether or not this live video/replay contains sensitive content
1993 description: Live video/replay name
1998 description: Live video/replay tags (maximum 5 tags each between 2 and 30 characters)
2007 description: Enable or disable comments for this live video/replay
2010 description: Enable or disable downloading for the replay of this live
2017 contentType: image/jpeg
2019 contentType: image/jpeg
2023 summary: Get information about a live
2024 operationId: getLiveId
2031 - $ref: '#/components/parameters/idOrUUID'
2034 description: successful operation
2038 $ref: '#/components/schemas/LiveVideoResponse'
2040 summary: Update information about a live
2041 operationId: updateLiveId
2048 - $ref: '#/components/parameters/idOrUUID'
2053 $ref: '#/components/schemas/LiveVideoUpdate'
2056 description: successful operation
2058 description: bad parameters or trying to update a live that has already started
2060 description: trying to save replay of the live but saving replay is not enabled on the instance
2064 summary: List my abuses
2065 operationId: getMyAbuses
2074 description: only list the report with this id
2080 $ref: '#/components/schemas/AbuseStateSet'
2081 - $ref: '#/components/parameters/abusesSort'
2082 - $ref: '#/components/parameters/start'
2083 - $ref: '#/components/parameters/count'
2086 description: successful operation
2098 $ref: '#/components/schemas/Abuse'
2102 summary: List abuses
2103 operationId: getAbuses
2113 description: only list the report with this id
2116 - name: predefinedReason
2118 description: predefined reason the listed reports should contain
2120 $ref: '#/components/schemas/PredefinedAbuseReasons'
2123 description: plain search that will match with video titles, reporter names and more
2129 $ref: '#/components/schemas/AbuseStateSet'
2130 - name: searchReporter
2132 description: only list reports of a specific reporter
2135 - name: searchReportee
2136 description: only list reports of a specific reportee
2142 description: only list reports of a specific video
2145 - name: searchVideoChannel
2147 description: only list reports of a specific video channel
2152 description: only list blacklisted or deleted videos
2160 description: only list account, comment or video reports
2167 - $ref: '#/components/parameters/start'
2168 - $ref: '#/components/parameters/count'
2169 - $ref: '#/components/parameters/abusesSort'
2172 description: successful operation
2184 $ref: '#/components/schemas/Abuse'
2187 summary: Report an abuse
2200 description: Reason why the user reports this video
2205 $ref: '#/components/schemas/PredefinedAbuseReasons'
2210 description: Video id to report
2212 - $ref: '#/components/schemas/Video/properties/id'
2216 description: Timestamp in the video that marks the beginning of the report
2221 description: Timestamp in the video that marks the ending of the report
2227 description: Comment id to report
2229 - $ref: '#/components/schemas/VideoComment/properties/id'
2234 description: Account id to report
2240 description: successful operation
2242 description: incorrect request parameters
2243 '/abuses/{abuseId}':
2245 summary: Update an abuse
2253 - $ref: '#/components/parameters/abuseId'
2261 $ref: '#/components/schemas/AbuseStateSet'
2264 description: Update the report comment visible only to the moderation team
2269 description: successful operation
2271 description: abuse not found
2275 summary: Delete an abuse
2281 - $ref: '#/components/parameters/abuseId'
2284 description: successful operation
2286 description: block not found
2287 '/abuses/{abuseId}/messages':
2289 summary: List messages of an abuse
2295 - $ref: '#/components/parameters/abuseId'
2298 description: successful operation
2304 $ref: '#/components/schemas/AbuseMessage'
2307 summary: Add message to an abuse
2313 - $ref: '#/components/parameters/abuseId'
2322 description: Message to send
2330 description: successful operation
2332 description: incorrect request parameters
2333 '/abuses/{abuseId}/messages/{abuseMessageId}':
2335 summary: Delete an abuse message
2341 - $ref: '#/components/parameters/abuseId'
2342 - $ref: '#/components/parameters/abuseMessageId'
2345 description: successful operation
2347 '/videos/{id}/blacklist':
2349 summary: Block a video
2357 - $ref: '#/components/parameters/idOrUUID'
2360 description: successful operation
2362 summary: Unblock a video by its id
2370 - $ref: '#/components/parameters/idOrUUID'
2373 description: successful operation
2375 description: block not found
2380 summary: List video blocks
2389 list only blocks that match this type:
2393 - `2`: automatic block that needs review
2401 description: plain search that will match with video titles, and more
2404 - $ref: '#/components/parameters/start'
2405 - $ref: '#/components/parameters/count'
2406 - $ref: '#/components/parameters/blacklistsSort'
2409 description: successful operation
2421 $ref: '#/components/schemas/VideoBlacklist'
2422 /videos/{id}/captions:
2424 summary: List captions of a video
2428 - $ref: '#/components/parameters/idOrUUID'
2431 description: successful operation
2443 $ref: '#/components/schemas/VideoCaption'
2444 /videos/{id}/captions/{captionLanguage}:
2446 summary: Add or replace a video caption
2453 - $ref: '#/components/parameters/idOrUUID'
2454 - $ref: '#/components/parameters/captionLanguage'
2457 multipart/form-data:
2462 description: The file to upload.
2467 contentType: text/vtt, application/x-subrip, text/plain
2470 description: successful operation
2472 description: video or language not found
2474 summary: Delete a video caption
2481 - $ref: '#/components/parameters/idOrUUID'
2482 - $ref: '#/components/parameters/captionLanguage'
2485 description: successful operation
2487 description: video or language or caption for that language not found
2490 summary: List video channels
2491 operationId: getVideoChannels
2495 - $ref: '#/components/parameters/start'
2496 - $ref: '#/components/parameters/count'
2497 - $ref: '#/components/parameters/sort'
2500 description: successful operation
2504 $ref: '#/components/schemas/VideoChannelList'
2506 summary: Create a video channel
2507 operationId: createVideoChannel
2514 description: successful operation
2524 $ref: '#/components/schemas/VideoChannel/properties/id'
2529 $ref: '#/components/schemas/VideoChannelCreate'
2530 '/video-channels/{channelHandle}':
2532 summary: Get a video channel
2533 operationId: getVideoChannel
2537 - $ref: '#/components/parameters/channelHandle'
2540 description: successful operation
2544 $ref: '#/components/schemas/VideoChannel'
2546 summary: Update a video channel
2552 - $ref: '#/components/parameters/channelHandle'
2555 description: successful operation
2560 $ref: '#/components/schemas/VideoChannelUpdate'
2562 summary: Delete a video channel
2568 - $ref: '#/components/parameters/channelHandle'
2571 description: successful operation
2572 '/video-channels/{channelHandle}/videos':
2574 summary: List videos of a video channel
2579 - $ref: '#/components/parameters/channelHandle'
2580 - $ref: '#/components/parameters/categoryOneOf'
2581 - $ref: '#/components/parameters/isLive'
2582 - $ref: '#/components/parameters/tagsOneOf'
2583 - $ref: '#/components/parameters/tagsAllOf'
2584 - $ref: '#/components/parameters/licenceOneOf'
2585 - $ref: '#/components/parameters/languageOneOf'
2586 - $ref: '#/components/parameters/nsfw'
2587 - $ref: '#/components/parameters/filter'
2588 - $ref: '#/components/parameters/skipCount'
2589 - $ref: '#/components/parameters/start'
2590 - $ref: '#/components/parameters/count'
2591 - $ref: '#/components/parameters/videosSort'
2594 description: successful operation
2598 $ref: '#/components/schemas/VideoListResponse'
2599 '/video-channels/{channelHandle}/avatar/pick':
2601 summary: Update channel avatar
2607 - $ref: '#/components/parameters/channelHandle'
2610 description: successful operation
2617 $ref: '#/components/schemas/ActorImage'
2619 description: image file too large
2621 X-File-Maximum-Size:
2625 description: Maximum file size for the avatar
2628 multipart/form-data:
2633 description: The file to upload.
2638 contentType: image/png, image/jpeg
2639 '/video-channels/{channelHandle}/avatar':
2641 summary: Delete channel avatar
2647 - $ref: '#/components/parameters/channelHandle'
2650 description: successful operation
2653 '/video-channels/{channelHandle}/banner/pick':
2655 summary: Update channel banner
2661 - $ref: '#/components/parameters/channelHandle'
2664 description: successful operation
2671 $ref: '#/components/schemas/ActorImage'
2673 description: image file too large
2675 X-File-Maximum-Size:
2679 description: Maximum file size for the banner
2682 multipart/form-data:
2687 description: The file to upload.
2692 contentType: image/png, image/jpeg
2693 '/video-channels/{channelHandle}/banner':
2695 summary: Delete channel banner
2701 - $ref: '#/components/parameters/channelHandle'
2704 description: successful operation
2706 /video-playlists/privacies:
2708 summary: List available playlist privacy policies
2709 operationId: getPlaylistPrivacyPolicies
2714 description: successful operation
2723 externalValue: https://peertube2.cpy.re/api/v1/video-playlists/privacies
2727 summary: List video playlists
2728 operationId: getPlaylists
2732 - $ref: '#/components/parameters/start'
2733 - $ref: '#/components/parameters/count'
2734 - $ref: '#/components/parameters/sort'
2737 description: successful operation
2749 $ref: '#/components/schemas/VideoPlaylist'
2751 summary: Create a video playlist
2752 description: If the video playlist is set as public, `videoChannelId` is mandatory.
2753 operationId: createPlaylist
2760 description: successful operation
2770 $ref: '#/components/schemas/VideoPlaylist/properties/id'
2772 $ref: '#/components/schemas/VideoPlaylist/properties/uuid'
2775 multipart/form-data:
2780 description: Video playlist display name
2785 description: Video playlist thumbnail file
2789 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
2791 description: Video playlist description
2797 - $ref: '#/components/schemas/id'
2798 description: Video channel in which the playlist will be published
2803 contentType: image/jpeg
2805 /video-playlists/{playlistId}:
2807 summary: Get a video playlist
2811 - $ref: '#/components/parameters/playlistId'
2814 description: successful operation
2818 $ref: '#/components/schemas/VideoPlaylist'
2820 summary: Update a video playlist
2821 description: 'If the video playlist is set as public, the playlist must have a assigned channel.'
2828 description: successful operation
2830 - $ref: '#/components/parameters/playlistId'
2833 multipart/form-data:
2838 description: Video playlist display name
2843 description: Video playlist thumbnail file
2847 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
2849 description: Video playlist description
2853 - $ref: '#/components/schemas/id'
2854 description: Video channel in which the playlist will be published
2857 contentType: image/jpeg
2859 summary: Delete a video playlist
2865 - $ref: '#/components/parameters/playlistId'
2868 description: successful operation
2870 /video-playlists/{playlistId}/videos:
2872 summary: 'List videos of a playlist'
2877 - $ref: '#/components/parameters/playlistId'
2880 description: successful operation
2884 $ref: '#/components/schemas/VideoListResponse'
2886 summary: Add a video in a playlist
2893 - $ref: '#/components/parameters/playlistId'
2896 description: successful operation
2902 videoPlaylistElement:
2916 - $ref: '#/components/schemas/Video/properties/uuid'
2917 - $ref: '#/components/schemas/Video/properties/id'
2918 description: Video to add in the playlist
2922 description: Start the video at this specific timestamp
2926 description: Stop the video at this specific timestamp
2930 /video-playlists/{playlistId}/videos/reorder:
2932 summary: 'Reorder a playlist'
2938 - $ref: '#/components/parameters/playlistId'
2941 description: successful operation
2950 description: 'Start position of the element to reorder'
2952 insertAfterPosition:
2954 description: 'New position for the block to reorder, to add the block before the first element'
2958 description: 'How many element from `startPosition` to reorder'
2962 - insertAfterPosition
2964 /video-playlists/{playlistId}/videos/{playlistElementId}:
2966 summary: Update a playlist element
2972 - $ref: '#/components/parameters/playlistId'
2973 - $ref: '#/components/parameters/playlistElementId'
2976 description: successful operation
2986 description: Start the video at this specific timestamp
2990 description: Stop the video at this specific timestamp
2992 summary: Delete an element from a playlist
2998 - $ref: '#/components/parameters/playlistId'
2999 - $ref: '#/components/parameters/playlistElementId'
3002 description: successful operation
3004 '/users/me/video-playlists/videos-exist':
3006 summary: Check video exists in my playlists
3015 description: The video ids to check
3019 $ref: '#/components/schemas/Video/properties/id'
3022 description: successful operation
3044 '/accounts/{name}/video-channels':
3046 summary: List video channels of an account
3051 - $ref: '#/components/parameters/name'
3054 description: include view statistics for the last 30 days (only if authentified as the account user)
3057 - $ref: '#/components/parameters/start'
3058 - $ref: '#/components/parameters/count'
3059 - $ref: '#/components/parameters/sort'
3062 description: successful operation
3066 $ref: '#/components/schemas/VideoChannelList'
3067 '/accounts/{name}/ratings':
3069 summary: List ratings of an account
3075 - $ref: '#/components/parameters/name'
3076 - $ref: '#/components/parameters/start'
3077 - $ref: '#/components/parameters/count'
3078 - $ref: '#/components/parameters/sort'
3082 description: Optionally filter which ratings to retrieve
3090 description: successful operation
3096 $ref: '#/components/schemas/VideoRating'
3097 '/videos/{id}/comment-threads':
3099 summary: List threads of a video
3103 - $ref: '#/components/parameters/idOrUUID'
3104 - $ref: '#/components/parameters/start'
3105 - $ref: '#/components/parameters/count'
3106 - $ref: '#/components/parameters/commentsSort'
3109 description: successful operation
3113 $ref: '#/components/schemas/CommentThreadResponse'
3115 summary: Create a thread
3121 - $ref: '#/components/parameters/idOrUUID'
3124 description: successful operation
3128 $ref: '#/components/schemas/CommentThreadPostResponse'
3130 description: video does not exist
3139 - $ref: '#/components/schemas/VideoComment/properties/text'
3145 '/videos/{id}/comment-threads/{threadId}':
3147 summary: Get a thread
3151 - $ref: '#/components/parameters/idOrUUID'
3152 - $ref: '#/components/parameters/threadId'
3155 description: successful operation
3159 $ref: '#/components/schemas/VideoCommentThreadTree'
3160 '/videos/{id}/comments/{commentId}':
3162 summary: Reply to a thread of a video
3168 - $ref: '#/components/parameters/idOrUUID'
3169 - $ref: '#/components/parameters/commentId'
3172 description: successful operation
3176 $ref: '#/components/schemas/CommentThreadPostResponse'
3178 description: thread or video does not exist
3187 - $ref: '#/components/schemas/VideoComment/properties/text'
3194 summary: Delete a comment or a reply
3200 - $ref: '#/components/parameters/idOrUUID'
3201 - $ref: '#/components/parameters/commentId'
3204 description: successful operation
3206 description: cannot remove comment of another user
3208 description: comment or video does not exist
3210 description: comment is already deleted
3211 '/videos/{id}/rate':
3213 summary: Like/dislike a video
3219 - $ref: '#/components/parameters/idOrUUID'
3235 description: successful operation
3237 description: video does not exist
3242 summary: Search videos
3247 allowEmptyValue: false
3249 String to search. If the user can make a remote URI search, and the string is an URI then the
3250 PeerTube instance will fetch the remote object and add it to its database. Then,
3251 you can use the REST API to fetch the complete video information and interact with it.
3254 - $ref: '#/components/parameters/categoryOneOf'
3255 - $ref: '#/components/parameters/isLive'
3256 - $ref: '#/components/parameters/tagsOneOf'
3257 - $ref: '#/components/parameters/tagsAllOf'
3258 - $ref: '#/components/parameters/licenceOneOf'
3259 - $ref: '#/components/parameters/languageOneOf'
3260 - $ref: '#/components/parameters/nsfw'
3261 - $ref: '#/components/parameters/filter'
3262 - $ref: '#/components/parameters/skipCount'
3263 - $ref: '#/components/parameters/start'
3264 - $ref: '#/components/parameters/count'
3265 - $ref: '#/components/parameters/searchTarget'
3266 - $ref: '#/components/parameters/videosSearchSort'
3269 description: Get videos that are published after this date
3275 description: Get videos that are published before this date
3279 - name: originallyPublishedStartDate
3281 description: Get videos that are originally published after this date
3285 - name: originallyPublishedEndDate
3287 description: Get videos that are originally published before this date
3293 description: Get videos that have this minimum duration
3298 description: Get videos that have this maximum duration
3302 'searchTarget === search-index':
3303 $ref: '#/components/callbacks/searchIndex'
3306 description: successful operation
3310 $ref: '#/components/schemas/VideoListResponse'
3312 description: search index unavailable
3313 /search/video-channels:
3317 summary: Search channels
3323 String to search. If the user can make a remote URI search, and the string is an URI then the
3324 PeerTube instance will fetch the remote object and add it to its database. Then,
3325 you can use the REST API to fetch the complete channel information and interact with it.
3328 - $ref: '#/components/parameters/start'
3329 - $ref: '#/components/parameters/count'
3330 - $ref: '#/components/parameters/searchTarget'
3331 - $ref: '#/components/parameters/sort'
3333 'searchTarget === search-index':
3334 $ref: '#/components/callbacks/searchIndex'
3337 description: successful operation
3341 $ref: '#/components/schemas/VideoChannelList'
3343 description: search index unavailable
3345 /server/blocklist/accounts:
3349 summary: List account blocks
3354 - $ref: '#/components/parameters/start'
3355 - $ref: '#/components/parameters/count'
3356 - $ref: '#/components/parameters/sort'
3359 description: successful operation
3363 summary: Block an account
3375 example: chocobozzz@example.org
3376 description: account to block, in the form `username@domain`
3381 description: successful operation
3383 description: self-blocking forbidden
3384 '/server/blocklist/accounts/{accountName}':
3388 summary: Unblock an account by its handle
3396 description: account to unblock, in the form `username@domain`
3401 description: successful operation
3403 description: account or account block does not exist
3405 /server/blocklist/servers:
3409 summary: List server blocks
3414 - $ref: '#/components/parameters/start'
3415 - $ref: '#/components/parameters/count'
3416 - $ref: '#/components/parameters/sort'
3419 description: successful operation
3423 summary: Block a server
3436 description: server domain to block
3441 description: successful operation
3443 description: self-blocking forbidden
3444 '/server/blocklist/servers/{host}':
3448 summary: Unblock a server by its domain
3456 description: server domain to unblock
3462 description: successful operation
3464 description: account block does not exist
3466 /server/redundancy/{host}:
3469 - Instance Redundancy
3470 summary: Update a server redundancy policy
3478 description: server domain to mirror
3490 description: allow mirroring of the host's local videos
3495 description: successful operation
3497 description: server is not already known
3498 /server/redundancy/videos:
3502 summary: List videos being mirrored
3510 description: direction of the mirror
3516 - $ref: '#/components/parameters/start'
3517 - $ref: '#/components/parameters/count'
3518 - $ref: '#/components/parameters/videoRedundanciesSort'
3521 description: successful operation
3527 $ref: '#/components/schemas/VideoRedundancy'
3531 summary: Mirror a video
3542 $ref: '#/components/schemas/Video/properties/id'
3547 description: successful operation
3549 description: cannot mirror a local video
3551 description: video does not exist
3553 description: video is already mirrored
3554 /server/redundancy/videos/{redundancyId}:
3558 summary: Delete a mirror done on a video
3563 - name: redundancyId
3566 description: id of an existing redundancy on a video
3571 description: successful operation
3573 description: video redundancy not found
3575 '/feeds/video-comments.{format}':
3579 summary: List comments on videos
3584 description: 'format expected (we focus on making `rss` the most featureful ; it serves [Media RSS](https://www.rssboard.org/media-rss))'
3597 description: 'limit listing to a specific video'
3602 description: 'limit listing to a specific account'
3607 description: 'limit listing to a specific account'
3610 - name: videoChannelId
3612 description: 'limit listing to a specific video channel'
3615 - name: videoChannelName
3617 description: 'limit listing to a specific video channel'
3622 description: successful operation
3627 default: 'max-age=900' # 15 min cache
3631 $ref: '#/components/schemas/VideoCommentsForXML'
3634 externalValue: https://peertube2.cpy.re/feeds/video-comments.xml?filter=local
3635 application/rss+xml:
3637 $ref: '#/components/schemas/VideoCommentsForXML'
3640 externalValue: https://peertube2.cpy.re/feeds/video-comments.rss?filter=local
3643 $ref: '#/components/schemas/VideoCommentsForXML'
3646 externalValue: https://peertube2.cpy.re/feeds/video-comments.xml?filter=local
3647 application/atom+xml:
3649 $ref: '#/components/schemas/VideoCommentsForXML'
3652 externalValue: https://peertube2.cpy.re/feeds/video-comments.atom?filter=local
3658 externalValue: https://peertube2.cpy.re/feeds/video-comments.json?filter=local
3660 x-summary: field inconsistencies
3663 - videoId filter is mixed with a channel filter
3665 description: video, video channel or account not found
3667 description: accept header unsupported
3668 '/feeds/videos.{format}':
3672 summary: List videos
3677 description: 'format expected (we focus on making `rss` the most featureful ; it serves [Media RSS](https://www.rssboard.org/media-rss))'
3690 description: 'limit listing to a specific account'
3695 description: 'limit listing to a specific account'
3698 - name: videoChannelId
3700 description: 'limit listing to a specific video channel'
3703 - name: videoChannelName
3705 description: 'limit listing to a specific video channel'
3708 - $ref: '#/components/parameters/sort'
3709 - $ref: '#/components/parameters/nsfw'
3710 - $ref: '#/components/parameters/filter'
3713 description: successful operation
3718 default: 'max-age=900' # 15 min cache
3722 $ref: '#/components/schemas/VideosForXML'
3725 externalValue: https://peertube2.cpy.re/feeds/videos.xml?filter=local
3726 application/rss+xml:
3728 $ref: '#/components/schemas/VideosForXML'
3731 externalValue: https://peertube2.cpy.re/feeds/videos.rss?filter=local
3734 $ref: '#/components/schemas/VideosForXML'
3737 externalValue: https://peertube2.cpy.re/feeds/videos.xml?filter=local
3738 application/atom+xml:
3740 $ref: '#/components/schemas/VideosForXML'
3743 externalValue: https://peertube2.cpy.re/feeds/videos.atom?filter=local
3749 externalValue: https://peertube2.cpy.re/feeds/videos.json?filter=local
3751 description: video channel or account not found
3753 description: accept header unsupported
3754 '/feeds/subscriptions.{format}':
3759 summary: List videos of subscriptions tied to a token
3764 description: 'format expected (we focus on making `rss` the most featureful ; it serves [Media RSS](https://www.rssboard.org/media-rss))'
3777 description: limit listing to a specific account
3783 description: private token allowing access
3787 - $ref: '#/components/parameters/sort'
3788 - $ref: '#/components/parameters/nsfw'
3789 - $ref: '#/components/parameters/filter'
3792 description: successful operation
3797 default: 'max-age=900' # 15 min cache
3801 $ref: '#/components/schemas/VideosForXML'
3802 application/rss+xml:
3804 $ref: '#/components/schemas/VideosForXML'
3807 $ref: '#/components/schemas/VideosForXML'
3808 application/atom+xml:
3810 $ref: '#/components/schemas/VideosForXML'
3815 description: accept header unsupported
3820 summary: List plugins
3833 - $ref: '#/components/parameters/start'
3834 - $ref: '#/components/parameters/count'
3835 - $ref: '#/components/parameters/sort'
3838 description: successful operation
3842 $ref: '#/components/schemas/PluginResponse'
3847 summary: List available plugins
3860 - name: currentPeerTubeEngine
3864 - $ref: '#/components/parameters/start'
3865 - $ref: '#/components/parameters/count'
3866 - $ref: '#/components/parameters/sort'
3869 description: successful operation
3873 $ref: '#/components/schemas/PluginResponse'
3875 description: plugin index unavailable
3880 summary: Install a plugin
3893 example: peertube-plugin-auth-ldap
3896 additionalProperties: false
3903 additionalProperties: false
3906 description: successful operation
3908 description: should have either `npmName` or `path` set
3913 summary: Update a plugin
3926 example: peertube-plugin-auth-ldap
3929 additionalProperties: false
3936 additionalProperties: false
3939 description: successful operation
3941 description: should have either `npmName` or `path` set
3943 description: existing plugin not found
3948 summary: Uninstall a plugin
3960 description: name of the plugin/theme in its package.json
3961 example: peertube-plugin-auth-ldap
3966 description: successful operation
3968 description: existing plugin not found
3973 summary: Get a plugin
3978 - $ref: '#/components/parameters/npmName'
3981 description: successful operation
3985 $ref: '#/components/schemas/Plugin'
3987 description: plugin not found
3988 /plugins/{npmName}/settings:
3992 summary: Set a plugin's settings
3997 - $ref: '#/components/parameters/npmName'
4006 additionalProperties: true
4009 description: successful operation
4011 description: plugin not found
4012 /plugins/{npmName}/public-settings:
4016 summary: Get a plugin's public settings
4018 - $ref: '#/components/parameters/npmName'
4021 description: successful operation
4026 additionalProperties: true
4028 description: plugin not found
4029 /plugins/{npmName}/registered-settings:
4033 summary: Get a plugin's registered settings
4038 - $ref: '#/components/parameters/npmName'
4041 description: successful operation
4046 additionalProperties: true
4048 description: plugin not found
4050 - url: 'https://peertube2.cpy.re/api/v1'
4051 description: Live Test Server (live data - latest nightly version)
4052 - url: 'https://peertube3.cpy.re/api/v1'
4053 description: Live Test Server (live data - latest RC version)
4054 - url: 'https://peertube.cpy.re/api/v1'
4055 description: Live Test Server (live data - stable version)
4062 description: Offset used to paginate results
4070 description: "Number of items to return"
4080 description: Sort column
4088 description: Plain text search, applied to various parts of the model depending on endpoint
4096 If the administrator enabled search index support, you can override the default search target.
4099 **Warning**: If you choose to make an index search, PeerTube will get results from a third party service.
4100 It means the instance may not yet know the objects you fetched. If you want to load video/channel information:
4101 * If the current user has the ability to make a remote URI search (this information is available in the config endpoint),
4102 then reuse the search API to make a search using the object URI so PeerTube instance fetches the remote object and fill its database.
4103 After that, you can use the classic REST API endpoints to fetch the complete object or interact with it
4104 * If the current user doesn't have the ability to make a remote URI search, then redirect the user on the origin instance or fetch
4105 the data from the origin instance API
4115 description: Sort videos by criteria
4131 description: Sort videos by criteria
4146 description: Sort comments by criteria
4156 description: Sort blacklists by criteria
4172 description: Plain text search that will match with user usernames or emails
4179 description: Filter results down to (un)banned users
4186 description: Sort users by criteria
4197 description: Sort abuses by criteria
4204 videoRedundanciesSort:
4208 description: Sort abuses by criteria
4217 description: The username or handle of the account
4220 example: chocobozzz | chocobozzz@example.org
4225 description: The user id
4227 $ref: '#/components/schemas/id'
4232 description: The object id or uuid
4235 - $ref: '#/components/schemas/id'
4236 - $ref: '#/components/schemas/UUIDv4'
4241 description: Playlist id
4243 $ref: '#/components/schemas/VideoPlaylist/properties/id'
4245 name: playlistElementId
4248 description: Playlist element id
4250 $ref: '#/components/schemas/id'
4255 description: Abuse id
4257 $ref: '#/components/schemas/Abuse/properties/id'
4259 name: abuseMessageId
4262 description: Abuse message id
4264 $ref: '#/components/schemas/AbuseMessage/properties/id'
4266 name: captionLanguage
4269 description: The caption language
4271 $ref: '#/components/schemas/VideoLanguageSet'
4276 description: The video channel handle
4279 example: my_username | my_username@example.com
4281 name: subscriptionHandle
4284 description: The subscription handle
4287 example: my_username | my_username@example.com
4292 description: The thread id (root comment id)
4294 $ref: '#/components/schemas/VideoCommentThreadTree/properties/comment/properties/id'
4299 description: The comment id
4301 $ref: '#/components/schemas/VideoComment/properties/id'
4306 description: whether or not the video is a live
4313 description: category id of the video (see [/videos/categories](#operation/getCategories))
4316 - $ref: '#/components/schemas/VideoCategorySet'
4319 $ref: '#/components/schemas/VideoCategorySet'
4326 description: tag(s) of the video
4340 description: tag(s) of the video, where all should be present in the video
4353 description: language id of the video (see [/videos/languages](#operation/getLanguages)). Use `_unknown` to filter on videos that don't have a video language
4356 - $ref: '#/components/schemas/VideoLanguageSet'
4359 $ref: '#/components/schemas/VideoLanguageSet'
4366 description: licence id of the video (see [/videos/licences](#operation/getLicences))
4369 - $ref: '#/components/schemas/VideoLicenceSet'
4372 $ref: '#/components/schemas/VideoLicenceSet'
4379 description: if you don't need the `total` in the response
4390 description: whether to include nsfw videos, if any
4401 Special filters which might require special rights:
4402 * `local` - only videos local to the instance
4403 * `all-local` - only videos local to the instance, but showing private and unlisted videos (requires Admin privileges)
4404 * `all` - all videos, showing private and unlisted videos (requires Admin privileges)
4414 description: list of uris to check if each is part of the user subscriptions
4424 description: name of the plugin/theme on npmjs.com or in its package.json
4427 example: peertube-plugin-auth-ldap
4432 description: job type
4436 - activitypub-follow
4437 - activitypub-http-broadcast
4438 - activitypub-http-fetcher
4439 - activitypub-http-unicast
4445 - activitypub-refresher
4470 Authenticating via OAuth requires the following steps:
4471 - Have an activated account
4472 - [Generate] an access token for that account at `/api/v1/users/token`.
4473 - Make requests with the *Authorization: Bearer <token\>* header
4474 - Profit, depending on the role assigned to the account
4476 Note that the __access token is valid for 1 day__ and is given
4477 along with a __refresh token valid for 2 weeks__.
4479 [Generate]: https://docs.joinpeertube.org/api-rest-getting-started
4483 tokenUrl: /api/v1/users/token
4486 moderator: Moderator scope
4489 # Resuable core properties
4497 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4498 pattern: '^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$'
4503 description: immutable name of the user, used to find or mention its actor
4505 pattern: '/^[a-z0-9._]+$/'
4510 description: immutable name of the channel, used to interact with its actor
4511 example: framasoft_videos
4512 pattern: '/^[a-zA-Z0-9\\-_.:]+$/'
4523 description: category id of the video (see [/videos/categories](#operation/getCategories))
4525 VideoConstantNumber-Category:
4528 $ref: '#/components/schemas/VideoCategorySet'
4531 example: Science & Technology
4535 description: licence id of the video (see [/videos/licences](#operation/getLicences))
4537 VideoConstantNumber-Licence:
4540 $ref: '#/components/schemas/VideoLicenceSet'
4543 example: Attribution - Share Alike
4547 description: language id of the video (see [/videos/languages](#operation/getLanguages))
4549 VideoConstantString-Language:
4552 $ref: '#/components/schemas/VideoLanguageSet'
4557 VideoPlaylistPrivacySet:
4563 description: Video playlist privacy policy (see [/video-playlists/privacies])
4564 VideoPlaylistPrivacyConstant:
4567 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
4571 VideoPlaylistTypeSet:
4576 description: The video playlist type (Regular = `1`, Watch Later = `2`)
4577 VideoPlaylistTypeConstant:
4580 $ref: '#/components/schemas/VideoPlaylistTypeSet'
4591 description: privacy id of the video (see [/videos/privacies](#operation/getPrivacyPolicies))
4592 VideoPrivacyConstant:
4595 $ref: '#/components/schemas/VideoPrivacySet'
4612 description: 'The user role (Admin = `0`, Moderator = `1`, User = `2`)'
4619 description: 'Admin flags for the user (None = `0`, Bypass video blacklist = `1`)'
4630 description: 'The video state (Published = `1`, to transcode = `2`, to import = `3`)'
4640 description: 'The abuse state (Pending = `1`, Rejected = `2`, Accepted = `3`)'
4644 $ref: '#/components/schemas/AbuseStateSet'
4647 AbusePredefinedReasons:
4660 example: [spamOrMisleading]
4665 Video resolution (`0`, `240`, `360`, `720`, `1080`, `1440` or `2160`)
4667 `0` is used as a special value for stillimage videos dedicated to audio, a.k.a. audio-only videos.
4669 VideoResolutionConstant:
4670 description: resolutions and their labels for the video
4673 $ref: '#/components/schemas/VideoResolutionSet'
4677 VideoScheduledUpdate:
4680 $ref: '#/components/schemas/VideoPrivacySet'
4684 description: When to update the video
4704 - $ref: '#/components/schemas/ActorImage'
4705 VideoChannelSummary:
4708 $ref: '#/components/schemas/id'
4722 - $ref: '#/components/schemas/ActorImage'
4736 - $ref: '#/components/schemas/Video'
4743 description: magnet URI allowing to resolve the video via BitTorrent without a metainfo file
4744 example: magnet:?xs=https%3A%2F%2Fframatube.org%2Fstatic%2Ftorrents%2F9c9de5e8-0a1e-484a-b099-e80766180a6d-240.torrent&xt=urn:btih:38b4747ff788b30bf61f59d1965cd38f9e48e01f&dn=What+is+PeerTube%3F&tr=wss%3A%2F%2Fframatube.org%2Ftracker%2Fsocket&tr=https%3A%2F%2Fframatube.org%2Ftracker%2Fannounce&ws=https%3A%2F%2Fframatube.org%2Fstatic%2Fwebseed%2F9c9de5e8-0a1e-484a-b099-e80766180a6d-240.mp4
4745 pattern: /magnet:\?xt=urn:[a-z0-9]+:[a-z0-9]{32}/i
4747 $ref: '#/components/schemas/VideoResolutionConstant'
4750 description: Video file size in bytes
4753 description: Direct URL of the torrent file
4757 description: URL endpoint that transfers the torrent file as an attachment (so that the browser opens a download dialog)
4761 description: Direct URL of the video
4765 description: URL endpoint that transfers the video file as an attachment (so that the browser opens a download dialog)
4769 description: Frames per second of the video file
4773 description: URL dereferencing the output of ffprobe on the file
4774 VideoStreamingPlaylists:
4779 $ref: '#/components/schemas/id'
4787 - $ref: '#/components/schemas/VideoStreamingPlaylists-HLS'
4788 VideoStreamingPlaylists-HLS:
4799 Video files associated to this playlist.
4801 The difference with the root `files` property is that these files are fragmented, so they can be used in this streaming playlist (HLS, etc.)
4803 $ref: '#/components/schemas/VideoFile'
4815 $ref: '#/components/schemas/Video/properties/id'
4817 $ref: '#/components/schemas/Video/properties/uuid'
4819 $ref: '#/components/schemas/Video/properties/name'
4823 description: object id for the video
4825 - $ref: '#/components/schemas/id'
4827 description: universal identifier for the video, that can be used across instances
4829 - $ref: '#/components/schemas/UUIDv4'
4835 example: 2017-10-01T10:52:46.396Z
4836 description: time at which the video object was first drafted
4840 example: 2018-10-01T10:52:46.396Z
4841 description: time at which the video was marked as ready for playback (with restrictions depending on `privacy`). Usually set after a `state` evolution.
4845 example: 2021-05-04T08:01:01.502Z
4846 description: last time the video's metadata was modified
4847 originallyPublishedAt:
4850 example: 2010-10-01T10:52:46.396Z
4851 description: used to represent a date of first publication, prior to the practical publication date of `publishedAt`
4854 - $ref: '#/components/schemas/VideoConstantNumber-Category'
4855 description: category in which the video is classified
4858 - $ref: '#/components/schemas/VideoConstantNumber-Licence'
4859 description: licence under which the video is distributed
4862 - $ref: '#/components/schemas/VideoConstantString-Language'
4863 description: main language used in the video
4866 - $ref: '#/components/schemas/VideoPrivacyConstant'
4867 description: privacy policy used to distribute the video
4871 **[Want to help to translate this video?](https://weblate.framasoft.org/projects/what-is-peertube-video/)**\r\n\r\n
4872 **Take back the control of your videos! [#JoinPeertube](https://joinpeertube.org)**\r\n*A decentralized video hosting network, based on fr...
4876 truncated description of the video, written in Markdown.
4877 Resolve `descriptionPath` to get the full description of maximum `10000` characters.
4882 description: duration of the video in seconds
4887 description: title of the video
4888 example: What is PeerTube?
4893 example: /static/thumbnails/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg
4896 example: /lazy-static/previews/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg
4899 example: /videos/embed/a65bc12f-9383-462e-81ae-8207e8b434ee
4916 - $ref: '#/components/schemas/VideoStateConstant'
4917 description: represents the internal state of the video processing within the PeerTube instance
4921 - $ref: '#/components/schemas/VideoScheduledUpdate'
4929 $ref: '#/components/schemas/AccountSummary'
4931 $ref: '#/components/schemas/VideoChannelSummary'
4940 - $ref: '#/components/schemas/Video'
4945 example: /api/v1/videos/9c9de5e8-0a1e-484a-b099-e80766180a6d/description
4946 description: path at which to get the full description of maximum `10000` characters
4949 description: A text tell the audience how to support the video creator
4950 example: Please support our work on https://soutenir.framasoft.org/en/ <3
4954 $ref: '#/components/schemas/VideoChannel'
4956 $ref: '#/components/schemas/Account'
4958 example: [flowers, gardening]
4976 - https://peertube2.cpy.re/tracker/announce
4977 - wss://peertube2.cpy.re/tracker/socket
4981 $ref: '#/components/schemas/VideoFile'
4983 WebTorrent/raw video files. If WebTorrent is disabled on the server:
4985 - field will be empty
4986 - video files will be found in `streamingPlaylists[].files` field
4990 $ref: '#/components/schemas/VideoStreamingPlaylists'
4992 HLS playlists/manifest files. If HLS is disabled on the server:
4994 - field will be empty
4995 - video files will be found in `files` field
4996 FileRedundancyInformation:
4999 $ref: '#/components/schemas/id'
5024 $ref: '#/components/schemas/id'
5031 $ref: '#/components/schemas/UUIDv4'
5038 $ref: '#/components/schemas/FileRedundancyInformation'
5042 $ref: '#/components/schemas/FileRedundancyInformation'
5043 VideoImportStateConstant:
5051 description: 'The video import state (Pending = `1`, Success = `2`, Failed = `3`)'
5058 additionalProperties: false
5062 $ref: '#/components/schemas/VideoImport/properties/targetUrl'
5063 required: [targetUrl]
5066 $ref: '#/components/schemas/VideoImport/properties/magnetUri'
5067 required: [magnetUri]
5070 $ref: '#/components/schemas/VideoImport/properties/torrentfile'
5071 required: [torrentfile]
5072 - $ref: '#/components/schemas/VideoUploadRequestCommon'
5081 - $ref: '#/components/schemas/id'
5085 description: remote URL where to find the import's source video
5086 example: https://framatube.org/videos/watch/9c9de5e8-0a1e-484a-b099-e80766180a6d
5090 description: magnet URI allowing to resolve the import's source video
5091 example: magnet:?xs=https%3A%2F%2Fframatube.org%2Fstatic%2Ftorrents%2F9c9de5e8-0a1e-484a-b099-e80766180a6d-240.torrent&xt=urn:btih:38b4747ff788b30bf61f59d1965cd38f9e48e01f&dn=What+is+PeerTube%3F&tr=wss%3A%2F%2Fframatube.org%2Ftracker%2Fsocket&tr=https%3A%2F%2Fframatube.org%2Ftracker%2Fannounce&ws=https%3A%2F%2Fframatube.org%2Fstatic%2Fwebseed%2F9c9de5e8-0a1e-484a-b099-e80766180a6d-240.mp4
5092 pattern: /magnet:\?xt=urn:[a-z0-9]+:[a-z0-9]{32}/i
5097 description: Torrent file containing only the video file
5104 - $ref: '#/components/schemas/VideoImportStateConstant'
5120 - $ref: '#/components/schemas/Video'
5130 $ref: '#/components/schemas/VideoImport'
5134 $ref: '#/components/schemas/id'
5137 example: The video is a spam
5141 $ref: '#/components/schemas/AbusePredefinedReasons'
5143 $ref: '#/components/schemas/Account'
5145 $ref: '#/components/schemas/AbuseStateConstant'
5148 example: Decided to ban the server since it spams us regularly
5152 $ref: '#/components/schemas/VideoInfo'
5159 $ref: '#/components/schemas/id'
5170 $ref: '#/components/schemas/AccountSummary'
5174 $ref: '#/components/schemas/id'
5176 $ref: '#/components/schemas/Video/properties/id'
5188 $ref: '#/components/schemas/UUIDv4'
5206 $ref: '#/components/schemas/id'
5208 $ref: '#/components/schemas/UUIDv4'
5231 $ref: '#/components/schemas/VideoPlaylistPrivacyConstant'
5233 $ref: '#/components/schemas/VideoPlaylistTypeConstant'
5235 $ref: '#/components/schemas/AccountSummary'
5237 $ref: '#/components/schemas/VideoChannelSummary'
5241 $ref: '#/components/schemas/id'
5248 description: Text of the comment
5250 example: This video is wonderful!
5252 $ref: '#/components/schemas/id'
5256 - $ref: '#/components/schemas/id'
5258 $ref: '#/components/schemas/Video/properties/id'
5273 totalRepliesFromVideoAuthor:
5280 $ref: '#/components/schemas/Account'
5281 VideoCommentThreadTree:
5284 $ref: '#/components/schemas/VideoComment'
5288 $ref: '#/components/schemas/VideoCommentThreadTree'
5292 $ref: '#/components/schemas/VideoConstantString-Language'
5308 $ref: '#/components/schemas/id'
5325 $ref: '#/components/schemas/id'
5330 description: immutable name of the actor, used to find or mention it
5332 - $ref: '#/components/schemas/username'
5336 description: server on which the actor is resident
5337 hostRedundancyAllowed:
5339 description: whether this actor's host allows redundancy of its videos
5343 description: number of actors subscribed to by this actor, as seen by this instance
5347 description: number of followers of this actor, as seen by this instance
5355 $ref: '#/components/schemas/ActorImage'
5358 - $ref: '#/components/schemas/Actor'
5361 description: object id for the user tied to this account
5363 - $ref: '#/components/schemas/User/properties/id'
5366 description: editable name of the account, displayed in its representations
5371 description: text or bio displayed on the account's profile
5377 description: timestamp within the video, in seconds
5444 allowedForCurrentIP:
5446 requiresEmailVerification:
5464 $ref: '#/components/schemas/VideoResolutionSet'
5549 example: 16810141515
5652 requiresEmailVerification:
5667 description: Settings that apply to new users, if registration is enabled
5671 example: 16810141515
5677 description: Settings pertaining to transcoding jobs
5681 allowAdditionalExtensions:
5683 description: Allow your users to upload .mkv, .mov, .avi, .wmv, .flv, .f4v, .3g2, .3gp, .mts, m2ts, .mxf, .nut videos
5686 description: If a user uploads an audio file, PeerTube will create a video by merging the preview file and the audio file
5689 description: Amount of threads used by ffmpeg for 1 transcoding job
5692 description: Amount of transcoding jobs to execute in parallel
5698 New profiles can be added by plugins ; available in core PeerTube: 'default'.
5701 description: Resolutions to transcode _new videos_ to
5721 description: WebTorrent-specific settings
5727 description: HLS-specific settings
5771 $ref: '#/components/schemas/id'
5773 $ref: '#/components/schemas/Actor'
5775 $ref: '#/components/schemas/Actor'
5778 description: score reflecting the reachability of the actor, with steps of `10` and a base score of `1000`.
5791 PredefinedAbuseReasons:
5792 description: Reason categories that help triage reports
5810 $ref: '#/components/schemas/id'
5822 - activitypub-http-unicast
5823 - activitypub-http-broadcast
5824 - activitypub-http-fetcher
5825 - activitypub-follow
5831 - activitypub-refresher
5835 additionalProperties: true
5838 additionalProperties: true
5854 $ref: '#/components/schemas/id'
5859 $ref: '#/components/schemas/id'
5860 VideoUploadRequestCommon:
5863 description: Video name
5865 example: What is PeerTube?
5869 description: Channel id that will contain this video
5874 $ref: '#/components/schemas/VideoPrivacySet'
5876 $ref: '#/components/schemas/VideoCategorySet'
5878 $ref: '#/components/schemas/VideoLicenceSet'
5880 $ref: '#/components/schemas/VideoLanguageSet'
5882 description: Video description
5885 **[Want to help to translate this video?](https://weblate.framasoft.org/projects/what-is-peertube-video/)**\r\n\r\n**Take back the control of your videos! [#JoinPeertube](https://joinpeertube.org)**
5887 description: Whether or not we wait transcoding before publish the video
5890 description: A text tell the audience how to support the video creator
5891 example: Please support our work on https://soutenir.framasoft.org/en/ <3
5894 description: Whether or not this video contains sensitive content
5897 description: Video tags (maximum 5 tags each between 2 and 30 characters)
5910 description: Enable or disable comments for this video
5913 description: Enable or disable downloading for this video
5915 originallyPublishedAt:
5916 description: Date when the content was originally published
5920 $ref: '#/components/schemas/VideoScheduledUpdate'
5922 description: Video thumbnail file
5926 description: Video preview file
5932 VideoUploadRequestLegacy:
5934 - $ref: '#/components/schemas/VideoUploadRequestCommon'
5940 description: Video file
5943 VideoUploadRequestResumable:
5945 - $ref: '#/components/schemas/VideoUploadRequestCommon'
5951 description: Video filename including extension
5954 example: what_is_peertube.mp4
5956 description: Video thumbnail file
5960 description: Video preview file
5963 VideoUploadResponse:
5969 $ref: '#/components/schemas/Video/properties/id'
5971 $ref: '#/components/schemas/Video/properties/uuid'
5972 CommentThreadResponse:
5981 $ref: '#/components/schemas/VideoComment'
5982 CommentThreadPostResponse:
5985 $ref: '#/components/schemas/VideoComment'
5995 $ref: '#/components/schemas/Video'
5999 $ref: '#/components/schemas/Account'
6002 description: Automatically start playing the upcoming video after the currently playing video
6003 autoPlayNextVideoPlaylist:
6005 description: Automatically start playing the video on the playlist after the currently playing video
6008 description: Automatically start playing the video on the watch page
6018 description: The user email
6021 description: Has the user confirmed their email address?
6024 - $ref: '#/components/schemas/id'
6028 description: Auth plugin to use to authenticate the user
6032 noInstanceConfigWarningModal:
6037 $ref: '#/components/schemas/NSFWPolicy'
6039 $ref: '#/components/schemas/UserRole'
6048 description: Theme enabled by this user
6050 $ref: '#/components/schemas/username'
6054 $ref: '#/components/schemas/VideoChannel'
6057 description: The user video quota in bytes
6061 description: The user daily video quota in bytes
6065 description: Enable P2P in the player
6068 - $ref: '#/components/schemas/User'
6070 # optionally present fields: they require WITH_STATS scope
6073 description: Count of videos published
6076 description: Count of reports/abuses of which the user is a target
6077 abusesAcceptedCount:
6079 description: Count of reports/abuses created by the user and accepted/acted upon by the moderation team
6082 description: Count of reports/abuses created by the user
6085 description: Count of comments published
6089 $ref: '#/components/schemas/username'
6091 $ref: '#/components/schemas/password'
6095 description: The user email
6098 description: The user video quota in bytes
6102 description: The user daily video quota in bytes
6105 $ref: '#/components/schemas/usernameChannel'
6107 $ref: '#/components/schemas/UserRole'
6109 $ref: '#/components/schemas/UserAdminFlags'
6120 description: The updated email of the user
6122 - $ref: '#/components/schemas/User/properties/email'
6125 description: Set the email as verified
6128 description: The updated video quota of the user in bytes
6131 description: The updated daily video quota of the user in bytes
6135 description: The auth plugin to use to authenticate the user
6136 example: 'peertube-plugin-auth-saml2'
6138 $ref: '#/components/schemas/UserRole'
6140 $ref: '#/components/schemas/UserAdminFlags'
6142 # see shared/models/users/user-update-me.model.ts:
6145 $ref: '#/components/schemas/password'
6147 $ref: '#/components/schemas/password'
6149 description: new email used for login and service communications
6151 - $ref: '#/components/schemas/User/properties/email'
6154 description: new name of the user in its representations
6159 description: new NSFW display policy
6166 description: whether to enable P2P in the player or not
6169 description: new preference regarding playing videos automatically
6172 description: new preference regarding playing following videos automatically
6173 autoPlayNextVideoPlaylist:
6175 description: new preference regarding playing following playlist videos automatically
6176 videosHistoryEnabled:
6178 description: whether to keep track of watched history or not
6183 description: list of languages to filter videos down to
6186 noInstanceConfigWarningModal:
6193 $ref: '#/components/schemas/id'
6200 description: Rating of the video
6207 $ref: '#/components/schemas/Video'
6214 description: Rating of the video
6221 description: immutable name of the user, used to find or mention its actor
6223 - $ref: '#/components/schemas/username'
6225 $ref: '#/components/schemas/password'
6229 description: email of the user, used for login or service communications
6232 description: editable name of the user, displayed in its representations
6237 description: channel base information used to create the first channel of the user
6240 $ref: '#/components/schemas/usernameChannel'
6242 $ref: '#/components/schemas/VideoChannel/properties/displayName'
6252 pattern: /^[a-z0-9]$/
6255 example: v1ikx5hnfop4mdpnci8nsqh93c45rldf
6258 pattern: /^[a-zA-Z0-9]$/
6261 example: AjWiOapPltI6EnsWQwlFarRtLh4u8tDt
6262 OAuthToken-password:
6264 - $ref: '#/components/schemas/OAuthClient'
6274 $ref: '#/components/schemas/User/properties/username'
6276 $ref: '#/components/schemas/password'
6283 OAuthToken-refresh_token:
6285 - $ref: '#/components/schemas/OAuthClient'
6296 example: 2e0d675df9fc96d2e4ec8a3ebbbf45eca9137bb7
6305 # GET/POST/PUT properties
6308 description: editable name of the channel, displayed in its representations
6309 example: Videos of Framasoft
6314 example: Videos made with <3 by Framasoft
6319 description: text shown by default on all videos of this channel, to tell the audience how to support it
6320 example: Please support our work on https://soutenir.framasoft.org/en/ <3
6323 # GET-only properties
6327 - $ref: '#/components/schemas/id'
6343 $ref: '#/components/schemas/UUIDv4'
6346 - $ref: '#/components/schemas/VideoChannel'
6349 description: username of the channel to create
6351 - $ref: '#/components/schemas/usernameChannel'
6357 - $ref: '#/components/schemas/VideoChannel'
6359 bulkVideosSupportUpdate:
6361 description: Update the support field for all videos of this channel
6371 - $ref: '#/components/schemas/VideoChannel'
6372 - $ref: '#/components/schemas/Actor'
6377 name: 'media:peerLink'
6386 - application/x-bittorrent
6392 name: 'media:content'
6423 VideoCommentsForXML:
6458 description: video watch page URL
6461 description: video canonical URL
6465 description: video publication date
6468 description: video description
6471 description: video description
6474 description: publisher user name
6477 description: video category (MRSS)
6480 description: see [media:community](https://www.rssboard.org/media-rss#media-community) (MRSS)
6495 description: video embed path, relative to the canonical URL domain (MRSS)
6504 description: video watch path, relative to the canonical URL domain (MRSS)
6525 description: see [media:title](https://www.rssboard.org/media-rss#media-title) (MRSS). We only use `plain` titles.
6526 'media:description':
6533 description: see [media:rating](https://www.rssboard.org/media-rss#media-rating) (MRSS)
6536 description: main streamable file for the video
6546 - application/x-bittorrent
6555 description: list of streamable files for the video. see [media:peerLink](https://www.rssboard.org/media-rss#media-peerlink) and [media:content](https://www.rssboard.org/media-rss#media-content) or (MRSS)
6558 - $ref: '#/components/schemas/MRSSPeerLink'
6559 - $ref: '#/components/schemas/MRSSGroupContent'
6560 NotificationSettingValue:
6577 $ref: '#/components/schemas/id'
6581 Notification type, following the `UserNotificationType` enum:
6583 - `1` NEW_VIDEO_FROM_SUBSCRIPTION
6585 - `2` NEW_COMMENT_ON_MY_VIDEO
6587 - `3` NEW_ABUSE_FOR_MODERATORS
6589 - `4` BLACKLIST_ON_MY_VIDEO
6591 - `5` UNBLACKLIST_ON_MY_VIDEO
6593 - `6` MY_VIDEO_PUBLISHED
6595 - `7` MY_VIDEO_IMPORT_SUCCESS
6597 - `8` MY_VIDEO_IMPORT_ERROR
6599 - `9` NEW_USER_REGISTRATION
6603 - `11` COMMENT_MENTION
6605 - `12` VIDEO_AUTO_BLACKLIST_FOR_MODERATORS
6607 - `13` NEW_INSTANCE_FOLLOWER
6609 - `14` AUTO_INSTANCE_FOLLOWING
6615 - $ref: '#/components/schemas/VideoInfo'
6619 $ref: '#/components/schemas/ActorInfo'
6625 $ref: '#/components/schemas/id'
6628 $ref: '#/components/schemas/VideoInfo'
6633 $ref: '#/components/schemas/VideoImport/properties/magnetUri'
6643 $ref: '#/components/schemas/id'
6647 $ref: '#/components/schemas/VideoInfo'
6649 $ref: '#/components/schemas/ActorInfo'
6655 $ref: '#/components/schemas/id'
6658 - $ref: '#/components/schemas/VideoInfo'
6664 $ref: '#/components/schemas/id'
6667 - $ref: '#/components/schemas/VideoInfo'
6671 - $ref: '#/components/schemas/ActorInfo'
6677 $ref: '#/components/schemas/id'
6679 $ref: '#/components/schemas/ActorInfo'
6707 NotificationListResponse:
6716 $ref: '#/components/schemas/Notification'
6721 example: peertube-plugin-auth-ldap
6749 example: https://framagit.org/framasoft/peertube/official-plugins/tree/master/peertube-plugin-auth-ldap
6752 additionalProperties: true
6768 $ref: '#/components/schemas/Plugin'
6775 description: User can stream multiple times in a permanent live
6784 description: RTMP stream key to use to stream into this live video
6788 description: User can stream multiple times in a permanent live
6795 'https://search.example.org/api/v1/search/videos':
6797 summary: third-party search index MAY be used instead of the local index, if enabled by the instance admin. see `searchTarget`
6800 description: successful operation
6804 $ref: '#/components/schemas/VideoListResponse'