Requests API - from any system

Configure API calls from any system to Agent Connect.

Agent Connect offers an API to automatically trigger the distribution of customer feedback requests, allowing you to streamline the process for gathering real-time customer feedback without impacting your agent's workflow.

Any system or database that knows that an interaction occurred can be used to trigger connect requests, typically with just a day or two of work by a developer.

illustration of API requests coming from outside Agent Connect

Details are outlined below, and the Agent Connect implementation team is available to answer any questions you may have.

Step 1: Request and retrieve your test credentials

Activate your API credentials

To get started, click the Integrations tile on the Settings page.

image of the main integrations tile

To enable your API credentials, specify an email address to be used for testing and monitoring. This email address will be used for the following purposes:

  • As the recipient of all test auto-triggered connect requests (those sent with Test credentials)

  • Alerting — In the event that more than 5% of requests result in error within an hour, Agent Connect will notify you at this email address.

Image of integration configuration

Retrieve your test API key

Once activated, the Integrations page will display your test and production API keys, a link to the API status page to monitor results, and links to API documentation.

Picture4.png

Step 2: Configure your system to automatically trigger requests

Structure the API calls

The following custom headers are needed for the API call:

  • accept: application/json
  • content-type: application/json
  • x-api-key: <YOUR API KEY>

In order to trigger an Agent Connect request, your system will need to identify five items for each interaction:

  • The customer's name

  • The customer's email address

  • Either the agent's email address or an employee ID that matches the agent's ID in their profile

  • The channel of the interaction (phone, email, chat, or custom channel)

  • A transaction ID (typically a case number, ticket number, order number, or Interaction ID)

Send requests to the Agent Connect endpoint at https://api.stellaconnect.net/v1/requests using the following schema. Only the fields marked in bold are required.

{
  "customer": {
  "name": "Jane",
    "email": "janecustomer@example.com"
  },
  "employee": {
    "custom_id": "522743",
    "email": "paulagent@blancapeak.com"
  },
  "channel": "chat",
 "ext_interaction_id": "5000f00001ClBXZ",
  "external_url": "https://na63.salesforce.com/5087b40001ClBXZ",
  "do_not_send": true,
  "tags": [
    "product-defect",
    "return",
    "vip"
  ],
  "brand": "blancakids",
  "language": "en",
  "country": "us"
}

For example:

Sample InteractionCorresponding API Call

Jane Customer (janecustomer@example.com) had a phone interaction with Paul Agent (paulagent@blancapeak.com) today.

This interaction was attached to Case # 123456, and marked as Closed following this phone call.

{
    "customer": {
        "name": "Jane",
        "email": "janecustomer@example.com"
    },
    "ext_interaction_id": "123456",
    "employee": {
        "email": "paulagent@blancapeak.com"
    },
    "channel": "phone"
}
Note: Clients using advanced features like tagging and multi-brand will populate additional fields in the API call. See Sample Stella Connect API Structure for more examples.

Configure your system to send API calls for each eligible interaction

It is a best practice to send a feedback request after every service experience.

In addition, Agent Connect contains logic to validate each request, manage suppression periods (for example, do not send a customer more than one request in a seven-day period) and handle unsubscribe requests, so your triggering logic does not have to account for this.

However, you can also configure your integration in a more granular way. See Best practice business rules for auto-triggering for more details.

Visit our API documentation under "Requests" for detailed libraries, custom header examples, and sample code.

Step 3: Monitor and confirm test results

Note: During the testing period, your agents will continue to send requests manually.

All test API calls that you send to Agent Connect will be sent to your API test email address and also display on the API status page.

Each API call that you make to the Agent Connect endpoint will return either:

  • A request_ID if the request was successful
  • An error if the request was unsuccessful

We recommend that you monitor the integration in test mode for a week to ensure it is working as you expect it to. This method allows you to:

  • Ensure that the number of requests is in line with your expectations.

  • Understand and address the root cause of any errors (see Troubleshooting / Maintenance for details).

Step 4: Go live

To start sending requests to customers, you'll need to start using your production key and turn each channel into "integrated" mode on the Integrations page.

example of switching channels to integrated mode

Switch to your production API key

With testing complete, return to the Integrations page and retrieve your production API key. Replace the test key with this production key inside your system.

Once this step is completed, your integration is live and sending requests to customers automatically.

Notify your team

Let your team know that you are now automatically triggering requests! You may wish to inform them of the following changes:

  • If you have enabled the integration for all channels, the manual send box will disappear completely.

  • If you have enabled only some of your channels, the manual send box will only work for the non-integrated channel (in the above example, the manual send box would only be used to send email interactions)