Miscellaneous routes.

Constructors

Methods

  • Delete a user's status, this includes the app's one.

    Parameters

    • userID: string

      User ID (@me can be used).

    Returns Promise<void>

  • Get Application/Client Partial User (and sets Client#user if REST Mode is enabled).

    Returns Promise<AppUser>

  • Get a specified social link from the member, if member is connected to them through Guilded.

    Parameters

    • guildID: string

      The ID of the guild the member is in.

    • memberID: string

      The ID of the member to get their social link.

    • socialMediaName: string

      Name of a social media linked to this member.

    Returns Promise<SocialLink>

  • Get a user.

    If you'd like to get the App User, we recommend to use Client#user or request it using Misc#getAppUser.

    Parameters

    • userID: string

      The ID of the user to get.

    Returns Promise<User>

  • Retrieve user's joined servers.

    Parameters

    • userID: string

      ID of the user. (@me can be used to select your instance)

    Returns Promise<Guild[]>

  • Create a URL Signature from a Guilded CDN URL. (RAW API RESPONSE)

    Due to restrictions imposed by the Guilded API CDN, you are required to sign the file's CDN URL in order to access its content, and have to store it (within 5 minutes as the signed URL will expire) appropriately as you can only create a new signed URL of the same file each day.

    More information about it on the Guilded API Documentation.

    Note that TouchGuild doesn't provide a built-in handler for CDN assets.

    Parameters

    • options: {
          urls: string[];
      }

      Signature options

      • urls: string[]

        An array of guilded CDN based URLs to get a signature on. Each URL is valid for 5 minutes and limited to one request per day

    Returns Promise<{
        urlSignatures: {
            retryAfter?: number;
            signature?: string;
            url: string;
        }[];
    }>

  • Change a user's status, this includes the app's one.

    Parameters

    • userID: string

      User ID (@me can be used).

    • options: {
          content?: string;
          emoteId: number;
          expiresAt?: string;
      }

      Status options

      • Optionalcontent?: string

        Content Format: status markdown

        The content of the user status. The supported markdown for this content only includes reactions and plaintext for now

      • emoteId: number

        Emote ID to apply

      • OptionalexpiresAt?: string

        Expires at Format: date-time

        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

    Returns Promise<void>