Treasure AI
Enterprise customer data platform for collecting, unifying, and activating customer data with built-in AI and machine learning capabilities.
Prerequisites
Complete these steps in Treasure AI before configuring Signal.
Access your Treasure AI account
Log in to the Treasure AI console at console.treasuredata.com (US) or console.eu01.treasuredata.com (EU). If you do not have an account, contact your Treasure AI representative.
Determine your region
Your Treasure AI region determines the API endpoint. Check your console URL:
| Console URL | Region | Value for Signal |
|---|---|---|
console.treasuredata.com | US | us |
console.eu01.treasuredata.com | EU | eu |
console.ap1.treasuredata.com | Asia Pacific | ap |
Create a database
Navigate to Data Workbench > Databases and click New Database. Give it a descriptive name (e.g. datafly_events). This is where your ingested events will be stored.
Create a table
Within your new database, click New Table. Give it a name (e.g. events). The table schema will be created automatically based on the data you ingest. Alternatively, you can predefine columns if you want stricter schema enforcement.
Generate a write-only API key
Navigate to My Settings > API Keys (or Administration > API Keys). Click Create New API Key and select Write-only as the key type. Copy the key immediately.
Use a Write-only API key for Signal. This provides the minimum permissions needed for data ingestion and limits the key’s access if compromised.
Configuration
| Field | Type | Required | Description |
|---|---|---|---|
api_key | secret | Yes | Your Treasure AI write-only API key. Generated in My Settings > API Keys. |
database_name | string | Yes | The target database name. Must already exist in your Treasure AI account. |
table_name | string | Yes | The target table name within the database. Created automatically if it does not exist. |
region | select | Yes | Your Treasure AI region (us, eu, or ap). Determines the API endpoint. |
Signal Setup
Quick Setup
- Navigate to Integrations in the sidebar.
- Open the Integration Library tab.
- Find Treasure AI under the CDP category.
- Click Install, and fill in the required fields with the credentials gathered above.
- Click Install Integration to create the integration with a ready-to-use default configuration.
API Setup
curl -X POST http://localhost:8084/v1/admin/integration-catalog/treasure_data/install \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Treasure AI",
"variant": "default",
"config": {
"api_key": "xxxxxxxxxxxxxxxxxxxx",
"database_name": "datafly_events",
"table_name": "events",
"region": "us"
},
"delivery_mode": "server_side"
}'Event Mapping
Signal events are mapped to Treasure AI records as follows:
| Signal Event | Treasure AI Concept | Notes |
|---|---|---|
page | Table record | Page view data inserted as a record with URL, title, referrer, and timestamp columns |
track | Table record | Event name and properties inserted as a record with event-specific columns |
identify | Table record | User traits inserted as a record for downstream identity resolution and audience building |
All records include a time column (Unix timestamp) that Treasure AI uses for time-based partitioning and querying. Event properties are flattened into individual columns.
Identity
| Field | Source | Notes |
|---|---|---|
td_user_id | user_id from datafly.identify() | Canonical authenticated identifier. |
email | traits.email | Email for downstream identity stitching. |
td_client_id | Datafly anonymous identifier | Browser-scoped first-party identifier. |
td_ip | request IP | Forwarded for geo and bot detection. |
td_user_agent | request user-agent | Forwarded for device classification. |
Consent
Treasure AI events should typically be sent under the marketing consent category. Visitors who decline are filtered out by Signal before ingestion, so the table only contains records you are permitted to use.
Delivery
Events are delivered server-side from your Datafly Signal infrastructure directly to the Treasure AI Postback API. No client-side scripts are loaded for this integration.
Verify it’s working
- After installing the integration, trigger a test event from your website or via the Signal event API.
- In the Treasure AI console, navigate to Data Workbench > Databases and select your database and table.
- Run a quick query (
SELECT * FROM your_table ORDER BY time DESC LIMIT 10) to verify records were ingested. - In Signal, check Live Events to confirm delivery with a
200response status.
Troubleshooting
| Symptom | Possible Cause | Resolution |
|---|---|---|
401 Unauthorized | Invalid API key | Regenerate the API key in Treasure AI My Settings > API Keys and update the integration config |
404 Not Found | Database does not exist | Create the database in Treasure AI Data Workbench > Databases before sending events |
403 Forbidden | Wrong key type | Ensure you are using a Write-only (or Master) API key, not a Read-only key |
| Wrong region | Region mismatch | Check your Treasure AI console URL and ensure the region config matches |
| Data not appearing | Ingestion delay | Treasure AI may buffer ingested data for a few minutes. Wait and re-query the table |
Visit Treasure AI documentation for full API reference and database configuration details.
See also
- Lytics — behavioural scoring CDP
- Salesforce CDP — enterprise CDP
- Google BigQuery — direct warehouse delivery