From b838da2c6b823bee60c62dc498a7e35f8a5c9c95 Mon Sep 17 00:00:00 2001 From: Zaid Arshad Date: Tue, 28 May 2024 23:39:32 -0400 Subject: [PATCH] chore: update event typings --- .../api/lib/generated/api-typings/v1/ws.ts | 1553 ++++++++++++----- 1 file changed, 1105 insertions(+), 448 deletions(-) diff --git a/packages/api/lib/generated/api-typings/v1/ws.ts b/packages/api/lib/generated/api-typings/v1/ws.ts index 518027f4..2195a1fd 100644 --- a/packages/api/lib/generated/api-typings/v1/ws.ts +++ b/packages/api/lib/generated/api-typings/v1/ws.ts @@ -7,31 +7,27 @@ export type paths = Record; export type webhooks = Record; -export type components = { +export interface components { schemas: { _SocketEventEnvelope: { /** * Opcode - * * @description An operation code corresponding to the nature of the sent message (for example, success, failure, etc.) * @enum {integer} */ op: 0 | 1 | 2 | 8 | 9; /** * Data - * * @description Data of any form depending on the underlying event */ d?: Record; /** * Message ID - * * @description Message ID used for replaying events after a disconnect */ s?: string; /** * Event name - * * @description Event name for the given message */ t?: string; @@ -92,83 +88,81 @@ export type components = { /** * Message ID * Format: uuid - * * @description The ID of the message */ id: string; /** * Type - * * @description The type of chat message. "system" messages are generated by Guilded, while "default" messages are user or bot-generated. * @enum {string} */ type: "default" | "system"; /** * Server ID - * * @description The ID of the server */ serverId?: string; /** * Group ID - * * @description The ID of the group */ groupId?: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Content - * Format: markdown - * + * Format: chat markdown * @description The content of the message */ content?: string; + /** + * Hidden content link preview URLs + * @description Links in `content` to prevent unfurling as a link preview when displaying in Guilded + */ + hiddenLinkPreviewUrls?: string[]; embeds?: components["schemas"]["ChatEmbed"][]; /** @description Message IDs that were replied to */ replyMessageIds?: string[]; /** * Is private - * * @description If set, this message will only be seen by those mentioned or replied to */ isPrivate?: boolean; /** * Is silent - * * @description If set, this message did not notify mention or reply recipients * @default false */ isSilent?: boolean; + /** + * Is pinned + * @default false + */ + isPinned?: boolean; mentions?: components["schemas"]["Mentions"]; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the message was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this message (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Created by Webhook ID - * * @description The ID of the webhook who created this message, if it was created by a webhook */ createdByWebhookId?: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the message was updated at, if relevant */ updatedAt?: string; @@ -180,7 +174,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "messageId": "00000000-0000-0000-0000-000000000000" * } @@ -189,13 +183,12 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; @@ -203,13 +196,12 @@ export type components = { /** * Message ID * Format: uuid - * * @description The ID of the message */ messageId: string; }; /** - * @description Rich content sections optionally associated with chat messages. Properties with "webhook-markdown" support allow for the following: link, italic, bold, strikethrough, underline, inline code, block code, reaction, and mention. + * @description Rich content sections optionally associated with chat messages. Properties with "webhook-markdown" support allow for the following: link, italic, bold, strikethrough, underline, inline code, block code, reaction, mention, and role mention. * @example { * "title": "embed title", * "description": "embeds support a **different** __subset__ *of* markdown than other markdown fields. <@Ann6LewA>\n\n [links](https://www.guilded.gg) ```\ncheck this code out```\n\n:pizza: time!! ttyl", @@ -252,29 +244,25 @@ export type components = { ChatEmbed: { /** * Format: webhook-markdown - * * @description Main header of the embed */ title?: string; /** * Format: webhook-markdown - * * @description Subtext of the embed */ description?: string; /** * Format: uri - * * @description URL to linkify the `title` field with */ url?: string; - /** @description Decimal value of the color that the left border should be */ + /** @description The integer value corresponds to the decimal RGB representation for the color. The color that the left border should be */ color?: number; /** @description A small section at the bottom of the embed */ footer?: { /** * Format: media-uri - * * @description URL of a small image to put in the footer */ icon_url?: string; @@ -283,7 +271,6 @@ export type components = { }; /** * Format: date-time - * * @description A timestamp to put in the footer */ timestamp?: string; @@ -291,7 +278,6 @@ export type components = { thumbnail?: { /** * Format: media-uri - * * @description URL of the image */ url?: string; @@ -300,7 +286,6 @@ export type components = { image?: { /** * Format: media-uri - * * @description URL of the image */ url?: string; @@ -311,13 +296,11 @@ export type components = { name?: string; /** * Format: uri - * * @description URL to linkify the author's `name` field */ url?: string; /** * Format: media-uri - * * @description URL of a small image to display to the left of the author's `name` */ icon_url?: string; @@ -326,13 +309,11 @@ export type components = { fields?: { /** * Format: webhook-markdown - * * @description Header of the table-like cell */ name: string; /** * Format: webhook-markdown - * * @description Subtext of the table-like cell */ value: string; @@ -355,14 +336,13 @@ export type components = { SocialLink: { /** * Social link type - * * @description The type of social link that Guilded supports. Depending on this value, `handle` or `serviceId` may or may not be present * @enum {string} */ - type: "bnet" | "epic" | "facebook" | "origin" | "patreon" | "psn" | "roblox" | "steam" | "switch" | "twitch" | "twitter" | "xbox" | "youtube"; + type: "twitch" | "bnet" | "psn" | "xbox" | "steam" | "origin" | "youtube" | "twitter" | "facebook" | "switch" | "patreon" | "roblox" | "epic"; /** * User ID - * + * Format: user-id * @description The ID of the user that the social link is associated with */ userId: string; @@ -373,7 +353,6 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the social link was created at */ createdAt: string; @@ -403,53 +382,46 @@ export type components = { Mentions: { /** * Users - * * @description Info on mentioned users */ users?: { /** * User ID - * + * Format: user-id * @description The ID of the user */ id: string; }[]; /** * Channels - * * @description Info on mentioned channels */ channels?: { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ id: string; }[]; /** * Roles - * * @description Info on mentioned roles */ roles?: { /** * Role ID - * * @description The ID of the role */ id: number; }[]; /** * Everyone - * * @description If @everyone was mentioned */ everyone?: boolean; /** * Here - * * @description If @here was mentioned */ here?: boolean; @@ -469,29 +441,25 @@ export type components = { id: number; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the forum topic comment */ content: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic comment was created at */ createdAt: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic comment was updated at, if relevant */ updatedAt?: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; @@ -499,7 +467,6 @@ export type components = { forumTopicId: number; /** * Created by - * * @description The ID of the user who created this forum topic comment (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; @@ -512,7 +479,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "forumTopicId": 123456 * } @@ -521,13 +488,12 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; @@ -542,7 +508,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "forumTopicId": 123456, * "forumTopicCommentId": 1234567890 @@ -552,13 +518,12 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; @@ -572,6 +537,7 @@ export type components = { * @example { * "id": 123456, * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", * "channelId": "00000000-0000-0000-0000-000000000000", * "title": "Welcome new members!!", * "createdAt": "2021-06-15T20:15:00.706Z", @@ -584,66 +550,61 @@ export type components = { id: number; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Title - * * @description The title of the forum topic */ title: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this forum topic (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was updated at, if relevant */ updatedAt?: string; /** * Bumped at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was bumped at. This timestamp is updated whenever there is any activity on the posts within the forum topic. */ bumpedAt?: string; /** * Is pinned - * * @default false */ isPinned?: boolean; /** * Is locked - * * @default false */ isLocked?: boolean; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the forum topic */ content: string; @@ -653,6 +614,7 @@ export type components = { * @example { * "id": 123456, * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", * "channelId": "00000000-0000-0000-0000-000000000000", * "title": "Welcome new members!!", * "createdAt": "2021-06-15T20:15:00.706Z", @@ -664,59 +626,55 @@ export type components = { id: number; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Title - * * @description The title of the forum topic */ title: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this forum topic (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was updated at, if relevant */ updatedAt?: string; /** * Bumped at * Format: date-time - * * @description The ISO 8601 timestamp that the forum topic was bumped at. This timestamp is updated whenever there is any activity on the posts within the forum topic. */ bumpedAt?: string; /** * Is pinned - * * @default false */ isPinned?: boolean; /** * Is locked - * * @default false */ isLocked?: boolean; @@ -725,6 +683,7 @@ export type components = { * @example { * "id": "00000000-0000-0000-0000-000000000000", * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", * "channelId": "00000000-0000-0000-0000-000000000000", * "message": "Remember to say hello **world**!", * "createdAt": "2021-06-15T20:15:00.706Z", @@ -739,27 +698,28 @@ export type components = { ListItem: { /** * Format: uuid - * * @description The ID of the list item */ id: string; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Message - * Format: markdown - * + * Format: list item markdown * @description The message of the list item */ message: string; @@ -767,51 +727,43 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this list item (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Created by Webhook ID - * * @description The ID of the webhook who created this list item, if it was created by a webhook */ createdByWebhookId?: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was updated at, if relevant */ updatedAt?: string; /** * Updated by - * * @description The ID of the user who updated this list item */ updatedBy?: string; /** * Format: uuid - * * @description The ID of the parent list item if this list item is nested */ parentListItemId?: string; /** * Completed at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was completed at */ completedAt?: string; /** * Completed by - * * @description The ID of the user who completed this list item */ completedBy?: string; @@ -819,34 +771,29 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the note was created at. If this field is populated, then there's a note associated with the list item */ createdAt: string; /** * Created by - * * @description The ID of the user who created this note */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the note was updated at, if relevant */ updatedAt?: string; /** * Updated by - * * @description The ID of the user who updated this note */ updatedBy?: string; mentions?: components["schemas"]["Mentions"]; /** * Note - * Format: markdown - * + * Format: long-form markdown * @description The note of the list item */ content: string; @@ -869,27 +816,23 @@ export type components = { ListItemSummary: { /** * Format: uuid - * * @description The ID of the list item */ id: string; /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Message - * Format: markdown - * + * Format: list item markdown * @description The message of the list item */ message: string; @@ -897,51 +840,43 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this list item (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Created by Webhook ID - * * @description The ID of the webhook who created this list item, if it was created by a webhook */ createdByWebhookId?: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was updated at, if relevant */ updatedAt?: string; /** * Updated by - * * @description The ID of the user who updated this list item */ updatedBy?: string; /** * Format: uuid - * * @description The ID of the parent list item if this list item is nested */ parentListItemId?: string; /** * Completed at * Format: date-time - * * @description The ISO 8601 timestamp that the list item was completed at */ completedAt?: string; /** * Completed by - * * @description The ID of the user who completed this list item */ completedBy?: string; @@ -949,26 +884,22 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the note was created at. If this field is populated, then there's a note associated with the list item */ createdAt: string; /** * Created by - * * @description The ID of the user who created this note */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the note was updated at, if relevant */ updatedAt?: string; /** * Updated by - * * @description The ID of the user who updated this note */ updatedBy?: string; @@ -978,6 +909,7 @@ export type components = { * @example { * "id": 0, * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", * "channelId": "00000000-0000-0000-0000-000000000000", * "title": "HOW-TO: Smoke These Meats with Sweet Baby Ray's", * "content": "Spicy jalapeno bacon ipsum dolor amet sirloin ground round short loin, meatball brisket capicola tri-tip ham pork belly biltong corned beef chuck. Chicken ham brisket shank rump buffalo t-bone. Short loin sausage buffalo porchetta pork belly rump tri-tip frankfurter tail pork chop cow sirloin. Pancetta porchetta tail ball tip chislic beef ribs. Buffalo andouille leberkas jerky. Fatback shankle andouille beef. Cow kielbasa buffalo pork loin chislic meatloaf short loin rump meatball prosciutto.", @@ -990,33 +922,33 @@ export type components = { Doc: { /** * Doc ID - * * @description The ID of the doc */ id: number; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Title - * * @description The title of the doc */ title: string; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the doc */ content: string; @@ -1024,26 +956,22 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the doc was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this doc */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the doc was updated at, if relevant */ updatedAt?: string; /** * Updated by - * * @description The ID of the user who updated this doc */ updatedBy?: string; @@ -1061,47 +989,40 @@ export type components = { DocComment: { /** * Doc comment ID - * * @description The ID of the doc comment */ id: number; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the doc comment */ content: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the doc comment was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this doc comment (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the doc comment was updated at, if relevant */ updatedAt?: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Doc ID - * * @description The ID of the doc */ docId: number; @@ -1114,7 +1035,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "docId": 0 * } @@ -1123,20 +1044,18 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Doc ID - * * @description The ID of the doc */ docId: number; @@ -1148,7 +1067,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "docId": 0, * "docCommentId": 123456 @@ -1158,26 +1077,23 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Doc ID - * * @description The ID of the doc */ docId: number; /** * Doc comment ID - * * @description The ID of the doc comment */ docCommentId: number; @@ -1204,13 +1120,11 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the member was created at */ joinedAt: string; /** * Is owner - * * @default false */ isOwner?: boolean; @@ -1241,44 +1155,40 @@ export type components = { User: { /** * User ID - * + * Format: user-id * @description The ID of the user */ id: string; /** * User type - * * @description The type of user. If this property is absent, it can assumed to be of type `user` * @enum {string} */ type?: "bot" | "user"; /** * User name - * * @description The user's name */ name: string; /** * Avatar * Format: media-uri - * * @description The avatar image associated with the user */ avatar?: string; /** * Banner * Format: media-uri - * * @description The banner image associated with the user */ banner?: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the user was created at */ createdAt: string; + status?: components["schemas"]["UserStatus"]; }; /** * @example { @@ -1290,27 +1200,24 @@ export type components = { UserSummary: { /** * User ID - * + * Format: user-id * @description The ID of the user */ id: string; /** * User type - * * @description The type of user. If this property is absent, it can assumed to be of type `user` * @enum {string} */ type?: "bot" | "user"; /** * User name - * * @description The user's name */ name: string; /** * Avatar * Format: media-uri - * * @description The avatar image associated with the user */ avatar?: string; @@ -1331,20 +1238,17 @@ export type components = { user: components["schemas"]["UserSummary"]; /** * Reason - * * @description The reason for the ban as submitted by the banner */ reason?: string; /** * Created by - * * @description The ID of the user who created this server member ban */ createdBy: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the server member ban was created at */ createdAt: string; @@ -1365,7 +1269,6 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ id: string; @@ -1373,72 +1276,79 @@ export type components = { * @description The type of channel. This will determine what routes to use for creating content in a channel. For example, if this "chat", then one must use the routes for creating channel messages * @enum {string} */ - type: "announcements" | "calendar" | "chat" | "docs" | "forums" | "list" | "media" | "scheduling" | "stream" | "voice"; + type: "announcements" | "chat" | "calendar" | "forums" | "media" | "docs" | "voice" | "list" | "scheduling" | "stream"; /** @description The name of the channel */ name: string; - /** @description The topic of the channel */ + /** @description The topic of the channel. Not applicable to threads */ topic?: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the channel was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this channel */ createdBy: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the channel was updated at, if relevant */ updatedAt?: string; /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Channel ID * Format: uuid - * - * @description ID of the parent channel or parent thread, if present. Only relevant for server channels + * @description ID of the **root** channel or thread in the channel hierarchy. Only applicable to "chat", "voice", and "stream" channels and indicates that this channel is a thread, if present + */ + rootId?: string; + /** + * Channel ID + * Format: uuid + * @description ID of the **immediate** parent channel or thread in the channel hierarchy. Only applicable to "chat", "voice", and "stream" channels and indicates that this channel is a thread, if present */ parentId?: string; - /** @description Only relevant for server channels */ + /** + * Message ID + * Format: uuid + * @description The ID of the message that this channel was created off of. Only applicable to "chat", "voice", and "stream" channels and indicates that this channel is a thread, if present + */ + messageId?: string; + /** @description The category that the channel exists in. Only relevant for server channels */ categoryId?: number; /** * Group ID - * * @description The ID of the group */ groupId: string; /** - * Is public - * - * @description Whether the channel can be accessed from users who are not member of the server - * @default false + * @description What users can access the channel. Only applicable to server channels. If not present, this channel will respect normal permissions. `public` is accessible to everyone, even those who aren't of the server. `private` is only accessible to explicitly mentioned users. Currently, threads cannot be `public` and other channels cannot be `private`. Additionally, `private` threads can only exist with an associated `messageId` that is for a private message + * @enum {string|null} */ - isPublic?: boolean; + visibility?: "" | "private" | "public" | null; /** * Archived by - * * @description The ID of the user who archived this channel */ archivedBy?: string; /** * Archived at * Format: date-time - * * @description The ISO 8601 timestamp that the channel was archived at, if relevant */ archivedAt?: string; + /** + * Priority + * @description The priority of the channel will determine its position relative to other categories in the group. The higher the value, the higher up it will be displayed in the UI. Returned values can be null, in which case sorting will be done by `createdAt` in ascending order. Due to legacy issues, sending a null value is not possible + */ + priority?: number; }; /** * @example { @@ -1456,78 +1366,66 @@ export type components = { Server: { /** * Server ID - * * @description The ID of the server */ id: string; /** * Created by - * * @description The ID of the user who created this server */ ownerId: string; /** * Server type - * * @description The type of server designated from the server's settings page * @enum {string} */ - type?: "clan" | "community" | "friends" | "guild" | "organization" | "other" | "streaming" | "team"; + type?: "team" | "organization" | "community" | "clan" | "guild" | "friends" | "streaming" | "other"; /** * Server name - * * @description The name given to the server */ name: string; /** * Server URL - * * @description The URL that the server can be accessible from. For example, a value of "Guilded-Official" means the server can be accessible from https://www.guilded.gg/Guilded-Official */ url?: string; /** * Description - * * @description The description associated with the server */ about?: string; /** * Avatar * Format: media-uri - * * @description The avatar image associated with the server */ avatar?: string; /** * Banner * Format: media-uri - * * @description The banner image associated with the server */ banner?: string; /** * Timezone - * * @description The timezone associated with the server */ timezone?: string; /** * Is verified - * * @description The verified status of the server */ isVerified?: boolean; /** * Channel ID * Format: uuid - * * @description The channel ID of the default channel of the server. This channel is defined as the first chat or voice channel in the left sidebar of a server in our UI. This channel is useful for sending welcome messages, though note that a bot may not have permissions to interact with this channel depending on how the server is configured. */ defaultChannelId?: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the server was created at */ createdAt: string; @@ -1546,59 +1444,50 @@ export type components = { /** * Webhook ID * Format: uuid - * * @description The ID of the webhook */ id: string; /** * Name - * * @description The name of the webhook */ name: string; /** * Avatar * Format: media-uri - * * @description The avatar image associated with the webhook */ avatar?: string; /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the webhook was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this webhook */ createdBy: string; /** * Deleted at * Format: date-time - * * @description The ISO 8601 timestamp that the webhook was deleted at */ deletedAt?: string; /** * Token - * * @description The token of the webhook */ token?: string; @@ -1613,7 +1502,7 @@ export type components = { * "location": "My house!", * "url": "https://www.surprisepartygame.com/", * "duration": 60, - * "color": 16106496, + * "color": 6118369, * "startsAt": "2022-06-16T00:00:00.000Z", * "createdAt": "2021-06-15T20:15:00.706Z", * "createdBy": "Ann6LewA" @@ -1622,74 +1511,68 @@ export type components = { CalendarEvent: { /** * Calendar event ID - * * @description The ID of the calendar event */ id: number; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Name - * * @description The name of the event */ name: string; /** * Description - * Format: markdown - * + * Format: long-form markdown * @description The description of the event */ description?: string; /** * Location - * * @description The location of the event */ location?: string; /** * Format: uri - * * @description A URL to associate with the event */ url?: string; - /** @description The color of the event when viewing in the calendar */ + /** @description The integer value corresponds to the decimal RGB representation for the color. The color of the event when viewing in the calendar */ color?: number; /** @description Is this event a repeating event */ repeats?: boolean; /** * Calendar event series ID * Format: uuid - * * @description The ID of the calendar event series. Only shows if the event is repeating */ seriesId?: string; /** * Role IDs - * * @description The role IDs to restrict the event to */ roleIds?: number[]; /** * RSVP disabled - * * @description When disabled, users will not be able to RSVP to the event */ rsvpDisabled?: boolean; /** * Is all day - * * @description Does the event last all day */ isAllDay?: boolean; @@ -1700,13 +1583,11 @@ export type components = { /** * Starts at * Format: date-time - * * @description The ISO 8601 timestamp that the event starts at */ startsAt: string; /** * Duration - * * @description The duration of the event _**in minutes**_ */ duration?: number; @@ -1716,27 +1597,23 @@ export type components = { /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the event was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this event */ createdBy: string; cancellation?: { /** * Description - * Format: markdown - * + * Format: long-form markdown * @description The description of event cancellation */ description?: string; /** * Created by - * * @description The ID of the user who created this event cancellation */ createdBy: string; @@ -1746,32 +1623,28 @@ export type components = { * @example { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * } */ Emote: { /** * Emote ID - * * @description The ID of the emote */ id: number; /** * Name - * * @description The name of the emote */ name: string; /** * Emote URL * Format: media-uri - * * @description The URL of the emote image */ url: string; /** * Server ID - * * @description The ID of the server the emote was created on */ serverId?: string; @@ -1790,59 +1663,51 @@ export type components = { CalendarEventRsvp: { /** * Calendar event ID - * * @description The ID of the calendar event */ calendarEventId: number; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Server ID - * * @description The ID of the server */ serverId: string; /** * User ID - * + * Format: user-id * @description The ID of the user */ userId: string; /** * Status - * * @description The status of the RSVP * @enum {string} */ - status: "declined" | "going" | "invited" | "maybe" | "not responded" | "waitlisted"; + status: "going" | "maybe" | "declined" | "invited" | "waitlisted" | "not responded"; /** * Created by - * * @description The ID of the user who created this RSVP */ createdBy: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the RSVP was created at */ createdAt: string; /** * Updated by - * * @description The ID of the user who updated this RSVP */ updatedBy?: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the RSVP was updated at, if relevant */ updatedAt?: string; @@ -1860,47 +1725,40 @@ export type components = { CalendarEventComment: { /** * Calendar event comment ID - * * @description The ID of the calendar event comment */ id: number; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the calendar event comment */ content: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the calendar event comment was created at */ createdAt: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the calendar event comment was updated at, if relevant */ updatedAt?: string; /** * Calendar event ID - * * @description The ID of the calendar event */ calendarEventId: number; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Created by - * * @description The ID of the user who created this calendar event comment (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; @@ -1913,7 +1771,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "calendarEventId": 1 * } @@ -1922,20 +1780,18 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Calendar event ID - * * @description The ID of the calendar event */ calendarEventId: number; @@ -1947,7 +1803,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "calendarEventId": 1, * "calendarEventCommentId": 1234567890 @@ -1957,26 +1813,23 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Calendar event ID - * * @description The ID of the calendar event */ calendarEventId: number; /** * Calendar event comment ID - * * @description The ID of the calendar event comment */ calendarEventCommentId: number; @@ -1992,20 +1845,17 @@ export type components = { /** * Calendar event series ID * Format: uuid - * * @description The ID of the calendar event series */ id: string; /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; @@ -2024,47 +1874,45 @@ export type components = { Announcement: { /** * Announcement ID - * * @description The ID of the announcement */ id: string; /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the announcement was created at */ createdAt: string; /** * Created by - * * @description The ID of the user who created this announcement */ createdBy: string; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the announcement */ content: string; mentions?: components["schemas"]["Mentions"]; /** * Title - * * @description The title of the announcement */ title: string; @@ -2076,7 +1924,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "announcementId": "9RVMoDZy" * } @@ -2085,20 +1933,18 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Announcement ID - * * @description The ID of the announcement */ announcementId: string; @@ -2116,47 +1962,40 @@ export type components = { AnnouncementComment: { /** * Announcement comment ID - * * @description The ID of the announcement comment */ id: number; /** * Content - * Format: markdown - * + * Format: long-form markdown * @description The content of the announcement comment */ content: string; /** * Created at * Format: date-time - * * @description The ISO 8601 timestamp that the announcement comment was created at */ createdAt: string; /** * Updated at * Format: date-time - * * @description The ISO 8601 timestamp that the announcement comment was updated at, if relevant */ updatedAt?: string; /** * Created by - * * @description The ID of the user who created this announcement comment (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) */ createdBy: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Announcement ID - * * @description The ID of the announcement */ announcementId: string; @@ -2169,7 +2008,7 @@ export type components = { * "emote": { * "id": 90000000, * "name": "grinning", - * "url": "https://img.guildedcdn.com/asset/Emojis/grinning.webp" + * "url": "https://www.guilded.gg/asset/Emojis/grinning.webp" * }, * "announcementId": "9RVMoDZy", * "announcementCommentId": 123456 @@ -2179,100 +2018,550 @@ export type components = { /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * User ID - * + * Format: user-id * @description The ID of the user who added the reaction */ createdBy: string; emote: components["schemas"]["Emote"]; /** * Announcement ID - * * @description The ID of the announcement */ announcementId: string; /** * Announcement comment ID - * * @description The ID of the announcement comment */ announcementCommentId: number; }; - }; - responses: { - _WelcomeMessage: { - content: { - "application/json": { - /** @description The interval in milliseconds that your bot should be configured to send ping frames for the bot's [heartbeat](/docs/api/heartbeat) to be considered valid. */ - heartbeatIntervalMs: number; - /** @description The last message's ID that was sent to this bot. See [event replay](/docs/api/replay) for more details */ - lastMessageId: string; - /** - * Bot ID - * Format: uuid - * - * @description The ID of the bot - */ - botId: string; - user: components["schemas"]["User"]; - }; - }; + /** + * @example { + * "id": "ZVzBo83p", + * "serverId": "wlVr3Ggl", + * "name": "Fans of Turnip Boy Commits Tax Evasion", + * "description": "Best game on steam!", + * "isPublic": true, + * "createdAt": "2021-06-15T00:04:20.696Z", + * "createdBy": "Ann6LewA" + * } + */ + Group: { + /** + * Group ID + * @description The ID of the group + */ + id: string; + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + /** @description The name of the group */ + name: string; + /** + * Description + * @description The description associated with the group + */ + description?: string; + /** + * Avatar + * Format: media-uri + * @description The avatar image associated with the group + */ + avatar?: string; + /** + * Is home + * @description If `true`, this is the server's home group + */ + isHome?: boolean; + /** @description The emote to associate with the group */ + emoteId?: number; + /** + * Is public + * @description Is this group open for anyone to join? + * @default false + */ + isPublic?: boolean; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the group was created at + */ + createdAt: string; + /** + * Created by + * @description The ID of the user who created this group + */ + createdBy: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the group was updated at, if relevant + */ + updatedAt?: string; + /** + * Updated by + * @description The ID of the user who updated this group + */ + updatedBy?: string; + /** + * Archived at + * Format: date-time + * @description The ISO 8601 timestamp that the group was archived at, if relevant + */ + archivedAt?: string; + /** + * Archived by + * @description The ID of the user who archived this group + */ + archivedBy?: string; }; - /** @description Emitted when a bot is added to a server */ - BotServerMembershipCreated: { - content: { - "application/json": { - server: components["schemas"]["Server"]; - /** - * Created by - * - * @description The ID of the user who created this server membership - */ - createdBy: string; - }; - }; + /** + * @example { + * "content": "Ready for the weekend!", + * "emoteId": 90000000 + * } + */ + UserStatus: { + /** + * Content + * Format: status markdown + * @description The content of the user status. The supported markdown for this content only includes reactions and plaintext for now + */ + content?: string; + /** @description Emote ID */ + emoteId: number; }; - /** @description Emitted when a bot is removed from a server */ - BotServerMembershipDeleted: { - content: { - "application/json": { - server: components["schemas"]["Server"]; - /** - * Deleted by - * - * @description The ID of the user who deleted this server membership - */ - deletedBy: string; - }; - }; + /** + * @example { + * "id": 591232, + * "serverId": "wlVr3Ggl", + * "createdAt": "2023-04-15T20:15:00.706Z", + * "updatedAt": "2023-04-16T20:15:00.706Z", + * "name": "Captain", + * "isSelfAssignable": true, + * "permissions": [ + * "CanUpdateServer", + * "CanReadChats", + * "CanCreateChats" + * ], + * "colors": [ + * 6118369 + * ] + * } + */ + Role: { + /** + * Role ID + * @description The ID of the role + */ + id: number; + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the role was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the role was updated at, if relevant + */ + updatedAt?: string; + /** + * Role name + * @description The role's name + */ + name: string; + /** + * Display Separately + * @description If set, the role will be displayed separately in the channel member list + * @default false + */ + isDisplayedSeparately?: boolean; + /** + * Self Assignable + * @description If set, this roll will be self assigned + * @default false + */ + isSelfAssignable?: boolean; + /** + * Mentionable + * @description If set, this role can be mentioned + * @default false + */ + isMentionable?: boolean; + /** @description Permissions must be a collection of valid permissions as defined in the [Enums/Permissions](https://www.guilded.gg/docs/api/Permissions) section */ + permissions: string[]; + /** @description An array of integer values corresponding to the decimal RGB representation for a color. The first color is solid, and a second color indicates a gradient */ + colors?: number[]; + /** + * Role icon URL + * Format: media-uri + * @description The URL of the role icon + */ + icon?: string; + /** + * Priority + * @description The priority the role will be in relation to other roles in the server. The higher the value, the more precedence the role has over lower priority roles, and the higher up it will be displayed in the UI. Values can be zero or negative! + */ + priority?: number; + /** + * Is Base + * @description The default role users are given when joining the server. Base roles are tied directly to the server and cannot be created or deleted + * @default false + */ + isBase?: boolean; + /** + * Bot user ID + * Format: user-id + * @description The bot user ID this role has been defined for. Roles with this populated can only be deleted by kicking the bot + */ + botUserId?: string; }; - ChatMessageCreated: { - content: { - "application/json": { - /** - * Server ID - * - * @description The ID of the server - */ - serverId: string; - message: components["schemas"]["ChatMessage"]; - }; - }; + /** + * @example { + * "type": "Gold", + * "serverId": "wlVr3Ggl", + * "roleId": 591232, + * "description": "Once you subscribe, this tier's benefits are free for the rest of the month!", + * "cost": 500, + * "createdAt": "2021-06-15T20:15:00.706Z" + * } + */ + ServerSubscriptionTier: { + /** + * Server subscription tier type + * @description The type of the server subscription tier. This field is case sensitive!! + * @enum {string} + */ + type: "Gold" | "Silver" | "Copper"; + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + /** + * Description + * @description The description associated with the server subscription tier + */ + description?: string; + /** + * Role ID + * @description The ID of the role + */ + roleId?: number; + /** @description The cost of the tier in cents USD per month */ + cost: number; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the server subscription tier was created at + */ + createdAt: string; }; - ChatMessageUpdated: { - content: { - "application/json": { - /** - * Server ID - * - * @description The ID of the server - */ - serverId: string; + /** + * @example { + * "permissions": [ + * "CanUpdateServer", + * "CanReadChats", + * "CanCreateChats" + * ] + * } + */ + ServerMemberPermissions: { + /** @description Permissions must be a collection of valid permissions as defined in the [Enums/Permissions](https://www.guilded.gg/docs/api/Permissions) section */ + permissions: string[]; + }; + /** + * @example { + * "id": 1337, + * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", + * "name": "Social", + * "createdAt": "2023-07-07T20:15:00.706Z", + * "updatedAt": "2023-07-08T20:15:00.706Z" + * } + */ + Category: { + /** @description The ID of the category */ + id: number; + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + /** + * Group ID + * @description The ID of the group + */ + groupId: string; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the category was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the category was updated at, if relevant + */ + updatedAt?: string; + /** @description Name of the category */ + name: string; + /** + * Priority + * @description The priority of the category will determine its position relative to other categories in the group. The higher the value, the higher up it will be displayed in the UI. Returned values can be null, in which case sorting will be done by `createdAt` in descending order. Due to legacy issues, sending a null value is not possible + */ + priority?: number; + }; + /** + * @example { + * "id": 591232, + * "serverId": "wlVr3Ggl", + * "createdAt": "2023-06-15T20:15:00.706Z", + * "permissions": { + * "CanUpdateServer": true, + * "CanReadChats": true + * }, + * "roleId": 591232, + * "channelId": "00000000-0000-0000-0000-000000000000" + * } + */ + ChannelRolePermission: { + permissions: { + [key: string]: boolean | undefined; + }; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was updated at, if relevant + */ + updatedAt?: string; + /** + * Role ID + * @description The ID of the role + */ + roleId: number; + /** + * Channel ID + * Format: uuid + * @description The ID of the channel + */ + channelId: string; + }; + /** + * @example { + * "id": 591232, + * "serverId": "wlVr3Ggl", + * "createdAt": "2023-06-15T20:15:00.706Z", + * "permissions": { + * "CanUpdateServer": true, + * "CanReadChats": true + * }, + * "userId": "Ann6LewA", + * "channelId": "00000000-0000-0000-0000-000000000000" + * } + */ + ChannelUserPermission: { + permissions: { + [key: string]: boolean | undefined; + }; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was updated at, if relevant + */ + updatedAt?: string; + /** + * User ID + * Format: user-id + * @description The ID of the user + */ + userId: string; + /** + * Channel ID + * Format: uuid + * @description The ID of the channel + */ + channelId: string; + }; + /** + * @example { + * "id": 591232, + * "serverId": "wlVr3Ggl", + * "createdAt": "2023-06-15T20:15:00.706Z", + * "permissions": { + * "CanUpdateServer": true, + * "CanReadChats": true + * }, + * "userId": "Ann6LewA", + * "categoryId": 1337 + * } + */ + ChannelCategoryUserPermission: { + permissions: { + [key: string]: boolean | undefined; + }; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was updated at, if relevant + */ + updatedAt?: string; + /** + * User ID + * Format: user-id + * @description The ID of the user + */ + userId: string; + /** @description The ID of the category */ + categoryId: number; + }; + /** + * @example { + * "id": 591232, + * "serverId": "wlVr3Ggl", + * "createdAt": "2023-06-15T20:15:00.706Z", + * "permissions": { + * "CanUpdateServer": true, + * "CanReadChats": true + * }, + * "roleId": 591232, + * "categoryId": 1337 + * } + */ + ChannelCategoryRolePermission: { + permissions: { + [key: string]: boolean | undefined; + }; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was created at + */ + createdAt: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the permission override was updated at, if relevant + */ + updatedAt?: string; + /** + * Role ID + * @description The ID of the role + */ + roleId: number; + /** @description The ID of the category */ + categoryId: number; + }; + /** + * @example { + * "url": "https://cdn.gilcdn.com/TeamAvatar/f3ca3496e7f2b6bfaeddfbb6526bdec7-Large.png?w=450&h=450" + * } + */ + UrlSignature: { + /** @description The URL that is to be signed */ + url: string; + /** @description The url with a valid signature that has a 5 minute expiration on the signature */ + signature?: string; + /** @description The number of seconds to wait before retrying the request */ + retryAfter?: number; + }; + }; + responses: { + _WelcomeMessage: { + content: { + "application/json": { + /** @description The interval in milliseconds that your bot should be configured to send ping frames for the bot's [heartbeat](/docs/api/heartbeat) to be considered valid. */ + heartbeatIntervalMs: number; + /** @description The last message's ID that was sent to this bot. See [event replay](/docs/api/replay) for more details */ + lastMessageId: string; + /** + * Bot ID + * Format: uuid + * @description The ID of the bot + */ + botId: string; + user: components["schemas"]["User"]; + }; + }; + }; + /** @description Emitted when a bot is added to a server */ + BotServerMembershipCreated: { + content: { + "application/json": { + server: components["schemas"]["Server"]; + /** + * Created by + * @description The ID of the user who created this server membership + */ + createdBy: string; + }; + }; + }; + /** @description Emitted when a bot is removed from a server */ + BotServerMembershipDeleted: { + content: { + "application/json": { + server: components["schemas"]["Server"]; + /** + * Deleted by + * @description The ID of the user who deleted this server membership + */ + deletedBy: string; + }; + }; + }; + ChatMessageCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + message: components["schemas"]["ChatMessage"]; + }; + }; + }; + ChatMessageUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; message: components["schemas"]["ChatMessage"]; }; }; @@ -2282,40 +2571,155 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; + /** + * Deleted at + * Format: date-time + * @description The ISO 8601 timestamp that the message was deleted at + */ + deletedAt: string; + /** + * @example { + * "id": "00000000-0000-0000-0000-000000000000", + * "type": "default", + * "serverId": "wlVr3Ggl", + * "groupId": "ZVzBo83p", + * "channelId": "00000000-0000-0000-0000-000000000000", + * "content": "Hello **world**!", + * "embeds": [ + * { + * "title": "embed title", + * "description": "embeds support a **different** __subset__ *of* markdown than other markdown fields. <@Ann6LewA>\n\n [links](https://www.guilded.gg) ```\ncheck this code out```\n\n:pizza: time!! ttyl", + * "url": "https://www.guilded.gg", + * "color": 6118369, + * "timestamp": "2022-04-12T22:14:36.737Z", + * "footer": { + * "icon_url": "https://www.guilded.gg/asset/Logos/logomark/Color/Guilded_Logomark_Color.png", + * "text": "footer text" + * }, + * "thumbnail": { + * "url": "https://www.guilded.gg/asset/Logos/logomark/Color/Guilded_Logomark_Color.png" + * }, + * "image": { + * "url": "https://www.guilded.gg/asset/Logos/logomark_wordmark/Color/Guilded_Logomark_Wordmark_Color.png" + * }, + * "author": { + * "name": "Gil", + * "url": "https://www.guilded.gg", + * "icon_url": "https://www.guilded.gg/asset/Default/Gil-md.png" + * }, + * "fields": [ + * { + * "name": "hello", + * "value": "these are fields" + * }, + * { + * "name": "~~help i have been crossed out~~", + * "value": "~~oh noes~~", + * "inline": true + * }, + * { + * "name": "another inline", + * "value": "field", + * "inline": true + * } + * ] + * } + * ], + * "createdAt": "2021-06-15T20:15:00.706Z", + * "createdBy": "Ann6LewA" + * } + */ message: { /** * Message ID * Format: uuid - * * @description The ID of the message */ id: string; + /** + * Type + * @description The type of chat message. "system" messages are generated by Guilded, while "default" messages are user or bot-generated. + * @enum {string} + */ + type: "default" | "system"; /** * Server ID - * * @description The ID of the server */ serverId?: string; + /** + * Group ID + * @description The ID of the group + */ + groupId?: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; + /** + * Content + * Format: chat markdown + * @description The content of the message + */ + content?: string; + /** + * Hidden content link preview URLs + * @description Links in `content` to prevent unfurling as a link preview when displaying in Guilded + */ + hiddenLinkPreviewUrls?: string[]; + embeds?: components["schemas"]["ChatEmbed"][]; + /** @description Message IDs that were replied to */ + replyMessageIds?: string[]; + /** + * Is private + * @description If set, this message will only be seen by those mentioned or replied to + */ + isPrivate?: boolean; + /** + * Is silent + * @description If set, this message did not notify mention or reply recipients + * @default false + */ + isSilent?: boolean; + /** + * Is pinned + * @default false + */ + isPinned?: boolean; + mentions?: components["schemas"]["Mentions"]; + /** + * Created at + * Format: date-time + * @description The ISO 8601 timestamp that the message was created at + */ + createdAt: string; + /** + * Created by + * @description The ID of the user who created this message (Note: If this event has `createdByWebhookId` present, this field will still be populated, but can be ignored. In this case, the value of this field will always be Ann6LewA) + */ + createdBy: string; + /** + * Created by Webhook ID + * @description The ID of the webhook who created this message, if it was created by a webhook + */ + createdByWebhookId?: string; + /** + * Updated at + * Format: date-time + * @description The ISO 8601 timestamp that the message was updated at, if relevant + */ + updatedAt?: string; /** * Deleted at * Format: date-time - * * @description The ISO 8601 timestamp that the message was deleted at */ deletedAt: string; - /** Is private */ - isPrivate?: boolean; }; }; }; @@ -2325,11 +2729,12 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; member: components["schemas"]["ServerMember"]; + /** @description Count of members in this server after this join. **Note:** at higher member counts (1000+), this value is only updated periodically and should not be used in situations that require absolute accuracy */ + serverMemberCount: number; }; }; }; @@ -2338,25 +2743,22 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; /** * User ID - * + * Format: user-id * @description The ID of the user */ userId: string; /** * Is kick? - * * @description If this member leaving was the result of a kick */ isKick?: boolean; /** * Is ban? - * * @description If this member leaving was the result of a ban */ isBan?: boolean; @@ -2368,7 +2770,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2381,7 +2782,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2394,20 +2794,18 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; userInfo: { /** * User ID - * + * Format: user-id * @description The ID of the user */ id: string; /** * Nickname - * * @description The nickname that was just updated for the user */ nickname?: string | null; @@ -2420,20 +2818,18 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; memberRoleIds: { /** * User ID - * + * Format: user-id * @description The ID of the member that had roles updated */ userId: string; /** * Role IDs - * * @description The IDs of the roles that the member currently has _after_ this operation */ roleIds: number[]; @@ -2446,7 +2842,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2459,7 +2854,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2472,7 +2866,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2485,7 +2878,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2498,7 +2890,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2511,7 +2902,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2524,7 +2914,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2537,7 +2926,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2550,7 +2938,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2563,7 +2950,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2576,7 +2962,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2589,7 +2974,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2602,7 +2986,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2615,7 +2998,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2628,7 +3010,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2641,7 +3022,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2654,7 +3034,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2667,7 +3046,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2680,7 +3058,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2693,7 +3070,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2706,7 +3082,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2719,7 +3094,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2732,7 +3106,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2745,7 +3118,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2758,7 +3130,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2771,7 +3142,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2784,7 +3154,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2797,7 +3166,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2810,7 +3178,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2823,7 +3190,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2836,7 +3202,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2849,7 +3214,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2862,7 +3226,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2875,7 +3238,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2888,7 +3250,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2901,7 +3262,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2914,7 +3274,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2927,7 +3286,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -2940,13 +3298,11 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Deleted by - * * @description The ID of the user who deleted this reaction */ deletedBy: string; @@ -2959,27 +3315,23 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; /** * Channel ID * Format: uuid - * * @description The ID of the channel */ channelId: string; /** * Message ID * Format: uuid - * * @description The ID of the message */ messageId: string; /** * Deleted by - * * @description The ID of the user who deleted this reaction */ deletedBy: string; @@ -2995,7 +3347,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3008,7 +3359,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3021,7 +3371,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3034,7 +3383,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3047,7 +3395,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3060,7 +3407,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3073,7 +3419,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3086,7 +3431,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3099,7 +3443,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3112,7 +3455,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3125,7 +3467,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3138,7 +3479,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3151,7 +3491,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3164,14 +3503,12 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; calendarEventSeries: components["schemas"]["CalendarEventSeries"]; /** * Calendar event ID - * * @description The calendar event updates started at */ calendarEventId?: number; @@ -3183,95 +3520,123 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; calendarEventSeries: components["schemas"]["CalendarEventSeries"]; /** * Calendar event ID - * * @description The calendar event deletions started at */ calendarEventId?: number; }; }; }; - AnnouncementCreated: { + GroupCreated: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - announcement: components["schemas"]["Announcement"]; + group: components["schemas"]["Group"]; }; }; }; - AnnouncementUpdated: { + GroupUpdated: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - announcement: components["schemas"]["Announcement"]; + group: components["schemas"]["Group"]; }; }; }; - AnnouncementDeleted: { + GroupDeleted: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - announcement: components["schemas"]["Announcement"]; + group: components["schemas"]["Group"]; }; }; }; - AnnouncementReactionCreated: { + AnnouncementCreated: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - reaction: components["schemas"]["AnnouncementReaction"]; + announcement: components["schemas"]["Announcement"]; }; }; }; - AnnouncementReactionDeleted: { + AnnouncementUpdated: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - reaction: components["schemas"]["AnnouncementReaction"]; + announcement: components["schemas"]["Announcement"]; }; }; }; - AnnouncementCommentCreated: { + AnnouncementDeleted: { content: { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; - announcementComment: components["schemas"]["AnnouncementComment"]; + announcement: components["schemas"]["Announcement"]; + }; + }; + }; + AnnouncementReactionCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + reaction: components["schemas"]["AnnouncementReaction"]; + }; + }; + }; + AnnouncementReactionDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + reaction: components["schemas"]["AnnouncementReaction"]; + }; + }; + }; + AnnouncementCommentCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + announcementComment: components["schemas"]["AnnouncementComment"]; }; }; }; @@ -3280,7 +3645,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3293,7 +3657,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3306,7 +3669,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3319,7 +3681,6 @@ export type components = { "application/json": { /** * Server ID - * * @description The ID of the server */ serverId: string; @@ -3327,12 +3688,308 @@ export type components = { }; }; }; + UserStatusCreated: { + content: { + "application/json": { + /** + * Expires at + * Format: date-time + * @description An ISO 8601 timestamp that will be used to indicate when an expiration occurs. Expiration usually will not occur exactly at this time. Bot logic should not expect a guarantee of timing as a result, but can expect that it'll happen very shortly afterwards + */ + expiresAt?: string; + /** + * User ID + * Format: user-id + * @description The ID of the user + */ + userId: string; + userStatus: components["schemas"]["UserStatus"]; + }; + }; + }; + UserStatusDeleted: { + content: { + "application/json": { + /** + * User ID + * Format: user-id + * @description The ID of the user + */ + userId: string; + userStatus: components["schemas"]["UserStatus"]; + }; + }; + }; + RoleCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + role: components["schemas"]["Role"]; + }; + }; + }; + RoleUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + role: components["schemas"]["Role"]; + }; + }; + }; + RoleDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + role: components["schemas"]["Role"]; + }; + }; + }; + ChannelArchived: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channel: components["schemas"]["ServerChannel"]; + }; + }; + }; + ChannelRestored: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channel: components["schemas"]["ServerChannel"]; + }; + }; + }; + CategoryCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + category: components["schemas"]["Category"]; + }; + }; + }; + CategoryUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + category: components["schemas"]["Category"]; + }; + }; + }; + CategoryDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + category: components["schemas"]["Category"]; + }; + }; + }; + ChannelMessagePinned: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + message: components["schemas"]["ChatMessage"]; + }; + }; + }; + ChannelMessageUnpinned: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + message: components["schemas"]["ChatMessage"]; + }; + }; + }; + ChannelRolePermissionCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelRolePermission: components["schemas"]["ChannelRolePermission"]; + }; + }; + }; + ChannelRolePermissionUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelRolePermission: components["schemas"]["ChannelRolePermission"]; + }; + }; + }; + ChannelRolePermissionDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelRolePermission: components["schemas"]["ChannelRolePermission"]; + }; + }; + }; + ChannelUserPermissionCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelUserPermission: components["schemas"]["ChannelUserPermission"]; + }; + }; + }; + ChannelUserPermissionUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelUserPermission: components["schemas"]["ChannelUserPermission"]; + }; + }; + }; + ChannelUserPermissionDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelUserPermission: components["schemas"]["ChannelUserPermission"]; + }; + }; + }; + ChannelCategoryUserPermissionCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryUserPermission: components["schemas"]["ChannelCategoryUserPermission"]; + }; + }; + }; + ChannelCategoryRolePermissionCreated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryRolePermission: components["schemas"]["ChannelCategoryRolePermission"]; + }; + }; + }; + ChannelCategoryUserPermissionUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryUserPermission: components["schemas"]["ChannelCategoryUserPermission"]; + }; + }; + }; + ChannelCategoryRolePermissionUpdated: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryRolePermission: components["schemas"]["ChannelCategoryRolePermission"]; + }; + }; + }; + ChannelCategoryUserPermissionDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryUserPermission: components["schemas"]["ChannelCategoryUserPermission"]; + }; + }; + }; + ChannelCategoryRolePermissionDeleted: { + content: { + "application/json": { + /** + * Server ID + * @description The ID of the server + */ + serverId: string; + channelCategoryRolePermission: components["schemas"]["ChannelCategoryRolePermission"]; + }; + }; + }; }; parameters: never; requestBodies: never; headers: never; pathItems: never; -}; +} export type external = Record;