|
13 | 13 | - name: Migration - Registration not required |
14 | 14 | - name: Services - Registration required |
15 | 15 | - name: Services - Registration not required |
| 16 | + - name: Resource addressing with relative roots - Registration not required |
| 17 | + - name: Resource addressing with relative roots - Registration required |
16 | 18 | paths: |
17 | 19 | /.p2/core/v1/challenge: |
18 | 20 | get: |
@@ -743,6 +745,73 @@ paths: |
743 | 745 | type: string |
744 | 746 | security: |
745 | 747 | - BearerAuth: [] |
| 748 | + /.p2/core/v1/resource/{rid}: |
| 749 | + get: |
| 750 | + operationId: Unregistered_getResource |
| 751 | + summary: Get resource by resource ID |
| 752 | + description: |- |
| 753 | + Retrieve a [RawR](https://docs.polyphony.chat/Protocol%20Specifications/core/#731-resource-addressing-with-relative-roots) |
| 754 | + resource by specifying the ID of the resource. |
| 755 | + parameters: |
| 756 | + - name: rid |
| 757 | + in: path |
| 758 | + required: true |
| 759 | + description: ': Resource Identifier - unique identifier for a resource.' |
| 760 | + schema: |
| 761 | + type: string |
| 762 | + responses: |
| 763 | + '200': |
| 764 | + description: |- |
| 765 | + - `200`: File found and retrieved. |
| 766 | + - `401`: Server or resource requires authentication to access this endpoint. |
| 767 | + - `403`: Server or resource not accessible for the actor making this request. |
| 768 | + - `404`: Resource not found. |
| 769 | + content: |
| 770 | + application/json: |
| 771 | + schema: |
| 772 | + $ref: '#/components/schemas/TypeSpec.Http.File' |
| 773 | + '401': |
| 774 | + description: |- |
| 775 | + - `200`: File found and retrieved. |
| 776 | + - `401`: Server or resource requires authentication to access this endpoint. |
| 777 | + - `403`: Server or resource not accessible for the actor making this request. |
| 778 | + - `404`: Resource not found. |
| 779 | + '403': |
| 780 | + description: |- |
| 781 | + - `200`: File found and retrieved. |
| 782 | + - `401`: Server or resource requires authentication to access this endpoint. |
| 783 | + - `403`: Server or resource not accessible for the actor making this request. |
| 784 | + - `404`: Resource not found. |
| 785 | + '404': |
| 786 | + description: |- |
| 787 | + - `200`: File found and retrieved. |
| 788 | + - `401`: Server or resource requires authentication to access this endpoint. |
| 789 | + - `403`: Server or resource not accessible for the actor making this request. |
| 790 | + - `404`: Resource not found. |
| 791 | + tags: |
| 792 | + - Resource addressing with relative roots - Registration not required |
| 793 | + post: |
| 794 | + operationId: Registered_postResource |
| 795 | + summary: Upload RawR resource |
| 796 | + parameters: |
| 797 | + - name: rid |
| 798 | + in: path |
| 799 | + required: true |
| 800 | + schema: |
| 801 | + type: string |
| 802 | + - name: Content-Length |
| 803 | + in: header |
| 804 | + required: true |
| 805 | + schema: |
| 806 | + type: integer |
| 807 | + format: uint64 |
| 808 | + responses: |
| 809 | + '200': |
| 810 | + description: The request has succeeded. |
| 811 | + tags: |
| 812 | + - Resource addressing with relative roots - Registration required |
| 813 | + security: |
| 814 | + - BearerAuth: [] |
746 | 815 | /.p2/core/v1/services: |
747 | 816 | post: |
748 | 817 | operationId: Registered_registerService |
@@ -1191,6 +1260,18 @@ paths: |
1191 | 1260 | - {} |
1192 | 1261 | components: |
1193 | 1262 | schemas: |
| 1263 | + TypeSpec.Http.File: |
| 1264 | + type: object |
| 1265 | + required: |
| 1266 | + - contents |
| 1267 | + properties: |
| 1268 | + contentType: |
| 1269 | + type: string |
| 1270 | + filename: |
| 1271 | + type: string |
| 1272 | + contents: |
| 1273 | + type: string |
| 1274 | + format: byte |
1194 | 1275 | Version: |
1195 | 1276 | type: string |
1196 | 1277 | enum: |
|
0 commit comments