chore: generate OpenAPI specification

This commit is contained in:
Revolt CI
2023-04-22 20:30:57 +00:00
parent 400a52616a
commit 2dba8ab628
+804 -8
View File
@@ -5491,6 +5491,805 @@
}
}
},
{
"description": "Core crate error",
"type": "object",
"oneOf": [
{
"description": "This error was not labeled :(",
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"LabelMe"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"AlreadyOnboarded"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UsernameTaken"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidUsername"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UnknownUser"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"AlreadyFriends"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"AlreadySentRequest"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"Blocked"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"BlockedByOther"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotFriends"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UnknownChannel"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UnknownAttachment"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UnknownMessage"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"CannotEditMessage"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"CannotJoinCall"
]
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyAttachments"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyReplies"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyChannels"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"EmptyMessage"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"PayloadTooLarge"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"CannotRemoveYourself"
]
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"GroupTooLarge"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"AlreadyInGroup"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotInGroup"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"UnknownServer"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidRole"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"Banned"
]
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyServers"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyEmoji"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"max",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"TooManyRoles"
]
},
"max": {
"type": "integer",
"format": "uint",
"minimum": 0.0
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"ReachedMaximumBots"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"IsBot"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"BotIsPrivate"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"CannotReportYourself"
]
}
}
},
{
"type": "object",
"required": [
"permission",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"MissingPermission"
]
},
"permission": {
"type": "string"
}
}
},
{
"type": "object",
"required": [
"permission",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"MissingUserPermission"
]
},
"permission": {
"type": "string"
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotElevated"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotPrivileged"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"CannotGiveMissingPermissions"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotOwner"
]
}
}
},
{
"type": "object",
"required": [
"collection",
"operation",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"DatabaseError"
]
},
"operation": {
"type": "string"
},
"collection": {
"type": "string"
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InternalError"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidOperation"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidCredentials"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidProperty"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"InvalidSession"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"DuplicateNonce"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NotFound"
]
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"NoEffect"
]
}
}
},
{
"type": "object",
"required": [
"error",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"FailedValidation"
]
},
"error": {
"type": "string"
}
}
},
{
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"VosoUnavailable"
]
}
}
}
],
"required": [
"location",
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"Core"
]
},
"location": {
"description": "Where this error occurred",
"type": "string"
}
}
},
{
"type": "object",
"required": [
@@ -8436,6 +9235,8 @@
"type": "object",
"required": [
"_id",
"avatar",
"description",
"username"
],
"properties": {
@@ -8449,22 +9250,17 @@
},
"avatar": {
"description": "Profile Avatar",
"allOf": [
{
"$ref": "#/components/schemas/File"
}
],
"nullable": true
"type": "string"
},
"description": {
"description": "Profile Description",
"type": "string",
"nullable": true
"type": "string"
}
}
},
"BotResponse": {
"title": "Bot Response",
"description": "TODO: move to revolt-models",
"type": "object",
"required": [
"bot",