API

Guides

Messages

Voice

WhatsApp Business

Groups

Contacts

Outbox

Account

Sender IDs

Teammate/Subaccount

Conversations

Workflows

Message Templates

Birthday Message

Opt-out

Other

Webhooks (v2)

Get conversation assignment

Returns which team member is handling a conversation and its status (open, pending or closed). A conversation that was never assigned or given a status is reported as unassigned and open. Team users need API access and the conversation permission.

Base URL:

GET: https://api.smsgatewayapi.com/v1/conversations/{key}/assignment

Example:

GET: https://api.smsgatewayapi.com/v1/conversations/32470123456/assignment
ParameterInputDescription
client_idAPI client IDDeveloper › API & Webhooks › API credentials
Required
client_secretAPI client secretA cs_ credential, shown once when you create it under Developer › API & Webhooks › API credentials
Required
keyconversation keyThe conversation as shown in your conversation list: a phone number in international format (e.g. 32470123456), a WhatsApp user ID for a user without phone number (BE.… for WhatsApp Business, WA.LID… for WhatsApp Web) or group:gid_… for a group conversation (the numeric group ID is accepted too). Group keys are always returned with the public group ID.
Required
<?php
	//PHP - cURL
	$ch = curl_init();
	$url = "https://api.smsgatewayapi.com/v1/conversations/{key}/assignment";
	$client_id = "XXX"; // Your API client ID (required)
	$client_secret = "YYY"; // Your API client secret (required)
	
curl_setopt($ch, CURLOPT_URL, "$url"); curl_setopt($ch, CURLOPT_POST, false); curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET'); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_VERBOSE, true); curl_setopt($ch, CURLOPT_HTTPHEADER, [ "X-Client-Id: $client_id", "X-Client-Secret: $client_secret", "Content-Type: application/json", ]); $response = curl_exec($ch); ?>

Example success response:

{
	"conversation_key": "32470123456",
	"assignee": {
		"public_id": "sub_3520a1ec234dbabe1232def67e858855",
		"name": "alice"
	},
	"status": "open",
	"assigned_at": "2026-09-07 10:15:00"
}

assignee is null when nobody is assigned; name is the username of the team member (see List subaccounts).

Example error response:

{
	"error": 145,
	"errorMsg": "Invalid conversation key [group:]"
}

SMS API

Smstools
Integrate our SMS Gateway by implementing our SMS API, and add text messaging to your platform in minutes. Free trial. SMS API
5 out of 5 based on 3302 user ratings.
SMSGATEWAYAPI API1

REGISTER NOW

Discover our SMS platform today!

REGISTER