Each data connector consists of an API call which you can configure behind the scenes. Fin will automatically choose when to use it and deliver a personalized answer to the customer.
You can connect any system which has an API; that might be your unique internal backend tool you have built for your business, or a third party app you're using like Shopify, Salesforce, Stripe, Jira, and more.
The Messenger preview here uses example data. When setting the data connector live, Fin will use your real customer data.
Connect to external systems
Navigate to Settings > Integrations > data connectors and click New data connector.
Note: You need the “Can access developer hub” permission to configure an data connector or set an data connector live.
If you have one of the supported apps installed, you’ll see a template for this app listed under Create data connector. We currently support templates for Shopify, Stripe, and Statuspage (more on that below).
Create a data connector
From a 3rd party template
data connector templates are available when the following apps are installed in your workspace:
If the app is not already installed, go to the App Store to install. Once the app is installed, data connector templates for each app will appear as an data connector ready to set live.
When you click on a template, you’ll see some information about what the data connector does and you can test it in the Messenger preview. If you’re happy with the data connector behavior, just select Set live for AI Agent.
The Messenger preview here uses example data. When setting the data connector live, Fin will use your real customer data.
If you want to configure the data connector you can click on Customize, which will take you to the data connector builder for advanced configuration.
If you don’t have one of our supported apps installed, the apps will appear here for you to install them on your workspace. After installation, the relevant data connector templates will appear in the section above.
Learn more about available data connector templates and use cases for Fin.
From an AI recommendation
To see AI recommended data connectors, go to Settings > Integrations > data connectors and click New data connector.
You’ll see your unique AI recommended data connectors under "Create data connector from template". These are generated based on your conversation history to help you identify potential data connectors, see what percentage of conversation volume they could resolve, and preview them in the Messenger, before setting anything up.
For AI recommendations to appear, Fin needs to be live on your workspace and you must have sufficient conversation volume.
When you click on an AI recommended data connector, you’ll find information about what the data connector does and you can preview it in the Messenger (using example data). AI recommended data connectors are merely suggestions based on your conversation volume, but they require an API to be connected manually in order to work.
To set the data connector live, click Set up to configure the API details.
Now all you need to do is connect the data connector to your API by adding the HTTPS URL.
To further customize this data connector, see the custom data connector section below. 👇
From a custom data connector
To set up your own custom data connector for Fin, navigate to Settings > Integrations > data connectors and click New data connector > Create data connector.
About
First, provide a short name to describe what this data connector does such as “Get unpaid account balance”. This will help Fin know when to use it.
Next, provide a detailed description explaining when Fin should use this data connector. Include examples of the data this data connector provides and customer queries it helps answer.
For example:
Use this data connector to retrieve recent transdata connectors for a customer. This data connector provides key information such as… Example customer queries include…
See best practices for writing data connector descriptions.
Then check the box to enable Fin to use this action directly without adding it to a workflow or task.
Audience rules
You can customize who this data connector is available for by clicking Add audience rule. This way, you can set up an data connector to be used when, for example, a logged in user with a verified email asks about their account balance.
If you want to test the data connector before enabling it for customers, use the audience rules to enable the data connector just for you or your teammates initially.
Click Next step when done which will bring you to the API connection section.
API connection
If you want, you can specify if Fin should collect any data before using this data connector. This can be helpful in cases where you need to make sure data exists before the data connector is run. For example, you might want to ask the customer for their account number if this is not stored on their user profile in Intercom.
To collect data inputs, click on + Add data input and pick the format of the data that should be collected (text, number, decimal number, or true/false) and give it a name and description so Fin knows how to collect it.
When available, Fin will gather the information from the conversation context.
Next, you must specify the HTTPS URL of your API along with the type of request to be made (GET, POST, etc).
You may want to use attributes available within your workspace, such as a customer’s user ID, to perform a lookup as part of the workflow.
Within a data connector, you can use people, company and more attributes in the path or body of the request.
Passing dynamic attributes
You can pass dynamic attributes in the API endpoint URL like this:
This is also how you can ensure that Fin can use any collected data inputs configured in the data connector.
Tip: You can connect data connectors to APIs that return XML. Intercom will automatically convert XML responses to JSON, so you don’t need to do any manual conversion or use a third-party tool. This means you can connect to a wider range of external systems, even if they don’t support JSON natively.
Important: There are a few potential ways that Fin could accidentally share information from another user when parameter passing. See our recommended settings to best mitigate the risks.
HTTP Headers
You also need to make sure to specify the correct authentication token and to specify correct headers (for example: Accept: application/json or Content-Type: application/json).
Once done, click on Next step to proceed to the next step where you can test your data connector.
Test response
You’ll need to test this data connector to make sure it’s fetching the right data from the API you’re connecting to. You can test your data connector using two methods:
Live response: Test with live response data from your API request to ensure correct configuration. Live response will make an actual API call to your endpoint so be careful in case this request affects any real-world data.
Example response: Provide example JSON data which is useful if your API is not yet fully developed or you need to simulate/mock a particular response.
Tip: When you connect an API that returns XML, Data connectors will handle the conversion behind the scenes. You can test and preview the converted JSON in the “Test response” step, just as you would with a JSON API.
If everything is looking good, click on Next step to set up your data access.
Data transformation
By default, Fin can access the full response data to generate replies. Select Manually restrict access if you wish to limit the data Fin can read. Then check the data fields you want to give Fin access to.
You can also edit the individual data items by clicking on the edit icon to give your response data a customer facing name as well as specify any transformations to the data.
For example, if the API response returns a balance of 0, instead of Fin stating the unpaid balance is 0, it can reply stating that there is currently no unpaid balance remaining.
Use code to filter or transform the response
With code blocks for data connectors, we're empowering you to directly transform and manipulate API responses using Python—right inside your connector setup.
Unstructured or overly large payloads from APIs can cause AI-based responses (like Fin or other AI agents) to hallucinate, misinterpret, or simply fail to deliver clear answers. Now, you can programmatically preprocess, filter, or massage API responses before they're sent to Fin or mapped to Intercom objects without needing backend changes or third-party integrations.
How it works
return
statement: The main result your code block produces must be returned with areturn
statement. Only what’s returned will be sent forward to Fin or the rest of your connector.print()
statements: Use these only for debug or progress logging. These outputs are captured separately and are NOT sent as the API result.Standard modules only: You’re limited to a set of standard Python modules (
math
,decimal
,re
,datetime
,datetime.timezone
,json
,random
,time
). We will add more modules over time as they are needed.
Note:
Non-JSON Test Responses: Code blocks require that your API test response is a valid JSON object or array. Non-JSON payloads are not supported (and will cause failures).
Non-successful API requests: Code blocks can only transform successful API responses (status code 200). Error responses with status codes like 400, 404, or 500 are not supported for code block transformation.
How to configure code blocks for data connectors
Go to Settings > Integrations > data connectors and select the data connector you'd like to use code blocks with.
Then click on Data transformation and select the "Use code to filter or transform the response" option.
Access input data (API Response) in your code block
To access the data returned by your API (the test response), use the inputs['data']
variable inside your code block. Typically, this gives you the entire response from your API, ready to transform however you like.
For example, at the start of your code block, you typically write:
api_response = inputs['data']
This assigns the API response (a Python dictionary or list or string, depending on your API) to the variable api_response
for further processing.
Get automatic suggestions for code blocks
When you navigate to the Data transformation tab, your data connector response is automatically analyzed to identify suggestions that will improve Fin's performance.
This detects common issues like Unix timestamps and oversized payloads—unstructured or overly large data that can cause AI-based responses to hallucinate, misinterpret, or fail to deliver clear answers.
When a suggestion is found, you'll see a banner with a View suggestion button showing recommended Python code that will make your data cleaner and more reliable for Fin.
Select Test code to see the result it returns.
If you're happy with the return statement, select Accept suggestion to significantly improve the quality and accuracy of Fin's responses from your connector data.
Object mapping
When creating data connectors for Fin, there is no need to map response data to Intercom attributes or objects. Instead, Fin directly interprets the JSON response and can then use it to resolve questions. The response is generated based on the ‘Test response’ section. Each line item corresponds to a data point in the JSON response.
Click Set live and that’s it, Fin’s ready to use your data connector. 🎉
Using code blocks to optimize data for Fin
To use code blocks to optimize your data for Fin AI Agent, follow these steps:
Navigate to your Data Connector. In your workspace, go to Settings > Data connectors and select your data connector from the list.
Click the Data transformation tab.
View the code block suggestion. Look for the banner that says "We found ways to improve your data connector response format" and click View suggestion.
Review the suggested code block and the explanation ("Why we suggested a possible code block...") provided.
Save your changes. Click Save and set live to accept the suggestion and apply the code block.
Tip: Using code blocks helps improve the Fin AI Agent's performance and accuracy. They can reduce hallucinations and speed up response times by processing large data payloads and handling things like UNIX timestamps before the data is ingested by Fin.
Rolling out data connectors
We recommend using audience rules to roll out data connectors in phases to your customer base. This enables you to validate the performance of the data connector and make tweaks/changes where necessary.
Monitor and manage
To find existing data connectors, navigate to Settings > Integrations > data connectors. The data connectors enabled for Fin show a tick below "Usage" and you can see whether they're Live below the "Status" column.
Viewing in the inbox
Go to the Inbox conversation and select Show conversation events. Events will show if Fin has access to the data connector and if the data connector is successfully triggered.
Note:
If there’s an error with the data connector triggering, select Logs to find out why.
Fin may not always choose to use the data connector despite making an API request if other content is determined to be more relevant.
Inbox views can be created with the attribute “Fin AI Agent: data connector used in reply”. This attribute is set if Fin calls an data connector and uses some or all of the response in an answer.
Troubleshooting
For troubleshooting purposes, all response data generated from data connectors triggered by Fin is recorded for up to 7 days. You can access these logs under the specific data connector in Logs.
You can view response data based on what kind of data Fin has access to.
Entire response – Full, unmodified response
Redacted & Formatted response – After transformation
No response data
Need more help? Get support from our Community Forum
Find answers and get help from Intercom Support and Community Experts