Managing plugins installed from a local path or from NPM, or search for new ones.
externalDocs:
url: https://docs.joinpeertube.org/#/api-plugins
- - name: Video Abuses
+ - name: Abuses
description: |
- Video abuses deal with reports of local or remote videos alike.
+ Abuses deal with reports of local or remote videos/comments/accounts alike.
- name: Video
description: |
Operations dealing with listing, uploading, fetching or modifying videos.
- Search
- name: Moderation
tags:
- - Video Abuses
+ - Abuses
- Video Blocks
- Account Blocks
- Server Blocks
$ref: '#/components/schemas/NotificationSettingValue'
newCommentOnMyVideo:
$ref: '#/components/schemas/NotificationSettingValue'
- videoAbuseAsModerator:
+ abuseAsModerator:
$ref: '#/components/schemas/NotificationSettingValue'
videoAutoBlacklistAsModerator:
$ref: '#/components/schemas/NotificationSettingValue'
description: HTTP or Torrent/magnetURI import not enabled
'400':
description: '`magnetUri` or `targetUrl` or a torrent file missing'
- /videos/abuse:
+ /abuses:
get:
- deprecated: true
- summary: List video abuses
+ summary: List abuses
security:
- OAuth2:
- admin
- moderator
tags:
- - Video Abuses
+ - Abuses
parameters:
- name: id
in: query
in: query
description: predefined reason the listed reports should contain
schema:
- type: string
- enum:
- - violentOrAbusive
- - hatefulOrAbusive
- - spamOrMisleading
- - privacy
- - rights
- - serverRules
- - thumbnails
- - captions
+ $ref: '#/components/schemas/PredefinedAbuseReasons'
- name: search
in: query
description: plain search that will match with video titles, reporter names and more
type: string
- name: state
in: query
- description: 'The video playlist privacy (Pending = `1`, Rejected = `2`, Accepted = `3`)'
+ description: 'The abuse state (Pending = `1`, Rejected = `2`, Accepted = `3`)'
schema:
type: integer
enum:
description: only list reports of a specific video channel
schema:
type: string
+ - name: videoIs
+ in: query
+ description: only list blacklisted or deleted videos
+ schema:
+ type: string
+ enum:
+ - 'deleted'
+ - 'blacklisted'
+ - name: filter
+ in: query
+ description: only list account, comment or video reports
+ schema:
+ type: string
+ enum:
+ - 'video'
+ - 'comment'
+ - 'account'
- $ref: '#/components/parameters/start'
- $ref: '#/components/parameters/count'
- $ref: '#/components/parameters/abusesSort'
type: array
items:
$ref: '#/components/schemas/VideoAbuse'
- '/videos/{id}/abuse':
+
post:
- deprecated: true
summary: Report an abuse
security:
- OAuth2: []
tags:
- - Video Abuses
- - Videos
- parameters:
- - $ref: '#/components/parameters/idOrUUID'
+ - Abuses
requestBody:
required: true
content:
type: string
minLength: 4
predefinedReasons:
- description: Reason categories that help triage reports
- type: array
- items:
- type: string
- enum:
- - violentOrAbusive
- - hatefulOrAbusive
- - spamOrMisleading
- - privacy
- - rights
- - serverRules
- - thumbnails
- - captions
- startAt:
- type: integer
- description: Timestamp in the video that marks the beginning of the report
- minimum: 0
- endAt:
- type: integer
- description: Timestamp in the video that marks the ending of the report
- minimum: 0
+ $ref: '#/components/schemas/PredefinedAbuseReasons'
+
+ video:
+ type: object
+ properties:
+ id:
+ description: Video id to report
+ type: number
+ startAt:
+ type: integer
+ description: Timestamp in the video that marks the beginning of the report
+ minimum: 0
+ endAt:
+ type: integer
+ description: Timestamp in the video that marks the ending of the report
+ minimum: 0
+ comment:
+ type: object
+ properties:
+ id:
+ description: Comment id to report
+ type: number
+ account:
+ type: object
+ properties:
+ id:
+ description: Account id to report
+ type: number
required:
- reason
responses:
description: successful operation
'400':
description: incorrect request parameters
- '/videos/{id}/abuse/{abuseId}':
+ '/abuses/{abuseId}':
put:
- deprecated: true
summary: Update an abuse
security:
- OAuth2:
- admin
- moderator
tags:
- - Video Abuses
+ - Abuses
parameters:
- - $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/abuseId'
requestBody:
content:
type: object
properties:
state:
- $ref: '#/components/schemas/VideoAbuseStateSet'
+ $ref: '#/components/schemas/AbuseStateSet'
moderationComment:
type: string
description: Update the report comment visible only to the moderation team
'204':
description: successful operation
'404':
- description: video abuse not found
+ description: abuse not found
delete:
- deprecated: true
tags:
- - Video Abuses
+ - Abuses
summary: Delete an abuse
security:
- OAuth2:
- admin
- moderator
parameters:
- - $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/abuseId'
responses:
'204':
name: abuseId
in: path
required: true
- description: Video abuse id
+ description: Abuse id
schema:
type: integer
captionLanguage:
label:
type: string
- VideoAbuseStateSet:
+ AbuseStateSet:
type: integer
enum:
- 1
- 2
- 3
description: 'The video playlist privacy (Pending = `1`, Rejected = `2`, Accepted = `3`)'
- VideoAbuseStateConstant:
+ AbuseStateConstant:
properties:
id:
- $ref: '#/components/schemas/VideoAbuseStateSet'
+ $ref: '#/components/schemas/AbuseStateSet'
label:
type: string
- VideoAbusePredefinedReasons:
+ AbusePredefinedReasons:
type: array
items:
type: string
type: string
example: The video is a spam
predefinedReasons:
- $ref: '#/components/schemas/VideoAbusePredefinedReasons'
+ $ref: '#/components/schemas/AbusePredefinedReasons'
reporterAccount:
$ref: '#/components/schemas/Account'
state:
- $ref: '#/components/schemas/VideoAbuseStateConstant'
+ $ref: '#/components/schemas/AbuseStateConstant'
moderationComment:
type: string
example: Decided to ban the server since it spams us regularly
updatedAt:
type: string
format: date-time
+
+ PredefinedAbuseReasons:
+ description: Reason categories that help triage reports
+ type: array
+ items:
+ type: string
+ enum:
+ - violentOrAbusive
+ - hatefulOrAbusive
+ - spamOrMisleading
+ - privacy
+ - rights
+ - serverRules
+ - thumbnails
+ - captions
+
Job:
properties:
id:
description: The user daily video quota
videosCount:
type: integer
- videoAbusesCount:
+ abusesCount:
type: integer
- videoAbusesAcceptedCount:
+ abusesAcceptedCount:
type: integer
- videoAbusesCreatedCount:
+ abusesCreatedCount:
type: integer
videoCommentsCount:
type: integer
- `2` NEW_COMMENT_ON_MY_VIDEO
- - `3` NEW_VIDEO_ABUSE_FOR_MODERATORS
+ - `3` NEW_ABUSE_FOR_MODERATORS
- `4` BLACKLIST_ON_MY_VIDEO