The User Data API lets your AI agent give personalised answers by fetching live data about the person it is talking to — their subscription tier, recent orders, account status, or any other information your backend holds. Rather than calling your systems directly, My AskAI calls a webhook URL you register. Your endpoint receives the user’s identifier, looks up the relevant data, and returns it as a JSON response. The agent then injects that context into its reasoning before composing a reply. This is especially powerful for e-commerce and SaaS support scenarios: instead of giving a generic “check your account page” reply, the agent can say “Your last order (#12345) was delivered on 1 September and is currently showing as Delivered.”Documentation Index
Fetch the complete documentation index at: https://mintlify.com/arainey2022/myaskai-docs/llms.txt
Use this file to discover all available pages before exploring further.
If you run a Shopify store, you can use the no-code Shopify connector instead of building a custom endpoint. Go to Knowledge → Content → Connect live user data to get started.
How It Works
You register a webhook URL
In the My AskAI dashboard go to Knowledge → Content, scroll to Connect live user data, and click + New Connection. Enter your endpoint URL, the
Authorization header name, and the corresponding secret key.A user starts a conversation
When a user with a validated email address contacts your AI agent, My AskAI detects their identifier (e.g. their email address, extracted from a Zendesk ticket or an authenticated Intercom conversation).
My AskAI calls your endpoint
My AskAI makes a
POST request to your registered URL, sending the user’s identifier in the request body. Your endpoint must respond within 10 seconds.Your endpoint returns user data
You return a JSON payload containing any user context that may be relevant for answering support questions — name, plan, order history, entitlements, and so on.
Configuring the Webhook
- Log in to your My AskAI dashboard.
- Go to Knowledge → Content.
- Scroll to Connect live user data and click + New Connection.
- Fill in the following fields:
- API endpoint URL — the full URL My AskAI should call (e.g.
https://api.yourcompany.com/myaskai/user-data) - Authorization Header — the header name your endpoint expects (e.g.
Authorization) - Authorization Header Key — the secret value My AskAI will send in that header
- API endpoint URL — the full URL My AskAI should call (e.g.
- Enter a test user email address and click Test User Data API to verify your endpoint returns a valid response.
- Once satisfied, click the toggle to Activate live user data.
Incoming Request from My AskAI
My AskAI sends the followingPOST request to your endpoint for every new support conversation or ticket where the user’s identifier is available.
Headers My AskAI Sends
| Header | Value |
|---|---|
Content-Type | application/json |
Authorization | The secret key you configured in the dashboard |
Request Body
The user’s email address, extracted from the authenticated support conversation or ticket. This is the lookup key your endpoint should use to retrieve user data.
Example Request Body
Expected Response from Your Endpoint
Your endpoint must return an HTTP200 with a JSON body containing the following fields.
A string containing all relevant user information. Format it clearly so the agent can parse and reference individual data points — plain text with newlines or a structured format both work well. Keep it focused: include only information that might be needed to answer a support question.
If
user_info exceeds 1,500 characters, each response is charged as a tool call at $0.02 per message.Echo back the same
identifier value that was sent in the request.Example Response
Authentication of Incoming Requests
My AskAI authenticates itself to your endpoint using the shared secret you configure in the dashboard. Verify this secret on every request to ensure you only process calls from My AskAI.Performance Requirements
| Requirement | Value |
|---|---|
| Maximum response time | 10 seconds |
| Response format | application/json |
Maximum user_info length (free) | 1,500 characters |
Error Handling
Your endpoint should return appropriate HTTP status codes for error conditions. If your endpoint is unavailable or returns an error, My AskAI will continue the conversation without user context rather than failing the entire conversation.| Status code | Meaning |
|---|---|
200 OK | User data returned successfully |
400 Bad Request | Request body missing the identifier field |
401 Unauthorized | Authorization header missing or incorrect |
404 Not Found | No user found for the provided identifier |
500 Internal Server Error | Unexpected error in your backend |