/ Platform API
Platform API
    Chat Platform API v3
    Chat Platform API
    Chat Platform API
    Version 3

    Get a group channel

    Copy link

    This action retrieves information about a specific group channel. You can use the optional query parameters to determine whether to include delivery receipt, read receipt, or member information in the response.


    HTTP request

    Copy link
    GET https://api-{application_id}.sendbird.com/v3/group_channels/{channel_url}
    

    Parameters

    Copy link

    The following table lists the parameters that this action supports.

    Parameters
    RequiredTypeDescription

    channel_url

    string

    Specifies the URL of the channel.

    OptionalTypeDescription

    show_delivery_receipt

    boolean

    Determines whether to include information about the delivery receipt of each member of the channel in the response. The delivery receipt indicates the timestamp of when each member has last received messages from the Sendbird server in the channel, in Unix milliseconds. (Default: false)

    show_read_receipt

    boolean

    Determines whether to include information about the read receipt of each member of the channel in the response. The read receipt indicates the timestamp of when each member has last read messages in the channel, in Unix milliseconds. (Default: false)

    show_member

    boolean

    Determines whether to include information about the channel members in the response. (Default: false)

    * For Supergroup channels, only ten members are shown as a preview to the full list. Use the list members API to retrieve the complete member list of a Supergroup channel.

    read_receipt

    boolean

    (Deprecated) Superseded by show_read_receipt.

    member

    boolean

    (Deprecated) Superseded by show_member.

    ?show_delivery_receipt=true&show_read_receipt=true&show_member=true
    

    Responses

    Copy link

    If successful, this action returns a group channel resource in the response body.

    {
        "name": "Saturday soccer members",
        "channel_url": "private_chat_room_424",
        "cover_url": "https://sendbird.com/main/img/cover/cover_08.jpg",
        "custom_type": "sports",
        "unread_message_count": 0,
        "data": "",
        "is_distinct": true,
        "is_public": false,
        "is_super": false,
        "is_ephemeral": false,
        "is_access_code_required": false,
        "member_count": 4,
        "joined_member_count": 1,
        "members": [
            {
                "user_id": "James",
                "nickname": "Knight",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_08_512px.png",
                "is_active": true,
                "is_online": false,
                "last_seen_at": 1530237133254,
                "state": "invited",
                "role": "",             // Either 'operator' or null. The value of null indicates that this user is a normal channel member.
                "metadata": {
                    "font_preference": "times new roman",
                    "font_color": "black"
                }
            },
            {
                "user_id": "Jay",
                "nickname": "Rooster",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_17_512px.png",
                "is_active": true,
                "is_online": false,
                "last_seen_at": 1530232836311,
                "state": "joined",
                "role": "",         // Either 'operator' or null. The value of null indicates that this user is a normal channel member.
                "metadata": {
                    "font_preference": "times new roman",
                    "font_color": "black"
                }
            },
            {
                "user_id": "Jeff",
                "nickname": "OldBoy",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_22_512px.png",
                "is_active": true,
                "is_online": true,
                "last_seen_at": 0,
                "state": "",
                "role": "operator",     // Either 'operator' or null. The value of null indicates that this user is a normal channel member.
                "metadata": {
                    "font_preference": "times new roman",
                    "font_color": "black"
                }
            },
            {
                "user_id": "Young",
                "nickname": "Sportsman",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_23_512px.png",
                "is_active": true,
                "is_online": true,
                "last_seen_at": 0,
                "state": "invited",
                "role": "",             // Either 'operator' or null. The value of null indicates that this user is a normal channel member.
                "metadata": {
                    "font_preference": "times new roman",
                    "font_color": "black"
                }
            },
        ],
        "operators": [
            {
                "user_id": "Jeff",
                "nickname": "OldBoy",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_22_512px.png",
                "is_active": true,
                "is_online": true,
                "last_seen_at": 0,
                "state": "",
                "metadata": {}
            }
        ],
        "max_length_message": 500,
        "last_message": null,
        "created_at": 1543468122,
        "freeze": false,
        "delivery_receipt": {
            "Jay": 1542762344162,
            "Jin": 1542394323413,
            "David": 1542543464371
        },
        "read_receipt": {
            "Jay": 1542762343245,
            "Jin": 1542394301402,
            "David": 1542543456343
        },
        "channel": {
            ...  # This key has been deprecated and only exists for backward compatibility.
        }
    }
    

    In the case of an error, an error object like below is returned. See the error codes section for more details.

    {
        "message": "\"Channel\" not found.",
        "code": 400201,
        "error": true
    }