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
17 The PeerTube API is built on HTTP(S) and is RESTful. You can use your favorite
18 HTTP/REST library for your programming language to use PeerTube. The spec API is fully compatible with
19 [openapi-generator](https://github.com/OpenAPITools/openapi-generator/wiki/API-client-generator-HOWTO)
20 which generates a client SDK in the language of your choice - we generate some client SDKs automatically:
22 - [Python](https://framagit.org/framasoft/peertube/clients/python)
23 - [Go](https://framagit.org/framasoft/peertube/clients/go)
24 - [Kotlin](https://framagit.org/framasoft/peertube/clients/kotlin)
26 See the [Quick Start guide](https://docs.joinpeertube.org/api-rest-getting-started) so you can play with the PeerTube API.
30 When you sign up for an account, you are given the possibility to generate
31 sessions, and authenticate using this session token. One session token can
32 currently be used at a time.
36 Accounts are given permissions based on their role. There are three roles on
37 PeerTube: Administrator, Moderator, and User. See the [roles guide](https://docs.joinpeertube.org/admin-managing-users?id=roles) for a detail of their permissions.
41 The API uses standard HTTP status codes to indicate the success or failure
42 of the API call. The body of the response will be JSON in the following
47 "code": "unauthorized_request", // example inner error code
48 "error": "Token is invalid." // example exposed error message
52 url: https://docs.joinpeertube.org/api-rest-reference.html
56 Accounts encompass remote accounts discovered across the federation,
57 and correspond to the main Actor, along with video channels a user can create, which
60 When a comment is posted, it is done with your Account's Actor.
63 Using some features of PeerTube require authentication, for which User
64 provide different levels of permission as well as associated user
65 information. Each user has a corresponding local Account for federation.
68 Operations related to your own User, when logged-in.
69 - name: My Subscriptions
71 Operations related to your subscriptions to video channels, their
72 new videos, and how to keep up to date with their latest publications!
75 Operations related to your watch history.
76 - name: My Notifications
78 Notifications following new videos, follows or reports. They allow you
79 to keep track of the interactions and overall important information that
80 concerns you. You MAY set per-notification type delivery preference, to
81 receive the info either by mail, by in-browser notification or both.
84 Each server exposes public information regarding supported videos and
88 Jobs are long-running tasks enqueued and processed by the instance
89 itself. No additional worker registration is currently available.
90 - name: Instance Follows
92 Managing servers which the instance interacts with is crucial to the
93 concept of federation in PeerTube and external video indexation. The PeerTube
94 server then deals with inter-server ActivityPub operations and propagates
95 information across its social graph by posting activities to actors' inbox
98 url: https://docs.joinpeertube.org/admin-following-instances?id=instances-follows
99 - name: Instance Redundancy
101 Redundancy is part of the inter-server solidarity that PeerTube fosters.
102 Manage the list of instances you wish to help by seeding their videos according
103 to the policy of video selection of your choice. Note that you have a similar functionality
104 to mirror individual videos, see `Video Mirroring`.
106 url: https://docs.joinpeertube.org/admin-following-instances?id=instances-redundancy
109 Managing plugins installed from a local path or from NPM, or search for new ones.
111 url: https://docs.joinpeertube.org/api-plugins
114 Abuses deal with reports of local or remote videos/comments/accounts alike.
117 Operations dealing with listing, uploading, fetching or modifying videos.
120 The search helps to find _videos_ or _channels_ from within the instance and beyond.
121 Videos from other instances federated by the instance (that is, instances
122 followed by the instance) can be found via keywords and other criteria of
125 Administrators can also enable the use of a remote search system, indexing
126 videos and channels not could be not federated by the instance.
127 - name: Video Comments
129 Operations dealing with comments to a video. Comments are organized in
131 - name: Video Playlists
133 Operations dealing with playlists of videos. Playlists are bound to users
135 - name: Video Channels
137 Operations dealing with the creation, modification and listing of videos within a channel.
140 Operations dealing with blocking videos (removing them from view and
141 preventing interactions).
144 Like/dislike a video.
147 Server syndication feeds
165 - Video Ownership Change
178 - name: Instance Configuration
182 - Instance Redundancy
192 summary: Get an account
194 - $ref: '#/components/parameters/name'
197 description: successful operation
201 $ref: '#/components/schemas/Account'
203 description: account not found
204 '/accounts/{name}/videos':
209 summary: 'List videos of an account'
211 - $ref: '#/components/parameters/name'
212 - $ref: '#/components/parameters/categoryOneOf'
213 - $ref: '#/components/parameters/isLive'
214 - $ref: '#/components/parameters/tagsOneOf'
215 - $ref: '#/components/parameters/tagsAllOf'
216 - $ref: '#/components/parameters/licenceOneOf'
217 - $ref: '#/components/parameters/languageOneOf'
218 - $ref: '#/components/parameters/nsfw'
219 - $ref: '#/components/parameters/filter'
220 - $ref: '#/components/parameters/skipCount'
221 - $ref: '#/components/parameters/start'
222 - $ref: '#/components/parameters/count'
223 - $ref: '#/components/parameters/videosSort'
226 description: successful operation
230 $ref: '#/components/schemas/VideoListResponse'
234 fetch('https://peertube2.cpy.re/api/v1/accounts/{name}/videos')
235 .then(function(response) {
236 return response.json()
237 }).then(function(data) {
243 curl -s https://peertube2.cpy.re/api/v1/accounts/{name}/videos | jq
249 uri = URI.parse("https://peertube2.cpy.re/api/v1/accounts/{name}/videos")
251 http = Net::HTTP.new(uri.host, uri.port)
254 response = http.get(uri.request_uri)
256 puts JSON.parse(response.read_body)
261 r = requests.get("https://peertube2.cpy.re/api/v1//accounts/{name}/videos")
269 summary: List accounts
271 - $ref: '#/components/parameters/start'
272 - $ref: '#/components/parameters/count'
273 - $ref: '#/components/parameters/sort'
276 description: successful operation
282 $ref: '#/components/schemas/Account'
287 summary: Get instance public configuration
290 description: successful operation
294 $ref: '#/components/schemas/ServerConfig'
297 summary: Get instance "About" information
302 description: successful operation
306 $ref: '#/components/schemas/ServerConfigAbout'
309 summary: Get instance runtime configuration
317 description: successful operation
321 $ref: '#/components/schemas/ServerConfigCustom'
323 summary: Set instance runtime configuration
331 description: successful operation
333 x-summary: field inconsistencies
336 - the emailer is disabled and the instance is open to registrations
337 - webtorrent and hls are disabled with transcoding enabled - you need at least one enabled
339 summary: Delete instance runtime configuration
347 description: successful operation
350 summary: List instance jobs
360 description: The state of the job ('' for for no filter)
370 - $ref: '#/components/parameters/jobType'
371 - $ref: '#/components/parameters/start'
372 - $ref: '#/components/parameters/count'
373 - $ref: '#/components/parameters/sort'
376 description: successful operation
389 $ref: '#/components/schemas/Job'
390 '/server/following/{host}':
397 summary: Unfollow a server
402 description: 'The host to unfollow '
408 description: successful operation
413 summary: List instance followers
415 - $ref: '#/components/parameters/start'
416 - $ref: '#/components/parameters/count'
417 - $ref: '#/components/parameters/sort'
420 description: successful operation
426 $ref: '#/components/schemas/Follow'
431 summary: List instances followed by the server
450 - $ref: '#/components/parameters/start'
451 - $ref: '#/components/parameters/count'
452 - $ref: '#/components/parameters/sort'
455 description: successful operation
461 $ref: '#/components/schemas/Follow'
468 summary: Follow a server
471 description: successful operation
473 description: cannot follow a non-HTTPS server
488 summary: Create a user
496 description: user created
500 $ref: '#/components/schemas/AddUserResponse'
504 operationId: getUserId
506 id: '$response.body#/user/id'
509 operationId: putUserId
511 id: '$response.body#/user/id'
514 operationId: delUserId
516 id: '$response.body#/user/id'
518 description: insufficient authority to create an admin or moderator
523 $ref: '#/components/schemas/AddUser'
524 description: User to create
534 - $ref: '#/components/parameters/usersSearch'
535 - $ref: '#/components/parameters/usersBlocked'
536 - $ref: '#/components/parameters/start'
537 - $ref: '#/components/parameters/count'
538 - $ref: '#/components/parameters/usersSort'
541 description: successful operation
547 $ref: '#/components/schemas/User'
550 - $ref: '#/components/parameters/id'
552 summary: Delete a user
558 operationId: delUserId
561 description: successful operation
568 operationId: getUserId
571 description: successful operation
575 $ref: '#/components/schemas/User'
577 summary: Update a user
582 operationId: putUserId
585 description: successful operation
590 $ref: '#/components/schemas/UpdateUser'
594 summary: Register a user
599 description: successful operation
604 $ref: '#/components/schemas/RegisterUser'
608 summary: Get my user information
616 description: successful operation
622 $ref: '#/components/schemas/User'
624 summary: Update my user information
632 description: successful operation
637 $ref: '#/components/schemas/UpdateMe'
639 /users/me/videos/imports:
641 summary: Get video imports of my user
649 - $ref: '#/components/parameters/start'
650 - $ref: '#/components/parameters/count'
651 - $ref: '#/components/parameters/sort'
654 description: successful operation
658 $ref: '#/components/schemas/VideoImport'
659 /users/me/video-quota-used:
661 summary: Get my user used quota
669 description: successful operation
674 '/users/me/videos/{videoId}/rating':
676 summary: Get rate of my user for a video
686 description: 'The video id '
691 description: successful operation
695 $ref: '#/components/schemas/GetMeVideoRating'
698 summary: Get videos of my user
706 - $ref: '#/components/parameters/start'
707 - $ref: '#/components/parameters/count'
708 - $ref: '#/components/parameters/sort'
711 description: successful operation
715 $ref: '#/components/schemas/VideoListResponse'
716 /users/me/subscriptions:
718 summary: Get my user subscriptions
725 - $ref: '#/components/parameters/start'
726 - $ref: '#/components/parameters/count'
727 - $ref: '#/components/parameters/sort'
730 description: successful operation
734 summary: Add subscription to my user
747 description: uri of the video channels to subscribe to
753 uri: 008a0e54-375d-49d0-8379-143202e24152@video.lqdn.fr
756 description: successful operation
757 /users/me/subscriptions/exist:
759 summary: Get if subscriptions exist for my user
766 - $ref: '#/components/parameters/subscriptionsUris'
769 description: successful operation
774 /users/me/subscriptions/videos:
776 summary: List videos of subscriptions of my user
784 - $ref: '#/components/parameters/categoryOneOf'
785 - $ref: '#/components/parameters/isLive'
786 - $ref: '#/components/parameters/tagsOneOf'
787 - $ref: '#/components/parameters/tagsAllOf'
788 - $ref: '#/components/parameters/licenceOneOf'
789 - $ref: '#/components/parameters/languageOneOf'
790 - $ref: '#/components/parameters/nsfw'
791 - $ref: '#/components/parameters/filter'
792 - $ref: '#/components/parameters/skipCount'
793 - $ref: '#/components/parameters/start'
794 - $ref: '#/components/parameters/count'
795 - $ref: '#/components/parameters/videosSort'
798 description: successful operation
802 $ref: '#/components/schemas/VideoListResponse'
803 '/users/me/subscriptions/{subscriptionHandle}':
805 summary: Get subscription of my user
812 - $ref: '#/components/parameters/subscriptionHandle'
815 description: successful operation
819 $ref: '#/components/schemas/VideoChannel'
821 summary: Delete subscription of my user
828 - $ref: '#/components/parameters/subscriptionHandle'
831 description: successful operation
832 /users/me/notifications:
834 summary: List my notifications
842 description: only list unread notifications
845 - $ref: '#/components/parameters/start'
846 - $ref: '#/components/parameters/count'
847 - $ref: '#/components/parameters/sort'
850 description: successful operation
854 $ref: '#/components/schemas/NotificationListResponse'
855 /users/me/notifications/read:
857 summary: Mark notifications as read by their id
870 description: ids of the notifications to mark as read
877 description: successful operation
878 /users/me/notifications/read-all:
880 summary: Mark all my notification as read
887 description: successful operation
888 /users/me/notification-settings:
890 summary: Update my notification settings
901 newVideoFromSubscription:
902 $ref: '#/components/schemas/NotificationSettingValue'
904 $ref: '#/components/schemas/NotificationSettingValue'
906 $ref: '#/components/schemas/NotificationSettingValue'
907 videoAutoBlacklistAsModerator:
908 $ref: '#/components/schemas/NotificationSettingValue'
910 $ref: '#/components/schemas/NotificationSettingValue'
912 $ref: '#/components/schemas/NotificationSettingValue'
913 myVideoImportFinished:
914 $ref: '#/components/schemas/NotificationSettingValue'
916 $ref: '#/components/schemas/NotificationSettingValue'
918 $ref: '#/components/schemas/NotificationSettingValue'
920 $ref: '#/components/schemas/NotificationSettingValue'
922 $ref: '#/components/schemas/NotificationSettingValue'
923 autoInstanceFollowing:
924 $ref: '#/components/schemas/NotificationSettingValue'
927 description: successful operation
928 /users/me/history/videos:
930 summary: List watched videos history
936 - $ref: '#/components/parameters/start'
937 - $ref: '#/components/parameters/count'
938 - $ref: '#/components/parameters/search'
941 description: successful operation
945 $ref: '#/components/schemas/VideoListResponse'
946 /users/me/history/videos/remove:
948 summary: Clear video history
960 description: history before this date will be deleted
965 description: successful operation
966 /users/me/avatar/pick:
968 summary: Update my user avatar
975 description: successful operation
982 $ref: '#/components/schemas/ActorImage'
984 description: image file too large
990 description: Maximum file size for the avatar
998 description: The file to upload.
1003 contentType: image/png, image/jpeg
1006 summary: Delete my avatar
1013 description: successful operation
1017 summary: List video ownership changes
1019 - Video Ownership Change
1024 description: successful operation
1025 '/videos/ownership/{id}/accept':
1027 summary: Accept ownership change request
1029 - Video Ownership Change
1033 - $ref: '#/components/parameters/idOrUUID'
1036 description: successful operation
1038 description: cannot terminate an ownership change of another user
1040 description: video owneship change not found
1041 '/videos/ownership/{id}/refuse':
1043 summary: Refuse ownership change request
1045 - Video Ownership Change
1049 - $ref: '#/components/parameters/idOrUUID'
1052 description: successful operation
1054 description: cannot terminate an ownership change of another user
1056 description: video owneship change not found
1057 '/videos/{id}/give-ownership':
1059 summary: Request ownership change
1061 - Video Ownership Change
1065 - $ref: '#/components/parameters/idOrUUID'
1069 application/x-www-form-urlencoded:
1079 description: successful operation
1081 description: changing video ownership to a remote account is not supported yet
1083 description: video not found
1086 summary: List videos
1090 - $ref: '#/components/parameters/categoryOneOf'
1091 - $ref: '#/components/parameters/isLive'
1092 - $ref: '#/components/parameters/tagsOneOf'
1093 - $ref: '#/components/parameters/tagsAllOf'
1094 - $ref: '#/components/parameters/licenceOneOf'
1095 - $ref: '#/components/parameters/languageOneOf'
1096 - $ref: '#/components/parameters/nsfw'
1097 - $ref: '#/components/parameters/filter'
1098 - $ref: '#/components/parameters/skipCount'
1099 - $ref: '#/components/parameters/start'
1100 - $ref: '#/components/parameters/count'
1101 - $ref: '#/components/parameters/videosSort'
1104 description: successful operation
1108 $ref: '#/components/schemas/VideoListResponse'
1111 summary: List available video categories
1116 description: successful operation
1125 externalValue: https://peertube2.cpy.re/api/v1/videos/categories
1128 summary: List available video licences
1133 description: successful operation
1142 externalValue: https://peertube2.cpy.re/api/v1/videos/licences
1145 summary: List available video languages
1150 description: successful operation
1159 externalValue: https://peertube2.cpy.re/api/v1/videos/languages
1162 summary: List available video privacies
1167 description: successful operation
1176 externalValue: https://peertube2.cpy.re/api/v1/videos/privacies
1179 summary: Update a video
1185 - $ref: '#/components/parameters/idOrUUID'
1188 description: successful operation
1191 multipart/form-data:
1196 description: Video thumbnail file
1200 description: Video preview file
1204 description: Video category
1208 description: Video licence
1212 description: Video language
1215 $ref: '#/components/schemas/VideoPrivacySet'
1217 description: Video description
1220 description: Whether or not we wait transcoding before publish the video
1223 description: A text tell the audience how to support the video creator
1224 example: Please support my work on <insert crowdfunding plateform>! <3
1227 description: Whether or not this video contains sensitive content
1230 description: Video name
1235 description: Video tags (maximum 5 tags each between 2 and 30 characters)
1244 description: Enable or disable comments for this video
1246 originallyPublishedAt:
1247 description: Date when the content was originally published
1251 $ref: '#/components/schemas/VideoScheduledUpdate'
1254 contentType: image/jpeg
1256 contentType: image/jpeg
1258 summary: Get a video
1262 - $ref: '#/components/parameters/idOrUUID'
1265 description: successful operation
1269 $ref: '#/components/schemas/VideoDetails'
1271 summary: Delete a video
1277 - $ref: '#/components/parameters/idOrUUID'
1280 description: successful operation
1281 '/videos/{id}/description':
1283 summary: Get complete video description
1287 - $ref: '#/components/parameters/idOrUUID'
1290 description: successful operation
1295 '/videos/{id}/views':
1297 summary: Add a view to a video
1301 - $ref: '#/components/parameters/idOrUUID'
1304 description: successful operation
1305 '/videos/{id}/watching':
1307 summary: Set watching progress of a video
1313 - $ref: '#/components/parameters/idOrUUID'
1318 $ref: '#/components/schemas/UserWatchingVideo'
1322 description: successful operation
1325 summary: Upload a video
1332 description: successful operation
1336 $ref: '#/components/schemas/VideoUploadResponse'
1338 description: invalid file field, schedule date or parameter
1340 description: video didn't pass upload filter
1342 description: upload has timed out
1344 description: video file too large, due to quota or max body size limit set by the reverse-proxy
1346 X-File-Maximum-Size:
1350 description: Maximum file size for the video
1352 description: video type unsupported
1354 description: video unreadable
1357 multipart/form-data:
1362 description: Video file
1366 description: Channel id that will contain this video
1369 description: Video thumbnail file
1373 description: Video preview file
1377 $ref: '#/components/schemas/VideoPrivacySet'
1379 description: Video category
1383 description: Video licence
1387 description: Video language
1390 description: Video description
1393 description: Whether or not we wait transcoding before publish the video
1396 description: A text tell the audience how to support the video creator
1397 example: Please support my work on <insert crowdfunding plateform>! <3
1400 description: Whether or not this video contains sensitive content
1403 description: Video name
1408 description: Video tags (maximum 5 tags each between 2 and 30 characters)
1418 description: Enable or disable comments for this video
1421 description: Enable or disable downloading for this video
1423 originallyPublishedAt:
1424 description: Date when the content was originally published
1428 $ref: '#/components/schemas/VideoScheduledUpdate'
1435 contentType: video/mp4, video/webm, video/ogg, video/avi, video/quicktime, video/x-msvideo, video/x-flv, video/x-matroska, application/octet-stream
1437 contentType: image/jpeg
1439 contentType: image/jpeg
1444 USERNAME="<your_username>"
1445 PASSWORD="<your_password>"
1446 FILE_PATH="<your_file_path>"
1447 CHANNEL_ID="<your_channel_id>"
1450 API_PATH="https://peertube2.cpy.re/api/v1"
1452 client_id=$(curl -s "$API_PATH/oauth-clients/local" | jq -r ".client_id")
1453 client_secret=$(curl -s "$API_PATH/oauth-clients/local" | jq -r ".client_secret")
1454 token=$(curl -s "$API_PATH/users/token" \
1455 --data client_id="$client_id" \
1456 --data client_secret="$client_secret" \
1457 --data grant_type=password \
1458 --data response_type=code \
1459 --data username="$USERNAME" \
1460 --data password="$PASSWORD" \
1461 | jq -r ".access_token")
1463 curl -s "$API_PATH/videos/upload" \
1464 -H "Authorization: Bearer $token" \
1466 --form videofile=@"$FILE_PATH" \
1467 --form channelId=$CHANNEL_ID \
1471 summary: Import a video
1472 description: Import a torrent or magnetURI or HTTP resource (if enabled by the instance administrator)
1479 multipart/form-data:
1484 description: Torrent File
1488 description: HTTP target URL
1491 description: Magnet URI
1494 description: Channel id that will contain this video
1497 description: Video thumbnail file
1501 description: Video preview file
1505 $ref: '#/components/schemas/VideoPrivacySet'
1507 description: Video category
1511 description: Video licence
1515 description: Video language
1518 description: Video description
1521 description: Whether or not we wait transcoding before publish the video
1524 description: A text tell the audience how to support the video creator
1525 example: Please support my work on <insert crowdfunding plateform>! <3
1528 description: Whether or not this video contains sensitive content
1531 description: Video name
1536 description: Video tags (maximum 5 tags each between 2 and 30 characters)
1545 description: Enable or disable comments for this video
1548 description: Enable or disable downloading for this video
1551 $ref: '#/components/schemas/VideoScheduledUpdate'
1557 contentType: application/x-bittorrent
1559 contentType: image/jpeg
1561 contentType: image/jpeg
1564 description: successful operation
1568 $ref: '#/components/schemas/VideoUploadResponse'
1570 description: '`magnetUri` or `targetUrl` or a torrent file missing'
1572 description: video didn't pass pre-import filter
1574 description: HTTP or Torrent/magnetURI import not enabled
1578 summary: Create a live
1586 description: successful operation
1590 $ref: '#/components/schemas/VideoUploadResponse'
1592 description: Live is not enabled, allow replay is not enabled, or max instance/user live videos limit is exceeded
1595 multipart/form-data:
1600 description: Channel id that will contain this live video
1605 description: User can stream multiple times in a permanent live
1608 description: Live video/replay thumbnail file
1612 description: Live video/replay preview file
1616 $ref: '#/components/schemas/VideoPrivacySet'
1618 description: Live video/replay category
1621 description: Live video/replay licence
1624 description: Live video/replay language
1627 description: Live video/replay description
1630 description: A text tell the audience how to support the creator
1631 example: Please support my work on <insert crowdfunding plateform>! <3
1634 description: Whether or not this live video/replay contains sensitive content
1637 description: Live video/replay name
1642 description: Live video/replay tags (maximum 5 tags each between 2 and 30 characters)
1651 description: Enable or disable comments for this live video/replay
1654 description: Enable or disable downloading for the replay of this live
1661 contentType: image/jpeg
1663 contentType: image/jpeg
1667 summary: Get a live information
1674 - $ref: '#/components/parameters/idOrUUID'
1677 description: successful operation
1681 $ref: '#/components/schemas/LiveVideoResponse'
1683 summary: Update a live information
1690 - $ref: '#/components/parameters/idOrUUID'
1695 $ref: '#/components/schemas/LiveVideoUpdate'
1698 description: Successful operation
1700 description: Bad parameters or trying to update a live that has already started
1702 description: Trying to save replay of the live but saving replay is not enabled on the instance
1706 summary: List my abuses
1715 description: only list the report with this id
1721 $ref: '#/components/schemas/AbuseStateSet'
1722 - $ref: '#/components/parameters/start'
1723 - $ref: '#/components/parameters/count'
1724 - $ref: '#/components/parameters/abusesSort'
1727 description: successful operation
1733 $ref: '#/components/schemas/Abuse'
1737 summary: List abuses
1747 description: only list the report with this id
1750 - name: predefinedReason
1752 description: predefined reason the listed reports should contain
1754 $ref: '#/components/schemas/PredefinedAbuseReasons'
1757 description: plain search that will match with video titles, reporter names and more
1763 $ref: '#/components/schemas/AbuseStateSet'
1764 - name: searchReporter
1766 description: only list reports of a specific reporter
1769 - name: searchReportee
1770 description: only list reports of a specific reportee
1776 description: only list reports of a specific video
1779 - name: searchVideoChannel
1781 description: only list reports of a specific video channel
1786 description: only list blacklisted or deleted videos
1794 description: only list account, comment or video reports
1801 - $ref: '#/components/parameters/start'
1802 - $ref: '#/components/parameters/count'
1803 - $ref: '#/components/parameters/abusesSort'
1806 description: successful operation
1812 $ref: '#/components/schemas/Abuse'
1815 summary: Report an abuse
1828 description: Reason why the user reports this video
1833 $ref: '#/components/schemas/PredefinedAbuseReasons'
1838 description: Video id to report
1842 description: Timestamp in the video that marks the beginning of the report
1846 description: Timestamp in the video that marks the ending of the report
1852 description: Comment id to report
1858 description: Account id to report
1864 description: successful operation
1866 description: incorrect request parameters
1867 '/abuses/{abuseId}':
1869 summary: Update an abuse
1877 - $ref: '#/components/parameters/abuseId'
1885 $ref: '#/components/schemas/AbuseStateSet'
1888 description: Update the report comment visible only to the moderation team
1893 description: successful operation
1895 description: abuse not found
1899 summary: Delete an abuse
1905 - $ref: '#/components/parameters/abuseId'
1908 description: successful operation
1910 description: block not found
1911 '/abuses/{abuseId}/messages':
1913 summary: List messages of an abuse
1919 - $ref: '#/components/parameters/abuseId'
1922 description: successful operation
1928 $ref: '#/components/schemas/AbuseMessage'
1931 summary: Add message to an abuse
1937 - $ref: '#/components/parameters/abuseId'
1946 description: Message to send
1954 description: successful operation
1956 description: incorrect request parameters
1957 '/abuses/{abuseId}/messages/{abuseMessageId}':
1959 summary: Delete an abuse message
1965 - $ref: '#/components/parameters/abuseId'
1966 - $ref: '#/components/parameters/abuseMessageId'
1969 description: successful operation
1971 '/videos/{id}/blacklist':
1973 summary: Block a video
1981 - $ref: '#/components/parameters/idOrUUID'
1984 description: successful operation
1986 summary: Unblock a video by its id
1994 - $ref: '#/components/parameters/idOrUUID'
1997 description: successful operation
1999 description: block not found
2004 summary: List video blocks
2013 list only blocks that match this type:
2017 - `2`: automatic block that needs review
2025 description: plain search that will match with video titles, and more
2028 - $ref: '#/components/parameters/start'
2029 - $ref: '#/components/parameters/count'
2030 - $ref: '#/components/parameters/blacklistsSort'
2033 description: successful operation
2045 $ref: '#/components/schemas/VideoBlacklist'
2046 /videos/{id}/captions:
2048 summary: List captions of a video
2052 - $ref: '#/components/parameters/idOrUUID'
2055 description: successful operation
2067 $ref: '#/components/schemas/VideoCaption'
2068 /videos/{id}/captions/{captionLanguage}:
2070 summary: Add or replace a video caption
2077 - $ref: '#/components/parameters/idOrUUID'
2078 - $ref: '#/components/parameters/captionLanguage'
2081 multipart/form-data:
2086 description: The file to upload.
2091 contentType: text/vtt, application/x-subrip, text/plain
2094 description: successful operation
2096 description: video or language not found
2098 summary: Delete a video caption
2105 - $ref: '#/components/parameters/idOrUUID'
2106 - $ref: '#/components/parameters/captionLanguage'
2109 description: successful operation
2111 description: video or language or caption for that language not found
2114 summary: List video channels
2118 - $ref: '#/components/parameters/start'
2119 - $ref: '#/components/parameters/count'
2120 - $ref: '#/components/parameters/sort'
2123 description: successful operation
2135 $ref: '#/components/schemas/VideoChannel'
2137 summary: Create a video channel
2144 description: successful operation
2149 $ref: '#/components/schemas/VideoChannelCreate'
2150 '/video-channels/{channelHandle}':
2152 summary: Get a video channel
2156 - $ref: '#/components/parameters/channelHandle'
2159 description: successful operation
2163 $ref: '#/components/schemas/VideoChannel'
2165 summary: Update a video channel
2171 - $ref: '#/components/parameters/channelHandle'
2174 description: successful operation
2179 $ref: '#/components/schemas/VideoChannelUpdate'
2181 summary: Delete a video channel
2187 - $ref: '#/components/parameters/channelHandle'
2190 description: successful operation
2191 '/video-channels/{channelHandle}/videos':
2193 summary: List videos of a video channel
2198 - $ref: '#/components/parameters/channelHandle'
2199 - $ref: '#/components/parameters/categoryOneOf'
2200 - $ref: '#/components/parameters/isLive'
2201 - $ref: '#/components/parameters/tagsOneOf'
2202 - $ref: '#/components/parameters/tagsAllOf'
2203 - $ref: '#/components/parameters/licenceOneOf'
2204 - $ref: '#/components/parameters/languageOneOf'
2205 - $ref: '#/components/parameters/nsfw'
2206 - $ref: '#/components/parameters/filter'
2207 - $ref: '#/components/parameters/skipCount'
2208 - $ref: '#/components/parameters/start'
2209 - $ref: '#/components/parameters/count'
2210 - $ref: '#/components/parameters/videosSort'
2213 description: successful operation
2217 $ref: '#/components/schemas/VideoListResponse'
2218 '/video-channels/{channelHandle}/avatar/pick':
2220 summary: Update channel avatar
2226 - $ref: '#/components/parameters/channelHandle'
2229 description: successful operation
2236 $ref: '#/components/schemas/ActorImage'
2238 description: image file too large
2240 X-File-Maximum-Size:
2244 description: Maximum file size for the avatar
2247 multipart/form-data:
2252 description: The file to upload.
2257 contentType: image/png, image/jpeg
2258 '/video-channels/{channelHandle}/avatar':
2260 summary: Delete channel avatar
2266 - $ref: '#/components/parameters/channelHandle'
2269 description: successful operation
2272 '/video-channels/{channelHandle}/banner/pick':
2274 summary: Update channel banner
2280 - $ref: '#/components/parameters/channelHandle'
2283 description: successful operation
2290 $ref: '#/components/schemas/ActorImage'
2292 description: image file too large
2294 X-File-Maximum-Size:
2298 description: Maximum file size for the banner
2301 multipart/form-data:
2306 description: The file to upload.
2311 contentType: image/png, image/jpeg
2312 '/video-channels/{channelHandle}/banner':
2314 summary: Delete channel banner
2320 - $ref: '#/components/parameters/channelHandle'
2323 description: successful operation
2325 /video-playlists/privacies:
2327 summary: List available playlist privacies
2332 description: successful operation
2341 externalValue: https://peertube2.cpy.re/api/v1/video-playlists/privacies
2345 summary: List video playlists
2349 - $ref: '#/components/parameters/start'
2350 - $ref: '#/components/parameters/count'
2351 - $ref: '#/components/parameters/sort'
2354 description: successful operation
2366 $ref: '#/components/schemas/VideoPlaylist'
2368 summary: Create a video playlist
2369 description: 'If the video playlist is set as public, the videoChannelId is mandatory.'
2376 description: successful operation
2391 multipart/form-data:
2396 description: Video playlist display name
2401 description: Video playlist thumbnail file
2405 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
2407 description: Video playlist description
2410 description: Video channel in which the playlist will be published
2416 contentType: image/jpeg
2418 /video-playlists/{id}:
2420 summary: Get a video playlist
2424 - $ref: '#/components/parameters/idOrUUID'
2427 description: successful operation
2431 $ref: '#/components/schemas/VideoPlaylist'
2433 summary: Update a video playlist
2434 description: 'If the video playlist is set as public, the playlist must have a assigned channel.'
2441 description: successful operation
2443 - $ref: '#/components/parameters/idOrUUID'
2446 multipart/form-data:
2451 description: Video playlist display name
2456 description: Video playlist thumbnail file
2460 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
2462 description: Video playlist description
2465 description: Video channel in which the playlist will be published
2469 contentType: image/jpeg
2471 summary: Delete a video playlist
2477 - $ref: '#/components/parameters/idOrUUID'
2480 description: successful operation
2482 /video-playlists/{id}/videos:
2484 summary: 'List videos of a playlist'
2489 - $ref: '#/components/parameters/idOrUUID'
2492 description: successful operation
2496 $ref: '#/components/schemas/VideoListResponse'
2498 summary: 'Add a video in a playlist'
2505 - $ref: '#/components/parameters/idOrUUID'
2508 description: successful operation
2514 videoPlaylistElement:
2527 description: 'Video to add in the playlist'
2530 description: 'Start the video at this specific timestamp (in seconds)'
2533 description: 'Stop the video at this specific timestamp (in seconds)'
2537 /video-playlists/{id}/videos/reorder:
2539 summary: 'Reorder a playlist'
2545 - $ref: '#/components/parameters/idOrUUID'
2548 description: successful operation
2557 description: 'Start position of the element to reorder'
2559 insertAfterPosition:
2561 description: 'New position for the block to reorder, to add the block before the first element'
2565 description: 'How many element from `startPosition` to reorder'
2569 - insertAfterPosition
2571 /video-playlists/{id}/videos/{playlistElementId}:
2573 summary: 'Update a playlist element'
2579 - $ref: '#/components/parameters/idOrUUID'
2580 - $ref: '#/components/parameters/playlistElementId'
2583 description: successful operation
2592 description: 'Start the video at this specific timestamp (in seconds)'
2595 description: 'Stop the video at this specific timestamp (in seconds)'
2597 summary: 'Delete an element from a playlist'
2603 - $ref: '#/components/parameters/idOrUUID'
2604 - $ref: '#/components/parameters/playlistElementId'
2607 description: successful operation
2609 '/users/me/video-playlists/videos-exist':
2611 summary: 'Check video exists in my playlists'
2620 description: The video ids to check
2627 description: successful operation
2647 '/accounts/{name}/video-channels':
2649 summary: List video channels of an account
2654 - $ref: '#/components/parameters/name'
2657 description: include view statistics for the last 30 days (only if authentified as the account user)
2660 - $ref: '#/components/parameters/start'
2661 - $ref: '#/components/parameters/count'
2662 - $ref: '#/components/parameters/sort'
2665 description: successful operation
2676 $ref: '#/components/schemas/VideoChannel'
2677 '/accounts/{name}/ratings':
2679 summary: List ratings of an account
2685 - $ref: '#/components/parameters/name'
2686 - $ref: '#/components/parameters/start'
2687 - $ref: '#/components/parameters/count'
2688 - $ref: '#/components/parameters/sort'
2692 description: Optionally filter which ratings to retrieve
2700 description: successful operation
2706 $ref: '#/components/schemas/VideoRating'
2707 '/videos/{id}/comment-threads':
2709 summary: List threads of a video
2713 - $ref: '#/components/parameters/idOrUUID'
2714 - $ref: '#/components/parameters/start'
2715 - $ref: '#/components/parameters/count'
2716 - $ref: '#/components/parameters/commentsSort'
2719 description: successful operation
2723 $ref: '#/components/schemas/CommentThreadResponse'
2725 summary: Create a thread
2731 - $ref: '#/components/parameters/idOrUUID'
2734 description: successful operation
2738 $ref: '#/components/schemas/CommentThreadPostResponse'
2740 description: video does not exist
2749 description: 'Text comment'
2753 '/videos/{id}/comment-threads/{threadId}':
2755 summary: Get a thread
2759 - $ref: '#/components/parameters/idOrUUID'
2760 - $ref: '#/components/parameters/threadId'
2763 description: successful operation
2767 $ref: '#/components/schemas/VideoCommentThreadTree'
2768 '/videos/{id}/comments/{commentId}':
2770 summary: Reply to a thread of a video
2776 - $ref: '#/components/parameters/idOrUUID'
2777 - $ref: '#/components/parameters/commentId'
2780 description: successful operation
2784 $ref: '#/components/schemas/CommentThreadPostResponse'
2786 description: thread or video does not exist
2795 description: 'Text comment'
2800 summary: Delete a comment or a reply
2806 - $ref: '#/components/parameters/idOrUUID'
2807 - $ref: '#/components/parameters/commentId'
2810 description: successful operation
2812 description: cannot remove comment of another user
2814 description: comment or video does not exist
2816 description: comment is already deleted
2817 '/videos/{id}/rate':
2819 summary: Like/dislike a video
2825 - $ref: '#/components/parameters/idOrUUID'
2828 description: successful operation
2830 description: video does not exist
2835 summary: Search videos
2840 allowEmptyValue: false
2842 String to search. If the user can make a remote URI search, and the string is an URI then the
2843 PeerTube instance will fetch the remote object and add it to its database. Then,
2844 you can use the REST API to fetch the complete video information and interact with it.
2847 - $ref: '#/components/parameters/categoryOneOf'
2848 - $ref: '#/components/parameters/isLive'
2849 - $ref: '#/components/parameters/tagsOneOf'
2850 - $ref: '#/components/parameters/tagsAllOf'
2851 - $ref: '#/components/parameters/licenceOneOf'
2852 - $ref: '#/components/parameters/languageOneOf'
2853 - $ref: '#/components/parameters/nsfw'
2854 - $ref: '#/components/parameters/filter'
2855 - $ref: '#/components/parameters/skipCount'
2856 - $ref: '#/components/parameters/start'
2857 - $ref: '#/components/parameters/count'
2858 - $ref: '#/components/parameters/searchTarget'
2859 - $ref: '#/components/parameters/videosSearchSort'
2862 description: Get videos that are published after this date
2868 description: Get videos that are published before this date
2872 - name: originallyPublishedStartDate
2874 description: Get videos that are originally published after this date
2878 - name: originallyPublishedEndDate
2880 description: Get videos that are originally published before this date
2886 description: Get videos that have this minimum duration
2891 description: Get videos that have this maximum duration
2895 'searchTarget === search-index':
2896 $ref: '#/components/callbacks/searchIndex'
2899 description: successful operation
2903 $ref: '#/components/schemas/VideoListResponse'
2905 description: search index unavailable
2906 /search/video-channels:
2910 summary: Search channels
2916 String to search. If the user can make a remote URI search, and the string is an URI then the
2917 PeerTube instance will fetch the remote object and add it to its database. Then,
2918 you can use the REST API to fetch the complete channel information and interact with it.
2921 - $ref: '#/components/parameters/start'
2922 - $ref: '#/components/parameters/count'
2923 - $ref: '#/components/parameters/searchTarget'
2924 - $ref: '#/components/parameters/sort'
2926 'searchTarget === search-index':
2927 $ref: '#/components/callbacks/searchIndex'
2930 description: successful operation
2936 $ref: '#/components/schemas/VideoChannel'
2938 description: search index unavailable
2939 /blocklist/accounts:
2943 summary: List account blocks
2948 - $ref: '#/components/parameters/start'
2949 - $ref: '#/components/parameters/count'
2950 - $ref: '#/components/parameters/sort'
2953 description: successful operation
2957 summary: Block an account
2969 example: chocobozzz@example.org
2970 description: account to block, in the form `username@domain`
2975 description: successful operation
2977 description: self-blocking forbidden
2978 '/blocklist/accounts/{accountName}':
2982 summary: Unblock an account by its handle
2990 description: account to unblock, in the form `username@domain`
2995 description: successful operation
2997 description: account or account block does not exist
3002 summary: List server blocks
3007 - $ref: '#/components/parameters/start'
3008 - $ref: '#/components/parameters/count'
3009 - $ref: '#/components/parameters/sort'
3012 description: successful operation
3016 summary: Block a server
3029 description: server domain to block
3034 description: successful operation
3036 description: self-blocking forbidden
3037 '/blocklist/servers/{host}':
3041 summary: Unblock a server by its domain
3049 description: server domain to unblock
3055 description: successful operation
3057 description: account block does not exist
3061 - Instance Redundancy
3062 summary: Update a server redundancy policy
3070 description: server domain to mirror
3082 description: allow mirroring of the host's local videos
3087 description: successful operation
3089 description: server is not already known
3094 summary: List videos being mirrored
3102 description: direction of the mirror
3108 - $ref: '#/components/parameters/start'
3109 - $ref: '#/components/parameters/count'
3110 - $ref: '#/components/parameters/videoRedundanciesSort'
3113 description: successful operation
3119 $ref: '#/components/schemas/VideoRedundancy'
3123 summary: Mirror a video
3139 description: successful operation
3141 description: cannot mirror a local video
3143 description: video does not exist
3145 description: video is already mirrored
3146 /redundancy/videos/{redundancyId}:
3150 summary: Delete a mirror done on a video
3155 - name: redundancyId
3158 description: id of an existing redundancy on a video
3163 description: successful operation
3165 description: video redundancy not found
3166 '/feeds/video-comments.{format}':
3170 summary: List comments on videos
3172 - url: 'https://peertube2.cpy.re'
3173 description: Live Test Server (live data - latest nightly version)
3174 - url: 'https://peertube3.cpy.re'
3175 description: Live Test Server (live data - latest RC version)
3176 - url: 'https://peertube.cpy.re'
3177 description: Live Test Server (live data - stable version)
3182 description: 'format expected (we focus on making `rss` the most featureful ; it serves [Media RSS](https://www.rssboard.org/media-rss))'
3195 description: 'limit listing to a specific video'
3200 description: 'limit listing to a specific account'
3205 description: 'limit listing to a specific account'
3208 - name: videoChannelId
3210 description: 'limit listing to a specific video channel'
3213 - name: videoChannelName
3215 description: 'limit listing to a specific video channel'
3220 description: successful operation
3225 default: 'max-age=900' # 15 min cache
3229 $ref: '#/components/schemas/VideoCommentsForXML'
3230 application/rss+xml:
3232 $ref: '#/components/schemas/VideoCommentsForXML'
3235 $ref: '#/components/schemas/VideoCommentsForXML'
3236 application/atom+xml:
3238 $ref: '#/components/schemas/VideoCommentsForXML'
3243 x-summary: field inconsistencies
3246 - videoId filter is mixed with a channel filter
3248 description: video, video channel or account not found
3250 description: accept header unsupported
3251 '/feeds/videos.{format}':
3255 summary: List videos
3257 - url: 'https://peertube2.cpy.re'
3258 description: Live Test Server (live data - latest nightly version)
3259 - url: 'https://peertube3.cpy.re'
3260 description: Live Test Server (live data - latest RC version)
3261 - url: 'https://peertube.cpy.re'
3262 description: Live Test Server (live data - stable version)
3267 description: 'format expected (we focus on making `rss` the most featureful ; it serves [Media RSS](https://www.rssboard.org/media-rss))'
3280 description: 'limit listing to a specific account'
3285 description: 'limit listing to a specific account'
3288 - name: videoChannelId
3290 description: 'limit listing to a specific video channel'
3293 - name: videoChannelName
3295 description: 'limit listing to a specific video channel'
3298 - $ref: '#/components/parameters/sort'
3299 - $ref: '#/components/parameters/nsfw'
3300 - $ref: '#/components/parameters/filter'
3303 description: successful operation
3308 default: 'max-age=900' # 15 min cache
3312 $ref: '#/components/schemas/VideosForXML'
3315 externalValue: https://peertube2.cpy.re/feeds/videos.xml?filter=local
3316 application/rss+xml:
3318 $ref: '#/components/schemas/VideosForXML'
3321 $ref: '#/components/schemas/VideosForXML'
3322 application/atom+xml:
3324 $ref: '#/components/schemas/VideosForXML'
3329 description: video channel or account not found
3331 description: accept header unsupported
3336 summary: List plugins
3349 - $ref: '#/components/parameters/start'
3350 - $ref: '#/components/parameters/count'
3351 - $ref: '#/components/parameters/sort'
3354 description: successful operation
3358 $ref: '#/components/schemas/PluginResponse'
3363 summary: List available plugins
3376 - name: currentPeerTubeEngine
3380 - $ref: '#/components/parameters/start'
3381 - $ref: '#/components/parameters/count'
3382 - $ref: '#/components/parameters/sort'
3385 description: successful operation
3389 $ref: '#/components/schemas/PluginResponse'
3391 description: plugin index unavailable
3396 summary: Install a plugin
3409 example: peertube-plugin-auth-ldap
3412 additionalProperties: false
3419 additionalProperties: false
3422 description: successful operation
3424 description: should have either `npmName` or `path` set
3429 summary: Update a plugin
3442 example: peertube-plugin-auth-ldap
3445 additionalProperties: false
3452 additionalProperties: false
3455 description: successful operation
3457 description: should have either `npmName` or `path` set
3459 description: existing plugin not found
3464 summary: Uninstall a plugin
3476 description: name of the plugin/theme in its package.json
3477 example: peertube-plugin-auth-ldap
3482 description: successful operation
3484 description: existing plugin not found
3489 summary: Get a plugin
3494 - $ref: '#/components/parameters/npmName'
3497 description: successful operation
3501 $ref: '#/components/schemas/Plugin'
3503 description: plugin not found
3504 /plugins/{npmName}/settings:
3508 summary: Set a plugin's settings
3513 - $ref: '#/components/parameters/npmName'
3522 additionalProperties: true
3525 description: successful operation
3527 description: plugin not found
3528 /plugins/{npmName}/public-settings:
3532 summary: Get a plugin's public settings
3534 - $ref: '#/components/parameters/npmName'
3537 description: successful operation
3542 additionalProperties: true
3544 description: plugin not found
3545 /plugins/{npmName}/registered-settings:
3549 summary: Get a plugin's registered settings
3554 - $ref: '#/components/parameters/npmName'
3557 description: successful operation
3562 additionalProperties: true
3564 description: plugin not found
3566 - url: 'https://peertube2.cpy.re/api/v1'
3567 description: Live Test Server (live data - latest nightly version)
3568 - url: 'https://peertube3.cpy.re/api/v1'
3569 description: Live Test Server (live data - latest RC version)
3570 - url: 'https://peertube.cpy.re/api/v1'
3571 description: Live Test Server (live data - stable version)
3578 description: Offset used to paginate results
3586 description: "Number of items to return"
3596 description: Sort column
3604 description: Plain text search, applied to various parts of the model depending on endpoint
3612 If the administrator enabled search index support, you can override the default search target.
3615 **Warning**: If you choose to make an index search, PeerTube will get results from a third party service.
3616 It means the instance may not yet know the objects you fetched. If you want to load video/channel information:
3617 * If the current user has the ability to make a remote URI search (this information is available in the config endpoint),
3618 then reuse the search API to make a search using the object URI so PeerTube instance fetches the remote object and fill its database.
3619 After that, you can use the classic REST API endpoints to fetch the complete object or interact with it
3620 * 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
3621 the data from the origin instance API
3631 description: Sort videos by criteria
3647 description: Sort videos by criteria
3662 description: Sort comments by criteria
3672 description: Sort blacklists by criteria
3688 description: Plain text search that will match with user usernames or emails
3695 description: Filter results down to (un)banned users
3702 description: Sort users by criteria
3713 description: Sort abuses by criteria
3720 videoRedundanciesSort:
3724 description: Sort abuses by criteria
3733 description: The username or handle of the account
3736 example: chocobozzz | chocobozzz@example.org
3741 description: The user id
3750 description: The object id or uuid
3758 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
3760 name: playlistElementId
3763 description: Playlist element id
3770 description: Abuse id
3774 name: abuseMessageId
3777 description: Abuse message id
3781 name: captionLanguage
3784 description: The caption language
3791 description: The video channel handle
3794 example: my_username | my_username@example.com
3796 name: subscriptionHandle
3799 description: The subscription handle
3802 example: my_username | my_username@example.com
3807 description: The thread id (root comment id)
3814 description: The comment id
3821 description: whether or not the video is a live
3828 description: category id of the video (see [/videos/categories](#tag/Video/paths/~1videos~1categories/get))
3841 description: tag(s) of the video
3854 description: tag(s) of the video, where all should be present in the video
3867 description: language id of the video (see [/videos/languages](#tag/Video/paths/~1videos~1languages/get)). Use `_unknown` to filter on videos that don't have a video language
3880 description: licence id of the video (see [/videos/licences](#tag/Video/paths/~1videos~1licences/get))
3893 description: if you don't need the `total` in the response
3904 description: whether to include nsfw videos, if any
3915 Special filters which might require special rights:
3916 * `local` - only videos local to the instance
3917 * `all-local` - only videos local to the instance, but showing private and unlisted videos (requires Admin privileges)
3918 * `all` - all videos, showing private and unlisted videos (requires Admin privileges)
3928 description: list of uris to check if each is part of the user subscriptions
3938 description: name of the plugin/theme on npmjs.com or in its package.json
3941 example: peertube-plugin-auth-ldap
3946 description: job type
3950 - activitypub-follow
3951 - activitypub-http-broadcast
3952 - activitypub-http-fetcher
3953 - activitypub-http-unicast
3959 - activitypub-refresher
3965 In the header: *Authorization: Bearer <token\>*
3968 Authenticating via OAuth requires the following steps:
3971 - Have an account with sufficient authorization levels
3973 - [Generate](https://docs.joinpeertube.org/api-rest-getting-started) a
3976 - Make Authenticated Requests
3980 tokenUrl: 'https://peertube.example.com/api/v1/users/token'
3983 moderator: Moderator scope
3986 VideoConstantNumber-Category:
3990 description: category id of the video (see [/videos/categories](#tag/Video/paths/~1videos~1categories/get))
3993 VideoConstantNumber-Licence:
3997 description: licence id of the video (see [/videos/licences](#tag/Video/paths/~1videos~1licences/get))
4000 VideoConstantString-Language:
4004 description: language id of the video (see [/videos/languages](#tag/Video/paths/~1videos~1languages/get))
4008 VideoPlaylistPrivacySet:
4014 description: 'The video playlist privacy (Public = `1`, Unlisted = `2`, Private = `3`)'
4015 VideoPlaylistPrivacyConstant:
4018 $ref: '#/components/schemas/VideoPlaylistPrivacySet'
4022 VideoPlaylistTypeSet:
4027 description: 'The video playlist type (Regular = `1`, Watch Later = `2`)'
4028 VideoPlaylistTypeConstant:
4031 $ref: '#/components/schemas/VideoPlaylistTypeSet'
4042 description: 'The video privacy (Public = `1`, Unlisted = `2`, Private = `3`, Internal = `4`)'
4043 VideoPrivacyConstant:
4046 $ref: '#/components/schemas/VideoPrivacySet'
4063 description: 'The user role (Admin = `0`, Moderator = `1`, User = `2`)'
4070 description: 'Admin flags for the user (None = `0`, Bypass video blacklist = `1`)'
4081 description: 'The video state (Published = `1`, to transcode = `2`, to import = `3`)'
4091 description: 'The abuse state (Pending = `1`, Rejected = `2`, Accepted = `3`)'
4095 $ref: '#/components/schemas/AbuseStateSet'
4098 AbusePredefinedReasons:
4111 example: [spamOrMisleading]
4113 VideoResolutionConstant:
4117 description: 'Video resolution (240, 360, 720, 1080, 1440 or 2160)'
4122 VideoScheduledUpdate:
4125 $ref: '#/components/schemas/VideoPrivacySet'
4129 description: When to update the video
4149 - $ref: '#/components/schemas/ActorImage'
4150 VideoChannelSummary:
4167 - $ref: '#/components/schemas/ActorImage'
4179 - $ref: '#/components/schemas/Video'
4185 $ref: '#/components/schemas/VideoResolutionConstant'
4188 description: 'Video file size in bytes'
4191 description: Direct URL of the torrent file
4195 description: URL endpoint that transfers the torrent file as an attachment (so that the browser opens a download dialog)
4199 description: Direct URL of the video
4203 description: URL endpoint that transfers the video file as an attachment (so that the browser opens a download dialog)
4210 VideoStreamingPlaylists:
4218 description: 'Playlist type (HLS = `1`)'
4227 description: 'Video files associated to this playlist. The difference with the root "files" property is that these files are fragmented, so they can be used in this streaming playlist (HLS etc)'
4229 $ref: '#/components/schemas/VideoFile'
4245 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4258 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4270 originallyPublishedAt:
4274 $ref: '#/components/schemas/VideoConstantNumber-Category'
4276 $ref: '#/components/schemas/VideoConstantNumber-Licence'
4278 $ref: '#/components/schemas/VideoConstantString-Language'
4280 $ref: '#/components/schemas/VideoPrivacyConstant'
4290 example: What is PeerTube?
4295 example: /static/thumbnails/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg
4298 example: /lazy-static/previews/a65bc12f-9383-462e-81ae-8207e8b434ee.jpg
4301 example: /videos/embed/a65bc12f-9383-462e-81ae-8207e8b434ee
4317 $ref: '#/components/schemas/VideoStateConstant'
4321 - $ref: '#/components/schemas/VideoScheduledUpdate'
4329 $ref: '#/components/schemas/AccountSummary'
4331 $ref: '#/components/schemas/VideoChannelSummary'
4340 - $ref: '#/components/schemas/Video'
4347 description: A text tell the audience how to support the video creator
4348 example: Please support my work on <insert crowdfunding plateform>! <3
4350 $ref: '#/components/schemas/VideoChannel'
4352 $ref: '#/components/schemas/Account'
4354 example: [flowers, gardening]
4364 description: 'WebTorrent/raw video files. Can be empty if WebTorrent is disabled on the server. In this case, video files will be in the "streamingPlaylists[].files" property'
4366 $ref: '#/components/schemas/VideoFile'
4379 $ref: '#/components/schemas/VideoStreamingPlaylists'
4380 FileRedundancyInformation:
4417 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4424 $ref: '#/components/schemas/FileRedundancyInformation'
4428 $ref: '#/components/schemas/FileRedundancyInformation'
4429 VideoImportStateConstant:
4437 description: 'The video import state (Pending = `1`, Success = `2`, Failed = `3`)'
4449 example: https://framatube.org/videos/watch/9c9de5e8-0a1e-484a-b099-e80766180a6d
4453 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
4457 $ref: '#/components/schemas/VideoImportStateConstant'
4467 $ref: '#/components/schemas/Video'
4475 example: The video is a spam
4479 $ref: '#/components/schemas/AbusePredefinedReasons'
4481 $ref: '#/components/schemas/Account'
4483 $ref: '#/components/schemas/AbuseStateConstant'
4486 example: Decided to ban the server since it spams us regularly
4490 $ref: '#/components/schemas/VideoInfo'
4508 $ref: '#/components/schemas/AccountSummary'
4528 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4563 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4581 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
4593 $ref: '#/components/schemas/VideoPlaylistPrivacyConstant'
4595 $ref: '#/components/schemas/VideoPlaylistTypeConstant'
4597 $ref: '#/components/schemas/AccountSummary'
4599 $ref: '#/components/schemas/VideoChannelSummary'
4623 totalRepliesFromVideoAuthor:
4628 $ref: '#/components/schemas/Account'
4629 VideoCommentThreadTree:
4632 $ref: '#/components/schemas/VideoComment'
4636 $ref: '#/components/schemas/VideoCommentThreadTree'
4640 $ref: '#/components/schemas/VideoConstantString-Language'
4695 $ref: '#/components/schemas/ActorImage'
4698 - $ref: '#/components/schemas/Actor'
4711 description: timestamp within the video, in seconds
4778 allowedForCurrentIP:
4780 requiresEmailVerification:
4984 requiresEmailVerification:
5009 allowAdditionalExtensions:
5079 $ref: '#/components/schemas/Actor'
5081 $ref: '#/components/schemas/Actor'
5084 description: score reflecting the reachability of the actor, with steps of `10` and a base score of `1000`.
5097 PredefinedAbuseReasons:
5098 description: Reason categories that help triage reports
5129 - activitypub-http-unicast
5130 - activitypub-http-broadcast
5131 - activitypub-http-fetcher
5132 - activitypub-follow
5138 - activitypub-refresher
5142 additionalProperties: true
5145 additionalProperties: true
5169 VideoUploadResponse:
5180 example: 9c9de5e8-0a1e-484a-b099-e80766180a6d
5181 CommentThreadResponse:
5190 $ref: '#/components/schemas/VideoComment'
5191 CommentThreadPostResponse:
5194 $ref: '#/components/schemas/VideoComment'
5204 $ref: '#/components/schemas/Video'
5212 description: The user username
5218 description: The user email
5221 description: Auth plugin to use to authenticate the user
5224 description: Theme enabled by this user
5227 description: Has the user confirmed their email address?
5229 $ref: '#/components/schemas/NSFWPolicy'
5232 description: Enable P2P in the player
5235 description: Automatically start playing the video on the watch page
5237 $ref: '#/components/schemas/UserRole'
5246 description: The user video quota
5249 description: The user daily video quota
5254 abusesAcceptedCount:
5260 noInstanceConfigWarningModal:
5271 $ref: '#/components/schemas/Account'
5275 $ref: '#/components/schemas/VideoChannel'
5280 description: The user username
5286 description: The user password. If the smtp server is configured, you can leave empty and an email will be sent
5292 description: The user email
5295 description: The user video quota
5298 description: The user daily video quota
5301 description: The user default channel username
5303 $ref: '#/components/schemas/UserRole'
5305 $ref: '#/components/schemas/UserAdminFlags'
5317 description: The user id
5321 description: The updated email of the user
5324 description: Set the email as verified
5327 description: The updated video quota of the user
5330 description: The updated daily video quota of the user
5334 description: The auth plugin to use to authenticate the user
5335 example: 'peertube-plugin-auth-saml2'
5337 $ref: '#/components/schemas/UserRole'
5339 $ref: '#/components/schemas/UserAdminFlags'
5347 description: Your new password
5353 description: Your new email
5356 description: Your new displayNSFW
5363 description: Your new autoPlayVideo
5373 description: Id of the video
5376 description: Rating of the video
5383 $ref: '#/components/schemas/Video'
5386 description: 'Rating of the video'
5394 description: The username of the user
5397 pattern: '/^[a-z0-9._]{1,50}$/'
5401 description: The password of the user
5407 description: The email of the user
5410 description: The user display name
5418 description: The username for the default channel
5419 pattern: '/^[ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789\\-_.:]+$/'
5422 description: The display name for the default channel
5442 description: 'A text shown by default on all videos of this channel, to tell the audience how to support it'
5443 example: Please support my work on <insert crowdfunding plateform>! <3
5448 - $ref: '#/components/schemas/VideoChannelCommon'
5459 - $ref: '#/components/schemas/VideoChannelCommon'
5461 bulkVideosSupportUpdate:
5463 description: 'Update the support field for all videos of this channel'
5468 name: 'media:peerLink'
5477 - application/x-bittorrent
5483 name: 'media:content'
5514 VideoCommentsForXML:
5549 description: video watch page URL
5552 description: video canonical URL
5556 description: video publication date
5559 description: video description
5562 description: video description
5565 description: publisher user name
5568 description: video category (MRSS)
5571 description: see [media:community](https://www.rssboard.org/media-rss#media-community) (MRSS)
5586 description: video embed path, relative to the canonical URL domain (MRSS)
5595 description: video watch path, relative to the canonical URL domain (MRSS)
5616 description: see [media:title](https://www.rssboard.org/media-rss#media-title) (MRSS). We only use `plain` titles.
5617 'media:description':
5624 description: see [media:rating](https://www.rssboard.org/media-rss#media-rating) (MRSS)
5627 description: main streamable file for the video
5637 - application/x-bittorrent
5646 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)
5649 - $ref: '#/components/schemas/MRSSPeerLink'
5650 - $ref: '#/components/schemas/MRSSGroupContent'
5651 NotificationSettingValue:
5672 Notification type, following the `UserNotificationType` enum:
5674 - `1` NEW_VIDEO_FROM_SUBSCRIPTION
5676 - `2` NEW_COMMENT_ON_MY_VIDEO
5678 - `3` NEW_ABUSE_FOR_MODERATORS
5680 - `4` BLACKLIST_ON_MY_VIDEO
5682 - `5` UNBLACKLIST_ON_MY_VIDEO
5684 - `6` MY_VIDEO_PUBLISHED
5686 - `7` MY_VIDEO_IMPORT_SUCCESS
5688 - `8` MY_VIDEO_IMPORT_ERROR
5690 - `9` NEW_USER_REGISTRATION
5694 - `11` COMMENT_MENTION
5696 - `12` VIDEO_AUTO_BLACKLIST_FOR_MODERATORS
5698 - `13` NEW_INSTANCE_FOLLOWER
5700 - `14` AUTO_INSTANCE_FOLLOWING
5706 - $ref: '#/components/schemas/VideoInfo'
5710 $ref: '#/components/schemas/ActorInfo'
5719 $ref: '#/components/schemas/VideoInfo'
5740 $ref: '#/components/schemas/VideoInfo'
5742 $ref: '#/components/schemas/ActorInfo'
5751 - $ref: '#/components/schemas/VideoInfo'
5760 - $ref: '#/components/schemas/VideoInfo'
5764 - $ref: '#/components/schemas/ActorInfo'
5772 $ref: '#/components/schemas/ActorInfo'
5800 NotificationListResponse:
5809 $ref: '#/components/schemas/Notification'
5814 example: peertube-plugin-auth-ldap
5842 example: https://framagit.org/framasoft/peertube/official-plugins/tree/master/peertube-plugin-auth-ldap
5845 additionalProperties: true
5861 $ref: '#/components/schemas/Plugin'
5868 description: User can stream multiple times in a permanent live
5877 description: RTMP stream key to use to stream into this live video
5881 description: User can stream multiple times in a permanent live
5888 'https://search.example.org/api/v1/search/videos':
5890 summary: third-party search index MAY be used instead of the local index, if enabled by the instance admin. see `searchTarget`
5893 description: successful operation
5897 $ref: '#/components/schemas/VideoListResponse'