Skip to content

Commit 24a7383

Browse files
Merge pull request #452 from thoughtspot/26.4.0.cl
26.4.0.cl docs publication
2 parents dfc7030 + 7ed39c6 commit 24a7383

34 files changed

Lines changed: 2053 additions & 700 deletions

modules/ROOT/pages/abac-migration-from-jwt-beta.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ Verify that variable values are correctly assigned to users using one of the fol
175175
* Send a `POST` request to the `/api/rest/2.0/users/search` with user details, and explore the `variable_values` section of the response payload.
176176
* Send a `POST` request to the `/api/rest/2.0/template/variables/search` API endpoint with variable details. In the request body, specify the `response_content` as `METADATA_AND_VALUES`, and explore the variable values for each user in the response payload.
177177

178-
If you want to update the values of variables, use either `/api/rest/2.0/template/variables/update-values` or `/api/rest/2.0/auth/token/custom` API endpoint.
178+
If you want to update the values of variables, use either `/api/rest/2.0/template/variables/{identifier}/update-values` or `/api/rest/2.0/auth/token/custom` API endpoint.
179179

180180
== Review the configuration
181181
Before you begin testing, your setup should have the following JWT ABAC configuration:

modules/ROOT/pages/abac-migration-from-jwt-ga.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ Users with administration and *Can Administer and Bypass RLS* privileges are exe
148148
+
149149
[NOTE]
150150
====
151-
To update variable values for a user, use the `/api/rest/2.0/auth/token/custom` or `/api/rest/2.0/template/variables/update-values` API endpoint.
151+
To update variable values for a user, use the `/api/rest/2.0/auth/token/custom` or `/api/rest/2.0/template/variables/{identifier}/update-values` API endpoint.
152152
====
153153

154154
== Expected setup before the testing phase

modules/ROOT/pages/abac_rls-variables.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ The following rule restricts access to rows where the `date_column` is within th
162162

163163
To set or update variable values for a user, use the `POST /api/rest/2.0/auth/token/custom` endpoint when logging in the user.
164164

165-
You can also use the `/api/rest/2.0/template/variables/update-values` endpoint for bulk operations or targeted resets.
165+
You can also use the `/api/rest/2.0/template/variables/{identifier}/update-values` endpoint for bulk operations or targeted resets.
166166

167167
The variable attributes defined in the token request take effect only if they are referenced in an RLS rule. If the variables are not used in any formula or RLS rule, they have no impact on data access. Before generating the request with variable attributes, ensure that the xref:abac_rls-variables.adoc#_add_or_update_rls_rules_with_variable_references[variables are added to the RLS rules] for the table.
168168

@@ -263,7 +263,7 @@ If you don't want to append or replace any attribute values, do not pass any det
263263
=== Resetting a user or a variable
264264
Passing an empty array along with a formula variable name in the token request *does not reset the attribute values* for that formula variable for that user.
265265

266-
To change formula variable attributes of a user, especially to set entitlements to an empty set, use the `/api/rest/2.0/template/variables/update-values` API endpoint.
266+
To change formula variable attributes of a user, especially to set entitlements to an empty set, use the `/api/rest/2.0/template/variables/{identifier}/update-values` API endpoint.
267267

268268
[WARNING]
269269
====

modules/ROOT/pages/api-changelog.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ If the current period inclusion in rolling date filters feature is enabled on yo
9797
To disable this feature, use the `isThisPeriodInDateFiltersEnabled` setting. To hide, show, or disable this option in the embed view, use the action ID, `Action.IncludeCurrentPeriod`.
9898
|====
9999

100+
100101
== Version 1.46.x, March 2026
101102

