diff options
author | Chocobozzz <me@florianbigard.com> | 2020-07-10 09:51:56 +0200 |
---|---|---|
committer | Chocobozzz <chocobozzz@cpy.re> | 2020-07-10 14:02:41 +0200 |
commit | e3489df98e0d31caa890f2d50d0e531c33a06d86 (patch) | |
tree | a0f985bf024130195339e51b65a88ffb1ad52259 /support/doc/api/openapi.yaml | |
parent | 17b07dc5a2c3ac7055a0490e34b3a1a527286895 (diff) | |
download | PeerTube-e3489df98e0d31caa890f2d50d0e531c33a06d86.tar.gz PeerTube-e3489df98e0d31caa890f2d50d0e531c33a06d86.tar.zst PeerTube-e3489df98e0d31caa890f2d50d0e531c33a06d86.zip |
Update openapi
Diffstat (limited to 'support/doc/api/openapi.yaml')
-rw-r--r-- | support/doc/api/openapi.yaml | 91 |
1 files changed, 48 insertions, 43 deletions
diff --git a/support/doc/api/openapi.yaml b/support/doc/api/openapi.yaml index 1c5a60f6e..a0d086324 100644 --- a/support/doc/api/openapi.yaml +++ b/support/doc/api/openapi.yaml | |||
@@ -1471,9 +1471,8 @@ paths: | |||
1471 | description: HTTP or Torrent/magnetURI import not enabled | 1471 | description: HTTP or Torrent/magnetURI import not enabled |
1472 | '400': | 1472 | '400': |
1473 | description: '`magnetUri` or `targetUrl` or a torrent file missing' | 1473 | description: '`magnetUri` or `targetUrl` or a torrent file missing' |
1474 | /videos/abuse: | 1474 | /abuses: |
1475 | get: | 1475 | get: |
1476 | deprecated: true | ||
1477 | summary: List abuses | 1476 | summary: List abuses |
1478 | security: | 1477 | security: |
1479 | - OAuth2: | 1478 | - OAuth2: |
@@ -1491,16 +1490,7 @@ paths: | |||
1491 | in: query | 1490 | in: query |
1492 | description: predefined reason the listed reports should contain | 1491 | description: predefined reason the listed reports should contain |
1493 | schema: | 1492 | schema: |
1494 | type: string | 1493 | $ref: '#/components/schemas/PredefinedAbuseReasons' |
1495 | enum: | ||
1496 | - violentOrAbusive | ||
1497 | - hatefulOrAbusive | ||
1498 | - spamOrMisleading | ||
1499 | - privacy | ||
1500 | - rights | ||
1501 | - serverRules | ||
1502 | - thumbnails | ||
1503 | - captions | ||
1504 | - name: search | 1494 | - name: search |
1505 | in: query | 1495 | in: query |
1506 | description: plain search that will match with video titles, reporter names and more | 1496 | description: plain search that will match with video titles, reporter names and more |
@@ -1564,17 +1554,13 @@ paths: | |||
1564 | type: array | 1554 | type: array |
1565 | items: | 1555 | items: |
1566 | $ref: '#/components/schemas/VideoAbuse' | 1556 | $ref: '#/components/schemas/VideoAbuse' |
1567 | '/videos/{id}/abuse': | 1557 | |
1568 | post: | 1558 | post: |
1569 | deprecated: true | ||
1570 | summary: Report an abuse | 1559 | summary: Report an abuse |
1571 | security: | 1560 | security: |
1572 | - OAuth2: [] | 1561 | - OAuth2: [] |
1573 | tags: | 1562 | tags: |
1574 | - Abuses | 1563 | - Abuses |
1575 | - Videos | ||
1576 | parameters: | ||
1577 | - $ref: '#/components/parameters/idOrUUID' | ||
1578 | requestBody: | 1564 | requestBody: |
1579 | required: true | 1565 | required: true |
1580 | content: | 1566 | content: |
@@ -1587,27 +1573,34 @@ paths: | |||
1587 | type: string | 1573 | type: string |
1588 | minLength: 4 | 1574 | minLength: 4 |
1589 | predefinedReasons: | 1575 | predefinedReasons: |
1590 | description: Reason categories that help triage reports | 1576 | $ref: '#/components/schemas/PredefinedAbuseReasons' |
1591 | type: array | 1577 | |
1592 | items: | 1578 | video: |
1593 | type: string | 1579 | type: object |
1594 | enum: | 1580 | properties: |
1595 | - violentOrAbusive | 1581 | id: |
1596 | - hatefulOrAbusive | 1582 | description: Video id to report |
1597 | - spamOrMisleading | 1583 | type: number |
1598 | - privacy | 1584 | startAt: |
1599 | - rights | 1585 | type: integer |
1600 | - serverRules | 1586 | description: Timestamp in the video that marks the beginning of the report |
1601 | - thumbnails | 1587 | minimum: 0 |
1602 | - captions | 1588 | endAt: |
1603 | startAt: | 1589 | type: integer |
1604 | type: integer | 1590 | description: Timestamp in the video that marks the ending of the report |
1605 | description: Timestamp in the video that marks the beginning of the report | 1591 | minimum: 0 |
1606 | minimum: 0 | 1592 | comment: |
1607 | endAt: | 1593 | type: object |
1608 | type: integer | 1594 | properties: |
1609 | description: Timestamp in the video that marks the ending of the report | 1595 | id: |
1610 | minimum: 0 | 1596 | description: Comment id to report |
1597 | type: number | ||
1598 | account: | ||
1599 | type: object | ||
1600 | properties: | ||
1601 | id: | ||
1602 | description: Account id to report | ||
1603 | type: number | ||
1611 | required: | 1604 | required: |
1612 | - reason | 1605 | - reason |
1613 | responses: | 1606 | responses: |
@@ -1615,9 +1608,8 @@ paths: | |||
1615 | description: successful operation | 1608 | description: successful operation |
1616 | '400': | 1609 | '400': |
1617 | description: incorrect request parameters | 1610 | description: incorrect request parameters |
1618 | '/videos/{id}/abuse/{abuseId}': | 1611 | '/abuses/{abuseId}': |
1619 | put: | 1612 | put: |
1620 | deprecated: true | ||
1621 | summary: Update an abuse | 1613 | summary: Update an abuse |
1622 | security: | 1614 | security: |
1623 | - OAuth2: | 1615 | - OAuth2: |
@@ -1626,7 +1618,6 @@ paths: | |||
1626 | tags: | 1618 | tags: |
1627 | - Abuses | 1619 | - Abuses |
1628 | parameters: | 1620 | parameters: |
1629 | - $ref: '#/components/parameters/idOrUUID' | ||
1630 | - $ref: '#/components/parameters/abuseId' | 1621 | - $ref: '#/components/parameters/abuseId' |
1631 | requestBody: | 1622 | requestBody: |
1632 | content: | 1623 | content: |
@@ -1645,7 +1636,6 @@ paths: | |||
1645 | '404': | 1636 | '404': |
1646 | description: abuse not found | 1637 | description: abuse not found |
1647 | delete: | 1638 | delete: |
1648 | deprecated: true | ||
1649 | tags: | 1639 | tags: |
1650 | - Abuses | 1640 | - Abuses |
1651 | summary: Delete an abuse | 1641 | summary: Delete an abuse |
@@ -1654,7 +1644,6 @@ paths: | |||
1654 | - admin | 1644 | - admin |
1655 | - moderator | 1645 | - moderator |
1656 | parameters: | 1646 | parameters: |
1657 | - $ref: '#/components/parameters/idOrUUID' | ||
1658 | - $ref: '#/components/parameters/abuseId' | 1647 | - $ref: '#/components/parameters/abuseId' |
1659 | responses: | 1648 | responses: |
1660 | '204': | 1649 | '204': |
@@ -4570,6 +4559,22 @@ components: | |||
4570 | updatedAt: | 4559 | updatedAt: |
4571 | type: string | 4560 | type: string |
4572 | format: date-time | 4561 | format: date-time |
4562 | |||
4563 | PredefinedAbuseReasons: | ||
4564 | description: Reason categories that help triage reports | ||
4565 | type: array | ||
4566 | items: | ||
4567 | type: string | ||
4568 | enum: | ||
4569 | - violentOrAbusive | ||
4570 | - hatefulOrAbusive | ||
4571 | - spamOrMisleading | ||
4572 | - privacy | ||
4573 | - rights | ||
4574 | - serverRules | ||
4575 | - thumbnails | ||
4576 | - captions | ||
4577 | |||
4573 | Job: | 4578 | Job: |
4574 | properties: | 4579 | properties: |
4575 | id: | 4580 | id: |