feat: アンテナの公開#17428
Draft
samunohito wants to merge 4 commits into
Draft
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #17428 +/- ##
============================================
+ Coverage 13.97% 25.15% +11.18%
============================================
Files 237 1163 +926
Lines 11273 39628 +28355
Branches 3728 11003 +7275
============================================
+ Hits 1575 9970 +8395
- Misses 7578 23774 +16196
- Partials 2120 5884 +3764 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
|
このPRによるapi.jsonの差分 差分はこちら--- base
+++ head
@@ -20324,6 +20324,9 @@
},
"excludeNotesInSensitiveChannel": {
"type": "boolean"
+ },
+ "isPublic": {
+ "type": "boolean"
}
},
"required": [
@@ -20643,6 +20646,172 @@
}
}
},
+ "/antennas/favorite": {
+ "post": {
+ "operationId": "post___antennas___favorite",
+ "summary": "antennas/favorite",
+ "description": "No description provided.\n\n**Credential required**: *Yes* / **Permission**: *write:antenna-favorite*",
+ "externalDocs": {
+ "description": "Source code",
+ "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/favorite.ts"
+ },
+ "tags": [
+ "antennas"
+ ],
+ "security": [
+ {
+ "bearerAuth": []
+ }
+ ],
+ "requestBody": {
+ "required": true,
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "antennaId": {
+ "type": "string",
+ "format": "misskey:id"
+ }
+ },
+ "required": [
+ "antennaId"
+ ]
+ }
+ }
+ }
+ },
+ "responses": {
+ "204": {
+ "description": "OK (without any results)"
+ },
+ "400": {
+ "description": "Client error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "NO_SUCH_ANTENNA": {
+ "value": {
+ "error": {
+ "message": "No such antenna.",
+ "code": "NO_SUCH_ANTENNA",
+ "id": "a4d3b7f0-1c1e-4e16-9a8b-3a7e1d2f4b6a"
+ }
+ }
+ },
+ "ALREADY_FAVORITED": {
+ "value": {
+ "error": {
+ "message": "The antenna has already been favorited.",
+ "code": "ALREADY_FAVORITED",
+ "id": "d2a4e1c6-3b5e-4a8d-9f0c-1e2d3f4a5b6c"
+ }
+ }
+ },
+ "INVALID_PARAM": {
+ "value": {
+ "error": {
+ "message": "Invalid param.",
+ "code": "INVALID_PARAM",
+ "id": "3d81ceae-475f-4600-b2a8-2bc116157532"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "401": {
+ "description": "Authentication error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "CREDENTIAL_REQUIRED": {
+ "value": {
+ "error": {
+ "message": "Credential required.",
+ "code": "CREDENTIAL_REQUIRED",
+ "id": "1384574d-a912-4b81-8601-c7b1c4085df1"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "403": {
+ "description": "Forbidden error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "AUTHENTICATION_FAILED": {
+ "value": {
+ "error": {
+ "message": "Authentication failed. Please ensure your token is correct.",
+ "code": "AUTHENTICATION_FAILED",
+ "id": "b0a7f5f8-dc2f-4171-b91f-de88ad238e14"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "418": {
+ "description": "I'm Ai",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "I_AM_AI": {
+ "value": {
+ "error": {
+ "message": "You sent a request to Ai-chan, Misskey's showgirl, instead of the server.",
+ "code": "I_AM_AI",
+ "id": "60c46cd1-f23a-46b1-bebe-5d2b73951a84"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "500": {
+ "description": "Internal server error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INTERNAL_ERROR": {
+ "value": {
+ "error": {
+ "message": "Internal error occurred. Please contact us if the error persists.",
+ "code": "INTERNAL_ERROR",
+ "id": "5d37dbcb-891e-41ca-a3d6-e690c97775ac"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ },
"/antennas/list": {
"post": {
"operationId": "post___antennas___list",
@@ -20782,23 +20951,157 @@
}
}
},
- "/antennas/notes": {
+ "/antennas/my-favorites": {
"post": {
- "operationId": "post___antennas___notes",
- "summary": "antennas/notes",
- "description": "No description provided.\n\n**Credential required**: *Yes* / **Permission**: *read:account*",
+ "operationId": "post___antennas___my-favorites",
+ "summary": "antennas/my-favorites",
+ "description": "No description provided.\n\n**Credential required**: *Yes* / **Permission**: *read:antenna-favorite*",
"externalDocs": {
"description": "Source code",
- "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/notes.ts"
+ "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/my-favorites.ts"
},
"tags": [
- "antennas"
+ "account"
],
"security": [
{
"bearerAuth": []
}
],
+ "responses": {
+ "200": {
+ "description": "OK (with results)",
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/Antenna"
+ }
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "Client error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INVALID_PARAM": {
+ "value": {
+ "error": {
+ "message": "Invalid param.",
+ "code": "INVALID_PARAM",
+ "id": "3d81ceae-475f-4600-b2a8-2bc116157532"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "401": {
+ "description": "Authentication error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "CREDENTIAL_REQUIRED": {
+ "value": {
+ "error": {
+ "message": "Credential required.",
+ "code": "CREDENTIAL_REQUIRED",
+ "id": "1384574d-a912-4b81-8601-c7b1c4085df1"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "403": {
+ "description": "Forbidden error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "AUTHENTICATION_FAILED": {
+ "value": {
+ "error": {
+ "message": "Authentication failed. Please ensure your token is correct.",
+ "code": "AUTHENTICATION_FAILED",
+ "id": "b0a7f5f8-dc2f-4171-b91f-de88ad238e14"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "418": {
+ "description": "I'm Ai",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "I_AM_AI": {
+ "value": {
+ "error": {
+ "message": "You sent a request to Ai-chan, Misskey's showgirl, instead of the server.",
+ "code": "I_AM_AI",
+ "id": "60c46cd1-f23a-46b1-bebe-5d2b73951a84"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "500": {
+ "description": "Internal server error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INTERNAL_ERROR": {
+ "value": {
+ "error": {
+ "message": "Internal error occurred. Please contact us if the error persists.",
+ "code": "INTERNAL_ERROR",
+ "id": "5d37dbcb-891e-41ca-a3d6-e690c97775ac"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "/antennas/notes": {
+ "post": {
+ "operationId": "post___antennas___notes",
+ "summary": "antennas/notes",
+ "description": "No description provided.\n\n**Credential required**: *No* / **Permission**: *read:account*",
+ "externalDocs": {
+ "description": "Source code",
+ "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/notes.ts"
+ },
+ "tags": [
+ "antennas"
+ ],
"requestBody": {
"required": true,
"content": {
@@ -20973,7 +21276,7 @@
"post": {
"operationId": "post___antennas___show",
"summary": "antennas/show",
- "description": "No description provided.\n\n**Credential required**: *Yes* / **Permission**: *read:account*",
+ "description": "No description provided.\n\n**Credential required**: *No* / **Permission**: *read:account*",
"externalDocs": {
"description": "Source code",
"url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/show.ts"
@@ -20981,11 +21284,6 @@
"tags": [
"antennas"
],
- "security": [
- {
- "bearerAuth": []
- }
- ],
"requestBody": {
"required": true,
"content": {
@@ -21133,6 +21431,172 @@
}
}
},
+ "/antennas/unfavorite": {
+ "post": {
+ "operationId": "post___antennas___unfavorite",
+ "summary": "antennas/unfavorite",
+ "description": "No description provided.\n\n**Credential required**: *Yes* / **Permission**: *write:antenna-favorite*",
+ "externalDocs": {
+ "description": "Source code",
+ "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/antennas/unfavorite.ts"
+ },
+ "tags": [
+ "antennas"
+ ],
+ "security": [
+ {
+ "bearerAuth": []
+ }
+ ],
+ "requestBody": {
+ "required": true,
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "antennaId": {
+ "type": "string",
+ "format": "misskey:id"
+ }
+ },
+ "required": [
+ "antennaId"
+ ]
+ }
+ }
+ }
+ },
+ "responses": {
+ "204": {
+ "description": "OK (without any results)"
+ },
+ "400": {
+ "description": "Client error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "NO_SUCH_ANTENNA": {
+ "value": {
+ "error": {
+ "message": "No such antenna.",
+ "code": "NO_SUCH_ANTENNA",
+ "id": "e1f2a3b4-c5d6-4e7f-8a9b-0c1d2e3f4a5b"
+ }
+ }
+ },
+ "NOT_FAVORITED": {
+ "value": {
+ "error": {
+ "message": "You have not favorited the antenna.",
+ "code": "NOT_FAVORITED",
+ "id": "b6a7c8d9-e0f1-4a2b-9c3d-4e5f6a7b8c9d"
+ }
+ }
+ },
+ "INVALID_PARAM": {
+ "value": {
+ "error": {
+ "message": "Invalid param.",
+ "code": "INVALID_PARAM",
+ "id": "3d81ceae-475f-4600-b2a8-2bc116157532"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "401": {
+ "description": "Authentication error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "CREDENTIAL_REQUIRED": {
+ "value": {
+ "error": {
+ "message": "Credential required.",
+ "code": "CREDENTIAL_REQUIRED",
+ "id": "1384574d-a912-4b81-8601-c7b1c4085df1"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "403": {
+ "description": "Forbidden error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "AUTHENTICATION_FAILED": {
+ "value": {
+ "error": {
+ "message": "Authentication failed. Please ensure your token is correct.",
+ "code": "AUTHENTICATION_FAILED",
+ "id": "b0a7f5f8-dc2f-4171-b91f-de88ad238e14"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "418": {
+ "description": "I'm Ai",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "I_AM_AI": {
+ "value": {
+ "error": {
+ "message": "You sent a request to Ai-chan, Misskey's showgirl, instead of the server.",
+ "code": "I_AM_AI",
+ "id": "60c46cd1-f23a-46b1-bebe-5d2b73951a84"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "500": {
+ "description": "Internal server error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INTERNAL_ERROR": {
+ "value": {
+ "error": {
+ "message": "Internal error occurred. Please contact us if the error persists.",
+ "code": "INTERNAL_ERROR",
+ "id": "5d37dbcb-891e-41ca-a3d6-e690c97775ac"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ },
"/antennas/update": {
"post": {
"operationId": "post___antennas___update",
@@ -21224,6 +21688,9 @@
},
"excludeNotesInSensitiveChannel": {
"type": "boolean"
+ },
+ "isPublic": {
+ "type": "boolean"
}
},
"required": [
@@ -81351,6 +81818,179 @@
}
}
},
+ "/users/antennas": {
+ "post": {
+ "operationId": "post___users___antennas",
+ "summary": "users/antennas",
+ "description": "Show all public antennas this user owns.\n\n**Credential required**: *No*",
+ "externalDocs": {
+ "description": "Source code",
+ "url": "https://github.com/misskey-dev/misskey/blob/develop/packages/backend/src/server/api/endpoints/users/antennas.ts"
+ },
+ "tags": [
+ "users"
+ ],
+ "requestBody": {
+ "required": true,
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "userId": {
+ "type": "string",
+ "format": "misskey:id"
+ },
+ "limit": {
+ "type": "integer",
+ "minimum": 1,
+ "maximum": 100,
+ "default": 10
+ },
+ "sinceId": {
+ "type": "string",
+ "format": "misskey:id"
+ },
+ "untilId": {
+ "type": "string",
+ "format": "misskey:id"
+ },
+ "sinceDate": {
+ "type": "integer"
+ },
+ "untilDate": {
+ "type": "integer"
+ }
+ },
+ "required": [
+ "userId"
+ ]
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "OK (with results)",
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/Antenna"
+ }
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "Client error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INVALID_PARAM": {
+ "value": {
+ "error": {
+ "message": "Invalid param.",
+ "code": "INVALID_PARAM",
+ "id": "3d81ceae-475f-4600-b2a8-2bc116157532"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "401": {
+ "description": "Authentication error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "CREDENTIAL_REQUIRED": {
+ "value": {
+ "error": {
+ "message": "Credential required.",
+ "code": "CREDENTIAL_REQUIRED",
+ "id": "1384574d-a912-4b81-8601-c7b1c4085df1"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "403": {
+ "description": "Forbidden error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "AUTHENTICATION_FAILED": {
+ "value": {
+ "error": {
+ "message": "Authentication failed. Please ensure your token is correct.",
+ "code": "AUTHENTICATION_FAILED",
+ "id": "b0a7f5f8-dc2f-4171-b91f-de88ad238e14"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "418": {
+ "description": "I'm Ai",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "I_AM_AI": {
+ "value": {
+ "error": {
+ "message": "You sent a request to Ai-chan, Misskey's showgirl, instead of the server.",
+ "code": "I_AM_AI",
+ "id": "60c46cd1-f23a-46b1-bebe-5d2b73951a84"
+ }
+ }
+ }
+ }
+ }
+ }
+ },
+ "500": {
+ "description": "Internal server error",
+ "content": {
+ "application/json": {
+ "schema": {
+ "$ref": "#/components/schemas/Error"
+ },
+ "examples": {
+ "INTERNAL_ERROR": {
+ "value": {
+ "error": {
+ "message": "Internal error occurred. Please contact us if the error persists.",
+ "code": "INTERNAL_ERROR",
+ "id": "5d37dbcb-891e-41ca-a3d6-e690c97775ac"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ },
"/users/clips": {
"post": {
"operationId": "post___users___clips",
@@ -91914,6 +92554,23 @@
"excludeNotesInSensitiveChannel": {
"type": "boolean",
"default": false
+ },
+ "isPublic": {
+ "type": "boolean",
+ "default": false
+ },
+ "userId": {
+ "type": "string",
+ "format": "id"
+ },
+ "user": {
+ "$ref": "#/components/schemas/UserLite"
+ },
+ "favoritedCount": {
+ "type": "number"
+ },
+ "isFavorited": {
+ "type": "boolean"
}
},
"required": [
@@ -91933,7 +92590,11 @@
"isActive",
"hasUnreadNote",
"notify",
- "excludeNotesInSensitiveChannel"
+ "excludeNotesInSensitiveChannel",
+ "isPublic",
+ "userId",
+ "user",
+ "favoritedCount"
]
},
"Clip": { |
Contributor
Backend memory usage comparisonBefore GC
After GC
After Request
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
アンテナを公開し、第三者ユーザが閲覧できるようにします。
Why
fix #11132
Additional info (optional)
Checklist