You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/pages/product/apis-integrations/embedding.mdx
+16-1Lines changed: 16 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,10 +35,21 @@ Use the `/api/v1/embed/generate-session` endpoint to create a session for your u
35
35
</WarningBox>
36
36
37
37
38
+
#### Request parameters
39
+
40
+
-**`deploymentId`** (required): The deployment ID to scope the session to. This ensures tokens and access are limited to a specific deployment and model, providing better security isolation.
41
+
-**`externalId`** (required): A unique identifier for your user (e.g., email, user ID)
42
+
-**`userAttributes`** (optional): Array of attributes for row-level security and personalized responses
43
+
44
+
<InfoBox>
45
+
The `deploymentId` parameter is required for security purposes. It scopes the generated session token to a specific deployment and data model, preventing unauthorized access across different deployments or models.
@@ -110,6 +123,7 @@ Here's a complete HTML example that demonstrates the full flow for embedding a d
110
123
Authorization:`Access-Token ${API_KEY}`,
111
124
},
112
125
body:JSON.stringify({
126
+
deploymentId:DEPLOYMENT_ID,
113
127
externalId: externalId,
114
128
}),
115
129
},
@@ -165,6 +179,7 @@ User attributes enable row-level security and personalized chat responses by fil
165
179
## Security considerations
166
180
167
181
-**API Key Security**: Keep your API keys secure and never expose them in client-side code
182
+
-**Deployment Scoping**: The required `deploymentId` parameter ensures that generated session tokens are scoped to a specific deployment and data model. This provides isolation between different deployments and prevents unauthorized cross-deployment access.
168
183
-**Session Management**: Sessions are temporary and should be regenerated as needed
169
184
-**HTTPS**: Always use HTTPS in production environments
170
185
@@ -187,4 +202,4 @@ If you encounter issues with dashboard embedding:
187
202
- Contact support if you need assistance with configuration
0 commit comments