# Sprinklr

Teleskope integrates with Sprinklr’s GDPR API to fulfill **Delete User** DSRs by creating a redact request for the data subject.

## Requirements

In order to integrate Teleskope with Sprinklr for DSR requests, you must have:

* Your **Sprinklr API Key**
* Your **Sprinklr API Secret**
* *(Optional)* **API URL override**
  * Defaults to `https://api.sprinklr.com`. Provide a custom base URL only if your environment requires it.
* The data subject’s **identifier**:
  * **email** (default), or
  * **phone** (if the identifier name is `phone`)

### Integrating with Sprinklr

To integrate Teleskope with Sprinklr:

1. Navigate to **Data Subject Rights → Third Party Integrations** and pick **Sprinklr**.
2. Enter the required fields for the integration and click **Save**:
   * **API Key** (required)
   * **API Secret** (required)
   * **API URL** (optional; leave blank to use `https://api.sprinklr.com`)

### Parameter Defaults

* When Teleskope sends a **Delete User** request to Sprinklr, it includes these parameters by default:
  * **HTTP Method**: `POST`
  * **Endpoint**:

    ```
    {apiUrl}/v1/gdpr/delete
    ```
  * **Headers**:
    * `api-key: <API Key>`
    * `api-secret: <API Secret>`
    * `Content-Type: application/json`
    * `Accept: application/json`
  * **Request Body**:

    ```json
    {
      "dataSubjectIds": [
        {
          "channelType": "EMAIL" | "PHONE",
          "value": "<identifier.value>"
        }
      ],
      "redactOptions": {
        "redactPersonalInformation": true,
        "redactContent": true
      }
    }
    ```

    * `channelType` defaults to **EMAIL** unless the identifier name is `phone`, in which case **PHONE** is used.
  * **Expected success codes**: `200` or `201`
* **Default Identifier for Sprinklr = `email`**\
  (You may also use `phone` by passing an identifier named `phone`.)

### Behavior and Notes

* The handler constructs the GDPR delete request for a single data subject and submits it with your API key/secret.
* If the API response is not `200`/`201`, the error (including response body) is surfaced for troubleshooting.
* On success, Teleskope logs the operation and returns a standard “vendor deletion request submitted” message.

#### Helpful Links

[Sprinklr: GDPR and Privacy Cloud](https://www.sprinklr.com/help/articles/privacy-guides/gdpr-and-privacy-cloud/633c5c2359534970b26f96bd)

[Sprinklr Privacy Workflows](https://www.sprinklr.com/help/articles/privacy-guides/privacy-workflows/64679cc730f12540268fb606)
