Personal Connection API returning 400 Bad Request for outbound campaign

Trying to trigger an outbound call via the Personal Connection API for a specific campaign. The goal is to kick off a preview call from a script using the REST proxy action.

I’m building the JSON payload based on the docs, but the API keeps rejecting it with a 400 error. The response body says “invalid request” but doesn’t give much detail on which field is wrong.

Here is the code I’m using:

GetRESTProxy("POST", "https://{org_id}.mypurecloud.com/api/v2/outbound/campaigns/{campaignId}/preview", "{\"contactId\": \"12345\", \"userId\": \"agent-uuid-123\"}", "application/json", "Bearer {token}")

I’ve verified the campaign ID is valid and the user is authorized for outbound. The token is fresh.

Is the endpoint path correct? I’ve seen some docs mention /preview and others just /calls. Also, do I need to include the contact object explicitly or is the ID enough?

Tried adding "contact": {"id": "12345"} but that fails too. Getting nowhere.

The endpoint path is wrong. You’re hitting the root org URL instead of the specific outbound route. Use this instead:

POST /api/v2/outbound/contacts/{contactId}/preview

Also, make sure your contactId exists in the campaign’s dataset. If it’s a new number, you’ll get a 400.