Skip to main content
Sitecore Documentation
  • Learn
  • Downloads
  • Changelog
  • Roadmap
PersonalizeCloud Portal
Sitecore Personalize developer documentation
  • Developing with Sitecore Personalize
    • Base URL
    • Response codes
        • Create a connection
        • Retrieve connections
        • Retrieve a connection
        • Update a connection
        • Test a connection
  1. REST API Connection
  1. Sitecore Personalize developer documentation
  2. REST APIs

Test a connection

POST /v2/connections/testConnection

Tests a connection.

You must provide the following required attributes in the request body:

  • Attribute: Type
  • connection: object
curl -X POST '<baseURL>/v2/connections/testConnection' \
-H 'Authorization: Bearer <accessToken>' \
-H 'Accept: application/json' \
--data-raw '
{
    "connection": {
        "clientKey": "pqsDATA3lw12v5a9rrHPW1c4hET73GxQ",
        "href": "<baseURL>/v2/connections/ab5fc100-a0d2-49a0-87d9-1d4219a5d0a2",
        "ref": "ab5fc100-a0d2-49a0-87d9-1d4219a5d0a2",
        "name": "Promo Offer to Email Push and notif and SMS",
        "description": "Omnichannel publishing",
        "modifiedByRef": "343982bb-40e4-4119-bfab-144f65fb496c",
        "modifiedAt": "2026-09-14T20:`17:59`.737Z",
        "revision": 1,
        "archived": false,
        "auth": {
            "authType": "NONE"
        },
        "request": {
            "requestType": "POST",
            "connectionUrl": "<baseURL>/workflows/45aea1bb3c2845e8b4043e209c4456c2/triggers/manual/paths/invoke",
            "requestBody": "{\n    \"guest_sms\" : \"{sms}\",\n    \"x-brand-color\" : \"black\"\n}"
        },
        "inputMappings": [],
        "outputMappings": [
            {
                "label": "response",
                "outputReference": "message",
                "type": "String"
            }
        ],
        "customHeaders": [
            {
                "name": "Accept",
                "value": "application/json"
            },
            {
                "name": "Accept-Encoding",
                "value": "gzip"
            },
            {
                "name": "Content-Type",
                "value": "application/json"
            },
            {
                "name": "X-Brand-Color",
                "value": "{color-name-or-hex}"
            },
            {
                "name": "X-Guest-SMS",
                "value": "{sms}"
            }
        ],
        "urlParameters": [],
        "systemType": "DESTINATION",
        "connectionTimeout": 10000,
        "socketTimeout": 1000,
        "icon": "fad fa-sms"
    }
}'
{
    "statusCode": 202,
    "executionTimeInMilliseconds": 351,
    "request": {
        "headers": {
            "X-Brand-Color": "{color-name-or-hex}",
            "Accept": "application/json",
            "X-Correlation-Id": "0b79f2c2-2001-4131-80d2-df3936e19e78",
            "X-Guest-SMS": "{sms}",
            "Accept-Encoding": "gzip",
            "Content-Type": "application/json"
        }
    },
    "response": {
        "body": {
            "message": "cannot handle current output"
        }
    },
    "mappingResult": {
        "message": "cannot handle current output"
    },
    "connectionUrl": "<baseURL>/workflows/45aea1bb3c2845e8b4043e209c4456c2/triggers/manual/paths/invoke"
}
If you have suggestions for improving this article, let us know!

Documentation Assistant

This assistant uses AI to generate responses based on Sitecore documentation. While it has access to official sources, answers may be incomplete or inaccurate and should not be considered official advice or support.
Powered by
k
kapa.ai
Protected by reCAPTCHA

© Copyright 2026, Sitecore A/S or a Sitecore affiliated company.
All rights reserved.

Privacy policySitecore Trust CenterTerms of use