102103
[width="100%" cols="1,4"]
@@ -265,7 +266,7 @@ The `HostEvent.UpdateParameters` event now supports configuring the `isVisibleTo
265266

266267
[width="100%" cols="1,4"]
267268
|====
268-
|[tag greenBackground]#NEW FEATURE# a|*Runtime overrides in Spotter embed*
269+
|[tag greenBackground]#NEW FEATURE# a|*Runtime overrides in Spotter embed*
269270

270271
The Visual Embed SDK now supports runtime overrides in Spotter embed.
271272

Lines changed: 317 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,317 @@
1+
= Collections [beta betaBackground]^Beta^
2+
:toc: true
3+
:toclevels: 1
4+
:page-title: Collections
5+
:page-pageid: collections
6+
:page-description: group different ThoughtSpot objects into Collections to manage them more easily.
7+
8+
9+
ThoughtSpot now provides REST APIs that enable developers to organize different ThoughtSpot objects into an organizational container called *Collections*. These objects can be Liveboards, Answers, data models, tables, and even other Collections.
10+
Collections provide a powerful way to manage your data assets, making discovery and collaboration easier, while ensuring the integrity of embedded workflows.
11+
12+
[NOTE]
13+
====
14+
The Collections APIs are in Beta and disabled by default on ThoughtSpot instances. To enable these APIs on your instance, contact ThoughtSpot Support.
15+
====
16+
17+
== Before you begin
18+
19+
* For REST API v2 operations, the Org context is determined based on the authentication token used in your API requests. Ensure you log in to the appropriate Org context from which you want to send API requests.
20+
* When enabled on a ThoughtSpot instance, Collections can be created by any user, and need no special user privileges.
21+
22+
23+
== Create a Collection
24+
To create a new Collection, send a `POST` request to the `POST /api/rest/2.0/collections/create` API endpoint, with the following parameters in the request body.
25+
26+
=== Request parameters
27+
In your `POST` request body, include the following parameters:
28+
29+
[width="100%" cols="1,4"]
30+
[options='header']
31+
|=====
32+
|Parameter|Description
33+
34+
|`name` a|__String__. Required. Specify a name for the Collection.
35+
|`description` a|__String__. Optional. A short description for the Collection.
36+
|`metadata` a|__Array__. Optional. The details for the metadata objects to be added to the Collection.
37+
38+
* `type` +
39+
Metadata type. Select one of the following values:
40+
** `LIVEBOARD`
41+
** `ANSWER`
42+
** `LOGICAL_TABLE`
43+
** `COLLECTION`
44+
+
45+
To create nested collections, assign the `COLLECTION` metadata to a Collection.
46+
47+
* `identifiers` +
48+
List of unique IDs or names of metadata objects.
49+
|=====
50+
51+
==== Example request
52+
[source,CURL]
53+
----
54+
curl -X POST \
55+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/create' \
56+
-H 'Accept: application/json' \
57+
-H 'Content-Type: application/json' \
58+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
59+
--data-raw '{
60+
"name": "Demo Collection",
61+
"metadata": [
62+
{
63+
"type": "LIVEBOARD",
64+
"identifiers": [
65+
"Retail sales (Sample)",
66+
"fe307a35-5242-445f-b3cb-b84cd1fc339c"
67+
]
68+
},
69+
{
70+
"type": "COLLECTION",
71+
"identifiers": [
72+
"Collection A"
73+
]
74+
}
75+
],
76+
"description": "For testing"
77+
}'
78+
79+
----
80+
81+
==== API response
82+
83+
If the API request is successful, a Collection with the given metadata objects will be created.
84+
85+
== Search for a Collection
86+
To get a list of Collections, send a `POST` request to the `POST /api/rest/2.0/collections/search` API endpoint.
87+
88+
If no parameters are specified, the API returns the first 10 collections (or fewer, depending on the total number available).
89+
90+
=== Request parameters
91+
In your `POST` request body, include the following parameters:
92+
93+
[width="100%" cols="1,4"]
94+
[options='header']
95+
|=====
96+
|Parameter|Description
97+
98+
|`name_pattern` a|__String__. Optional. Specify any case agnostic pattern to match the name of a Collection. Use `%` to perform a wildcard search by name.
99+
|`record_offset` a|__Number__. Optional. The index of the first record to be included. Default value is 0.
100+
|`record_size` a|__Number__. Optional. The total number of records to be searched. Default value is 10. Set to -1 to search across all available collections.
101+
|`collection_identifiers` a|__Array__. Optional. GUID of the Collection(s) to be searched. `name_pattern` takes precedence over the `collection_identifiers`.
102+
|`created_by_user_identifiers` a|__Array__. Optional. Searches for Collections by the name of the author.
103+
|`include_metadata` a|__Boolean__. Optional. When set to `true`, includes the metadata objects within each Collection in the response.
104+
|`sort_options` a|__Array__. Optional. To sort the search results, specify the field to apply the sort on `field_name`, and the sort order `order`.
105+
|=====
106+
107+
==== Example request
108+
[source,CURL]
109+
----
110+
curl -X POST \
111+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/search' \
112+
-H 'Accept: application/json' \
113+
-H 'Content-Type: application/json' \
114+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
115+
--data-raw '{
116+
"record_offset": 2,
117+
"record_size": 15,
118+
"include_metadata": false,
119+
"name_pattern": "%",
120+
"sort_options": {
121+
"field_name": "NAME",
122+
"order": "ASC"
123+
}
124+
}'
125+
----
126+
127+
==== API response
128+
129+
If the API request is successful, it will return a list of Collection(s) matching the search criteria.
130+
131+
== Update a Collection
132+
To update an existing Collection, send a `POST` request to the `POST /api/rest/2.0/collections/{collection_identifier}/update` API endpoint.
133+
134+
=== Request parameters
135+
In your `POST` request body, include the following parameters:
136+
137+
[width="100%" cols="1,4"]
138+
[options='header']
139+
|=====
140+
|Parameter|Description
141+
142+
|`collection_identifier` a| Required. GUID of the Collection to be updated. `collection_identifier` is passed as a parameter in the API request.
143+
|`name` a|__String__. Optional. New name for the Collection.
144+
|`description` a|__String__. Optional. Updated or a newly added description for the Collection.
145+
|`metadata` a|__Array__. Required. The details for the metadata objects to be added, removed, or replaced in the Collection.
146+
147+
* `type`
148+
* `identifiers`
149+
|`operation` a|__Enum__. Required. Specify the nature of the update. Select one of the following values:
150+
151+
* ADD: Adds the specified metadata objects to the existing Collection without removing the current objects.
152+
* REMOVE: Removes only the specified metadata objects from the Collection.
153+
* REPLACE. __Default__: This replaces all existing objects in the Collection with the objects specified in this replace request.
154+
|=====
155+
156+
==== Example request
157+
[source,CURL]
158+
----
159+
curl -X POST \
160+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/0e5fd958-cb2b-43f0-b67f-13ac5c805bad/update' \
161+
-H 'Accept: application/json' \
162+
-H 'Content-Type: application/json' \
163+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
164+
--data-raw '{
165+
"operation": "ADD",
166+
"metadata": [
167+
{
168+
"type": "LIVEBOARD",
169+
"identifiers": [
170+
"6fee1adb-1c50-4c15-8d49-4fe0503d0b34"
171+
]
172+
}
173+
]
174+
}'
175+
----
176+
==== API response
177+
178+
If the API request is successful, the object specified in the API request is added to the Collection.
179+
180+
==== Example request
181+
[source,CURL]
182+
----
183+
curl -X POST \
184+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/0e5fd958-cb2b-43f0-b67f-13ac5c805bad/update' \
185+
-H 'Accept: application/json' \
186+
-H 'Content-Type: application/json' \
187+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
188+
--data-raw '{
189+
"operation": "REMOVE",
190+
"metadata": [
191+
{
192+
"type": "LIVEBOARD",
193+
"identifiers": [
194+
"6fee1adb-1c50-4c15-8d49-4fe0503d0b34"
195+
]
196+
}
197+
]
198+
}'
199+
----
200+
201+
==== API response
202+
203+
If the API request is successful, the object specified in the API request is removed from the Collection.
204+
205+
==== Example request
206+
[source,CURL]
207+
----
208+
curl -X POST \
209+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/0e5fd958-cb2b-43f0-b67f-13ac5c805bad/update' \
210+
-H 'Accept: application/json' \
211+
-H 'Content-Type: application/json' \
212+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
213+
--data-raw '{
214+
"operation": "REPLACE",
215+
"metadata": [
216+
{
217+
"type": "LIVEBOARD",
218+
"identifiers": [
219+
"6fee1adb-1c50-4c15-8d49-4fe0503d0b34",
220+
"87328d32-2bf0-4fc4-ac51-a738712d7e79"
221+
]
222+
},
223+
{
224+
"type": "COLLECTION",
225+
"identifiers": [
226+
"6d85c77c-4822-42ba-8074-6306a90ba8e1"
227+
]
228+
}
229+
]
230+
}'
231+
----
232+
233+
234+
==== API response
235+
236+
If the API request is successful, the objects in the Collection are replaced with the objects in this API request.
237+
238+
== Delete a Collection
239+
To remove an existing Collection, send a `POST` request to the `POST /api/rest/2.0/collections/delete` API endpoint.
240+
241+
=== Request parameters
242+
In your `POST` request body, include the following parameters:
243+
244+
[width="100%" cols="1,4"]
245+
[options='header']
246+
|=====
247+
|Parameter|Description
248+
249+
|`collection_identifiers` a|__String__. Required. GUID of the Collection to be deleted.
250+
|`delete_children` a|__String__. Optional. Set to `true` to delete child objects in the Collection where the user has permission. Any objects without delete access will be ignored.
251+
|`dry_run` a|__String__. Optional. Set to true to preview the deletion process without removing any objects. The response lists the items that would be deleted, so you can review them before proceeding with actual deletion.
252+
|=====
253+
254+
==== Example request
255+
To review your deletion request without actually deleting the Collection and its objects, set `dry_run` to `true` and `delete_children` to `true`.
256+
257+
[source,CURL]
258+
----
259+
curl -X POST \
260+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/delete' \
261+
-H 'Accept: application/json' \
262+
-H 'Content-Type: application/json' \
263+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
264+
--data-raw '{
265+
"collection_identifiers": [
266+
"6996b262-8733-4af6-8f8e-8d7faefb5be0"
267+
],
268+
"delete_children": true,
269+
"dry_run": true
270+
}'
271+
----
272+
273+
==== API response
274+
275+
If the API request is successful, it gives you a preview of the deletion operation without actually deleting anything.
276+
277+
* `metadata_deleted`: List of metadata objects that will be deleted
278+
* `metadata_skipped`: List of metadata objects that will not be deleted for lack of permissions or other constraints
279+
280+
[source,JSON]
281+
----
282+
{"metadata_deleted":[{"type":"COLLECTION","identifiers":[{"id":"6996b262-8733-4af6-8f8e-8d7faefb5be0","name":"Docs Collection"}]},{"type":"LIVEBOARD","identifiers":[{"id":"278d2313-ac3a-44bb-b842-a4c9dff84e68","name":"Demo-lb"},{"id":"1bcdb2c1-e960-4f6b-bbf9-64f3e0cd33b9","name":"Demo-lb1"}]}],"metadata_skipped":[]}
283+
----
284+
285+
==== Example request
286+
To delete the Collection and the objects within it, set `dry_run` to `false` and `delete_children` to `true`.
287+
288+
[source,CURL]
289+
----
290+
curl -X POST \
291+
--url 'https://{ThoughtSpot-Host}/api/rest/2.0/collections/delete' \
292+
-H 'Accept: application/json' \
293+
-H 'Content-Type: application/json' \
294+
-H 'Authorization: Bearer {AUTH_TOKEN}' \
295+
--data-raw '{
296+
"collection_identifiers": [
297+
"6996b262-8733-4af6-8f8e-8d7faefb5be0"
298+
],
299+
"delete_children": true,
300+
"dry_run": false
301+
}'
302+
----
303+
304+
==== API response
305+
If the API request is successful, it deletes the Collection and all objects within it for which you have delete permission.
306+
307+
[source,JSON]
308+
----
309+
{"metadata_deleted":[{"type":"COLLECTION","identifiers":[{"id":"6996b262-8733-4af6-8f8e-8d7faefb5be0","name":"Docs Collection"}]},{"type":"LIVEBOARD","identifiers":[{"id":"278d2313-ac3a-44bb-b842-a4c9dff84e68","name":"Demo-lb"},{"id":"1bcdb2c1-e960-4f6b-bbf9-64f3e0cd33b9","name":"Demo-lb1"}]}],"metadata_skipped":[]}
310+
----
311+
312+
== Additional references
313+
314+
315+
* For information about creating and managing Collections via ThoughtSpot UI, see link:https://docs.thoughtspot.com/cloud/latest/collections[Collections in ThoughtSpot, window=_blank]
316+
317+

0 commit comments

Comments
 (0)