GameChat Docs
  • Overview
  • Getting Started
  • Basics
    • Game Chat (V2)
      • Game Chat(한국어)
        • Game Chat 사용 준비
        • Game Chat 시작
          • Game Chat 운영 및 관리
          • Unity SDK
        • OpenAPI
          • 채널 생성
          • 채널 수정
          • 채널 삭제
        • Game Chat 리소스 관리
        • Game Chat 릴리즈 노트
      • Game Chat(English)
        • Prerequisites for using Game Chat
        • Getting started with Game Chat
          • Game Chat operation and management
          • Unity SDK
        • OpenAPI
          • Channel creation API
          • Channel edit
          • Channel deletion API
        • Game Chat resource management
        • Game Chat release notes
      • Game Chat(日本語)
        • Game Chat を使用する前に
        • Game Chat を開始する
          • Game Chat の運用と管理
          • Unity SDK
        • OpenAPI
          • チャンネル作成API
          • チャネルの修正
          • チャンネル削除API
        • Game Chatのリソース管理
        • Game Chat のリリースノート
      • Game Chat(中文)
        • Game Chat使用前准备
        • 启动Game Chat
          • Game Chat运营和管理
          • Unity SDK
        • Open API
          • 频道创建API
          • 修改频道
          • 频道删除API
        • Game Chat资源管理
        • Game Chat版本注释
    • Game Chat (V3)
      • Game Chat(한국어)
        • V3 사용 시작
          • Unity SDK 설치
          • 초기화
          • 로그인
          • 채널
          • 메시지
          • 이벤트
          • 친구
          • 푸시
          • 가져오기&내보내기
          • 고정 메시지
          • 외부연동
          • 사용예제
          • Troubleshooting
      • Game Chat(English)
        • Start using V3
          • Install Unity SDK
          • Initialization
          • Login
          • Channel
          • messages
          • Events
          • Friendship
          • Push
          • Import and export
          • Pinned message
          • External integration
          • Usage examples
          • Troubleshooting
      • Game Chat(日本語)
        • V3の使用を開始
          • Unity SDK のインストール
          • 初期化
          • ログイン
          • チャンネル
          • メッセージ
          • イベント
          • 友達
          • プッシュ
          • インポート&エクスポート
          • 固定メッセージ
          • 外部連携
          • ユースケース
          • Troubleshooting
      • Game Chat(中文)
        • 开始使用V3
          • Unity SDK 安装
          • 初始化
          • 登录
          • 频道
          • 消息功能
          • 事件
          • 好友
          • 推送
          • 导入与导出
          • 固定消息
          • 外部集成
          • 使用示例
          • Troubleshooting
Powered by GitBook
On this page
  • Pinned message
  • How to use pinned messages
  • Create pinned message
  • Edit pinned message
  • Pinned message information
  • Pinned message list
  1. Basics
  2. Game Chat (V3)
  3. Game Chat(English)
  4. Start using V3

Pinned message

Pinned message

In a chat, Pinned Message is a function that pins important messages in a chat room or a group chat to the top of the chat window. This function helps participants see the message easily whenever they open the chat room, and not miss important information or notifications. The following describes the main characteristics of pinned messages and how to use them.

How to use pinned messages

  • Meeting schedule notice: sets the schedule of regular meetings or important events as a pinned message to help participants not forget their schedule.

  • Important document links: pins the links of important documents and materials to allow all participants to access them easily.

  • Rules and guides sharing: sets the rules of the chat room or project guides as a pinned message to allow new participants to check the guides easily.

  • Urgent notification: allows sharing the content that needs to be forwarded urgently or any changes with a pinned message.

The pinned messages function is provided in various communication platforms. When you use it effectively, you can enhance the efficiency of team communication.

Create pinned message

It is a function that pins an important message to the top of the chat application so that users can easily see it. The following C# code shows how to pin messages in the chat channel.

var newPin = await nc.createPin(channelId, messageId, pinned, pinnedAt, expiredAt);
  • channelId: the unique identifier of the chat channel where the message will be pinned.

  • pinned: contents of a message to be pinned.

  • pinnedAt: displays the time when the message is pinned.

  • expiredAt: the time when the message will be unpinned.

When you use this function, you can easily highlight important messages in a specific chat channel.

Edit pinned message

It is a function to update the information of the existing pinned messages. You can change the contents of the message, and the time when the message is pinned and will be unpinned.

var updatedPin = await nc.updatePin(id, channelId, pinned, pinnedAt, expiredAt);
  • channelId: ID of the channel where there are messages to be edited.

  • pinned: the edited message content.

  • pinnedAt: the time when the message is newly pinned.

  • expiredAt: the newly set time when the message will be unpinned.

This code is used to change the details of the messages already pinned. It is useful when the importance of the message is changed or the time set for the message to be pinned needs to be changed.

Pinned message information

It is a function to view the information related to pinning certain messages. You can check the status of the pinned message, and the time when the message is pinned and will be unpinned.

var pin = await nc.getPin(channelId, messageId);
  • channelId: ID of the channel from which to retrieve information.

  • messageId: the unique identifier of the pinned message.

Through this function, you can check the current status of a specific message, which helps the admin or users manage messages in the channel effectively.

Pinned message list

It is a function that views the list of all messages currently pinned in the chat channel. This function supports paging, so the data can be processed efficiently even in a large-scale channel. Users can set offset and per_page to bring up the data in the desired range.

Hashtable filter = new Hashtable
{
    { "channel_id", channelId },
};
Hashtable sort = new Hashtable
{
    { "created_at", -1 },
};
Hashtable option = new Hashtable
{
    { "offset", 0 },
    { "per_page", 10 },
};
var pins = await nc.getPins(channelId, filter, sort, option);

Parameter descriptions

  • Filter: defines the conditions for filtering the data to be viewed. For example, you can view pinned messages in a specific channel.

  • Sort: defines how to sort the results list. Here, sorting in descending (-1) order is used based on the creation time (created_at).

  • Option: defines the options to be used when viewing. offset specifies the location where the view starts, and per_page specifies the number of messages to be shown per page.

Options details

ID
Type
Description

offset

number

Start location where the data will be brought up.

per_page

number

The number of messages to be returned per page, and up to 100 messages can be set.

If you use this function, the channel manager can easily monitor and manage important messages in the channel. Also, the channel manager can quickly find and sort pinned messages based on the specific user or time, which helps operate the channel efficiently.

PreviousImport and exportNextExternal integration

Last updated 6 months ago