@@ -49,33 +49,7 @@ If you swap the sort order of these columns, the resulting output changes accord
4949
5050== Runtime sorting of columns via REST API
5151
52- You can use the REST API v1 or REST API v2 endpoints to apply runtime sorting parameters.
53-
54- === REST API v1
55-
56- If you are using REST API v1 endpoints, runtime sorts can be applied when fetching a Liveboard or Answer object from ThoughtSpot.
57-
58- To sort columns when fetching data from a Liveboard object, add sort properties to the Liveboard data API request URL as shown in the example here:
59-
60- ----
61- http://{ThoughtSpot-host}/callosum/v1/tspublic/v1/pinboarddata?id=e36ee65e-64be-436b-a29a-22d8998c4fae&batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false
62- ----
63- ----
64- https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/pinboarddata?id=e36ee65e-64be-436b-a29a-22d8998c4fae&batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false&sortCol2=Tea
65- ----
66-
67- To sort columns of an Answer object, add the sort attributes to the search data API request URL as shown in the following examples:
68- ----
69- https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/searchdata?batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false
70- ----
71-
72- ----
73- https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/searchdata?batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false&sortCol2=Tea
74- ----
75-
76- === REST API v2.0
77-
78- The following REST API v2.0 endpoints support applying runtime sort parameters:
52+ The following REST API v2 endpoints support applying runtime sort parameters:
7953
8054* `POST /api/rest/2.0/report/liveboard`
8155* `POST /api/rest/2.0/report/answer`
@@ -86,7 +60,7 @@ The following REST API v2.0 endpoints support applying runtime sort parameters:
8660
8761The following examples show the request body with runtime sort attributes:
8862
89- .** Answer report**
63+ === Answer report
9064
9165[source,cURL]
9266----
@@ -106,7 +80,7 @@ curl -X POST \
10680}'
10781----
10882
109- .** Liveboard report**
83+ === Liveboard report
11084
11185[source,cURL]
11286----
@@ -127,8 +101,7 @@ curl -X POST \
127101----
128102
129103
130-
131- .**Search data**
104+ === Search data
132105
133106[source,cURL]
134107----
@@ -149,7 +122,7 @@ curl -X POST \
149122}'
150123----
151124
152- .** Answer data**
125+ === Answer data
153126
154127[source,cURL]
155128----
@@ -169,7 +142,7 @@ curl -X POST \
169142}'
170143----
171144
172- .** Liveboard data**
145+ === Liveboard data
173146
174147[source,cURL]
175148----
@@ -187,4 +160,26 @@ curl -X POST \
187160 "asc2": false
188161 }
189162}
190- ----
163+ ----
164+
165+ === REST API v1 (Legacy endpoints)
166+
167+ If you are using REST API v1 endpoints, runtime sorts can be applied when fetching a Liveboard or Answer object from ThoughtSpot.
168+
169+ To sort columns when fetching data from a Liveboard object, add sort properties to the Liveboard data API request URL as shown in the example here:
170+
171+ ----
172+ http://{ThoughtSpot-host}/callosum/v1/tspublic/v1/pinboarddata?id=e36ee65e-64be-436b-a29a-22d8998c4fae&batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false
173+ ----
174+ ----
175+ https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/pinboarddata?id=e36ee65e-64be-436b-a29a-22d8998c4fae&batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false&sortCol2=Tea
176+ ----
177+
178+ To sort columns of an Answer object, add the sort attributes to the search data API request URL as shown in the following examples:
179+ ----
180+ https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/searchdata?batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false
181+ ----
182+
183+ ----
184+ https://{ThoughtSpot-host}/callosum/v1/tspublic/v1/searchdata?batchsize=-1&pagenumber=-1&offset=-1&formattype=COMPACT&sortCol1=Sales&asc1=false&sortCol2=Tea
185+ ----
0 commit comments