Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Api / Channels

Method Description
🔹 assign() Assign to channel
🔹 create() Create channel
🔹 delete() Delete channel
🔹 listMembers() List members
🔹 listProspects() Find prospects
🔹 unassign() Unassign from channel
🔹 update() Update channel

📚 Channels API Reference

Getting started

// Place your API Key 👇 here
$sdk = new \Kronup\Sdk();

// API Call
$sdk->api()->channels();

assign()

Assign a user to a channel

#️⃣ Execute example in terminal

php -f assign.php

Request

PUT /teams/{teamId}/channels/{channelId}/users/{userId}

Type signature

(new \Kronup\Sdk())->api()->channels()->assign(
    string $team_id,
    string $channel_id,
    string $user_id
): \Kronup\Model\User

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID
$user_id string User ID

Return type

\Kronup\Model\User

🔺 Back to top


create()

Create a new channel for a team

#️⃣ Execute example in terminal

php -f create.php

Request

POST /teams/{teamId}/channels

Type signature

(new \Kronup\Sdk())->api()->channels()->create(
    string $team_id,
    \Kronup\Model\PayloadChannelCreate $payload_channel_create
): \Kronup\Model\TeamExpanded

Parameters

Name Type Description
$team_id string Team ID
$payload_channel_create \Kronup\Model\PayloadChannelCreate  

Return type

\Kronup\Model\TeamExpanded

🔺 Back to top


delete()

Delete a channel and unassign all users

#️⃣ Execute example in terminal

php -f delete.php

Request

DELETE /teams/{teamId}/channels/{channelId}

Type signature

(new \Kronup\Sdk())->api()->channels()->delete(
    string $team_id,
    string $channel_id
): bool

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID

Return type

bool

🔺 Back to top


listMembers()

List all channel members

#️⃣ Execute example in terminal

php -f listMembers.php

Request

GET /teams/{teamId}/channels/{channelId}/users

Type signature

(new \Kronup\Sdk())->api()->channels()->listMembers(
    string $team_id,
    string $channel_id,
    [ int $page_number = 1, ]
    [ int $page_size = 500 ]
): \Kronup\Model\ChannelMembersList

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID
$page_number int [default to 1]
$page_size int [default to 500]

Return type

\Kronup\Model\ChannelMembersList

🔺 Back to top


listProspects()

List 10 channel prospects

#️⃣ Execute example in terminal

php -f listProspects.php

Request

GET /teams/{teamId}/channels/{channelId}/prospects

Type signature

(new \Kronup\Sdk())->api()->channels()->listProspects(
    string $team_id,
    string $channel_id,
    [ string $user_name ]
): \Kronup\Model\ChannelProspectsList

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID
$user_name string Wildcard for prospect user name

Return type

\Kronup\Model\ChannelProspectsList

🔺 Back to top


unassign()

Remove a user from a channel; removing the user from the default channel is the same as removing the user from the team

#️⃣ Execute example in terminal

php -f unassign.php

Request

DELETE /teams/{teamId}/channels/{channelId}/users/{userId}

Type signature

(new \Kronup\Sdk())->api()->channels()->unassign(
    string $team_id,
    string $channel_id,
    string $user_id
): bool

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID
$user_id string User ID

Return type

bool

🔺 Back to top


update()

Update channel details for a team

#️⃣ Execute example in terminal

php -f update.php

Request

POST /teams/{teamId}/channels/{channelId}

Type signature

(new \Kronup\Sdk())->api()->channels()->update(
    string $team_id,
    string $channel_id,
    \Kronup\Model\PayloadChannelUpdate $payload_channel_update
): \Kronup\Model\TeamExpanded

Parameters

Name Type Description
$team_id string Team ID
$channel_id string Channel ID
$payload_channel_update \Kronup\Model\PayloadChannelUpdate  

Return type

\Kronup\Model\TeamExpanded

🔺 Back to top