Trying to start a cobrowse session via the Conversations API but getting a 404. The endpoint docs say it should work for active chat conversations. Here is the request:
POST /api/v2/conversations/{conversationId}/cobrowse
Returns 404 Not Found. The conversation exists and is active. Am I missing a required header or is the endpoint deprecated?
Check your OAuth scopes first. This is the #1 reason for 404s on conversation sub-resources. If the token doesn’t have conversation:cobrowse:add or conversation:cobrowsevoice:add, the API returns 404 instead of 403 to avoid leaking resource existence.
The docs state: “The client must have the appropriate scopes to access the endpoint.” You’re likely using a generic openid or user:read token. Here’s how to verify and fix it using the PureCloud SDK (Java):
// 1. Verify current token scopes
AccessTokenResponse token = platformClient.getOAuthApi().getAccessToken();
System.out.println("Scopes: " + token.getScope());
// 2. Ensure 'conversation:cobrowse:add' and 'conversation:cobrowsevoice:add' are present
// If missing, re-authenticate with these scopes in your client credentials flow
String[] requiredScopes = {"conversation:cobrowse:add", "conversation:cobrowsevoice:add", "openid"};
// 3. Attempt the cobrowse start with a valid token
ConversationApi convApi = new ConversationApi(platformClient);
try {
// Note: The endpoint is actually POST /api/v2/conversations/{conversationId}/cobrowse
// Check if you're hitting the correct path variant
ApiResponse<CobrowseSession> response = convApi.postConversationCobrowse(
conversationId,
null, // headers
null // queryParams
);
System.out.println("Session ID: " + response.getBody().getId());
} catch (ApiException e) {
System.err.println("Error: " + e.getMessage());
System.err.println("Response Code: " + e.getCode());
}
Also, double-check the exact path. Some older SDK versions map the cobrowse creation incorrectly. The current valid endpoint is POST /api/v2/conversations/{conversationId}/cobrowse. If you’re hitting a path with /sessions or /chat segments, you’ll get a 404.
Verify the conversation state too. Cobrowse only works if the chat is in connected state, not queued or closed. The API won’t start a session on a pending chat.
Check the provider configuration. The cobrowse session is tied to the deployment and provider configured in your org settings under Admin > Integrations > Cobrowse. If the provider isn’t correctly linked to the deployment, it’ll fail silently or with a 404.
Run a quick check on your active cobrowse conversations to ensure the session is actually being created:
curl -X GET "https://api.mypurecloud.com/api/v2/conversations/cobrowsesessions" \
-H "Authorization: Bearer $ACCESS_TOKEN"
Match that ID exactly. Case-sensitive.
1 Like