Skip to main content

ChatService

Index

Constructors

constructor

Properties

publicreadonlyhttpRequest

httpRequest: BaseHttpRequest

Methods

publicroomCreate

  • Create a chat Creates a new chat. If a 1:1 chat with the specified member already exists, the response will not create a duplicate but instead return the existing chat's information. For group chats with specified members, a new chat will be created even if one already exists with the same members.

    @throws

    ApiError


    Parameters

    Returns CancelablePromise<{ data?: CreateRoomResponse }>

    any Successfully created the chat.

publicroomInfo

  • Get a chat's information Retrieves information about a chat.

    @throws

    ApiError


    Parameters

    • __namedParameters: { roomId: string; targetUserId?: string }

    Returns CancelablePromise<{ data?: GetRoomResponse }>

    any Successfully retrieved the chat's information.

publicroomInvite

publicroomLevae

publicroomList

  • roomList(__namedParameters: { filter?: all | starred | unread; limit?: number; offset?: string; offsetOrderType?: less | eq_less | greater | eq_greater; page?: number; search?: string }): CancelablePromise<{ data?: GetRoomListResponse }>
  • List out chats Lists out a given number of chats. This method uses the Swit API's pagination scheme.

    @throws

    ApiError


    Parameters

    • __namedParameters: { filter?: all | starred | unread; limit?: number; offset?: string; offsetOrderType?: less | eq_less | greater | eq_greater; page?: number; search?: string }

    Returns CancelablePromise<{ data?: GetRoomListResponse }>

    any Successfully retrieved the chats.

publicroomUpdate