@thoughtspot/visual-embed-sdk 1.51.2 → 1.52.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (316) hide show
  1. package/cjs/package.json +9 -1
  2. package/cjs/src/api-intercept.d.ts.map +1 -1
  3. package/cjs/src/api-intercept.js +1 -0
  4. package/cjs/src/api-intercept.js.map +1 -1
  5. package/cjs/src/contracts/contracts.spec.d.ts +2 -0
  6. package/cjs/src/contracts/contracts.spec.d.ts.map +1 -0
  7. package/cjs/src/contracts/contracts.spec.js +345 -0
  8. package/cjs/src/contracts/contracts.spec.js.map +1 -0
  9. package/cjs/src/contracts/embed-event-payloads.d.ts +73 -0
  10. package/cjs/src/contracts/embed-event-payloads.d.ts.map +1 -0
  11. package/cjs/src/contracts/embed-event-payloads.js +3 -0
  12. package/cjs/src/contracts/embed-event-payloads.js.map +1 -0
  13. package/cjs/src/contracts/host-event-contracts.d.ts +378 -0
  14. package/cjs/src/contracts/host-event-contracts.d.ts.map +1 -0
  15. package/cjs/src/contracts/host-event-contracts.js +3 -0
  16. package/cjs/src/contracts/host-event-contracts.js.map +1 -0
  17. package/cjs/src/contracts/index.d.ts +22 -0
  18. package/cjs/src/contracts/index.d.ts.map +1 -0
  19. package/cjs/src/contracts/index.js +33 -0
  20. package/cjs/src/contracts/index.js.map +1 -0
  21. package/cjs/src/contracts/ui-passthrough-contracts.d.ts +277 -0
  22. package/cjs/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
  23. package/cjs/src/{embed/hostEventClient/contracts.js → contracts/ui-passthrough-contracts.js} +6 -2
  24. package/cjs/src/contracts/ui-passthrough-contracts.js.map +1 -0
  25. package/cjs/src/css-variables.d.ts +1 -1
  26. package/cjs/src/embed/app.d.ts +17 -140
  27. package/cjs/src/embed/app.d.ts.map +1 -1
  28. package/cjs/src/embed/app.js +20 -120
  29. package/cjs/src/embed/app.js.map +1 -1
  30. package/cjs/src/embed/app.spec.js +70 -26
  31. package/cjs/src/embed/app.spec.js.map +1 -1
  32. package/cjs/src/embed/conversation.d.ts +5 -5
  33. package/cjs/src/embed/events.spec.js +12 -2
  34. package/cjs/src/embed/events.spec.js.map +1 -1
  35. package/cjs/src/embed/hostEventClient/host-event-client.d.ts +3 -2
  36. package/cjs/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
  37. package/cjs/src/embed/hostEventClient/host-event-client.js +23 -18
  38. package/cjs/src/embed/hostEventClient/host-event-client.js.map +1 -1
  39. package/cjs/src/embed/hostEventClient/host-event-client.spec.js +36 -36
  40. package/cjs/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
  41. package/cjs/src/embed/hostEventClient/utils.d.ts +1 -1
  42. package/cjs/src/embed/hostEventClient/utils.d.ts.map +1 -1
  43. package/cjs/src/embed/hostEventClient/utils.js +3 -3
  44. package/cjs/src/embed/hostEventClient/utils.js.map +1 -1
  45. package/cjs/src/embed/liveboard.d.ts +9 -161
  46. package/cjs/src/embed/liveboard.d.ts.map +1 -1
  47. package/cjs/src/embed/liveboard.js +68 -135
  48. package/cjs/src/embed/liveboard.js.map +1 -1
  49. package/cjs/src/embed/liveboard.spec.js +215 -32
  50. package/cjs/src/embed/liveboard.spec.js.map +1 -1
  51. package/cjs/src/embed/search.d.ts +14 -0
  52. package/cjs/src/embed/search.d.ts.map +1 -1
  53. package/cjs/src/embed/search.js +4 -1
  54. package/cjs/src/embed/search.js.map +1 -1
  55. package/cjs/src/embed/search.spec.js +65 -0
  56. package/cjs/src/embed/search.spec.js.map +1 -1
  57. package/cjs/src/embed/ts-embed.d.ts +21 -25
  58. package/cjs/src/embed/ts-embed.d.ts.map +1 -1
  59. package/cjs/src/embed/ts-embed.js +105 -72
  60. package/cjs/src/embed/ts-embed.js.map +1 -1
  61. package/cjs/src/embed/ts-embed.spec.d.ts.map +1 -1
  62. package/cjs/src/embed/ts-embed.spec.js +380 -33
  63. package/cjs/src/embed/ts-embed.spec.js.map +1 -1
  64. package/cjs/src/full-height.d.ts +137 -0
  65. package/cjs/src/full-height.d.ts.map +1 -0
  66. package/cjs/src/full-height.js +272 -0
  67. package/cjs/src/full-height.js.map +1 -0
  68. package/cjs/src/full-height.spec.d.ts +2 -0
  69. package/cjs/src/full-height.spec.d.ts.map +1 -0
  70. package/cjs/src/full-height.spec.js +835 -0
  71. package/cjs/src/full-height.spec.js.map +1 -0
  72. package/cjs/src/index.d.ts +4 -3
  73. package/cjs/src/index.d.ts.map +1 -1
  74. package/cjs/src/index.js +5 -4
  75. package/cjs/src/index.js.map +1 -1
  76. package/cjs/src/react/all-types-export.d.ts +1 -1
  77. package/cjs/src/react/all-types-export.d.ts.map +1 -1
  78. package/cjs/src/react/all-types-export.js +2 -1
  79. package/cjs/src/react/all-types-export.js.map +1 -1
  80. package/cjs/src/react/all-types-export.parity.spec.js +55 -3
  81. package/cjs/src/react/all-types-export.parity.spec.js.map +1 -1
  82. package/cjs/src/react/index.d.ts +8 -8
  83. package/cjs/src/react/index.d.ts.map +1 -1
  84. package/cjs/src/react/index.js +1 -1
  85. package/cjs/src/react/index.js.map +1 -1
  86. package/cjs/src/react/index.spec.js +7 -7
  87. package/cjs/src/react/index.spec.js.map +1 -1
  88. package/cjs/src/types.d.ts +664 -39
  89. package/cjs/src/types.d.ts.map +1 -1
  90. package/cjs/src/types.js +406 -13
  91. package/cjs/src/types.js.map +1 -1
  92. package/cjs/src/utils/processTrigger.d.ts +3 -1
  93. package/cjs/src/utils/processTrigger.d.ts.map +1 -1
  94. package/cjs/src/utils/processTrigger.js +19 -51
  95. package/cjs/src/utils/processTrigger.js.map +1 -1
  96. package/cjs/src/utils/transport/iframe-transport.d.ts +55 -0
  97. package/cjs/src/utils/transport/iframe-transport.d.ts.map +1 -0
  98. package/cjs/src/utils/transport/iframe-transport.js +108 -0
  99. package/cjs/src/utils/transport/iframe-transport.js.map +1 -0
  100. package/cjs/src/utils/transport/iframe-transport.spec.d.ts +2 -0
  101. package/cjs/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
  102. package/cjs/src/utils/transport/iframe-transport.spec.js +140 -0
  103. package/cjs/src/utils/transport/iframe-transport.spec.js.map +1 -0
  104. package/cjs/src/utils.d.ts +18 -0
  105. package/cjs/src/utils.d.ts.map +1 -1
  106. package/cjs/src/utils.js +39 -1
  107. package/cjs/src/utils.js.map +1 -1
  108. package/cjs/src/utils.spec.js +62 -0
  109. package/cjs/src/utils.spec.js.map +1 -1
  110. package/dist/{index-D8_Zs-Nr.js → index-C1pmYb5H.js} +1 -1
  111. package/dist/src/api-intercept.d.ts.map +1 -1
  112. package/dist/src/contracts/contracts.spec.d.ts +2 -0
  113. package/dist/src/contracts/contracts.spec.d.ts.map +1 -0
  114. package/dist/src/contracts/embed-event-payloads.d.ts +73 -0
  115. package/dist/src/contracts/embed-event-payloads.d.ts.map +1 -0
  116. package/dist/src/contracts/host-event-contracts.d.ts +378 -0
  117. package/dist/src/contracts/host-event-contracts.d.ts.map +1 -0
  118. package/dist/src/contracts/index.d.ts +22 -0
  119. package/dist/src/contracts/index.d.ts.map +1 -0
  120. package/dist/src/contracts/ui-passthrough-contracts.d.ts +277 -0
  121. package/dist/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
  122. package/dist/src/css-variables.d.ts +1 -1
  123. package/dist/src/embed/app.d.ts +17 -140
  124. package/dist/src/embed/app.d.ts.map +1 -1
  125. package/dist/src/embed/conversation.d.ts +5 -5
  126. package/dist/src/embed/hostEventClient/host-event-client.d.ts +3 -2
  127. package/dist/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
  128. package/dist/src/embed/hostEventClient/utils.d.ts +1 -1
  129. package/dist/src/embed/hostEventClient/utils.d.ts.map +1 -1
  130. package/dist/src/embed/liveboard.d.ts +9 -161
  131. package/dist/src/embed/liveboard.d.ts.map +1 -1
  132. package/dist/src/embed/search.d.ts +14 -0
  133. package/dist/src/embed/search.d.ts.map +1 -1
  134. package/dist/src/embed/ts-embed.d.ts +21 -25
  135. package/dist/src/embed/ts-embed.d.ts.map +1 -1
  136. package/dist/src/embed/ts-embed.spec.d.ts.map +1 -1
  137. package/dist/src/full-height.d.ts +137 -0
  138. package/dist/src/full-height.d.ts.map +1 -0
  139. package/dist/src/full-height.spec.d.ts +2 -0
  140. package/dist/src/full-height.spec.d.ts.map +1 -0
  141. package/dist/src/index.d.ts +4 -3
  142. package/dist/src/index.d.ts.map +1 -1
  143. package/dist/src/react/all-types-export.d.ts +1 -1
  144. package/dist/src/react/all-types-export.d.ts.map +1 -1
  145. package/dist/src/react/index.d.ts +8 -8
  146. package/dist/src/react/index.d.ts.map +1 -1
  147. package/dist/src/types.d.ts +664 -39
  148. package/dist/src/types.d.ts.map +1 -1
  149. package/dist/src/utils/processTrigger.d.ts +3 -1
  150. package/dist/src/utils/processTrigger.d.ts.map +1 -1
  151. package/dist/src/utils/transport/iframe-transport.d.ts +55 -0
  152. package/dist/src/utils/transport/iframe-transport.d.ts.map +1 -0
  153. package/dist/src/utils/transport/iframe-transport.spec.d.ts +2 -0
  154. package/dist/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
  155. package/dist/src/utils.d.ts +18 -0
  156. package/dist/src/utils.d.ts.map +1 -1
  157. package/dist/tsembed-react.es.js +1031 -392
  158. package/dist/tsembed-react.js +1030 -391
  159. package/dist/tsembed.es.js +1031 -392
  160. package/dist/tsembed.js +1029 -390
  161. package/dist/visual-embed-sdk-react-full.d.ts +1483 -693
  162. package/dist/visual-embed-sdk-react.d.ts +1364 -647
  163. package/dist/visual-embed-sdk.d.ts +1426 -659
  164. package/lib/package.json +9 -1
  165. package/lib/src/api-intercept.d.ts.map +1 -1
  166. package/lib/src/api-intercept.js +2 -1
  167. package/lib/src/api-intercept.js.map +1 -1
  168. package/lib/src/contracts/contracts.spec.d.ts +2 -0
  169. package/lib/src/contracts/contracts.spec.d.ts.map +1 -0
  170. package/lib/src/contracts/contracts.spec.js +342 -0
  171. package/lib/src/contracts/contracts.spec.js.map +1 -0
  172. package/lib/src/contracts/embed-event-payloads.d.ts +73 -0
  173. package/lib/src/contracts/embed-event-payloads.d.ts.map +1 -0
  174. package/lib/src/contracts/embed-event-payloads.js +2 -0
  175. package/lib/src/contracts/embed-event-payloads.js.map +1 -0
  176. package/lib/src/contracts/host-event-contracts.d.ts +378 -0
  177. package/lib/src/contracts/host-event-contracts.d.ts.map +1 -0
  178. package/lib/src/contracts/host-event-contracts.js +2 -0
  179. package/lib/src/contracts/host-event-contracts.js.map +1 -0
  180. package/lib/src/contracts/index.d.ts +22 -0
  181. package/lib/src/contracts/index.d.ts.map +1 -0
  182. package/lib/src/contracts/index.js +22 -0
  183. package/lib/src/contracts/index.js.map +1 -0
  184. package/lib/src/contracts/ui-passthrough-contracts.d.ts +277 -0
  185. package/lib/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
  186. package/lib/src/{embed/hostEventClient/contracts.js → contracts/ui-passthrough-contracts.js} +6 -2
  187. package/lib/src/contracts/ui-passthrough-contracts.js.map +1 -0
  188. package/lib/src/css-variables.d.ts +1 -1
  189. package/lib/src/embed/app.d.ts +17 -140
  190. package/lib/src/embed/app.d.ts.map +1 -1
  191. package/lib/src/embed/app.js +22 -122
  192. package/lib/src/embed/app.js.map +1 -1
  193. package/lib/src/embed/app.spec.js +70 -26
  194. package/lib/src/embed/app.spec.js.map +1 -1
  195. package/lib/src/embed/conversation.d.ts +5 -5
  196. package/lib/src/embed/events.spec.js +12 -2
  197. package/lib/src/embed/events.spec.js.map +1 -1
  198. package/lib/src/embed/hostEventClient/host-event-client.d.ts +3 -2
  199. package/lib/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
  200. package/lib/src/embed/hostEventClient/host-event-client.js +6 -1
  201. package/lib/src/embed/hostEventClient/host-event-client.js.map +1 -1
  202. package/lib/src/embed/hostEventClient/host-event-client.spec.js +1 -1
  203. package/lib/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
  204. package/lib/src/embed/hostEventClient/utils.d.ts +1 -1
  205. package/lib/src/embed/hostEventClient/utils.d.ts.map +1 -1
  206. package/lib/src/embed/hostEventClient/utils.js +1 -1
  207. package/lib/src/embed/hostEventClient/utils.js.map +1 -1
  208. package/lib/src/embed/liveboard.d.ts +9 -161
  209. package/lib/src/embed/liveboard.d.ts.map +1 -1
  210. package/lib/src/embed/liveboard.js +70 -137
  211. package/lib/src/embed/liveboard.js.map +1 -1
  212. package/lib/src/embed/liveboard.spec.js +215 -32
  213. package/lib/src/embed/liveboard.spec.js.map +1 -1
  214. package/lib/src/embed/search.d.ts +14 -0
  215. package/lib/src/embed/search.d.ts.map +1 -1
  216. package/lib/src/embed/search.js +4 -1
  217. package/lib/src/embed/search.js.map +1 -1
  218. package/lib/src/embed/search.spec.js +65 -0
  219. package/lib/src/embed/search.spec.js.map +1 -1
  220. package/lib/src/embed/ts-embed.d.ts +21 -25
  221. package/lib/src/embed/ts-embed.d.ts.map +1 -1
  222. package/lib/src/embed/ts-embed.js +106 -73
  223. package/lib/src/embed/ts-embed.js.map +1 -1
  224. package/lib/src/embed/ts-embed.spec.d.ts.map +1 -1
  225. package/lib/src/embed/ts-embed.spec.js +378 -31
  226. package/lib/src/embed/ts-embed.spec.js.map +1 -1
  227. package/lib/src/full-height.d.ts +137 -0
  228. package/lib/src/full-height.d.ts.map +1 -0
  229. package/lib/src/full-height.js +268 -0
  230. package/lib/src/full-height.js.map +1 -0
  231. package/lib/src/full-height.spec.d.ts +2 -0
  232. package/lib/src/full-height.spec.d.ts.map +1 -0
  233. package/lib/src/full-height.spec.js +833 -0
  234. package/lib/src/full-height.spec.js.map +1 -0
  235. package/lib/src/index.d.ts +4 -3
  236. package/lib/src/index.d.ts.map +1 -1
  237. package/lib/src/index.js +3 -3
  238. package/lib/src/index.js.map +1 -1
  239. package/lib/src/react/all-types-export.d.ts +1 -1
  240. package/lib/src/react/all-types-export.d.ts.map +1 -1
  241. package/lib/src/react/all-types-export.js +1 -1
  242. package/lib/src/react/all-types-export.js.map +1 -1
  243. package/lib/src/react/all-types-export.parity.spec.js +55 -3
  244. package/lib/src/react/all-types-export.parity.spec.js.map +1 -1
  245. package/lib/src/react/index.d.ts +8 -8
  246. package/lib/src/react/index.d.ts.map +1 -1
  247. package/lib/src/react/index.js +1 -1
  248. package/lib/src/react/index.js.map +1 -1
  249. package/lib/src/react/index.spec.js +7 -7
  250. package/lib/src/react/index.spec.js.map +1 -1
  251. package/lib/src/types.d.ts +664 -39
  252. package/lib/src/types.d.ts.map +1 -1
  253. package/lib/src/types.js +405 -12
  254. package/lib/src/types.js.map +1 -1
  255. package/lib/src/utils/processTrigger.d.ts +3 -1
  256. package/lib/src/utils/processTrigger.d.ts.map +1 -1
  257. package/lib/src/utils/processTrigger.js +19 -51
  258. package/lib/src/utils/processTrigger.js.map +1 -1
  259. package/lib/src/utils/transport/iframe-transport.d.ts +55 -0
  260. package/lib/src/utils/transport/iframe-transport.d.ts.map +1 -0
  261. package/lib/src/utils/transport/iframe-transport.js +101 -0
  262. package/lib/src/utils/transport/iframe-transport.js.map +1 -0
  263. package/lib/src/utils/transport/iframe-transport.spec.d.ts +2 -0
  264. package/lib/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
  265. package/lib/src/utils/transport/iframe-transport.spec.js +138 -0
  266. package/lib/src/utils/transport/iframe-transport.spec.js.map +1 -0
  267. package/lib/src/utils.d.ts +18 -0
  268. package/lib/src/utils.d.ts.map +1 -1
  269. package/lib/src/utils.js +37 -0
  270. package/lib/src/utils.js.map +1 -1
  271. package/lib/src/utils.spec.js +63 -1
  272. package/lib/src/utils.spec.js.map +1 -1
  273. package/lib/src/visual-embed-sdk.d.ts +1426 -659
  274. package/package.json +9 -1
  275. package/src/api-intercept.ts +2 -1
  276. package/src/contracts/contracts.spec.ts +392 -0
  277. package/src/contracts/embed-event-payloads.ts +83 -0
  278. package/src/contracts/host-event-contracts.ts +456 -0
  279. package/src/contracts/index.ts +53 -0
  280. package/src/contracts/ui-passthrough-contracts.ts +301 -0
  281. package/src/css-variables.ts +1 -1
  282. package/src/embed/app.spec.ts +86 -34
  283. package/src/embed/app.ts +37 -264
  284. package/src/embed/conversation.ts +5 -5
  285. package/src/embed/events.spec.ts +14 -2
  286. package/src/embed/hostEventClient/host-event-client.spec.ts +2 -2
  287. package/src/embed/hostEventClient/host-event-client.ts +18 -5
  288. package/src/embed/hostEventClient/utils.ts +2 -1
  289. package/src/embed/liveboard.spec.ts +261 -42
  290. package/src/embed/liveboard.ts +78 -297
  291. package/src/embed/search.spec.ts +80 -0
  292. package/src/embed/search.ts +20 -0
  293. package/src/embed/ts-embed.spec.ts +518 -31
  294. package/src/embed/ts-embed.ts +133 -82
  295. package/src/full-height.spec.ts +1008 -0
  296. package/src/full-height.ts +361 -0
  297. package/src/index.ts +95 -5
  298. package/src/react/all-types-export.parity.spec.ts +63 -3
  299. package/src/react/all-types-export.ts +46 -0
  300. package/src/react/index.spec.tsx +7 -7
  301. package/src/react/index.tsx +9 -9
  302. package/src/types.ts +665 -37
  303. package/src/utils/processTrigger.ts +28 -58
  304. package/src/utils/transport/iframe-transport.spec.ts +177 -0
  305. package/src/utils/transport/iframe-transport.ts +122 -0
  306. package/src/utils.spec.ts +71 -0
  307. package/src/utils.ts +38 -0
  308. package/cjs/src/embed/hostEventClient/contracts.d.ts +0 -231
  309. package/cjs/src/embed/hostEventClient/contracts.d.ts.map +0 -1
  310. package/cjs/src/embed/hostEventClient/contracts.js.map +0 -1
  311. package/dist/src/embed/hostEventClient/contracts.d.ts +0 -231
  312. package/dist/src/embed/hostEventClient/contracts.d.ts.map +0 -1
  313. package/lib/src/embed/hostEventClient/contracts.d.ts +0 -231
  314. package/lib/src/embed/hostEventClient/contracts.d.ts.map +0 -1
  315. package/lib/src/embed/hostEventClient/contracts.js.map +0 -1
  316. package/src/embed/hostEventClient/contracts.ts +0 -262
@@ -445,7 +445,7 @@ export interface CustomCssVariables {
445
445
  * Left and right margin of the header and the tab/filter section of an
446
446
  * embedded Liveboard. Use alongside the `liveboardGutter` view config to
447
447
  * keep the header aligned with a custom tile-grid gutter.
448
- * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
448
+ * @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
449
449
  */
450
450
  "--ts-var-liveboard-header-horizontal-margin"?: string;
451
451
  /**
@@ -1250,6 +1250,280 @@ declare class AnswerService {
1250
1250
  addDisplayedVizToLiveboard(liveboardId: string): Promise<any>;
1251
1251
  setTMLOverride(override: any): void;
1252
1252
  }
1253
+ export interface LiveboardTab {
1254
+ id: string;
1255
+ name: string;
1256
+ [key: string]: any;
1257
+ }
1258
+ export interface LiveboardGroup {
1259
+ id: string;
1260
+ name: string;
1261
+ [key: string]: any;
1262
+ }
1263
+ /**
1264
+ * Levels at which a filter or parameter can be applied.
1265
+ */
1266
+ export declare enum ApplicabilityLevel {
1267
+ Liveboard = "LIVEBOARD",
1268
+ Tab = "TAB",
1269
+ Group = "GROUP"
1270
+ }
1271
+ /**
1272
+ * Scopes a filter or parameter to a specific target.
1273
+ * At `LIVEBOARD` level the filter applies to the whole Liveboard, so `targetId`
1274
+ * is not required. `level` accepts the enum or its string value, e.g. `'TAB'`.
1275
+ */
1276
+ export interface Applicability {
1277
+ level: ApplicabilityLevel | `${ApplicabilityLevel}`;
1278
+ targetId?: string;
1279
+ }
1280
+ export interface FilterUpdate {
1281
+ column: string;
1282
+ oper: string;
1283
+ values: string[];
1284
+ type?: string;
1285
+ applicability?: Applicability;
1286
+ }
1287
+ export interface LiveboardFilter {
1288
+ applicability?: Applicability;
1289
+ [key: string]: any;
1290
+ }
1291
+ export interface LiveboardParameter {
1292
+ applicability?: Applicability;
1293
+ [key: string]: any;
1294
+ }
1295
+ export declare enum UIPassthroughEvent {
1296
+ PinAnswerToLiveboard = "addVizToPinboard",
1297
+ SaveAnswer = "saveAnswer",
1298
+ GetDiscoverabilityStatus = "getDiscoverabilityStatus",
1299
+ GetAvailableUIPassthroughs = "getAvailableUiPassthroughs",
1300
+ GetAnswerConfig = "getAnswerPageConfig",
1301
+ GetLiveboardConfig = "getPinboardPageConfig",
1302
+ GetUnsavedAnswerTML = "getUnsavedAnswerTML",
1303
+ UpdateFilters = "updateFilters",
1304
+ Drilldown = "drillDown",
1305
+ GetAnswerSession = "getAnswerSession",
1306
+ GetFilters = "getFilters",
1307
+ GetIframeUrl = "getIframeUrl",
1308
+ GetParameters = "getParameters",
1309
+ GetTML = "getTML",
1310
+ GetTabs = "getTabs",
1311
+ GetGroups = "getGroups",
1312
+ GetExportRequestForCurrentPinboard = "getExportRequestForCurrentPinboard"
1313
+ }
1314
+ /**
1315
+ * UI passthrough contract. Each event's request/response is a named interface so it
1316
+ * documents and imports cleanly; `UIPassthroughContractBase` maps events to the pairs.
1317
+ */
1318
+ /** Request for {@link UIPassthroughEvent.PinAnswerToLiveboard}. */
1319
+ export interface PinAnswerToLiveboardRequest {
1320
+ vizId?: string;
1321
+ newVizName: string;
1322
+ newVizDescription?: string;
1323
+ liveboardId?: string;
1324
+ tabId?: string;
1325
+ newLiveboardName?: string;
1326
+ newTabName?: string;
1327
+ }
1328
+ /** Response for {@link UIPassthroughEvent.PinAnswerToLiveboard}. */
1329
+ export interface PinAnswerToLiveboardResponse {
1330
+ liveboardId: string;
1331
+ tabId: string;
1332
+ vizId: string;
1333
+ }
1334
+ /** Request for {@link UIPassthroughEvent.SaveAnswer}. */
1335
+ export interface SaveAnswerRequest {
1336
+ name: string;
1337
+ description: string;
1338
+ vizId?: string;
1339
+ isDiscoverable?: boolean;
1340
+ }
1341
+ /** Response for {@link UIPassthroughEvent.SaveAnswer}. */
1342
+ export interface SaveAnswerResponse {
1343
+ answerId: string;
1344
+ saveResponse?: any;
1345
+ shareResponse?: any;
1346
+ }
1347
+ /** Response for {@link UIPassthroughEvent.GetDiscoverabilityStatus}. */
1348
+ export interface GetDiscoverabilityStatusResponse {
1349
+ shouldShowDiscoverability: boolean;
1350
+ isDiscoverabilityCheckboxUnselectedPerOrg: boolean;
1351
+ }
1352
+ /** Response for {@link UIPassthroughEvent.GetAvailableUIPassthroughs}. */
1353
+ export interface GetAvailableUIPassthroughsResponse {
1354
+ keys: string[];
1355
+ }
1356
+ /** Request for {@link UIPassthroughEvent.GetAnswerConfig}. */
1357
+ export interface GetAnswerConfigRequest {
1358
+ vizId?: string;
1359
+ }
1360
+ /** Request for {@link UIPassthroughEvent.GetUnsavedAnswerTML}. */
1361
+ export interface GetUnsavedAnswerTMLRequest {
1362
+ sessionId?: string;
1363
+ vizId?: string;
1364
+ }
1365
+ /** Response for {@link UIPassthroughEvent.GetUnsavedAnswerTML}. */
1366
+ export interface GetUnsavedAnswerTMLResponse {
1367
+ tml: string;
1368
+ }
1369
+ /** Request for {@link UIPassthroughEvent.GetAnswerSession}. */
1370
+ export interface GetAnswerSessionRequest {
1371
+ vizId?: string;
1372
+ }
1373
+ /** Response for {@link UIPassthroughEvent.GetAnswerSession}. */
1374
+ export interface GetAnswerSessionResponse {
1375
+ session: SessionInterface;
1376
+ embedAnswerData?: Record<string, any>;
1377
+ }
1378
+ /** Request for {@link UIPassthroughEvent.GetFilters}. */
1379
+ export interface GetFiltersRequest {
1380
+ vizId?: string;
1381
+ }
1382
+ /** Response for {@link UIPassthroughEvent.GetFilters}. */
1383
+ export interface GetFiltersResponse {
1384
+ liveboardFilters: LiveboardFilter[];
1385
+ runtimeFilters: RuntimeFilter[];
1386
+ }
1387
+ /** Response for {@link UIPassthroughEvent.GetIframeUrl}. */
1388
+ export interface GetIframeUrlResponse {
1389
+ iframeUrl: string;
1390
+ }
1391
+ /** Response for {@link UIPassthroughEvent.GetParameters}. */
1392
+ export interface GetParametersResponse {
1393
+ parameters: LiveboardParameter[];
1394
+ }
1395
+ /** Request for {@link UIPassthroughEvent.GetTML}. */
1396
+ export interface GetTMLRequest {
1397
+ vizId?: string;
1398
+ includeNonExecutedSearchTokens?: boolean;
1399
+ }
1400
+ /** Response for {@link UIPassthroughEvent.GetTabs}. */
1401
+ export interface GetTabsResponse {
1402
+ orderedTabIds: string[];
1403
+ numberOfTabs: number;
1404
+ Tabs: LiveboardTab[];
1405
+ }
1406
+ /** Response for {@link UIPassthroughEvent.GetGroups}. */
1407
+ export interface GetGroupsResponse {
1408
+ orderedGroupIds: string[];
1409
+ numberOfGroups: number;
1410
+ Groups: LiveboardGroup[];
1411
+ }
1412
+ /** Response for {@link UIPassthroughEvent.GetExportRequestForCurrentPinboard}. */
1413
+ export interface GetExportRequestForCurrentPinboardResponse {
1414
+ data: {
1415
+ v2Content: string;
1416
+ };
1417
+ type: UIPassthroughEvent.GetExportRequestForCurrentPinboard;
1418
+ }
1419
+ /**
1420
+ * Request for {@link UIPassthroughEvent.UpdateFilters}. Not the host-event
1421
+ * `UpdateFiltersRequest` (host-event-contracts.ts), which has a different shape.
1422
+ */
1423
+ export interface UpdateFiltersPassthroughRequest {
1424
+ filter?: FilterUpdate;
1425
+ filters?: FilterUpdate[];
1426
+ }
1427
+ /** Request for {@link UIPassthroughEvent.Drilldown}. */
1428
+ export interface DrilldownRequest {
1429
+ points: {
1430
+ selectedPoints?: string[];
1431
+ clickedPoint?: string;
1432
+ };
1433
+ columnGuid?: string;
1434
+ autoDrillDown?: boolean;
1435
+ vizId?: string;
1436
+ }
1437
+ /** Maps each UI passthrough event to its request/response pair. */
1438
+ export type UIPassthroughContractBase = {
1439
+ [UIPassthroughEvent.PinAnswerToLiveboard]: {
1440
+ request: PinAnswerToLiveboardRequest;
1441
+ response: PinAnswerToLiveboardResponse;
1442
+ };
1443
+ [UIPassthroughEvent.SaveAnswer]: {
1444
+ request: SaveAnswerRequest;
1445
+ response: SaveAnswerResponse;
1446
+ };
1447
+ [UIPassthroughEvent.GetDiscoverabilityStatus]: {
1448
+ request: any;
1449
+ response: GetDiscoverabilityStatusResponse;
1450
+ };
1451
+ [UIPassthroughEvent.GetAvailableUIPassthroughs]: {
1452
+ request: any;
1453
+ response: GetAvailableUIPassthroughsResponse;
1454
+ };
1455
+ [UIPassthroughEvent.GetAnswerConfig]: {
1456
+ request: GetAnswerConfigRequest;
1457
+ response: any;
1458
+ };
1459
+ [UIPassthroughEvent.GetLiveboardConfig]: {
1460
+ request: any;
1461
+ response: any;
1462
+ };
1463
+ [UIPassthroughEvent.GetUnsavedAnswerTML]: {
1464
+ request: GetUnsavedAnswerTMLRequest;
1465
+ response: GetUnsavedAnswerTMLResponse;
1466
+ };
1467
+ [UIPassthroughEvent.GetAnswerSession]: {
1468
+ request: GetAnswerSessionRequest;
1469
+ response: GetAnswerSessionResponse;
1470
+ };
1471
+ [UIPassthroughEvent.GetFilters]: {
1472
+ request: GetFiltersRequest;
1473
+ response: GetFiltersResponse;
1474
+ };
1475
+ [UIPassthroughEvent.GetIframeUrl]: {
1476
+ request: Record<string, never>;
1477
+ response: GetIframeUrlResponse;
1478
+ };
1479
+ [UIPassthroughEvent.GetParameters]: {
1480
+ request: Record<string, never>;
1481
+ response: GetParametersResponse;
1482
+ };
1483
+ [UIPassthroughEvent.GetTML]: {
1484
+ request: GetTMLRequest;
1485
+ response: Record<string, any>;
1486
+ };
1487
+ [UIPassthroughEvent.GetTabs]: {
1488
+ request: Record<string, never>;
1489
+ response: GetTabsResponse;
1490
+ };
1491
+ [UIPassthroughEvent.GetGroups]: {
1492
+ request: Record<string, never>;
1493
+ response: GetGroupsResponse;
1494
+ };
1495
+ [UIPassthroughEvent.GetExportRequestForCurrentPinboard]: {
1496
+ request: Record<string, never>;
1497
+ response: GetExportRequestForCurrentPinboardResponse;
1498
+ };
1499
+ [UIPassthroughEvent.UpdateFilters]: {
1500
+ request: UpdateFiltersPassthroughRequest;
1501
+ response: unknown;
1502
+ };
1503
+ [UIPassthroughEvent.Drilldown]: {
1504
+ request: DrilldownRequest;
1505
+ response: unknown;
1506
+ };
1507
+ };
1508
+ export type UIPassthroughRequest<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["request"];
1509
+ export type UIPassthroughResponse<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["response"];
1510
+ export type UIPassthroughArrayResponse<ApiName extends keyof UIPassthroughContractBase> = Array<{
1511
+ refId?: string;
1512
+ value?: UIPassthroughResponse<ApiName>;
1513
+ error?: any;
1514
+ }>;
1515
+ export type EmbedApiHostEventMapping = {
1516
+ [HostEvent.Pin]: UIPassthroughEvent.PinAnswerToLiveboard;
1517
+ [HostEvent.SaveAnswer]: UIPassthroughEvent.SaveAnswer;
1518
+ [HostEvent.GetAnswerSession]: UIPassthroughEvent.GetAnswerSession;
1519
+ [HostEvent.GetFilters]: UIPassthroughEvent.GetFilters;
1520
+ [HostEvent.GetIframeUrl]: UIPassthroughEvent.GetIframeUrl;
1521
+ [HostEvent.GetParameters]: UIPassthroughEvent.GetParameters;
1522
+ [HostEvent.GetTML]: UIPassthroughEvent.GetTML;
1523
+ [HostEvent.GetTabs]: UIPassthroughEvent.GetTabs;
1524
+ [HostEvent.GetGroups]: UIPassthroughEvent.GetGroups;
1525
+ [HostEvent.getExportRequestForCurrentPinboard]: UIPassthroughEvent.GetExportRequestForCurrentPinboard;
1526
+ };
1253
1527
  /**
1254
1528
  * The authentication mechanism for allowing access to
1255
1529
  * the embedded app
@@ -2098,9 +2372,11 @@ export interface FrameParams {
2098
2372
  }
2099
2373
  /**
2100
2374
  * Configuration for the pre-render wrapper element.
2101
- * All properties here mirror the top-level preRender properties on
2102
- * {@link BaseViewConfig} and take precedence over them when both are set,
2103
- * so existing top-level usage continues to work without any changes.
2375
+ * Each property here supersedes its deprecated top-level counterpart on
2376
+ * {@link BaseViewConfig} — `id` over `preRenderId`, `containerSelector` over
2377
+ * `preRenderContainer` and `doNotTrackSize` over `doNotTrackPreRenderSize` —
2378
+ * and takes precedence when both are set, so existing top-level usage continues
2379
+ * to work without any changes.
2104
2380
  *
2105
2381
  * @version SDK: 1.52.0
2106
2382
  * @example
@@ -2108,9 +2384,9 @@ export interface FrameParams {
2108
2384
  * init({ thoughtSpotHost: '...', authType: AuthType.None });
2109
2385
  * const embed = new LiveboardEmbed('#tsEmbed', {
2110
2386
  * preRenderConfig: {
2111
- * preRenderId: 'my-liveboard',
2112
- * preRenderContainer: '#my-scroll-container',
2113
- * doNotTrackPreRenderSize: false,
2387
+ * id: 'my-liveboard',
2388
+ * containerSelector: '#my-scroll-container',
2389
+ * doNotTrackSize: false,
2114
2390
  * zIndex: -10,
2115
2391
  * },
2116
2392
  * });
@@ -2131,7 +2407,7 @@ export interface PreRenderConfig {
2131
2407
  *
2132
2408
  * @default undefined
2133
2409
  */
2134
- preRenderId?: string;
2410
+ id?: string;
2135
2411
  /**
2136
2412
  * The DOM element or CSS selector string specifying the container into
2137
2413
  * which the pre-rendered wrapper is inserted.
@@ -2147,7 +2423,7 @@ export interface PreRenderConfig {
2147
2423
  *
2148
2424
  * @default document.body
2149
2425
  */
2150
- preRenderContainer?: string | HTMLElement;
2426
+ containerSelector?: string | HTMLElement;
2151
2427
  /**
2152
2428
  * Disables the `ResizeObserver` that keeps the wrapper sized to the
2153
2429
  * placeholder element.
@@ -2159,7 +2435,7 @@ export interface PreRenderConfig {
2159
2435
  *
2160
2436
  * @default false
2161
2437
  */
2162
- doNotTrackPreRenderSize?: boolean;
2438
+ doNotTrackSize?: boolean;
2163
2439
  /**
2164
2440
  * CSS `z-index` value applied to the pre-render wrapper when hidden.
2165
2441
  * Override this when the host page's stacking context does not reach `-1000`
@@ -2366,7 +2642,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2366
2642
  *
2367
2643
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
2368
2644
  * @version SDK: 1.25.0 | ThoughtSpot: 9.6.0.cl, 9.8.0.sw
2369
- * @deprecated Use {@link PreRenderConfig.preRenderId} via `preRenderConfig` instead.
2645
+ * @deprecated Use {@link PreRenderConfig.id} via `preRenderConfig` instead.
2370
2646
  * @example
2371
2647
  * ```js
2372
2648
  * // Replace <EmbedComponent> with embed component name. For example, AppEmbed, SearchEmbed, or LiveboardEmbed
@@ -2386,7 +2662,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2386
2662
  * @type {boolean}
2387
2663
  * @default false
2388
2664
  * @version SDK: 1.24.0 | ThoughtSpot: 9.4.0.cl, 9.4.0.sw
2389
- * @deprecated Use {@link PreRenderConfig.doNotTrackPreRenderSize} via `preRenderConfig` instead.
2665
+ * @deprecated Use {@link PreRenderConfig.doNotTrackSize} via `preRenderConfig` instead.
2390
2666
  * @example
2391
2667
  * ```js
2392
2668
  * // Disable tracking PreRender size in the configuration
@@ -2428,7 +2704,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2428
2704
  *
2429
2705
  * @type {string | HTMLElement}
2430
2706
  * @version SDK: 1.49.2 | ThoughtSpot: *
2431
- * @deprecated Use {@link PreRenderConfig.preRenderContainer} via `preRenderConfig` instead.
2707
+ * @deprecated Use {@link PreRenderConfig.containerSelector} via `preRenderConfig` instead.
2432
2708
  * @example
2433
2709
  * ```js
2434
2710
  * const embed = new LiveboardEmbed('#tsEmbed', {
@@ -2441,9 +2717,11 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2441
2717
  preRenderContainer?: string | HTMLElement;
2442
2718
  /**
2443
2719
  * Configuration for the pre-render wrapper element.
2444
- * All properties here mirror the top-level preRender properties on
2445
- * `BaseViewConfig` and take precedence over them when both are set,
2446
- * so existing top-level usage continues to work without any changes.
2720
+ * Each property here supersedes its deprecated top-level counterpart on
2721
+ * `BaseViewConfig` — `id` over `preRenderId`, `containerSelector` over
2722
+ * `preRenderContainer` and `doNotTrackSize` over `doNotTrackPreRenderSize` —
2723
+ * and takes precedence when both are set, so existing top-level usage
2724
+ * continues to work without any changes.
2447
2725
  * See {@link PreRenderConfig} for available options.
2448
2726
  *
2449
2727
  * @version SDK: 1.52.0
@@ -2451,7 +2729,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2451
2729
  * ```js
2452
2730
  * const embed = new LiveboardEmbed('#tsEmbed', {
2453
2731
  * preRenderConfig: {
2454
- * preRenderId: 'my-liveboard',
2732
+ * id: 'my-liveboard',
2455
2733
  * zIndex: -10,
2456
2734
  * },
2457
2735
  * });
@@ -3203,7 +3481,7 @@ export interface LiveboardAppEmbedViewConfig {
3203
3481
  *
3204
3482
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`
3205
3483
  * @type {boolean}
3206
- * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
3484
+ * @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
3207
3485
  * @default false
3208
3486
  * @example
3209
3487
  * ```js
@@ -3328,7 +3606,7 @@ export interface LiveboardAppEmbedViewConfig {
3328
3606
  *
3329
3607
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`
3330
3608
  * @type {number}
3331
- * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
3609
+ * @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
3332
3610
  * @example
3333
3611
  * ```js
3334
3612
  * // Replace <EmbedComponent> with embed component name. For example, AppEmbed or LiveboardEmbed
@@ -3643,6 +3921,15 @@ export interface RuntimeParameter {
3643
3921
  * Values
3644
3922
  */
3645
3923
  value: number | boolean | string;
3924
+ /**
3925
+ * Whether the parameter is visible to the user (`UpdateParameters` only).
3926
+ */
3927
+ isVisibleToUser?: boolean;
3928
+ /**
3929
+ * Scope of the update (`UpdateParameters` only). Omitting it, or `level`,
3930
+ * targets the Liveboard level.
3931
+ */
3932
+ applicability?: Applicability;
3646
3933
  }
3647
3934
  /**
3648
3935
  * Event types emitted by the embedded ThoughtSpot application.
@@ -4094,6 +4381,9 @@ export declare enum EmbedEvent {
4094
4381
  Download = "download",
4095
4382
  /**
4096
4383
  * Emitted when the download action is triggered on an Answer.
4384
+ * Payload varies by context: {@link VizScopedRequest} (Search, Answer,
4385
+ * Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
4386
+ * accepts the union now; per-context enforced next release.
4097
4387
  * Use start:true to subscribe to when download is initiated, or end:true to
4098
4388
  * subscribe to when download is completed. Default is end:true.
4099
4389
  * @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.4.0.sw
@@ -4110,6 +4400,9 @@ export declare enum EmbedEvent {
4110
4400
  DownloadAsPng = "downloadAsPng",
4111
4401
  /**
4112
4402
  * Emitted when the Download as PDF action is triggered on an Answer
4403
+ * Payload varies by context: {@link VizScopedRequest} (Search, Answer; plus
4404
+ * liveboardId on Liveboard), {@link RequiredVizRequest} (Spotter). trigger()
4405
+ * accepts the union now; per-context enforced next release.
4113
4406
  * Use start:true to subscribe to when download as PDF is initiated, or end:true to
4114
4407
  * subscribe to when download as PDF is completed. Default is end:true.
4115
4408
  * @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
@@ -4126,6 +4419,9 @@ export declare enum EmbedEvent {
4126
4419
  DownloadAsPdf = "downloadAsPdf",
4127
4420
  /**
4128
4421
  * Emitted when the Download as CSV action is triggered on an Answer.
4422
+ * Payload varies by context: {@link VizScopedRequest} (Search, Answer,
4423
+ * Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
4424
+ * accepts the union now; per-context enforced next release.
4129
4425
  * Use start:true to subscribe to when download as CSV is initiated, or end:true to
4130
4426
  * subscribe to when download as CSV is completed. Default is end:true.
4131
4427
  * @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
@@ -4142,6 +4438,9 @@ export declare enum EmbedEvent {
4142
4438
  DownloadAsCsv = "downloadAsCsv",
4143
4439
  /**
4144
4440
  * Emitted when the Download as XLSX action is triggered on an Answer.
4441
+ * Payload varies by context: {@link VizScopedRequest} (Search, Answer,
4442
+ * Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
4443
+ * accepts the union now; per-context enforced next release.
4145
4444
  * Use start:true to subscribe to when download as XLSX is initiated, or end:true to
4146
4445
  * subscribe to when download as XLSX is completed. Default is end:true.
4147
4446
  * @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
@@ -4420,6 +4719,9 @@ export declare enum EmbedEvent {
4420
4719
  Schedule = "subscription",
4421
4720
  /**
4422
4721
  * Emitted when a user clicks **Edit** on a Liveboard or visualization
4722
+ * Payload varies by context: {@link VizScopedRequest} (Liveboard),
4723
+ * {@link RequiredVizRequest} (Spotter, vizId required). trigger() accepts the
4724
+ * union now; per-context enforced next release.
4423
4725
  * @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
4424
4726
  * @example
4425
4727
  * ```js
@@ -4961,7 +5263,32 @@ export declare enum EmbedEvent {
4961
5263
  */
4962
5264
  OrgSwitched = "orgSwitched",
4963
5265
  /**
4964
- * Emitted when the user intercepts a URL.
5266
+ * Emitted before the embedded ThoughtSpot app sends a network request whose
5267
+ * fully resolved URL matches one of the `interceptUrls` in the view config.
5268
+ * The request is held until you call `responder`, which decides whether the
5269
+ * real request goes out or a response you supply is used in its place.
5270
+ *
5271
+ * Setting `interceptUrls` is what enables this; there is no separate enable
5272
+ * flag. If `responder` is not called within `interceptTimeout` (30000 ms by
5273
+ * default) the request fails and `EmbedEvent.Error` is emitted.
5274
+ *
5275
+ * The payload is `{ input, init, urlType }`, where `input` is the request
5276
+ * URL and `init` is the `fetch` init object, with `init.body` parsed into an
5277
+ * object when it is valid JSON. `urlType` is the matching
5278
+ * `InterceptedApiType`; it is `InterceptedApiType.ALL` for any URL outside
5279
+ * the recognized API groups.
5280
+ *
5281
+ * Interception wraps the outermost layer of `fetch`, so `init` holds the
5282
+ * request as the application composed it, before ThoughtSpot attaches its
5283
+ * authentication headers. Those headers, and any token refresh and retry,
5284
+ * are applied afterwards and only when you pass `execute: true`. Only
5285
+ * requests made through `fetch` are intercepted.
5286
+ *
5287
+ * Pass `execute: true` to let the original request proceed untouched, in
5288
+ * which case any `response` you supply alongside it is ignored. With
5289
+ * `execute: false` the request is never sent, and your `response.body` is
5290
+ * returned to the app as JSON, defaulting to status 200 and a
5291
+ * `Content-Type: application/json` header.
4965
5292
  *
4966
5293
  * Supported on all embed types.
4967
5294
  *
@@ -5473,6 +5800,7 @@ export declare enum HostEvent {
5473
5800
  * the search query string.
5474
5801
  * Supported in `AppEmbed` and `SearchEmbed` deployments.
5475
5802
  * Includes the following properties:
5803
+ * Payload: {@link SearchRequest}.
5476
5804
  * @param - Includes the following keys:
5477
5805
  * - `searchQuery`: Query string with search tokens.
5478
5806
  * - `dataSources`: Data source GUID to search on.
@@ -5500,6 +5828,9 @@ export declare enum HostEvent {
5500
5828
  Search = "search",
5501
5829
  /**
5502
5830
  * Triggers a drill on certain points of the specified column
5831
+ * Payload: {@link DrillDownRequest}; in Liveboard context vizId is required
5832
+ * ({@link RequiredVizRequest}). trigger() accepts the union now; per-context
5833
+ * enforced next release.
5503
5834
  * Includes the following properties:
5504
5835
  * @param - Includes the following keys:
5505
5836
  * - `points`: An object containing `selectedPoints` and/or `clickedPoint`
@@ -5579,6 +5910,8 @@ export declare enum HostEvent {
5579
5910
  Reload = "reload",
5580
5911
  /**
5581
5912
  * Get iframe URL for the current embed view.
5913
+ * Payload: none.
5914
+ * Response: {@link GetIframeUrlResponse}.
5582
5915
  * @example
5583
5916
  * ```js
5584
5917
  * const url = embed.trigger(HostEvent.GetIframeUrl);
@@ -5597,6 +5930,7 @@ export declare enum HostEvent {
5597
5930
  GetIframeUrl = "GetIframeUrl",
5598
5931
  /**
5599
5932
  * Display specific visualizations on a Liveboard.
5933
+ * Payload: `string[]`.
5600
5934
  * @param - An array of GUIDs of the visualization to show. The visualization IDs not passed
5601
5935
  * in this parameter will be hidden.
5602
5936
  * @example
@@ -5619,6 +5953,7 @@ export declare enum HostEvent {
5619
5953
  SetVisibleVizs = "SetPinboardVisibleVizs",
5620
5954
  /**
5621
5955
  * Set a Liveboard tab as an active tab.
5956
+ * Payload: {@link SetActiveTabRequest}.
5622
5957
  * @param - tabId - string of id of Tab to show
5623
5958
  * @example
5624
5959
  * ```js
@@ -5646,6 +5981,7 @@ export declare enum HostEvent {
5646
5981
  * and `AppEmbed` only. In full application embedding, this event updates
5647
5982
  * the runtime filters applied on the Liveboard and saved Answer objects.
5648
5983
  *
5984
+ * Payload: {@link RuntimeFilter}[].
5649
5985
  * @param - Array of {@link RuntimeFilter} objects. Each item includes:
5650
5986
  * - `columnName`: Name of the column to filter on.
5651
5987
  * - `operator`: {@link RuntimeFilterOp} to apply. For more information, see
@@ -5687,6 +6023,7 @@ export declare enum HostEvent {
5687
6023
  * Accepts either a plain value or an object with `path`
5688
6024
  * and an optional `replace` flag.
5689
6025
  *
6026
+ * Payload: `string` | `number` | {@link NavigateRequest}.
5690
6027
  * @param data - A string path, a numeric history delta, or an object
5691
6028
  * `{ path: string | number, replace?: boolean }`.
5692
6029
  * - `path` — the route to navigate to, or a history delta such as `1`
@@ -5714,6 +6051,9 @@ export declare enum HostEvent {
5714
6051
  /**
5715
6052
  * Open the filter panel for a particular column.
5716
6053
  * Works with Search and Liveboard embed.
6054
+ * Payload: {@link OpenFilterRequest} (the cross-context superset). The
6055
+ * accepted fields vary by context: {@link OpenFilterLiveboardRequest},
6056
+ * {@link OpenFilterSpotterRequest}, {@link OpenFilterSearchRequest}.
5717
6057
  * @param - { columnId: string,
5718
6058
  * name: string,
5719
6059
  * type: ATTRIBUTE/MEASURE,
@@ -5770,7 +6110,7 @@ export declare enum HostEvent {
5770
6110
  *
5771
6111
  * Unlike {@link HostEvent.OpenFilter}, which opens the panel of an
5772
6112
  * existing filter, this event starts the creation of a new filter.
5773
- * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
6113
+ * @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
5774
6114
  * @example
5775
6115
  * ```js
5776
6116
  * liveboardEmbed.trigger(HostEvent.OpenAddFilterModal);
@@ -5786,7 +6126,7 @@ export declare enum HostEvent {
5786
6126
  * Hiding the *Add parameter* button with `hiddenActions:
5787
6127
  * [Action.AddParameter]` does not block this event, but disabling it
5788
6128
  * with `disabledActions` does.
5789
- * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
6129
+ * @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
5790
6130
  * @example
5791
6131
  * ```js
5792
6132
  * liveboardEmbed.trigger(HostEvent.OpenAddParameterModal);
@@ -5796,6 +6136,7 @@ export declare enum HostEvent {
5796
6136
  /**
5797
6137
  * Open the parameter panel for a particular parameter on a Liveboard.
5798
6138
  * Mirrors {@link HostEvent.OpenFilter} for parameters.
6139
+ * Payload: {@link OpenParameterRequest}.
5799
6140
  * @param - Includes the following keys:
5800
6141
  * - `parameter`: An object identifying the parameter to open, for
5801
6142
  * example, `{ parameterId: '<parameter-GUID>' }`.
@@ -5827,6 +6168,7 @@ export declare enum HostEvent {
5827
6168
  OpenParameter = "openParameter",
5828
6169
  /**
5829
6170
  * Add columns to the current search query.
6171
+ * Payload: `{ columnIds: string[] }`.
5830
6172
  * @param - { columnIds: string[] }
5831
6173
  * @example
5832
6174
  * ```js
@@ -5845,6 +6187,7 @@ export declare enum HostEvent {
5845
6187
  AddColumns = "addColumns",
5846
6188
  /**
5847
6189
  * Remove a column from the current search query.
6190
+ * Payload: `{ columnId: string }`.
5848
6191
  * @param - { columnId: string }
5849
6192
  * @example
5850
6193
  * ```js
@@ -5869,6 +6212,8 @@ export declare enum HostEvent {
5869
6212
  * sorting, toggling of legends, and data drill down.
5870
6213
  * For more information, see
5871
6214
  * link:https://developers.thoughtspot.com/docs/fetch-data-and-report-apis#transient-lb-content[Liveboard data with unsaved changes].
6215
+ * Payload: none.
6216
+ * Response: {@link GetExportRequestForCurrentPinboardResponse}.
5872
6217
  * @example
5873
6218
  * ```js
5874
6219
  * liveboardEmbed.trigger(HostEvent.getExportRequestForCurrentPinboard).then(
@@ -5890,6 +6235,8 @@ export declare enum HostEvent {
5890
6235
  * requiring additional user input via the *Pin to Liveboard* modal, define
5891
6236
  * the following parameters:
5892
6237
  *
6238
+ * Payload: {@link PinAnswerToLiveboardRequest}.
6239
+ * Response: {@link PinAnswerToLiveboardResponse}.
5893
6240
  * @param - Includes the following keys:
5894
6241
  * - `vizId`: GUID of the saved Answer or Spotter visualization ID to pin to a
5895
6242
  * Liveboard.
@@ -6004,6 +6351,7 @@ export declare enum HostEvent {
6004
6351
  LiveboardInfo = "pinboardInfo",
6005
6352
  /**
6006
6353
  * Trigger the **Schedule** action on an embedded Liveboard.
6354
+ * Payload: {@link VizScopedRequest}.
6007
6355
  * @example
6008
6356
  * ```js
6009
6357
  * liveboardEmbed.trigger(HostEvent.Schedule)
@@ -6019,6 +6367,7 @@ export declare enum HostEvent {
6019
6367
  Schedule = "subscription",
6020
6368
  /**
6021
6369
  * Trigger the **Manage schedule** action on an embedded Liveboard
6370
+ * Payload: {@link VizScopedRequest}.
6022
6371
  * @example
6023
6372
  * ```js
6024
6373
  * liveboardEmbed.trigger(HostEvent.SchedulesList)
@@ -6035,6 +6384,7 @@ export declare enum HostEvent {
6035
6384
  /**
6036
6385
  * Trigger the **Export TML** action on an embedded Liveboard or
6037
6386
  * Answer.
6387
+ * Payload: {@link VizScopedRequest}.
6038
6388
  * @example
6039
6389
  * ```js
6040
6390
  * liveboardEmbed.trigger(HostEvent.ExportTML)
@@ -6057,6 +6407,7 @@ export declare enum HostEvent {
6057
6407
  /**
6058
6408
  * Trigger the **Edit TML** action on an embedded Liveboard or
6059
6409
  * saved Answers in the full application embedding.
6410
+ * Payload: {@link VizScopedRequest}.
6060
6411
  * @example
6061
6412
  * ```js
6062
6413
  * liveboardEmbed.trigger(HostEvent.EditTML)
@@ -6078,6 +6429,7 @@ export declare enum HostEvent {
6078
6429
  EditTML = "editTSL",
6079
6430
  /**
6080
6431
  * Trigger the **Update TML** action on an embedded Liveboard.
6432
+ * Payload: {@link VizScopedRequest}.
6081
6433
  * @example
6082
6434
  * ```js
6083
6435
  * liveboardEmbed.trigger(HostEvent.UpdateTML)
@@ -6095,6 +6447,7 @@ export declare enum HostEvent {
6095
6447
  * Trigger the **Download PDF** action on an embedded Liveboard,
6096
6448
  * visualization or Answer.
6097
6449
  *
6450
+ * Payload: {@link VizScopedRequest} plus optional `liveboardId`.
6098
6451
  * @param - `vizId` refers to the Answer ID in Spotter embed and is required in Spotter embed.
6099
6452
  *
6100
6453
  * **NOTE**: The **Download** > **PDF** action is available on
@@ -6145,6 +6498,7 @@ export declare enum HostEvent {
6145
6498
  /**
6146
6499
  * Trigger the **AI Highlights** action on an embedded Liveboard
6147
6500
  *
6501
+ * Payload: none.
6148
6502
  * @example
6149
6503
  * ```js
6150
6504
  * liveboardEmbed.trigger(HostEvent.AIHighlights)
@@ -6199,6 +6553,9 @@ export declare enum HostEvent {
6199
6553
  MakeACopy = "makeACopy",
6200
6554
  /**
6201
6555
  * Trigger the **Delete** action for a Liveboard.
6556
+ * Payload varies by context: {@link RequiredVizRequest} (Liveboard, vizId
6557
+ * required), {@link VizScopedRequest} (Search). trigger() accepts the union
6558
+ * now; per-context enforced next release.
6202
6559
  * @example
6203
6560
  * ```js
6204
6561
  * appEmbed.trigger(HostEvent.Remove)
@@ -6213,6 +6570,7 @@ export declare enum HostEvent {
6213
6570
  Remove = "delete",
6214
6571
  /**
6215
6572
  * Trigger the **Explore** action on a visualization.
6573
+ * Payload: {@link RequiredVizRequest}.
6216
6574
  * @param - an object with `vizId` as a key
6217
6575
  * @example
6218
6576
  * ```js
@@ -6232,6 +6590,7 @@ export declare enum HostEvent {
6232
6590
  /**
6233
6591
  * Trigger the **Create alert** action on a KPI chart
6234
6592
  * in a Liveboard or saved Answer.
6593
+ * Payload: {@link VizScopedRequest}.
6235
6594
  * @param - an object with `vizId` as a key
6236
6595
  * @example
6237
6596
  * ```js
@@ -6263,6 +6622,7 @@ export declare enum HostEvent {
6263
6622
  /**
6264
6623
  * Trigger the **Manage alerts** action on a KPI chart
6265
6624
  * in a visualization or saved Answer.
6625
+ * Payload: {@link VizScopedRequest}.
6266
6626
  * @param - an object with `vizId` as a key
6267
6627
  * @example
6268
6628
  * ```js
@@ -6300,6 +6660,7 @@ export declare enum HostEvent {
6300
6660
  * on a Liveboard.
6301
6661
  *
6302
6662
  * This event is not supported in visualization embed and search embed.
6663
+ * Payload: {@link VizScopedRequest}.
6303
6664
  * @param - Object parameter. Includes the following keys:
6304
6665
  * - `vizId`: To trigger the action for a specific visualization in Liveboard embed,
6305
6666
  * pass in `vizId` as a key. In Spotter embed, `vizId` refers to the Answer ID and
@@ -6342,6 +6703,7 @@ export declare enum HostEvent {
6342
6703
  Edit = "edit",
6343
6704
  /**
6344
6705
  * Trigger the **Copy link** action on a Liveboard or visualization
6706
+ * Payload: {@link VizScopedRequest}.
6345
6707
  * @param - object - to trigger the action for a
6346
6708
  * specific visualization in Liveboard embed, pass in `vizId` as a key
6347
6709
  * @example
@@ -6387,6 +6749,7 @@ export declare enum HostEvent {
6387
6749
  CopyLink = "embedDocument",
6388
6750
  /**
6389
6751
  * Trigger the **Present** action on a Liveboard or visualization
6752
+ * Payload: {@link VizScopedRequest}.
6390
6753
  * @param - object - to trigger the action for a specific visualization
6391
6754
  * in Liveboard embed, pass in `vizId` as a key
6392
6755
  * @example
@@ -6432,6 +6795,8 @@ export declare enum HostEvent {
6432
6795
  Present = "present",
6433
6796
  /**
6434
6797
  * Get TML for the current search.
6798
+ * Payload: {@link GetTMLRequest}.
6799
+ * Response: `Record<string, any>`.
6435
6800
  * @example
6436
6801
  * ```js
6437
6802
  * searchEmbed.trigger(HostEvent.GetTML).then((tml) => {
@@ -6481,6 +6846,7 @@ export declare enum HostEvent {
6481
6846
  * Trigger the **Show underlying data** action on a
6482
6847
  * chart or table.
6483
6848
  *
6849
+ * Payload: {@link VizScopedRequest}.
6484
6850
  * @param - an object with vizId as a key
6485
6851
  * @example
6486
6852
  * ```js
@@ -6514,6 +6880,7 @@ export declare enum HostEvent {
6514
6880
  * Trigger the **Delete** action for a visualization
6515
6881
  * in an embedded Liveboard, or a chart or table
6516
6882
  * generated from Search.
6883
+ * Payload: {@link VizScopedRequest}.
6517
6884
  * @param - Liveboard embed takes an object with `vizId` as a key.
6518
6885
  * Can be left empty if embedding Search or visualization.
6519
6886
  * @example
@@ -6542,6 +6909,7 @@ export declare enum HostEvent {
6542
6909
  /**
6543
6910
  * Trigger the **SpotIQ analyze** action on a
6544
6911
  * chart or table.
6912
+ * Payload: {@link VizScopedRequest}.
6545
6913
  * @param - Liveboard embed takes `vizId` as a
6546
6914
  * key. Can be left undefined when embedding Search or
6547
6915
  * visualization.
@@ -6604,6 +6972,7 @@ export declare enum HostEvent {
6604
6972
  /**
6605
6973
  * Trigger the **Download** > **PNG** action on
6606
6974
  * charts in the embedded view.
6975
+ * Payload: {@link VizScopedRequest}.
6607
6976
  * @example
6608
6977
  * ```js
6609
6978
  * liveboardEmbed.trigger(HostEvent.DownloadAsPng,
@@ -6634,6 +7003,7 @@ export declare enum HostEvent {
6634
7003
  /**
6635
7004
  * Trigger the **Download** > **CSV** action on tables in
6636
7005
  * the embedded view.
7006
+ * Payload: {@link VizScopedRequest}.
6637
7007
  * @param - `vizId` refers to the Visualization ID in Spotter embed and is required in Spotter embed.
6638
7008
  * @example
6639
7009
  * ```js
@@ -6673,6 +7043,7 @@ export declare enum HostEvent {
6673
7043
  /**
6674
7044
  * Trigger the **Download** > **XLSX** action on tables
6675
7045
  * in the embedded view.
7046
+ * Payload: {@link VizScopedRequest}.
6676
7047
  * @param - `vizId` refers to the Visualization ID in Spotter embed and is required in Spotter embed.
6677
7048
  * @example
6678
7049
  * ```js
@@ -6712,6 +7083,7 @@ export declare enum HostEvent {
6712
7083
  /**
6713
7084
  * Trigger the **Share** action on an embedded
6714
7085
  * Liveboard or Answer.
7086
+ * Payload: {@link VizScopedRequest}.
6715
7087
  * @example
6716
7088
  * ```js
6717
7089
  * liveboardEmbed.trigger(HostEvent.Share)
@@ -6738,6 +7110,7 @@ export declare enum HostEvent {
6738
7110
  * Trigger the **Save** action on a Liveboard, Answer, or Spotter.
6739
7111
  * Saves the changes.
6740
7112
  *
7113
+ * Payload: {@link VizScopedRequest}.
6741
7114
  * @param - `vizId` refers to the Spotter Visualization Id used in Spotter embed.
6742
7115
  * It is required and can be retrieved from the data embed event.
6743
7116
  *
@@ -6789,6 +7162,7 @@ export declare enum HostEvent {
6789
7162
  /**
6790
7163
  * Trigger the **Sync to Sheets** action on an embedded visualization or Answer
6791
7164
  * Sends data from an Answer or Liveboard visualization to a Google sheet.
7165
+ * Payload: {@link VizScopedRequest}.
6792
7166
  * @param - an object with `vizId` as a key
6793
7167
  * @example
6794
7168
  * ```js
@@ -6819,6 +7193,7 @@ export declare enum HostEvent {
6819
7193
  * Trigger the **Sync to Other Apps** action on an embedded visualization or Answer
6820
7194
  * Sends data from an Answer or Liveboard visualization to third-party apps such
6821
7195
  * as Slack, Salesforce, Microsoft Teams, ServiceNow and so on.
7196
+ * Payload: {@link VizScopedRequest}.
6822
7197
  * @param - an object with vizId as a key
6823
7198
  * @example
6824
7199
  * ```js
@@ -6849,6 +7224,7 @@ export declare enum HostEvent {
6849
7224
  * Trigger the **Manage pipelines** action on an embedded
6850
7225
  * visualization or Answer.
6851
7226
  * Allows users to manage ThoughtSpot Sync pipelines.
7227
+ * Payload: {@link VizScopedRequest}.
6852
7228
  * @param - an object with `vizId` as a key
6853
7229
  * @example
6854
7230
  * ```js
@@ -6877,6 +7253,7 @@ export declare enum HostEvent {
6877
7253
  ManagePipelines = "manage-pipeline",
6878
7254
  /**
6879
7255
  * Reset search operation on the Search or Answer page.
7256
+ * Payload: none.
6880
7257
  * @example
6881
7258
  * ```js
6882
7259
  * searchEmbed.trigger(HostEvent.ResetSearch)
@@ -6904,6 +7281,8 @@ export declare enum HostEvent {
6904
7281
  * whole Liveboard.
6905
7282
  * The `applicability` attribute is available from SDK: 1.53.0 |
6906
7283
  * ThoughtSpot: 26.10.0.cl.
7284
+ * Payload: {@link GetFiltersRequest}.
7285
+ * Response: {@link GetFiltersResponse}.
6907
7286
  * @example
6908
7287
  * ```js
6909
7288
  * const data = await liveboardEmbed.trigger(HostEvent.GetFilters);
@@ -6923,6 +7302,7 @@ export declare enum HostEvent {
6923
7302
  GetFilters = "getFilters",
6924
7303
  /**
6925
7304
  * Update one or several filters applied on a Liveboard.
7305
+ * Payload: {@link UpdateFiltersRequest}.
6926
7306
  * @param - Includes the following keys:
6927
7307
  * - `filter`: A single filter object containing column name, filter operator, and
6928
7308
  * values.
@@ -7051,6 +7431,8 @@ export declare enum HostEvent {
7051
7431
  UpdateFilters = "updateFilters",
7052
7432
  /**
7053
7433
  * Get tab details for the current Liveboard.
7434
+ * Payload: none.
7435
+ * Response: {@link GetTabsResponse}.
7054
7436
  * @example
7055
7437
  * ```js
7056
7438
  * liveboardEmbed.trigger(HostEvent.GetTabs).then((tabDetails) => {
@@ -7076,6 +7458,8 @@ export declare enum HostEvent {
7076
7458
  /**
7077
7459
  * Get group details for the current Liveboard.
7078
7460
  * Mirrors {@link HostEvent.GetTabs} for filter/parameter groups.
7461
+ * Payload: none.
7462
+ * Response: {@link GetGroupsResponse}.
7079
7463
  * @example
7080
7464
  * ```js
7081
7465
  * liveboardEmbed.trigger(HostEvent.GetGroups).then((groupDetails) => {
@@ -7100,6 +7484,7 @@ export declare enum HostEvent {
7100
7484
  GetGroups = "getGroups",
7101
7485
  /**
7102
7486
  * Set the visible tabs on a Liveboard.
7487
+ * Payload: `string[]`.
7103
7488
  * @param - an array of ids of tabs to show, the IDs not passed
7104
7489
  * will be hidden.
7105
7490
  * @example
@@ -7122,6 +7507,7 @@ export declare enum HostEvent {
7122
7507
  SetVisibleTabs = "SetPinboardVisibleTabs",
7123
7508
  /**
7124
7509
  * Set the hidden tabs on a Liveboard.
7510
+ * Payload: `string[]`.
7125
7511
  * @param - an array of the IDs of the tabs to hide.
7126
7512
  * The IDs not passed will be shown.
7127
7513
  * @example
@@ -7150,6 +7536,8 @@ export declare enum HostEvent {
7150
7536
  * `getAnswerService()` method on the embed instance to get an AnswerService
7151
7537
  * object that provides a more convenient interface for working with answers.
7152
7538
  *
7539
+ * Payload: {@link GetAnswerSessionRequest}.
7540
+ * Response: {@link GetAnswerSessionResponse}.
7153
7541
  * @example
7154
7542
  * ```js
7155
7543
  * // Preferred way to get an AnswerService
@@ -7177,6 +7565,7 @@ export declare enum HostEvent {
7177
7565
  GetAnswerSession = "getAnswerSession",
7178
7566
  /**
7179
7567
  * Trigger the *Ask Sage* action for visualizations
7568
+ * Payload: {@link RequiredVizRequest}.
7180
7569
  * @example
7181
7570
  * ```js
7182
7571
  * liveboardEmbed.trigger(HostEvent.AskSage,
@@ -7188,6 +7577,7 @@ export declare enum HostEvent {
7188
7577
  /**
7189
7578
  * Trigger cross filter update action on a Liveboard.
7190
7579
  *
7580
+ * Payload: {@link UpdateCrossFilterRequest}.
7191
7581
  * @example
7192
7582
  * ```js
7193
7583
  * liveboardEmbed.trigger(HostEvent.UpdateCrossFilter, {
@@ -7203,7 +7593,9 @@ export declare enum HostEvent {
7203
7593
  UpdateCrossFilter = "UpdateCrossFilter",
7204
7594
  /**
7205
7595
  * Trigger reset action for a personalized Liveboard view.
7206
- * This event is deprecated. Use {@link HostEvent.ResetLiveboardPersonalizedView} instead.
7596
+ * This event is deprecated.
7597
+ * Use {@link HostEvent.ResetLiveboardPersonalizedView} instead.
7598
+ * Payload: none.
7207
7599
  * @example
7208
7600
  * ```js
7209
7601
  * liveboardEmbed.trigger(HostEvent.ResetLiveboardPersonalisedView);
@@ -7224,6 +7616,7 @@ export declare enum HostEvent {
7224
7616
  /**
7225
7617
  * Triggers an action to update Parameter values on embedded
7226
7618
  * Answers, Liveboard, and Spotter answer in Edit mode.
7619
+ * Payload: {@link RuntimeParameter}[].
7227
7620
  * @param - Includes the following keys for each item:
7228
7621
  * - `name`: Name of the parameter.
7229
7622
  * - `value`: The value to set for the parameter.
@@ -7281,6 +7674,8 @@ export declare enum HostEvent {
7281
7674
  * whole Liveboard.
7282
7675
  * The `applicability` attribute is available from SDK: 1.53.0 |
7283
7676
  * ThoughtSpot: 26.10.0.cl.
7677
+ * Payload: none.
7678
+ * Response: {@link GetParametersResponse}.
7284
7679
  * @param - `vizId` refers to the Answer ID in Spotter embed and is required in Spotter embed.
7285
7680
  * ```js
7286
7681
  * liveboardEmbed.trigger(HostEvent.GetParameters).then((parameter) => {
@@ -7318,6 +7713,7 @@ export declare enum HostEvent {
7318
7713
  * ```js
7319
7714
  * liveboardEmbed.trigger(HostEvent.UpdatePersonalisedView, {viewId: '1234'})
7320
7715
  * ```
7716
+ * Payload: {@link PersonalisedViewRequest} (`viewId` only).
7321
7717
  * @example
7322
7718
  * ```js
7323
7719
  * // Update personalized view from liveboard context
@@ -7350,6 +7746,7 @@ export declare enum HostEvent {
7350
7746
  * If neither is provided, the Liveboard resets to the original/default view.
7351
7747
  * When a `viewName` is provided and multiple views share
7352
7748
  * the same name, the first match is selected.
7749
+ * Payload: {@link PersonalisedViewRequest}.
7353
7750
  * @example
7354
7751
  * ```js
7355
7752
  * liveboardEmbed.trigger(
@@ -7393,6 +7790,8 @@ export declare enum HostEvent {
7393
7790
  * If no parameters are specified, the save action is
7394
7791
  * triggered with a modal to prompt users to
7395
7792
  * add a name and description for the Answer.
7793
+ * Payload: {@link SaveAnswerRequest}.
7794
+ * Response: {@link SaveAnswerResponse}.
7396
7795
  * @param - Includes the following keys:
7397
7796
  * - `vizId`: Refers to the Answer ID in Spotter embed and is **required** in Spotter
7398
7797
  * embed.
@@ -7478,6 +7877,7 @@ export declare enum HostEvent {
7478
7877
  /**
7479
7878
  * Triggers a search operation with the search tokens specified in
7480
7879
  * the search query string in spotter embed.
7880
+ * Payload: {@link SpotterSearchRequest}.
7481
7881
  * @param - Includes the following keys:
7482
7882
  * - `query`: Text string in Natural Language format.
7483
7883
  * - `executeSearch`: Boolean to execute search and update search query.
@@ -7502,6 +7902,7 @@ export declare enum HostEvent {
7502
7902
  SpotterSearch = "SpotterSearch",
7503
7903
  /**
7504
7904
  * Edits the last prompt in spotter embed.
7905
+ * Payload: `string`.
7505
7906
  * @param - `query`: Text string
7506
7907
  * @example
7507
7908
  * ```js
@@ -7518,6 +7919,7 @@ export declare enum HostEvent {
7518
7919
  EditLastPrompt = "EditLastPrompt",
7519
7920
  /**
7520
7921
  * Opens the data source preview modal in Spotter Embed.
7922
+ * Payload: none.
7521
7923
  * @example
7522
7924
  * ```js
7523
7925
  * spotterEmbed.trigger(HostEvent.PreviewSpotterData);
@@ -7553,6 +7955,7 @@ export declare enum HostEvent {
7553
7955
  DataModelInstructions = "DataModelInstructions",
7554
7956
  /**
7555
7957
  * Resets the Spotter Embed Conversation.
7958
+ * Payload: none.
7556
7959
  * @example
7557
7960
  * ```js
7558
7961
  * spotterEmbed.trigger(HostEvent.ResetSpotterConversation);
@@ -7565,6 +7968,7 @@ export declare enum HostEvent {
7565
7968
  * `conversationId` is **mandatory** — you must pass the id of the
7566
7969
  * conversation to share. Also no-op when sharing is disabled
7567
7970
  * (enableShareConversation off) or when already in the read-only shared view.
7971
+ * Payload: {@link ConversationScopedRequest}.
7568
7972
  * @example
7569
7973
  * ```js
7570
7974
  * spotterEmbed.trigger(HostEvent.ShareSpotterConversation, { conversationId: 'abc' });
@@ -7574,6 +7978,7 @@ export declare enum HostEvent {
7574
7978
  ShareSpotterConversation = "ShareSpotterConversation",
7575
7979
  /**
7576
7980
  * Closes the Spotter share-conversation modal. No-op if none is open.
7981
+ * Payload: none.
7577
7982
  * @example
7578
7983
  * ```js
7579
7984
  * spotterEmbed.trigger(HostEvent.CloseSpotterShareConversation);
@@ -7583,6 +7988,7 @@ export declare enum HostEvent {
7583
7988
  CloseSpotterShareConversation = "CloseSpotterShareConversation",
7584
7989
  /**
7585
7990
  * Exits the read-only shared-conversation view.
7991
+ * Payload: none.
7586
7992
  * @example
7587
7993
  * ```js
7588
7994
  * spotterEmbed.trigger(HostEvent.ExitSpotterSharedConversation);
@@ -7592,6 +7998,7 @@ export declare enum HostEvent {
7592
7998
  ExitSpotterSharedConversation = "ExitSpotterSharedConversation",
7593
7999
  /**
7594
8000
  * Deletes the last prompt in spotter embed.
8001
+ * Payload: none.
7595
8002
  * @example
7596
8003
  * ```js
7597
8004
  * spotterEmbed.trigger(HostEvent.DeleteLastPrompt);
@@ -7601,6 +8008,7 @@ export declare enum HostEvent {
7601
8008
  DeleteLastPrompt = "DeleteLastPrompt",
7602
8009
  /**
7603
8010
  * Toggle the visualization to chart or table view.
8011
+ * Payload: {@link RequiredVizRequest}.
7604
8012
  * @param - `vizId ` refers to the Visualization ID in Spotter embed and is required.
7605
8013
  * @example
7606
8014
  * ```js
@@ -7639,6 +8047,7 @@ export declare enum HostEvent {
7639
8047
  VisibleEmbedCoordinates = "visibleEmbedCoordinates",
7640
8048
  /**
7641
8049
  * Trigger the *Spotter* action for visualizations present on the liveboard's vizzes.
8050
+ * Payload: {@link RequiredVizRequest}.
7642
8051
  * @param - `vizId` refers to the Visualization ID in Spotter embed and is required.
7643
8052
  * @example
7644
8053
  * ```js
@@ -7663,7 +8072,13 @@ export declare enum HostEvent {
7663
8072
  */
7664
8073
  UpdateEmbedParams = "updateEmbedParams",
7665
8074
  /**
7666
- * Triggered when the embed needs to be destroyed. This is used to clean up any embed-related resources internally.
8075
+ * Notifies the embedded ThoughtSpot app that the embed is being torn down, so that
8076
+ * it can release any resources it holds before the iframe is removed from the DOM.
8077
+ *
8078
+ * This is triggered for you by `embed.destroy()`; you rarely need to trigger it
8079
+ * directly. If `waitForCleanupOnDestroy` is set in the embed config, `destroy()`
8080
+ * waits for the app to acknowledge this event (up to `cleanupTimeout`) before
8081
+ * removing the iframe.
7667
8082
  * @example
7668
8083
  * ```js
7669
8084
  * liveboardEmbed.trigger(HostEvent.DestroyEmbed);
@@ -7694,6 +8109,7 @@ export declare enum HostEvent {
7694
8109
  * instance. Contact your admin or ThoughtSpot Support to enable chat history on your
7695
8110
  * instance.
7696
8111
  *
8112
+ * Payload: {@link ConversationScopedRequest}.
7697
8113
  * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
7698
8114
  * @example
7699
8115
  * ```js
@@ -7711,6 +8127,7 @@ export declare enum HostEvent {
7711
8127
  * instance. Contact your admin or ThoughtSpot Support to enable chat history on your
7712
8128
  * instance.
7713
8129
  *
8130
+ * Payload: {@link ConversationScopedRequest}.
7714
8131
  * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
7715
8132
  * @example
7716
8133
  * ```js
@@ -7735,6 +8152,7 @@ export declare enum HostEvent {
7735
8152
  * Trigger the **Send Test Email** action in the Liveboard schedule modal.
7736
8153
  * Sends a test schedule email to self or all recipients.
7737
8154
  * Requires `isSendNowLiveboardSchedulingEnabled` to be enabled.
8155
+ * Payload: {@link ScheduleEmailRequest}.
7738
8156
  * @example
7739
8157
  * ```js
7740
8158
  * liveboardEmbed.trigger(HostEvent.SendTestScheduleEmail, {
@@ -7753,6 +8171,7 @@ export declare enum HostEvent {
7753
8171
  SendTestScheduleEmail = "sendTestScheduleEmail",
7754
8172
  /**
7755
8173
  * Sends a user message (prompt) to the SpotterViz panel programmatically.
8174
+ * Payload: `{ query: string }`.
7756
8175
  * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
7757
8176
  * @param query - the prompt text to send.
7758
8177
  * @example
@@ -7765,6 +8184,7 @@ export declare enum HostEvent {
7765
8184
  SpotterVizSendUserMessage = "SpotterVizSendUserMessage",
7766
8185
  /**
7767
8186
  * Initializes a new SpotterViz conversation.
8187
+ * Payload: none.
7768
8188
  * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
7769
8189
  * @example
7770
8190
  * ```js
@@ -7774,6 +8194,7 @@ export declare enum HostEvent {
7774
8194
  InitSpotterVizConversation = "InitSpotterVizConversation",
7775
8195
  /**
7776
8196
  * Opens the SpotterViz panel.
8197
+ * Payload: none.
7777
8198
  * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
7778
8199
  * @example
7779
8200
  * ```js
@@ -7783,6 +8204,7 @@ export declare enum HostEvent {
7783
8204
  OpenSpotterVizPanel = "OpenSpotterVizPanel",
7784
8205
  /**
7785
8206
  * Closes the SpotterViz panel.
8207
+ * Payload: none.
7786
8208
  * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
7787
8209
  * @example
7788
8210
  * ```js
@@ -7793,6 +8215,7 @@ export declare enum HostEvent {
7793
8215
  /**
7794
8216
  * Clears browser cache and fetches new data for liveboard ChartViz Containers.
7795
8217
  * Requires `enableLiveboardDataCache` to be enabled.
8218
+ * Payload: {@link ScheduleEmailRequest}.
7796
8219
  * @example
7797
8220
  * ```js
7798
8221
  * liveboardEmbed.trigger(HostEvent.RefreshLiveboardBrowserCache);
@@ -9613,7 +10036,7 @@ export declare enum Action {
9613
10036
  * ```js
9614
10037
  * hiddenActions: [Action.QuickSearchPill]
9615
10038
  * ```
9616
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10039
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
9617
10040
  */
9618
10041
  QuickSearchPill = "quickSearchPill",
9619
10042
  /**
@@ -9628,7 +10051,7 @@ export declare enum Action {
9628
10051
  * ```js
9629
10052
  * hiddenActions: [Action.DeepAnalysisPill]
9630
10053
  * ```
9631
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10054
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
9632
10055
  */
9633
10056
  DeepAnalysisPill = "deepAnalysisPill",
9634
10057
  /**
@@ -9643,7 +10066,7 @@ export declare enum Action {
9643
10066
  * ```js
9644
10067
  * hiddenActions: [Action.DataLiteracyPill]
9645
10068
  * ```
9646
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10069
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
9647
10070
  */
9648
10071
  DataLiteracyPill = "dataLiteracyPill",
9649
10072
  /**
@@ -9825,75 +10248,359 @@ export declare enum Action {
9825
10248
  * disabledActions: [Action.SpotterOnLiveboard]
9826
10249
  * ```
9827
10250
  */
9828
- SpotterOnLiveboard = "spotterOnLiveboard"
9829
- }
9830
- export declare enum PrefetchFeatures {
9831
- FullApp = "FullApp",
9832
- SearchEmbed = "SearchEmbed",
9833
- LiveboardEmbed = "LiveboardEmbed",
9834
- VizEmbed = "VizEmbed"
9835
- }
9836
- declare enum ContextMenuTriggerOptions {
9837
- LEFT_CLICK = "left-click",
9838
- RIGHT_CLICK = "right-click",
9839
- BOTH_CLICKS = "both-clicks"
9840
- }
9841
- export interface ColumnValue {
9842
- column: {
9843
- id: string;
9844
- name: string;
9845
- dataType: string;
9846
- [key: string]: any;
9847
- };
9848
- value: string | number | boolean | {
9849
- v: {
9850
- s: number;
9851
- e: number;
9852
- };
9853
- };
9854
- }
9855
- export interface VizPoint {
9856
- selectedAttributes: ColumnValue[];
9857
- selectedMeasures: ColumnValue[];
9858
- }
9859
- export interface CustomAction {
9860
- name: string;
9861
- id: string;
9862
- position: CustomActionsPosition;
9863
- target: CustomActionTarget;
9864
- metadataIds?: {
9865
- answerIds?: string[];
9866
- liveboardIds?: string[];
9867
- vizIds?: string[];
9868
- };
9869
- dataModelIds?: {
9870
- modelIds?: string[];
9871
- modelColumnNames?: string[];
9872
- };
9873
- orgIds?: string[];
9874
- groupIds?: string[];
9875
- }
9876
- /**
9877
- * Enum options to show custom actions at different
9878
- * positions in the application.
9879
- */
9880
- export declare enum CustomActionsPosition {
10251
+ SpotterOnLiveboard = "spotterOnLiveboard",
9881
10252
  /**
9882
- * Shows the action as a primary button
9883
- * in the toolbar area of the embed.
10253
+ * Controls the visibility and disabled state of the "Chart Type" menu item
10254
+ * in Chart Settings V2.
10255
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10256
+ * @example
10257
+ * ```js
10258
+ * {
10259
+ * hiddenActions: [Action.ChartTypeSettings],
10260
+ * disabledActions: [Action.ChartTypeSettings],
10261
+ * }
10262
+ * ```
9884
10263
  */
9885
- PRIMARY = "PRIMARY",
10264
+ ChartTypeSettings = "CHART_TYPE",
9886
10265
  /**
9887
- * Shows the action inside the "More" menu
9888
- * (three-dot overflow menu).
10266
+ * Controls the visibility and disabled state of the "Layout" menu item
10267
+ * in Chart Settings V2.
10268
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10269
+ * @example
10270
+ * ```js
10271
+ * {
10272
+ * hiddenActions: [Action.LayoutSettings],
10273
+ * disabledActions: [Action.LayoutSettings],
10274
+ * }
10275
+ * ```
9889
10276
  */
9890
- MENU = "MENU",
10277
+ LayoutSettings = "LAYOUT",
9891
10278
  /**
9892
- * Shows the action in the right-click
9893
- * context menu. Only supported for
9894
- * {@link CustomActionTarget.VIZ},
9895
- * {@link CustomActionTarget.ANSWER}, and
9896
- * {@link CustomActionTarget.SPOTTER} targets.
10279
+ * Controls the visibility and disabled state of the "Column" menu item
10280
+ * in Chart Settings V2.
10281
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10282
+ * @example
10283
+ * ```js
10284
+ * {
10285
+ * hiddenActions: [Action.ColumnSettings],
10286
+ * disabledActions: [Action.ColumnSettings],
10287
+ * }
10288
+ * ```
10289
+ */
10290
+ ColumnSettings = "COLUMN",
10291
+ /**
10292
+ * Controls the visibility and disabled state of the "Axis" menu item
10293
+ * in Chart Settings V2.
10294
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10295
+ * @example
10296
+ * ```js
10297
+ * {
10298
+ * hiddenActions: [Action.AxisSettings],
10299
+ * disabledActions: [Action.AxisSettings],
10300
+ * }
10301
+ * ```
10302
+ */
10303
+ AxisSettings = "AXIS",
10304
+ /**
10305
+ * Controls the visibility and disabled state of the "Data Label" menu item
10306
+ * in Chart Settings V2.
10307
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10308
+ * @example
10309
+ * ```js
10310
+ * {
10311
+ * hiddenActions: [Action.DataLabelSettings],
10312
+ * disabledActions: [Action.DataLabelSettings],
10313
+ * }
10314
+ * ```
10315
+ */
10316
+ DataLabelSettings = "DATA_LABEL",
10317
+ /**
10318
+ * Controls the visibility and disabled state of the "Tooltip" menu item
10319
+ * in Chart Settings V2.
10320
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10321
+ * @example
10322
+ * ```js
10323
+ * {
10324
+ * hiddenActions: [Action.TooltipSettings],
10325
+ * disabledActions: [Action.TooltipSettings],
10326
+ * }
10327
+ * ```
10328
+ */
10329
+ TooltipSettings = "TOOLTIP",
10330
+ /**
10331
+ * Controls the visibility and disabled state of the "Legend" menu item
10332
+ * in Chart Settings V2.
10333
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10334
+ * @example
10335
+ * ```js
10336
+ * {
10337
+ * hiddenActions: [Action.LegendSettings],
10338
+ * disabledActions: [Action.LegendSettings],
10339
+ * }
10340
+ * ```
10341
+ */
10342
+ LegendSettings = "LEGEND",
10343
+ /**
10344
+ * Controls the visibility and disabled state of the "Display" menu item
10345
+ * in Chart Settings V2.
10346
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10347
+ * @example
10348
+ * ```js
10349
+ * {
10350
+ * hiddenActions: [Action.DisplaySettings],
10351
+ * disabledActions: [Action.DisplaySettings],
10352
+ * }
10353
+ * ```
10354
+ */
10355
+ DisplaySettings = "DISPLAY",
10356
+ /**
10357
+ * Controls the visibility and disabled state of the "Query Details" menu
10358
+ * item in Chart Settings V2.
10359
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10360
+ * @example
10361
+ * ```js
10362
+ * {
10363
+ * hiddenActions: [Action.QuerySettings],
10364
+ * disabledActions: [Action.QuerySettings],
10365
+ * }
10366
+ * ```
10367
+ */
10368
+ QuerySettings = "QUERY_DETAILS",
10369
+ /**
10370
+ * Controls the visibility and disabled state of the "Custom Action" menu
10371
+ * item in Chart Settings V2.
10372
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10373
+ * @example
10374
+ * ```js
10375
+ * {
10376
+ * hiddenActions: [Action.CustomSettings],
10377
+ * disabledActions: [Action.CustomSettings],
10378
+ * }
10379
+ * ```
10380
+ */
10381
+ CustomSettings = "CUSTOM_ACTION",
10382
+ /**
10383
+ * Controls the visibility and disabled state of the "Muze AI" menu item
10384
+ * in Chart Settings V2.
10385
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10386
+ * @example
10387
+ * ```js
10388
+ * {
10389
+ * hiddenActions: [Action.MuzeAiSettings],
10390
+ * disabledActions: [Action.MuzeAiSettings],
10391
+ * }
10392
+ * ```
10393
+ */
10394
+ MuzeAiSettings = "MUZE_AI",
10395
+ /**
10396
+ * Controls the visibility and disabled state of the "R Analysis" menu item
10397
+ * in Chart Settings V2.
10398
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
10399
+ * @example
10400
+ * ```js
10401
+ * {
10402
+ * hiddenActions: [Action.RAnalysisSettings],
10403
+ * disabledActions: [Action.RAnalysisSettings],
10404
+ * }
10405
+ * ```
10406
+ */
10407
+ RAnalysisSettings = "R_ANALYSIS",
10408
+ /**
10409
+ * Controls the visibility and disabled state of the "Add to Collection" menu item.
10410
+ * @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
10411
+ * @example
10412
+ * ```js
10413
+ * {
10414
+ * hiddenActions: [Action.AddToCollection],
10415
+ * disabledActions: [Action.AddToCollection],
10416
+ * }
10417
+ * ```
10418
+ */
10419
+ AddToCollection = "addToCollection",
10420
+ /**
10421
+ * Controls the visibility and disabled state of the "Create Collection" button.
10422
+ * @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
10423
+ * @example
10424
+ * ```js
10425
+ * {
10426
+ * hiddenActions: [Action.CreateCollection],
10427
+ * disabledActions: [Action.CreateCollection],
10428
+ * }
10429
+ * ```
10430
+ */
10431
+ CreateCollection = "createCollection",
10432
+ /**
10433
+ * Controls the visibility and disabled state of the "Move" menu item in a
10434
+ * Collection.
10435
+ * @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
10436
+ * @example
10437
+ * ```js
10438
+ * {
10439
+ * hiddenActions: [Action.MoveToCollection],
10440
+ * disabledActions: [Action.MoveToCollection],
10441
+ * }
10442
+ * ```
10443
+ */
10444
+ MoveToCollection = "moveToCollection",
10445
+ /**
10446
+ * Controls the visibility and disabled state of the "Remove" menu item in a
10447
+ * Collection.
10448
+ * @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
10449
+ * @example
10450
+ * ```js
10451
+ * {
10452
+ * hiddenActions: [Action.RemoveFromCollection],
10453
+ * disabledActions: [Action.RemoveFromCollection],
10454
+ * }
10455
+ * ```
10456
+ */
10457
+ RemoveFromCollection = "removeFromCollection",
10458
+ /**
10459
+ * Controls the visibility and disabled state of the "Delete" menu item for a
10460
+ * Collection.
10461
+ * @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
10462
+ * @example
10463
+ * ```js
10464
+ * {
10465
+ * hiddenActions: [Action.DeleteCollection],
10466
+ * disabledActions: [Action.DeleteCollection],
10467
+ * }
10468
+ * ```
10469
+ */
10470
+ DeleteCollection = "deleteCollection"
10471
+ }
10472
+ export declare enum PrefetchFeatures {
10473
+ FullApp = "FullApp",
10474
+ SearchEmbed = "SearchEmbed",
10475
+ LiveboardEmbed = "LiveboardEmbed",
10476
+ VizEmbed = "VizEmbed"
10477
+ }
10478
+ declare enum ContextMenuTriggerOptions {
10479
+ LEFT_CLICK = "left-click",
10480
+ RIGHT_CLICK = "right-click",
10481
+ BOTH_CLICKS = "both-clicks"
10482
+ }
10483
+ export interface ColumnValue {
10484
+ column: {
10485
+ id: string;
10486
+ name: string;
10487
+ dataType: string;
10488
+ [key: string]: any;
10489
+ };
10490
+ value: string | number | boolean | {
10491
+ v: {
10492
+ s: number;
10493
+ e: number;
10494
+ };
10495
+ };
10496
+ }
10497
+ export interface VizPoint {
10498
+ selectedAttributes: ColumnValue[];
10499
+ selectedMeasures: ColumnValue[];
10500
+ }
10501
+ /**
10502
+ * @group Events
10503
+ */
10504
+ export interface CustomActionPayload {
10505
+ /**
10506
+ * Id of the custom action that was triggered. Matches the `id` you set on
10507
+ * the {@link CustomAction}. Omitted on Liveboard-level code-based actions.
10508
+ */
10509
+ id?: string;
10510
+ contextMenuPoints?: {
10511
+ clickedPoint: VizPoint;
10512
+ selectedPoints: VizPoint[];
10513
+ };
10514
+ embedAnswerData: {
10515
+ name: string;
10516
+ id: string;
10517
+ sources: {
10518
+ header: {
10519
+ guid: string;
10520
+ };
10521
+ };
10522
+ columns: any[];
10523
+ data: any[];
10524
+ [key: string]: any;
10525
+ };
10526
+ session: SessionInterface;
10527
+ vizId?: string;
10528
+ }
10529
+ /**
10530
+ * A code-based custom action to inject into the embedded ThoughtSpot UI.
10531
+ * Pass an array of these as `customActions` in the embed view config. When a
10532
+ * user invokes the action, the host emits {@link EmbedEvent.CustomAction} with
10533
+ * a {@link CustomActionPayload} carrying the same `id`.
10534
+ */
10535
+ export interface CustomAction {
10536
+ /**
10537
+ * Display label shown on the action's button or menu item.
10538
+ */
10539
+ name: string;
10540
+ /**
10541
+ * Unique identifier for the action. Echoed back as `id` on the
10542
+ * {@link CustomActionPayload} when the action is invoked.
10543
+ */
10544
+ id: string;
10545
+ /**
10546
+ * Where the action appears: a primary button, the "More" menu, or the
10547
+ * right-click context menu. See {@link CustomActionsPosition}.
10548
+ */
10549
+ position: CustomActionsPosition;
10550
+ /**
10551
+ * The surface the action applies to (Liveboard, visualization, Answer, or
10552
+ * Spotter). See {@link CustomActionTarget}. The allowed `position` values
10553
+ * and scoping keys depend on the target.
10554
+ */
10555
+ target: CustomActionTarget;
10556
+ /**
10557
+ * Scope the action to specific objects by GUID. Which keys are allowed
10558
+ * depends on `target` (for example, a `VIZ` action may use `answerIds`,
10559
+ * `liveboardIds`, and `vizIds`).
10560
+ */
10561
+ metadataIds?: {
10562
+ answerIds?: string[];
10563
+ liveboardIds?: string[];
10564
+ vizIds?: string[];
10565
+ };
10566
+ /**
10567
+ * Scope the action by data model, using model GUIDs or column names.
10568
+ * Allowed for `VIZ`, `ANSWER`, and `SPOTTER` targets.
10569
+ */
10570
+ dataModelIds?: {
10571
+ modelIds?: string[];
10572
+ modelColumnNames?: string[];
10573
+ };
10574
+ /**
10575
+ * Restrict the action to specific organizations by ID.
10576
+ */
10577
+ orgIds?: string[];
10578
+ /**
10579
+ * Restrict the action to specific user groups by ID.
10580
+ */
10581
+ groupIds?: string[];
10582
+ }
10583
+ /**
10584
+ * Enum options to show custom actions at different
10585
+ * positions in the application.
10586
+ */
10587
+ export declare enum CustomActionsPosition {
10588
+ /**
10589
+ * Shows the action as a primary button
10590
+ * in the toolbar area of the embed.
10591
+ */
10592
+ PRIMARY = "PRIMARY",
10593
+ /**
10594
+ * Shows the action inside the "More" menu
10595
+ * (three-dot overflow menu).
10596
+ */
10597
+ MENU = "MENU",
10598
+ /**
10599
+ * Shows the action in the right-click
10600
+ * context menu. Only supported for
10601
+ * {@link CustomActionTarget.VIZ},
10602
+ * {@link CustomActionTarget.ANSWER}, and
10603
+ * {@link CustomActionTarget.SPOTTER} targets.
9897
10604
  */
9898
10605
  CONTEXTMENU = "CONTEXTMENU"
9899
10606
  }
@@ -10131,9 +10838,40 @@ export interface EmbedErrorDetailsEvent {
10131
10838
  message: string | string[];
10132
10839
  /** Machine-readable error code for programmatic error handling */
10133
10840
  code: EmbedErrorCodes;
10841
+ /** How badly the embed is affected. Defaults to {@link EmbedErrorSeverity.SEV3}. */
10842
+ severity?: EmbedErrorSeverity;
10134
10843
  /** Additional context-specific for backward compatibility */
10135
10844
  [key: string]: any;
10136
10845
  }
10846
+ /**
10847
+ * How badly an error affects the embed, so the host can decide whether it is
10848
+ * worth surfacing to the end user.
10849
+ *
10850
+ * Mirrors the severity that ThoughtSpot itself stamps on errors raised inside
10851
+ * the embedded app, so a host can apply one rule to both sources.
10852
+ *
10853
+ * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10854
+ * @group Error Handling
10855
+ *
10856
+ * @example
10857
+ * Only surface errors that took the embed down
10858
+ *
10859
+ * ```js
10860
+ * embed.on(EmbedEvent.Error, (error) => {
10861
+ * if (error.severity === EmbedErrorSeverity.SEV1) {
10862
+ * showBanner(error.message);
10863
+ * }
10864
+ * });
10865
+ * ```
10866
+ */
10867
+ export declare enum EmbedErrorSeverity {
10868
+ /** The embed cannot render. Nothing usable is on screen. */
10869
+ SEV1 = 1,
10870
+ /** Something is degraded but the embed still works. */
10871
+ SEV2 = 2,
10872
+ /** Everything else, including validation of the embedder's own input. */
10873
+ SEV3 = 3
10874
+ }
10137
10875
  declare enum ContextType {
10138
10876
  /**
10139
10877
  * Search answer context for search page or edit viz dialog on liveboard page.
@@ -10175,25 +10913,40 @@ export interface DefaultAppInitData {
10175
10913
  useHostEventsV2?: boolean;
10176
10914
  }
10177
10915
  /**
10178
- * Enum for the type of API intercepted
10916
+ * Named groups of ThoughtSpot APIs that can be intercepted, for use in
10917
+ * `interceptUrls`. Each group expands to the underlying request URLs, so you do
10918
+ * not have to list them individually.
10179
10919
  */
10180
10920
  export declare enum InterceptedApiType {
10181
10921
  /**
10182
- * The apis that are use to get the data for the embed
10922
+ * The APIs that fetch the data backing an Answer, including its chart,
10923
+ * table, and headline data.
10183
10924
  */
10184
10925
  AnswerData = "AnswerData",
10185
10926
  /**
10186
- * This will intercept all the apis
10927
+ * Intercepts every `fetch` request the embedded application makes, not only
10928
+ * the data APIs. This includes authentication, session, and metadata calls,
10929
+ * so the handler must respond to requests it does not recognize by passing
10930
+ * `execute: true`. Listing this alongside other entries in `interceptUrls`
10931
+ * supersedes them.
10187
10932
  */
10188
10933
  ALL = "ALL",
10189
10934
  /**
10190
- * The apis that are use to get the data for the liveboard
10935
+ * The APIs that fetch the data backing a Liveboard.
10191
10936
  */
10192
10937
  LiveboardData = "LiveboardData"
10193
10938
  }
10194
10939
  export type ApiInterceptFlags = {
10195
10940
  /**
10196
- * Flag that allows using `EmbedEvent.OnBeforeGetVizDataIntercept`.
10941
+ * Emits `EmbedEvent.OnBeforeGetVizDataIntercept` before the Answer data
10942
+ * APIs are called. This is the earlier, narrower form of interception, kept
10943
+ * for backward compatibility and implemented on top of
10944
+ * `EmbedEvent.ApiIntercept`. Prefer `interceptUrls` with
10945
+ * `InterceptedApiType.AnswerData` in new code.
10946
+ *
10947
+ * Setting this also intercepts the Answer data APIs, so both
10948
+ * `EmbedEvent.OnBeforeGetVizDataIntercept` and `EmbedEvent.ApiIntercept`
10949
+ * are emitted for those requests.
10197
10950
  *
10198
10951
  * Can be used for Search and App Embed from SDK 1.29.0
10199
10952
  *
@@ -10201,14 +10954,21 @@ export type ApiInterceptFlags = {
10201
10954
  */
10202
10955
  isOnBeforeGetVizDataInterceptEnabled?: boolean;
10203
10956
  /**
10204
- * This allows to intercept the urls passed, once intercepted the api will only
10205
- * run based on the response from the responder of ApiIntercept event.
10957
+ * The requests to intercept, given as `InterceptedApiType` groups, absolute
10958
+ * URLs, or paths beginning with `/` that are resolved against the
10959
+ * ThoughtSpot host. Setting this is what turns interception on.
10960
+ *
10961
+ * A URL matches only on exact equality with the request's fully resolved
10962
+ * URL, query string included, so prefer an `InterceptedApiType` group where
10963
+ * one covers the API you need.
10964
+ *
10965
+ * Each intercepted request pauses and emits `EmbedEvent.ApiIntercept`, then
10966
+ * proceeds according to the response passed to that event's responder.
10206
10967
  *
10207
10968
  * @example
10208
10969
  * ```js
10209
10970
  * const embed = new LiveboardEmbed('#embed', {
10210
10971
  * ...viewConfig,
10211
- * enableApiIntercept: true,
10212
10972
  * interceptUrls: [InterceptedApiType.LiveboardData],
10213
10973
  * })
10214
10974
  * ```
@@ -10217,14 +10977,14 @@ export type ApiInterceptFlags = {
10217
10977
  */
10218
10978
  interceptUrls?: (string | InterceptedApiType)[];
10219
10979
  /**
10220
- * The timeout for the intercept, default is 30000ms
10221
- * the api will error out if the timeout is reached
10980
+ * How long, in milliseconds, an intercepted request waits for the
10981
+ * `EmbedEvent.ApiIntercept` responder before it is abandoned. Defaults to
10982
+ * 30000. On timeout the request fails and `EmbedEvent.Error` is emitted.
10222
10983
  *
10223
10984
  * @example
10224
10985
  * ```js
10225
10986
  * const embed = new LiveboardEmbed('#embed', {
10226
10987
  * ...viewConfig,
10227
- * enableApiIntercept: true,
10228
10988
  * interceptUrls: [InterceptedApiType.ALL],
10229
10989
  * interceptTimeout: 1000,
10230
10990
  * })
@@ -10669,6 +11429,166 @@ export interface VisualizationOverrides {
10669
11429
  /** Table visualization overrides */
10670
11430
  table?: TableOverrides;
10671
11431
  }
11432
+ /**
11433
+ * The configuration object for the full-height behavior shared by the
11434
+ * Liveboard and app embeds.
11435
+ *
11436
+ * When `fullHeight` is enabled the SDK resizes the embed container to match the
11437
+ * height reported by the ThoughtSpot app, and — when lazy loading is also
11438
+ * enabled — keeps the app informed of the portion of the embed that is
11439
+ * currently visible so that visualizations load on demand.
11440
+ */
11441
+ export interface FullHeightViewConfig {
11442
+ /**
11443
+ * If set to true, the embedded object container dynamically resizes
11444
+ * according to the height of the Liveboard.
11445
+ *
11446
+ * **Note**: Using fullHeight loads all visualizations on the
11447
+ * Liveboard simultaneously, which results in multiple warehouse
11448
+ * queries and potentially a longer wait for the topmost
11449
+ * visualizations to display on the screen.
11450
+ * Setting `fullHeight` to `false` fetches visualizations
11451
+ * incrementally as users scroll the page to view the charts and tables.
11452
+ *
11453
+ * From SDK 1.52.0, enabling `fullHeight` also turns on
11454
+ * {@link lazyLoadingForFullHeight} and
11455
+ * {@link enableScrollableContainerLazyLoading}, so visualizations load as
11456
+ * they scroll into view. Set either flag to `false` to opt out.
11457
+ *
11458
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11459
+ * @version SDK: 1.1.0 | ThoughtSpot: ts7.may.cl, 7.2.1
11460
+ * @example
11461
+ * ```js
11462
+ * // Replace <EmbedComponent> with the embed component name.
11463
+ * // For example, AppEmbed or LiveboardEmbed
11464
+ * const embed = new <EmbedComponent>('#embed', {
11465
+ * ... // other view config
11466
+ * fullHeight: true,
11467
+ * });
11468
+ * ```
11469
+ */
11470
+ fullHeight?: boolean;
11471
+ /**
11472
+ * This is the minimum height (in pixels) for a full-height Liveboard.
11473
+ * Setting this height helps resolve issues with empty Liveboards and
11474
+ * other screens navigable from a Liveboard.
11475
+ *
11476
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11477
+ * @version SDK: 1.44.2 | ThoughtSpot: 10.15.0.cl
11478
+ * @default 500
11479
+ * @example
11480
+ * ```js
11481
+ * // Replace <EmbedComponent> with the embed component name.
11482
+ * // For example, AppEmbed or LiveboardEmbed
11483
+ * const embed = new <EmbedComponent>('#embed', {
11484
+ * ... // other view config
11485
+ * fullHeight: true,
11486
+ * minimumHeight: 600,
11487
+ * });
11488
+ * ```
11489
+ */
11490
+ minimumHeight?: number;
11491
+ /**
11492
+ * This is the minimum height (in pixels) for a full-height Liveboard.
11493
+ * Setting this height helps resolve issues with empty Liveboards and
11494
+ * other screens navigable from a Liveboard.
11495
+ *
11496
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11497
+ * @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
11498
+ * @deprecated Use `minimumHeight` instead.
11499
+ * @default 500
11500
+ * @example
11501
+ * ```js
11502
+ * // Replace <EmbedComponent> with the embed component name.
11503
+ * // For example, AppEmbed or LiveboardEmbed
11504
+ * const embed = new <EmbedComponent>('#embed', {
11505
+ * ... // other view config
11506
+ * fullHeight: true,
11507
+ * defaultHeight: 600,
11508
+ * });
11509
+ * ```
11510
+ */
11511
+ defaultHeight?: number;
11512
+ /**
11513
+ * Loads visualizations only as they scroll into the viewport, instead of
11514
+ * loading the whole full-height Liveboard at once.
11515
+ *
11516
+ * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
11517
+ * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
11518
+ * set explicitly. Set it to `false` to load every visualization upfront.
11519
+ * The flag has no effect unless `fullHeight` is enabled.
11520
+ *
11521
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11522
+ * @type {boolean}
11523
+ * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
11524
+ * @default true when `fullHeight` is enabled, from SDK 1.52.0
11525
+ * @example
11526
+ * ```js
11527
+ * // Replace <EmbedComponent> with the embed component name.
11528
+ * // For example, AppEmbed or LiveboardEmbed
11529
+ * const embed = new <EmbedComponent>('#embed-container', {
11530
+ * // ...other options
11531
+ * fullHeight: true,
11532
+ * lazyLoadingForFullHeight: true,
11533
+ * })
11534
+ * ```
11535
+ */
11536
+ lazyLoadingForFullHeight?: boolean;
11537
+ /**
11538
+ * How far outside the viewport a visualization starts loading, when
11539
+ * {@link lazyLoadingForFullHeight} is enabled.
11540
+ *
11541
+ * For example, if the margin is set to '10px',
11542
+ * the visualization will be loaded 10px before its top edge is visible in the
11543
+ * viewport.
11544
+ *
11545
+ * The format is similar to CSS margin, so `'500px 0px'` extends the
11546
+ * prefetch 500px above and below the viewport and not sideways. Accepted
11547
+ * units are `px`, `em`, `rem`, `%`, `vh` and `vw`, plus bare `0` and
11548
+ * `auto`; an invalid value is logged and ignored.
11549
+ *
11550
+ * From SDK 1.52.0 this defaults to `'500px 0px'` — roughly one
11551
+ * visualization ahead of the scroll position, so a chart has usually
11552
+ * finished loading by the time it scrolls into view. Use a smaller margin
11553
+ * to cut warehouse queries further, or `'0px'` to load a visualization
11554
+ * only once it is actually visible.
11555
+ *
11556
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11557
+ * @type {string}
11558
+ * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
11559
+ * @default '500px 0px' when `fullHeight` is enabled, from SDK 1.52.0
11560
+ * @example
11561
+ * ```js
11562
+ * // Replace <EmbedComponent> with the embed component name.
11563
+ * // For example, AppEmbed or LiveboardEmbed
11564
+ * const embed = new <EmbedComponent>('#embed-container', {
11565
+ * // ...other options
11566
+ * fullHeight: true,
11567
+ * lazyLoadingForFullHeight: true,
11568
+ * // With 0px, the visualization only starts loading once it is
11569
+ * // visible in the viewport.
11570
+ * lazyLoadingMargin: '0px',
11571
+ * })
11572
+ * ```
11573
+ */
11574
+ lazyLoadingMargin?: string;
11575
+ /**
11576
+ * Computes the visible region of the embed against its scrollable and
11577
+ * clipping ancestors, instead of treating the browser window as the only
11578
+ * viewport, and tracks scroll and resize on those ancestors.
11579
+ *
11580
+ * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
11581
+ * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
11582
+ * set explicitly. Set it to `false` when the page scrolls with the window
11583
+ * and the embed has no clipping ancestor, to skip the extra ancestor
11584
+ * tracking.
11585
+ *
11586
+ * Supported embed types: `LiveboardEmbed`, `AppEmbed`
11587
+ * @type {boolean}
11588
+ * @default true when `fullHeight` is enabled, from SDK 1.52.0
11589
+ */
11590
+ enableScrollableContainerLazyLoading?: boolean;
11591
+ }
10672
11592
  /**
10673
11593
  * Enum for auth failure types.
10674
11594
  * This value is passed to the listener for {@link AuthStatus.FAILURE}.
@@ -10780,284 +11700,421 @@ export declare enum AuthStatus {
10780
11700
  SAML_POPUP_CLOSED_NO_AUTH = "SAML_POPUP_CLOSED_NO_AUTH"
10781
11701
  }
10782
11702
  /**
10783
- * Event emitter returned from {@link init}.
10784
- * @group Authentication / Init
11703
+ * Event emitter returned from {@link init}.
11704
+ * @group Authentication / Init
11705
+ */
11706
+ export interface AuthEventEmitter {
11707
+ /**
11708
+ * Register a listener on Auth failure.
11709
+ * @param event
11710
+ * @param listener
11711
+ */
11712
+ on(event: AuthStatus.FAILURE, listener: (failureType: AuthFailureType) => void): this;
11713
+ /**
11714
+ * Register a listener on Auth SDK success.
11715
+ * @param event
11716
+ * @param listener
11717
+ */
11718
+ on(event: AuthStatus.SDK_SUCCESS | AuthStatus.LOGOUT | AuthStatus.WAITING_FOR_POPUP | AuthStatus.SAML_POPUP_CLOSED_NO_AUTH, listener: () => void): this;
11719
+ on(event: AuthStatus.SUCCESS, listener: (sessionInfo: any) => void): this;
11720
+ once(event: AuthStatus.FAILURE, listener: (failureType: AuthFailureType) => void): this;
11721
+ once(event: AuthStatus.SDK_SUCCESS | AuthStatus.LOGOUT | AuthStatus.WAITING_FOR_POPUP | AuthStatus.SAML_POPUP_CLOSED_NO_AUTH, listener: () => void): this;
11722
+ once(event: AuthStatus.SUCCESS, listener: (sessionInfo: any) => void): this;
11723
+ /**
11724
+ * Trigger an event on the emitter returned from init.
11725
+ * @param {@link AuthEvent}
11726
+ */
11727
+ emit(event: AuthEvent, ...args: any[]): boolean;
11728
+ /**
11729
+ * Remove listener from the emitter returned from init.
11730
+ * @param event
11731
+ * @param listener
11732
+ * @param context
11733
+ * @param once
11734
+ */
11735
+ off(event: AuthStatus, listener: (...args: any[]) => void, context: any, once: boolean): this;
11736
+ /**
11737
+ * Remove all the event listeners
11738
+ * @param event
11739
+ */
11740
+ removeAllListeners(event: AuthStatus): this;
11741
+ }
11742
+ /**
11743
+ * Events which can be triggered on the emitter returned from {@link init}.
11744
+ * @group Authentication / Init
11745
+ */
11746
+ export declare enum AuthEvent {
11747
+ /**
11748
+ * Manually trigger the SSO popup. This is useful when
11749
+ * authStatus is SAMLRedirect/OIDCRedirect and inPopup is set to true
11750
+ */
11751
+ TRIGGER_SSO_POPUP = "TRIGGER_SSO_POPUP"
11752
+ }
11753
+ /**
11754
+ * Request for host events that MAY target a specific visualization.
11755
+ * Omitting vizId targets the current answer/liveboard as a whole.
11756
+ * (In some contexts, e.g. Spotter, the app requires vizId at runtime.)
11757
+ */
11758
+ export interface VizScopedRequest {
11759
+ vizId?: string;
11760
+ }
11761
+ /**
11762
+ * Request for host events that MUST target a specific visualization.
11763
+ */
11764
+ export interface RequiredVizRequest {
11765
+ vizId: string;
11766
+ }
11767
+ /**
11768
+ * Request for Spotter conversation-scoped host events.
11769
+ */
11770
+ export interface ConversationScopedRequest {
11771
+ conversationId: string;
11772
+ }
11773
+ /**
11774
+ * Request payload for {@link HostEvent.OpenFilter}. Field requirements
11775
+ * vary by context (Search requires columnId/type/dataType/name); the
11776
+ * contract is the cross-context superset — the app validates per context
11777
+ * at runtime. Per-context views: {@link OpenFilterLiveboardRequest},
11778
+ * {@link OpenFilterSpotterRequest}, {@link OpenFilterSearchRequest}.
11779
+ */
11780
+ export interface OpenFilterRequest {
11781
+ column: {
11782
+ columnId?: string;
11783
+ columnName?: string;
11784
+ type?: string;
11785
+ dataType?: string;
11786
+ name?: string;
11787
+ isStrictDateColumn?: boolean;
11788
+ };
11789
+ applicability?: Applicability;
11790
+ visualizationId?: string;
11791
+ liveboardId?: string;
11792
+ }
11793
+ /**
11794
+ * `OpenFilter` in Liveboard context: full column plus scoping fields.
11795
+ * A per-context view of {@link OpenFilterRequest} (documentation only today;
11796
+ * `trigger()` accepts the superset).
11797
+ */
11798
+ export interface OpenFilterLiveboardRequest {
11799
+ column: {
11800
+ columnId?: string;
11801
+ columnName?: string;
11802
+ };
11803
+ applicability?: Applicability;
11804
+ visualizationId?: string;
11805
+ liveboardId?: string;
11806
+ }
11807
+ /**
11808
+ * `OpenFilter` in Spotter context: only the column identity is accepted.
11809
+ */
11810
+ export interface OpenFilterSpotterRequest {
11811
+ column: {
11812
+ columnId?: string;
11813
+ columnName?: string;
11814
+ };
11815
+ }
11816
+ /**
11817
+ * `OpenFilter` in Search/Answer context: column identity plus column metadata.
11818
+ */
11819
+ export interface OpenFilterSearchRequest {
11820
+ column: {
11821
+ columnId?: string;
11822
+ columnName?: string;
11823
+ type?: string;
11824
+ dataType?: string;
11825
+ name?: string;
11826
+ isStrictDateColumn?: boolean;
11827
+ };
11828
+ }
11829
+ /**
11830
+ * Request payload for {@link HostEvent.DrillDown}. Drills on selected or
11831
+ * clicked points of a visualization. In Liveboard context `vizId` is required
11832
+ * at runtime (documentation only today; `trigger()` is not yet type-enforced).
11833
+ */
11834
+ export interface DrillDownRequest {
11835
+ points: {
11836
+ clickedPoint?: object;
11837
+ selectedPoints?: object[];
11838
+ };
11839
+ columnGuid?: string;
11840
+ autoDrillDown?: boolean;
11841
+ vizId?: string;
11842
+ }
11843
+ /**
11844
+ * Request payload for {@link HostEvent.OpenParameter}. One of parameterId
11845
+ * or parameterName must be provided (validated at runtime).
11846
+ */
11847
+ export interface OpenParameterRequest {
11848
+ parameter: {
11849
+ parameterId?: string;
11850
+ parameterName?: string;
11851
+ };
11852
+ applicability?: Applicability;
11853
+ }
11854
+ /**
11855
+ * Request payload for {@link HostEvent.Search}.
11856
+ */
11857
+ export interface SearchRequest {
11858
+ searchQuery: string;
11859
+ dataSources: string[];
11860
+ execute?: boolean;
11861
+ }
11862
+ /**
11863
+ * Request payload for {@link HostEvent.SpotterSearch}.
11864
+ */
11865
+ export interface SpotterSearchRequest {
11866
+ query: string;
11867
+ executeSearch: boolean;
11868
+ }
11869
+ /**
11870
+ * A single cross-filter condition for {@link HostEvent.UpdateCrossFilter}.
11871
+ */
11872
+ export interface CrossFilterCondition {
11873
+ columnName?: string;
11874
+ operator?: string;
11875
+ values: Array<string | number | boolean>;
11876
+ }
11877
+ /**
11878
+ * Request payload for {@link HostEvent.UpdateCrossFilter}.
11879
+ */
11880
+ export interface UpdateCrossFilterRequest {
11881
+ vizId: string;
11882
+ conditions: CrossFilterCondition[];
11883
+ }
11884
+ /**
11885
+ * A single filter entry for {@link HostEvent.UpdateFilters}. Supports both
11886
+ * the current (columnName/operator) and legacy (column/oper) field names.
10785
11887
  */
10786
- export interface AuthEventEmitter {
10787
- /**
10788
- * Register a listener on Auth failure.
10789
- * @param event
10790
- * @param listener
10791
- */
10792
- on(event: AuthStatus.FAILURE, listener: (failureType: AuthFailureType) => void): this;
11888
+ export interface HostFilterUpdate {
11889
+ columnName?: string;
11890
+ columnId?: string;
11891
+ operator?: string;
11892
+ values: Array<string | number | boolean>;
11893
+ type?: string;
11894
+ datePeriod?: string;
11895
+ negate?: boolean;
11896
+ /** Legacy field name for columnName. */
11897
+ column?: string;
11898
+ /** Legacy field name for operator. */
11899
+ oper?: string;
11900
+ applicability?: Applicability;
11901
+ }
11902
+ /**
11903
+ * Request payload for {@link HostEvent.UpdateFilters} (singular or plural
11904
+ * form).
11905
+ */
11906
+ export interface UpdateFiltersRequest {
11907
+ filter?: HostFilterUpdate;
11908
+ filters?: HostFilterUpdate[];
10793
11909
  /**
10794
- * Register a listener on Auth SDK success.
10795
- * @param event
10796
- * @param listener
11910
+ * Scope the update to a specific visualization on a Liveboard.
11911
+ * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10797
11912
  */
10798
- on(event: AuthStatus.SDK_SUCCESS | AuthStatus.LOGOUT | AuthStatus.WAITING_FOR_POPUP | AuthStatus.SAML_POPUP_CLOSED_NO_AUTH, listener: () => void): this;
10799
- on(event: AuthStatus.SUCCESS, listener: (sessionInfo: any) => void): this;
10800
- once(event: AuthStatus.FAILURE, listener: (failureType: AuthFailureType) => void): this;
10801
- once(event: AuthStatus.SDK_SUCCESS | AuthStatus.LOGOUT | AuthStatus.WAITING_FOR_POPUP | AuthStatus.SAML_POPUP_CLOSED_NO_AUTH, listener: () => void): this;
10802
- once(event: AuthStatus.SUCCESS, listener: (sessionInfo: any) => void): this;
11913
+ visualizationId?: string;
10803
11914
  /**
10804
- * Trigger an event on the emitter returned from init.
10805
- * @param {@link AuthEvent}
11915
+ * Scope the update to a specific Liveboard.
11916
+ * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
10806
11917
  */
10807
- emit(event: AuthEvent, ...args: any[]): boolean;
11918
+ liveboardId?: string;
11919
+ }
11920
+ /**
11921
+ * Request payload for personalised-view host events.
11922
+ */
11923
+ export interface PersonalisedViewRequest {
11924
+ viewId?: string;
11925
+ viewName?: string;
11926
+ }
11927
+ /**
11928
+ * Request payload for schedule-email related host events.
11929
+ */
11930
+ export interface ScheduleEmailRequest {
11931
+ sendToSelf?: boolean;
11932
+ }
11933
+ /**
11934
+ * Object form of the {@link HostEvent.Navigate} payload.
11935
+ */
11936
+ export interface NavigateRequest {
10808
11937
  /**
10809
- * Remove listener from the emitter returned from init.
10810
- * @param event
10811
- * @param listener
10812
- * @param context
10813
- * @param once
11938
+ * Route to navigate to, or a history delta such as `1` or `-1`.
10814
11939
  */
10815
- off(event: AuthStatus, listener: (...args: any[]) => void, context: any, once: boolean): this;
11940
+ path: string | number;
10816
11941
  /**
10817
- * Remove all the event listeners
10818
- * @param event
11942
+ * When `true`, replaces the current history entry instead of pushing.
10819
11943
  */
10820
- removeAllListeners(event: AuthStatus): this;
11944
+ replace?: boolean;
10821
11945
  }
10822
11946
  /**
10823
- * Events which can be triggered on the emitter returned from {@link init}.
10824
- * @group Authentication / Init
11947
+ * Request payload for {@link HostEvent.SetActiveTab}.
10825
11948
  */
10826
- export declare enum AuthEvent {
11949
+ export interface SetActiveTabRequest {
10827
11950
  /**
10828
- * Manually trigger the SSO popup. This is useful when
10829
- * authStatus is SAMLRedirect/OIDCRedirect and inPopup is set to true
11951
+ * Id of the liveboard tab to make active.
10830
11952
  */
10831
- TRIGGER_SSO_POPUP = "TRIGGER_SSO_POPUP"
10832
- }
10833
- export interface LiveboardTab {
10834
- id: string;
10835
- name: string;
10836
- [key: string]: any;
10837
- }
10838
- export interface LiveboardGroup {
10839
- id: string;
10840
- name: string;
10841
- [key: string]: any;
11953
+ tabId: string;
10842
11954
  }
10843
11955
  /**
10844
- * Levels at which a filter or parameter can be applied.
10845
- */
10846
- export declare enum ApplicabilityLevel {
10847
- Liveboard = "LIVEBOARD",
10848
- Tab = "TAB",
10849
- Group = "GROUP"
10850
- }
10851
- /**
10852
- * Scopes a filter or parameter to a specific target.
10853
- * At `LIVEBOARD` level the filter applies to the whole Liveboard, so `targetId`
10854
- * is not required.
11956
+ * Typed request payloads for host events that do not go through the UI
11957
+ * passthrough pipeline (`HostEvent` member → request type; `void` = no payload).
11958
+ *
11959
+ * Shapes are transcribed from the host's runtime validation schemas
11960
+ * (embed-util HostEventContract) — what the ThoughtSpot app actually enforces —
11961
+ * flattened across contexts to the permissive superset (context-specific
11962
+ * requirements are validated at runtime).
11963
+ *
11964
+ * Responses are typed only for UI-passthrough-backed events today (see
11965
+ * {@link HostEventResponse}). Add a response map alongside this one when the
11966
+ * first explicit response shape is specified; tightening later is additive.
11967
+ *
11968
+ * Deliberately absent (do not add without an audit):
11969
+ * - DrillDown: the runtime schema (object-shaped points) and the UI
11970
+ * passthrough contract (string-shaped points) disagree — resolve the
11971
+ * drift first.
11972
+ * - GetAnswerSession/GetParameters/GetTML: typed via the UI passthrough
11973
+ * mapping; their Spotter-context vizId requirement is runtime-only.
10855
11974
  */
10856
- export interface Applicability {
10857
- level: ApplicabilityLevel;
10858
- targetId?: string;
10859
- }
10860
- export interface FilterUpdate {
10861
- column: string;
10862
- oper: string;
10863
- values: string[];
10864
- type?: string;
10865
- applicability?: Applicability;
10866
- }
10867
- export interface LiveboardFilter {
10868
- applicability?: Applicability;
10869
- [key: string]: any;
10870
- }
10871
- export interface LiveboardParameter {
10872
- applicability?: Applicability;
10873
- [key: string]: any;
10874
- }
10875
- export declare enum UIPassthroughEvent {
10876
- PinAnswerToLiveboard = "addVizToPinboard",
10877
- SaveAnswer = "saveAnswer",
10878
- GetDiscoverabilityStatus = "getDiscoverabilityStatus",
10879
- GetAvailableUIPassthroughs = "getAvailableUiPassthroughs",
10880
- GetAnswerConfig = "getAnswerPageConfig",
10881
- GetLiveboardConfig = "getPinboardPageConfig",
10882
- GetUnsavedAnswerTML = "getUnsavedAnswerTML",
10883
- UpdateFilters = "updateFilters",
10884
- Drilldown = "drillDown",
10885
- GetAnswerSession = "getAnswerSession",
10886
- GetFilters = "getFilters",
10887
- GetIframeUrl = "getIframeUrl",
10888
- GetParameters = "getParameters",
10889
- GetTML = "getTML",
10890
- GetTabs = "getTabs",
10891
- GetGroups = "getGroups",
10892
- GetExportRequestForCurrentPinboard = "getExportRequestForCurrentPinboard"
10893
- }
10894
- export type UIPassthroughContractBase = {
10895
- [UIPassthroughEvent.PinAnswerToLiveboard]: {
10896
- request: {
10897
- vizId?: string;
10898
- newVizName: string;
10899
- newVizDescription?: string;
10900
- liveboardId?: string;
10901
- tabId?: string;
10902
- newLiveboardName?: string;
10903
- newTabName?: string;
10904
- };
10905
- response: {
10906
- liveboardId: string;
10907
- tabId: string;
10908
- vizId: string;
10909
- };
10910
- };
10911
- [UIPassthroughEvent.SaveAnswer]: {
10912
- request: {
10913
- name: string;
10914
- description: string;
10915
- vizId?: string;
10916
- isDiscoverable?: boolean;
10917
- };
10918
- response: {
10919
- answerId: string;
10920
- saveResponse?: any;
10921
- shareResponse?: any;
10922
- };
10923
- };
10924
- [UIPassthroughEvent.GetDiscoverabilityStatus]: {
10925
- request: any;
10926
- response: {
10927
- shouldShowDiscoverability: boolean;
10928
- isDiscoverabilityCheckboxUnselectedPerOrg: boolean;
10929
- };
10930
- };
10931
- [UIPassthroughEvent.GetAvailableUIPassthroughs]: {
10932
- request: any;
10933
- response: {
10934
- keys: string[];
10935
- };
10936
- };
10937
- [UIPassthroughEvent.GetAnswerConfig]: {
10938
- request: {
10939
- vizId?: string;
10940
- };
10941
- response: any;
10942
- };
10943
- [UIPassthroughEvent.GetLiveboardConfig]: {
10944
- request: any;
10945
- response: any;
10946
- };
10947
- [UIPassthroughEvent.GetUnsavedAnswerTML]: {
10948
- request: {
10949
- sessionId?: string;
10950
- vizId?: string;
10951
- };
10952
- response: {
10953
- tml: string;
10954
- };
10955
- };
10956
- [UIPassthroughEvent.GetAnswerSession]: {
10957
- request: {
10958
- vizId?: string;
10959
- };
10960
- response: {
10961
- session: SessionInterface;
10962
- embedAnswerData?: Record<string, any>;
10963
- };
10964
- };
10965
- [UIPassthroughEvent.GetFilters]: {
10966
- request: {
10967
- vizId?: string;
10968
- };
10969
- response: {
10970
- liveboardFilters: LiveboardFilter[];
10971
- runtimeFilters: RuntimeFilter[];
10972
- };
10973
- };
10974
- [UIPassthroughEvent.GetIframeUrl]: {
10975
- request: Record<string, never>;
10976
- response: {
10977
- iframeUrl: string;
10978
- };
10979
- };
10980
- [UIPassthroughEvent.GetParameters]: {
10981
- request: Record<string, never>;
10982
- response: {
10983
- parameters: LiveboardParameter[];
10984
- };
10985
- };
10986
- [UIPassthroughEvent.GetTML]: {
10987
- request: {
10988
- vizId?: string;
10989
- includeNonExecutedSearchTokens?: boolean;
10990
- };
10991
- response: Record<string, any>;
10992
- };
10993
- [UIPassthroughEvent.GetTabs]: {
10994
- request: Record<string, never>;
10995
- response: {
10996
- orderedTabIds: string[];
10997
- numberOfTabs: number;
10998
- Tabs: LiveboardTab[];
10999
- };
11975
+ export interface HostEventRequestMap {
11976
+ [HostEvent.UpdateRuntimeFilters]: RuntimeFilter[];
11977
+ [HostEvent.UpdateParameters]: RuntimeParameter[];
11978
+ [HostEvent.UpdateFilters]: UpdateFiltersRequest;
11979
+ [HostEvent.UpdateCrossFilter]: UpdateCrossFilterRequest;
11980
+ [HostEvent.OpenFilter]: OpenFilterRequest;
11981
+ [HostEvent.OpenParameter]: OpenParameterRequest;
11982
+ [HostEvent.SetVisibleVizs]: string[];
11983
+ [HostEvent.SetVisibleTabs]: string[];
11984
+ [HostEvent.SetHiddenTabs]: string[];
11985
+ [HostEvent.SetActiveTab]: SetActiveTabRequest;
11986
+ [HostEvent.Navigate]: string | number | NavigateRequest;
11987
+ [HostEvent.Search]: SearchRequest;
11988
+ [HostEvent.ResetSearch]: void;
11989
+ [HostEvent.AddColumns]: {
11990
+ columnIds: string[];
11000
11991
  };
11001
- [UIPassthroughEvent.GetGroups]: {
11002
- request: Record<string, never>;
11003
- response: {
11004
- orderedGroupIds: string[];
11005
- numberOfGroups: number;
11006
- Groups: LiveboardGroup[];
11007
- };
11992
+ [HostEvent.RemoveColumn]: {
11993
+ columnId: string;
11008
11994
  };
11009
- [UIPassthroughEvent.GetExportRequestForCurrentPinboard]: {
11010
- request: Record<string, never>;
11011
- response: {
11012
- data: {
11013
- v2Content: string;
11014
- };
11015
- type: UIPassthroughEvent.GetExportRequestForCurrentPinboard;
11016
- };
11995
+ [HostEvent.Edit]: VizScopedRequest;
11996
+ [HostEvent.Save]: VizScopedRequest;
11997
+ [HostEvent.Delete]: VizScopedRequest;
11998
+ [HostEvent.Share]: VizScopedRequest;
11999
+ [HostEvent.Present]: VizScopedRequest;
12000
+ [HostEvent.CopyLink]: VizScopedRequest;
12001
+ [HostEvent.ExportTML]: VizScopedRequest;
12002
+ [HostEvent.EditTML]: VizScopedRequest;
12003
+ [HostEvent.UpdateTML]: VizScopedRequest;
12004
+ [HostEvent.SchedulesList]: VizScopedRequest;
12005
+ [HostEvent.Schedule]: VizScopedRequest;
12006
+ [HostEvent.SpotIQAnalyze]: VizScopedRequest;
12007
+ [HostEvent.ShowUnderlyingData]: VizScopedRequest;
12008
+ [HostEvent.CreateMonitor]: VizScopedRequest;
12009
+ [HostEvent.ManageMonitor]: VizScopedRequest;
12010
+ [HostEvent.SyncToSheets]: VizScopedRequest;
12011
+ [HostEvent.SyncToOtherApps]: VizScopedRequest;
12012
+ [HostEvent.ManagePipelines]: VizScopedRequest;
12013
+ [HostEvent.DownloadAsPng]: VizScopedRequest;
12014
+ [HostEvent.DownloadAsCsv]: VizScopedRequest;
12015
+ [HostEvent.DownloadAsXlsx]: VizScopedRequest;
12016
+ [HostEvent.DownloadAsPdf]: VizScopedRequest & {
12017
+ liveboardId?: string;
11017
12018
  };
11018
- [UIPassthroughEvent.UpdateFilters]: {
11019
- request: {
11020
- filter?: FilterUpdate;
11021
- filters?: FilterUpdate[];
11022
- };
11023
- response: unknown;
12019
+ [HostEvent.Explore]: RequiredVizRequest;
12020
+ [HostEvent.AskSage]: RequiredVizRequest;
12021
+ [HostEvent.AskSpotter]: RequiredVizRequest;
12022
+ [HostEvent.AnswerChartSwitcher]: RequiredVizRequest;
12023
+ [HostEvent.UpdatePersonalisedView]: Pick<PersonalisedViewRequest, "viewId">;
12024
+ [HostEvent.SelectPersonalizedView]: PersonalisedViewRequest;
12025
+ [HostEvent.ResetLiveboardPersonalisedView]: void;
12026
+ [HostEvent.AIHighlights]: void;
12027
+ [HostEvent.SendTestScheduleEmail]: ScheduleEmailRequest;
12028
+ [HostEvent.RefreshLiveboardBrowserCache]: ScheduleEmailRequest;
12029
+ [HostEvent.SpotterSearch]: SpotterSearchRequest;
12030
+ [HostEvent.ResetSpotterConversation]: void;
12031
+ [HostEvent.ShareSpotterConversation]: ConversationScopedRequest;
12032
+ [HostEvent.CloseSpotterShareConversation]: void;
12033
+ [HostEvent.ExitSpotterSharedConversation]: void;
12034
+ [HostEvent.PinSpotterConversation]: ConversationScopedRequest;
12035
+ [HostEvent.UnpinSpotterConversation]: ConversationScopedRequest;
12036
+ [HostEvent.EditLastPrompt]: string;
12037
+ [HostEvent.DeleteLastPrompt]: void;
12038
+ [HostEvent.PreviewSpotterData]: void;
12039
+ [HostEvent.SpotterVizSendUserMessage]: {
12040
+ query: string;
11024
12041
  };
11025
- [UIPassthroughEvent.Drilldown]: {
11026
- request: {
11027
- points: {
11028
- selectedPoints?: string[];
11029
- clickedPoint?: string;
11030
- };
11031
- columnGuid?: string;
11032
- autoDrillDown?: boolean;
11033
- vizId?: string;
11034
- };
11035
- response: unknown;
12042
+ [HostEvent.InitSpotterVizConversation]: void;
12043
+ [HostEvent.OpenSpotterVizPanel]: void;
12044
+ [HostEvent.CloseSpotterVizPanel]: void;
12045
+ }
12046
+ /**
12047
+ * Per-context request shapes for events whose payload varies by
12048
+ /**
12049
+ * Resolves the typed request payload for a host event.
12050
+ * Resolution order:
12051
+ * 1. Explicitly typed request in {@link HostEventRequestMap}
12052
+ * 2. UI passthrough backed contract ({@link EmbedApiHostEventMapping})
12053
+ * 3. `any` (event not audited/typed yet — backward compatible)
12054
+ *
12055
+ * Requests are the cross-context superset today. The per-context `*Request`
12056
+ * interfaces (e.g. {@link OpenFilterLiveboardRequest}) document how the shape
12057
+ * narrows by context; a later release may thread the caller's context to
12058
+ * enforce it.
12059
+ */
12060
+ export type HostEventRequest<HostEventT extends HostEvent> = HostEventT extends keyof HostEventRequestMap ? HostEventRequestMap[HostEventT] : HostEventT extends keyof EmbedApiHostEventMapping ? UIPassthroughRequest<EmbedApiHostEventMapping[HostEventT]> : any;
12061
+ /**
12062
+ * Resolves the typed response payload for a host event. Only UI passthrough
12063
+ * backed events have typed responses today; everything else resolves to `any`.
12064
+ */
12065
+ export type HostEventResponse<HostEventT extends HostEvent, ContextT extends ContextType = ContextType> = HostEventT extends keyof EmbedApiHostEventMapping ? UIPassthroughResponse<EmbedApiHostEventMapping[HostEventT]> : any;
12066
+ /**
12067
+ * Payload type accepted by `embed.trigger()`. Keeps the historical
12068
+ * `PayloadT` escape hatch so untyped existing call sites keep compiling.
12069
+ */
12070
+ export type TriggerPayload<PayloadT, HostEventT extends HostEvent> = PayloadT | HostEventRequest<HostEventT>;
12071
+ /**
12072
+ * Deep `Partial` of a request type: every field optional at every depth, with no
12073
+ * index signature — so object literals carrying unknown fields are flagged.
12074
+ */
12075
+ export type DeepPartial<T> = T extends (infer U)[] ? DeepPartial<U>[] : T extends object ? {
12076
+ [K in keyof T]?: DeepPartial<T[K]>;
12077
+ } : T;
12078
+ /**
12079
+ * `trigger()`'s `data` type: an all-optional view of the event's request type.
12080
+ * See {@link HostEventRequest} and the `*Request` interfaces, e.g. {@link SearchRequest}.
12081
+ * No-payload events take `{}`. SDK 1.54.0 makes this strict (required fields enforced).
12082
+ */
12083
+ export type TriggerData<HostEventT extends HostEvent> = HostEventRequest<HostEventT> extends void ? Record<string, never> : DeepPartial<HostEventRequest<HostEventT>>;
12084
+ /**
12085
+ * Response type returned by `embed.trigger()`.
12086
+ */
12087
+ export type TriggerResponse<PayloadT, HostEventT extends HostEvent, ContextT extends ContextType = ContextType> = PayloadT extends HostEventRequest<HostEventT> ? HostEventResponse<HostEventT, ContextT> : any;
12088
+ /**
12089
+ * Typed `data` field per embed event. Seed with audited events only.
12090
+ */
12091
+ export interface EmbedEventDataExtension {
12092
+ [EmbedEvent.AuthInit]: {
12093
+ /**
12094
+ * Whether authentication was successful.
12095
+ */
12096
+ isLoggedIn?: boolean;
12097
+ [key: string]: any;
11036
12098
  };
12099
+ [EmbedEvent.EmbedListenerReady]: Record<string, any>;
12100
+ /**
12101
+ * Fired when a callback-type custom action is triggered. Use
12102
+ * `payload.data.id` to identify which action fired.
12103
+ */
12104
+ [EmbedEvent.CustomAction]: CustomActionPayload;
12105
+ }
12106
+ /**
12107
+ * Resolves the typed `data` payload for an embed event; `any` when the
12108
+ * event has not been audited/typed yet.
12109
+ */
12110
+ export type EmbedEventData<EmbedEventT extends EmbedEvent> = EmbedEventT extends keyof EmbedEventDataExtension ? EmbedEventDataExtension[EmbedEventT] : any;
12111
+ /**
12112
+ * Full envelope delivered to `embed.on()` callbacks for a given event:
12113
+ * the wire fields (`type`, `status`) plus the typed `data`.
12114
+ */
12115
+ export type EmbedEventPayload<EmbedEventT extends EmbedEvent> = Omit<MessagePayload, "data"> & {
12116
+ data: EmbedEventData<EmbedEventT>;
11037
12117
  };
11038
- export type UIPassthroughRequest<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["request"];
11039
- export type UIPassthroughResponse<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["response"];
11040
- export type UIPassthroughArrayResponse<ApiName extends keyof UIPassthroughContractBase> = Array<{
11041
- refId?: string;
11042
- value?: UIPassthroughResponse<ApiName>;
11043
- error?: any;
11044
- }>;
11045
- export type EmbedApiHostEventMapping = {
11046
- [HostEvent.Pin]: UIPassthroughEvent.PinAnswerToLiveboard;
11047
- [HostEvent.SaveAnswer]: UIPassthroughEvent.SaveAnswer;
11048
- [HostEvent.GetAnswerSession]: UIPassthroughEvent.GetAnswerSession;
11049
- [HostEvent.GetFilters]: UIPassthroughEvent.GetFilters;
11050
- [HostEvent.GetIframeUrl]: UIPassthroughEvent.GetIframeUrl;
11051
- [HostEvent.GetParameters]: UIPassthroughEvent.GetParameters;
11052
- [HostEvent.GetTML]: UIPassthroughEvent.GetTML;
11053
- [HostEvent.GetTabs]: UIPassthroughEvent.GetTabs;
11054
- [HostEvent.GetGroups]: UIPassthroughEvent.GetGroups;
11055
- [HostEvent.getExportRequestForCurrentPinboard]: UIPassthroughEvent.GetExportRequestForCurrentPinboard;
11056
- };
11057
- export type HostEventRequest<HostEventT extends HostEvent> = HostEventT extends keyof EmbedApiHostEventMapping ? UIPassthroughRequest<EmbedApiHostEventMapping[HostEventT]> : any;
11058
- export type HostEventResponse<HostEventT extends HostEvent, ContextT extends ContextType> = HostEventT extends keyof EmbedApiHostEventMapping ? UIPassthroughResponse<EmbedApiHostEventMapping[HostEventT]> : any;
11059
- export type TriggerPayload<PayloadT, HostEventT extends HostEvent> = PayloadT | HostEventRequest<HostEventT>;
11060
- export type TriggerResponse<PayloadT, HostEventT extends HostEvent, ContextT extends ContextType> = PayloadT extends HostEventRequest<HostEventT> ? HostEventResponse<HostEventT, ContextT> : any;
11061
12118
  declare class HostEventClient {
11062
12119
  iFrame: HTMLIFrameElement;
11063
12120
  /** Cached list of available UI passthrough keys from the embedded app */
@@ -11107,7 +12164,7 @@ declare class HostEventClient {
11107
12164
  * @param payload - Optional payload for the event
11108
12165
  * @param context - Optional context (e.g. vizId) for scoped operations
11109
12166
  */
11110
- triggerHostEvent<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(hostEvent: HostEventT, payload?: TriggerPayload<PayloadT, HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextType>>;
12167
+ triggerHostEvent<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(hostEvent: HostEventT, payload?: TriggerPayload<PayloadT, HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextT>>;
11111
12168
  }
11112
12169
  declare class TsEmbed {
11113
12170
  /**
@@ -11125,6 +12182,7 @@ declare class TsEmbed {
11125
12182
  * The key to store the embed instance in the DOM node
11126
12183
  */
11127
12184
  protected embedNodeKey: string;
12185
+ protected embedContainerLoadedKey: string;
11128
12186
  protected isAppInitialized: boolean;
11129
12187
  /**
11130
12188
  * A reference to the iframe within which the ThoughtSpot app
@@ -11294,10 +12352,10 @@ declare class TsEmbed {
11294
12352
  */
11295
12353
  protected getEmbedBasePath(query: string): string;
11296
12354
  protected getUpdateEmbedParamsObject(): Promise<{
11297
- customisations: CustomisationsInterface;
11298
- authToken: string;
11299
12355
  runtimeFilterParams: string;
11300
12356
  runtimeParameterParams: string;
12357
+ customisations: CustomisationsInterface;
12358
+ authToken: string;
11301
12359
  hiddenHomepageModules: HomepageModule[];
11302
12360
  reorderedHomepageModules: string[];
11303
12361
  hostConfig: Record<string, any>;
@@ -11393,9 +12451,10 @@ declare class TsEmbed {
11393
12451
  protected getRootIframeSrc(): string;
11394
12452
  protected createIframeEl(frameSrc: string): HTMLIFrameElement;
11395
12453
  /**
11396
- * Returns a merged {@link PreRenderConfig} object where each shared key
11397
- * prefers `preRenderConfig.key` over the top-level `viewConfig.key` for
11398
- * backward compatibility.
12454
+ * Returns a merged {@link PreRenderConfig} object where each key prefers the
12455
+ * value from `preRenderConfig` over its deprecated top-level `viewConfig`
12456
+ * counterpart (`id`/`preRenderId`, `containerSelector`/`preRenderContainer`,
12457
+ * `doNotTrackSize`/`doNotTrackPreRenderSize`) for backward compatibility.
11399
12458
  */
11400
12459
  protected getPreRenderConfig(): PreRenderConfig;
11401
12460
  /**
@@ -11489,21 +12548,6 @@ declare class TsEmbed {
11489
12548
  * or else the v2 event type itself
11490
12549
  */
11491
12550
  protected getCompatibleEventType(eventType: EmbedEvent): EmbedEvent;
11492
- /**
11493
- * Calculates the iframe center for the current visible viewPort
11494
- * of iframe using Scroll position of Host App, offsetTop for iframe
11495
- * in Host app. ViewPort height of the tab.
11496
- * @returns iframe Center in visible viewport,
11497
- * Iframe height,
11498
- * View port height.
11499
- */
11500
- protected getIframeCenter(): {
11501
- iframeCenter: number;
11502
- iframeScrolled: number;
11503
- iframeHeight: number;
11504
- viewPortHeight: number;
11505
- iframeVisibleViewPort: number;
11506
- };
11507
12551
  /**
11508
12552
  * Registers an event listener to trigger an alert when the ThoughtSpot app
11509
12553
  * sends an event of a particular message type to the host application.
@@ -11527,7 +12571,7 @@ declare class TsEmbed {
11527
12571
  * });
11528
12572
  * ```
11529
12573
  */
11530
- on(messageType: EmbedEvent, callback: MessageCallback, options?: MessageOptions, isRegisteredBySDK?: boolean): typeof TsEmbed.prototype;
12574
+ on<EmbedEventT extends EmbedEvent>(messageType: EmbedEventT, callback: (payload: EmbedEventPayload<EmbedEventT>, responder?: (data: any) => void) => void, options?: MessageOptions, isRegisteredBySDK?: boolean): typeof TsEmbed.prototype;
11531
12575
  /**
11532
12576
  * Removes an event listener for a particular event type.
11533
12577
  * @param messageType The message type
@@ -11563,6 +12607,8 @@ declare class TsEmbed {
11563
12607
  */
11564
12608
  private embedContainerReadyCallbacks;
11565
12609
  protected getPreRenderObj<T extends TsEmbed>(): T;
12610
+ protected takeOverPreRender(): void;
12611
+ private markEmbedContainerLoaded;
11566
12612
  private checkEmbedContainerLoaded;
11567
12613
  private executeEmbedContainerReadyCallbacks;
11568
12614
  /**
@@ -11573,8 +12619,12 @@ declare class TsEmbed {
11573
12619
  protected createEmbedContainerHandler: (source: EmbedEvent.AuthInit | EmbedEvent.EmbedListenerReady) => () => void;
11574
12620
  /**
11575
12621
  * Triggers an event to the embedded app
12622
+ *
12623
+ * Payload typing: from SDK 1.52.0 (ThoughtSpot Cloud 26.9.0.cl), unknown fields
12624
+ * on a known event's payload fail to compile. From SDK 1.54.0 (26.11.0.cl) the
12625
+ * payload is checked strictly against the event contract — update call sites now.
11576
12626
  * @param {HostEvent} messageType The event type
11577
- * @param {any} data The payload to send with the message
12627
+ * @param {TriggerData} data The payload, typed against the event's contract
11578
12628
  * @param {ContextType} context Optional context type to specify the context from which the event is triggered.
11579
12629
  * Use ContextType.Search for search answer context, ContextType.Answer for answer/explore context,
11580
12630
  * ContextType.Liveboard for liveboard context, or ContextType.Spotter for spotter context.
@@ -11591,7 +12641,7 @@ declare class TsEmbed {
11591
12641
  * ```
11592
12642
  * @version SDK: 1.45.2 | ThoughtSpot: 26.3.0.cl (for context parameter)
11593
12643
  */
11594
- trigger<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(messageType: HostEventT, data?: TriggerPayload<PayloadT, HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextT>>;
12644
+ trigger<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(messageType: HostEventT, data?: TriggerData<HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextT>>;
11595
12645
  /**
11596
12646
  * Triggers an event to the embedded app, skipping the UI flow.
11597
12647
  * @param {UIPassthroughEvent} apiName - The name of the API to be triggered.
@@ -11693,6 +12743,7 @@ declare class TsEmbed {
11693
12743
  * @returns
11694
12744
  */
11695
12745
  prerenderGeneric(): Promise<any>;
12746
+ protected preRenderParamsApplied: Promise<void>;
11696
12747
  protected beforePrerenderVisible(): void;
11697
12748
  /**
11698
12749
  * Displays the pre-rendered component inside the host element.
@@ -11771,7 +12822,7 @@ declare class V1Embed extends TsEmbed {
11771
12822
  * });
11772
12823
  * ```
11773
12824
  */
11774
- on(messageType: EmbedEvent, callback: MessageCallback, options?: MessageOptions): typeof TsEmbed.prototype;
12825
+ on<EmbedEventT extends EmbedEvent>(messageType: EmbedEventT, callback: (payload: EmbedEventPayload<EmbedEventT>, responder?: (data: any) => void) => void, options?: MessageOptions): typeof TsEmbed.prototype;
11775
12826
  /**
11776
12827
  * Only for testing purposes.
11777
12828
  * @hidden
@@ -11933,6 +12984,20 @@ export interface SearchViewConfig extends SearchLiveboardCommonViewConfig, Omit<
11933
12984
  * ```
11934
12985
  */
11935
12986
  dataSource?: string;
12987
+ /**
12988
+ * If set to `true`, the answer edit panel is hidden.
12989
+ *
12990
+ * Supported embed types: `SearchEmbed`
12991
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
12992
+ * @example
12993
+ * ```js
12994
+ * const embed = new SearchEmbed('#tsEmbed', {
12995
+ * ... // other embed view config
12996
+ * hideAnswerEditPanel: true,
12997
+ * })
12998
+ * ```
12999
+ */
13000
+ hideAnswerEditPanel?: boolean;
11936
13001
  /**
11937
13002
  * The initial search query to load the answer with.
11938
13003
  * Use {@link searchOptions} instead.
@@ -12449,7 +13514,7 @@ export interface SpotterShareConversationConfig {
12449
13514
  }
12450
13515
  /**
12451
13516
  * A single starter prompt question shown under a category pill.
12452
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
13517
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
12453
13518
  * @group Embed components
12454
13519
  */
12455
13520
  export interface StarterPromptQuestion {
@@ -12467,7 +13532,7 @@ export interface StarterPromptQuestion {
12467
13532
  /**
12468
13533
  * Configuration for a starter prompt category with questions
12469
13534
  * (`quick` and `research`).
12470
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
13535
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
12471
13536
  * @group Embed components
12472
13537
  */
12473
13538
  export interface StarterPromptCategory {
@@ -12485,7 +13550,7 @@ export interface StarterPromptCategory {
12485
13550
  /**
12486
13551
  * Configuration for the Data Literacy starter prompt category.
12487
13552
  * Only the label is customizable; the prompt text comes from the backend.
12488
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
13553
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
12489
13554
  * @group Embed components
12490
13555
  */
12491
13556
  export interface StarterPreviewDataCategory {
@@ -12503,7 +13568,7 @@ export interface StarterPreviewDataCategory {
12503
13568
  * Note: this controls the Spotter chat interface only. The starter prompts on
12504
13569
  * the Liveboard SpotterViz surface are configured separately through
12505
13570
  * {@link SpotterVizConfig.customStarterPrompts}.
12506
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
13571
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
12507
13572
  * @group Embed components
12508
13573
  */
12509
13574
  export interface StarterPromptsConfig {
@@ -12583,7 +13648,7 @@ export interface SpotterChatViewConfig {
12583
13648
  * `Action.DeepAnalysisPill` and `Action.DataLiteracyPill`.
12584
13649
  *
12585
13650
  * Supported embed types: `SpotterEmbed`, `LiveboardEmbed`, `AppEmbed`
12586
- * @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
13651
+ * @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
12587
13652
  * @example
12588
13653
  * ```js
12589
13654
  * const embed = new SpotterEmbed('#tsEmbed', {
@@ -13309,7 +14374,7 @@ export interface DiscoveryExperience {
13309
14374
  * The view configuration for full app embedding.
13310
14375
  * @group Embed components
13311
14376
  */
13312
- export interface AppViewConfig extends AllEmbedViewConfig {
14377
+ export interface AppViewConfig extends AllEmbedViewConfig, FullHeightViewConfig {
13313
14378
  /**
13314
14379
  * If true, the top navigation bar within the ThoughtSpot app
13315
14380
  * is displayed. By default, the navigation bar is hidden.
@@ -13594,34 +14659,6 @@ export interface AppViewConfig extends AllEmbedViewConfig {
13594
14659
  * ```
13595
14660
  */
13596
14661
  enableSearchAssist?: boolean;
13597
- /**
13598
- * If set to true, the Liveboard container dynamically resizes
13599
- * according to the height of the Liveboard.
13600
- *
13601
- * **Note**: Using fullHeight loads all visualizations
13602
- * on the Liveboard simultaneously, which results in
13603
- * multiple warehouse queries and potentially a
13604
- * longer wait for the topmost visualizations to
13605
- * display on the screen. Setting fullHeight to
13606
- * `false` fetches visualizations incrementally as
13607
- * users scroll the page to view the charts and tables.
13608
- *
13609
- * From SDK 1.52.0, enabling `fullHeight` also turns on
13610
- * {@link lazyLoadingForFullHeight} and
13611
- * {@link enableScrollableContainerLazyLoading}, so visualizations load as
13612
- * they scroll into view. Set either flag to `false` to opt out.
13613
- *
13614
- * Supported embed types: `AppEmbed`
13615
- * @version SDK: 1.21.0 | ThoughtSpot: 9.4.0.cl, 9.4.0-sw
13616
- * @example
13617
- * ```js
13618
- * const embed = new AppEmbed('#tsEmbed', {
13619
- * ... // other embed view config
13620
- * fullHeight: true,
13621
- * })
13622
- * ```
13623
- */
13624
- fullHeight?: boolean;
13625
14662
  /**
13626
14663
  * Enables the V2 navigation and modular home page experience.
13627
14664
  * For more information,
@@ -13816,78 +14853,6 @@ export interface AppViewConfig extends AllEmbedViewConfig {
13816
14853
  * ```
13817
14854
  */
13818
14855
  isGranularXLSXCSVSchedulesEnabled?: boolean;
13819
- /**
13820
- * Loads visualizations only as they scroll into the viewport, instead of
13821
- * loading the whole full-height Liveboard at once.
13822
- *
13823
- * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
13824
- * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
13825
- * set explicitly. Set it to `false` to load every visualization upfront.
13826
- * The flag has no effect unless `fullHeight` is enabled.
13827
- *
13828
- * @type {boolean}
13829
- * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
13830
- * @default true when `fullHeight` is enabled, from SDK 1.52.0
13831
- * @example
13832
- * ```js
13833
- * const embed = new AppEmbed('#embed-container', {
13834
- * // ...other options
13835
- * fullHeight: true,
13836
- * lazyLoadingForFullHeight: true,
13837
- * })
13838
- * ```
13839
- */
13840
- lazyLoadingForFullHeight?: boolean;
13841
- /**
13842
- * Computes the visible region of the embed against its scrollable and
13843
- * clipping ancestors, instead of treating the browser window as the only
13844
- * viewport, and tracks scroll and resize on those ancestors.
13845
- *
13846
- * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
13847
- * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
13848
- * set explicitly. Set it to `false` when the page scrolls with the window
13849
- * and the embed has no clipping ancestor, to skip the extra ancestor
13850
- * tracking.
13851
- *
13852
- * @type {boolean}
13853
- * @default true when `fullHeight` is enabled, from SDK 1.52.0
13854
- * @hidden
13855
- */
13856
- enableScrollableContainerLazyLoading?: boolean;
13857
- /**
13858
- * How far outside the viewport a visualization starts loading, when
13859
- * {@link lazyLoadingForFullHeight} is enabled.
13860
- *
13861
- * For example, if the margin is set to '10px',
13862
- * the visualization will be loaded 10px before its top edge is visible in the
13863
- * viewport.
13864
- *
13865
- * The format is similar to CSS margin, so `'500px 0px'` extends the
13866
- * prefetch 500px above and below the viewport and not sideways. Accepted
13867
- * units are `px`, `em`, `rem`, `%`, `vh` and `vw`, plus bare `0` and
13868
- * `auto`; an invalid value is logged and ignored.
13869
- *
13870
- * From SDK 1.52.0 this defaults to `'500px 0px'` — roughly one
13871
- * visualization ahead of the scroll position, so a chart has usually
13872
- * finished loading by the time it scrolls into view. Use a smaller margin
13873
- * to cut warehouse queries further, or `'0px'` to load a visualization
13874
- * only once it is actually visible.
13875
- *
13876
- * @type {string}
13877
- * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
13878
- * @default '500px 0px' when `fullHeight` is enabled, from SDK 1.52.0
13879
- * @example
13880
- * ```js
13881
- * const embed = new AppEmbed('#embed-container', {
13882
- * // ...other options
13883
- * fullHeight: true,
13884
- * lazyLoadingForFullHeight: true,
13885
- * // Using 0px, the visualization will be only loaded when it's visible in the viewport.
13886
- * lazyLoadingMargin: '0px',
13887
- * })
13888
- * ```
13889
- */
13890
- lazyLoadingMargin?: string;
13891
14856
  /**
13892
14857
  * updatedSpotterChatPrompt : Controls the updated spotter chat prompt.
13893
14858
  *
@@ -14075,23 +15040,6 @@ export interface AppViewConfig extends AllEmbedViewConfig {
14075
15040
  * @default false
14076
15041
  */
14077
15042
  enableStopAnswerGenerationEmbed?: boolean;
14078
- /**
14079
- * This is the minimum height (in pixels) for a full-height App.
14080
- * Setting this height helps resolve issues with empty Apps and
14081
- * other screens navigable from an App.
14082
- *
14083
- * @version SDK: 1.44.2 | ThoughtSpot: 10.15.0.cl
14084
- * @default 500
14085
- * @example
14086
- * ```js
14087
- * const embed = new AppEmbed('#embed', {
14088
- * ... // other app view config
14089
- * fullHeight: true,
14090
- * minimumHeight: 600,
14091
- * });
14092
- * ```
14093
- */
14094
- minimumHeight?: number;
14095
15043
  /**
14096
15044
  * To enable the homepage announcement banner.
14097
15045
  * Controls the visibility of the announcement section
@@ -14141,6 +15089,20 @@ export interface AppViewConfig extends AllEmbedViewConfig {
14141
15089
  * ```
14142
15090
  */
14143
15091
  updatedSpotterExperience?: boolean;
15092
+ /**
15093
+ * If set to `true`, the answer edit panel is hidden.
15094
+ *
15095
+ * Supported embed types: `AppEmbed`
15096
+ * @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
15097
+ * @example
15098
+ * ```js
15099
+ * const embed = new AppEmbed('#tsEmbed', {
15100
+ * ... // other embed view config
15101
+ * hideAnswerEditPanel: true,
15102
+ * })
15103
+ * ```
15104
+ */
15105
+ hideAnswerEditPanel?: boolean;
14144
15106
  }
14145
15107
  /**
14146
15108
  * APP_INIT data shape for AppEmbed.
@@ -14156,9 +15118,7 @@ export interface AppEmbedAppInitData extends DefaultAppInitData {
14156
15118
  }
14157
15119
  declare class AppEmbed extends V1Embed {
14158
15120
  protected viewConfig: AppViewConfig;
14159
- private defaultHeight;
14160
- private lazyLoadScrollContainers;
14161
- private lazyLoadResizeObserver;
15121
+ private readonly fullHeightController?;
14162
15122
  constructor(domSelector: DOMSelector, viewConfig: AppViewConfig);
14163
15123
  /**
14164
15124
  * Extends the default APP_INIT payload with `embedParams.spotterSidebarConfig`
@@ -14179,27 +15139,11 @@ declare class AppEmbed extends V1Embed {
14179
15139
  */
14180
15140
  protected getEmbedParams(): string;
14181
15141
  protected getEmbedParamsObject(): any;
14182
- private sendFullHeightLazyLoadData;
14183
- /**
14184
- * This is a handler for the RequestVisibleEmbedCoordinates event.
14185
- * It is used to send the visible coordinates data to the host application.
14186
- * @param data The event payload
14187
- * @param responder The responder function
14188
- */
14189
- private requestVisibleEmbedCoordinatesHandler;
14190
15142
  /**
14191
15143
  * Constructs the URL of the ThoughtSpot app page to be rendered.
14192
15144
  * @param pageId The ID of the page to be embedded.
14193
15145
  */
14194
15146
  getIFrameSrc(): string;
14195
- /**
14196
- * Set the iframe height as per the computed height received
14197
- * from the ThoughtSpot app.
14198
- * @param data The event payload
14199
- */
14200
- protected updateIFrameHeight: (data: MessagePayload) => void;
14201
- private embedIframeCenter;
14202
- private setIframeHeightForNonEmbedLiveboard;
14203
15147
  /**
14204
15148
  * Gets the ThoughtSpot route of the page for a particular page ID.
14205
15149
  * @param pageId The identifier for a page in the ThoughtSpot app.
@@ -14230,8 +15174,6 @@ declare class AppEmbed extends V1Embed {
14230
15174
  */
14231
15175
  destroy(): void;
14232
15176
  private postRender;
14233
- private registerLazyLoadEvents;
14234
- private unregisterLazyLoadEvents;
14235
15177
  /**
14236
15178
  * Renders the embedded application pages in the ThoughtSpot app.
14237
15179
  * @param renderOptions An object containing the page ID
@@ -14253,71 +15195,7 @@ export interface LiveboardEmbedAppInitData extends DefaultAppInitData {
14253
15195
  * The configuration for the embedded Liveboard or visualization page view.
14254
15196
  * @group Embed components
14255
15197
  */
14256
- export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardCommonViewConfig, LiveboardAppEmbedViewConfig {
14257
- /**
14258
- * If set to true, the embedded object container dynamically resizes
14259
- * according to the height of the Liveboard.
14260
- *
14261
- * **Note**: Using fullHeight loads all visualizations on the
14262
- * Liveboard simultaneously, which results in multiple warehouse
14263
- * queries and potentially a longer wait for the topmost
14264
- * visualizations to display on the screen.
14265
- * Setting `fullHeight` to `false` fetches visualizations
14266
- * incrementally as users scroll the page to view the charts and tables.
14267
- *
14268
- * From SDK 1.52.0, enabling `fullHeight` also turns on
14269
- * {@link lazyLoadingForFullHeight} and
14270
- * {@link enableScrollableContainerLazyLoading}, so visualizations load as
14271
- * they scroll into view. Set either flag to `false` to opt out.
14272
- *
14273
- *
14274
- * Supported embed types: `LiveboardEmbed`
14275
- * @version SDK: 1.1.0 | ThoughtSpot: ts7.may.cl, 7.2.1
14276
- * @example
14277
- * ```js
14278
- * const embed = new LiveboardEmbed('#embed', {
14279
- * ... // other liveboard view config
14280
- * fullHeight: true,
14281
- * });
14282
- * ```
14283
- */
14284
- fullHeight?: boolean;
14285
- /**
14286
- * This is the minimum height (in pixels) for a full-height Liveboard.
14287
- * Setting this height helps resolve issues with empty Liveboards and
14288
- * other screens navigable from a Liveboard.
14289
- *
14290
- * Supported embed types: `LiveboardEmbed`
14291
- * @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
14292
- * @deprecated Use `minimumHeight` instead.
14293
- * @default 500
14294
- * @example
14295
- * ```js
14296
- * const embed = new LiveboardEmbed('#embed', {
14297
- * ... // other liveboard view config
14298
- * fullHeight: true,
14299
- * defaultHeight: 600,
14300
- * });
14301
- * ```
14302
- */
14303
- defaultHeight?: number;
14304
- /**
14305
- * This is the minimum height (in pixels) for a full-height Liveboard.
14306
- * Setting this height helps resolve issues with empty Liveboards and
14307
- * other screens navigable from a Liveboard.
14308
- *
14309
- * @version SDK: 1.44.2 | ThoughtSpot: 10.15.0.cl
14310
- * @default 500
14311
- * @example
14312
- * ```js
14313
- * const embed = new LiveboardEmbed('#embed', {
14314
- * ... // other liveboard view config
14315
- * fullHeight: true,
14316
- * minimumHeight: 600,
14317
- * });
14318
- * ```
14319
- */
14320
- minimumHeight?: number;
15198
+ export interface LiveboardViewConfig extends BaseViewConfig, FullHeightViewConfig, SearchLiveboardCommonViewConfig, LiveboardAppEmbedViewConfig {
14321
15199
  /**
14322
15200
  * If set to true, the context menu in visualizations will be enabled.
14323
15201
  * @version SDK: 1.1.0 | ThoughtSpot: 8.1.0.sw
@@ -14661,77 +15539,6 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
14661
15539
  * ```
14662
15540
  */
14663
15541
  isGranularXLSXCSVSchedulesEnabled?: boolean;
14664
- /**
14665
- * Loads visualizations only as they scroll into the viewport, instead of
14666
- * loading the whole full-height Liveboard at once.
14667
- *
14668
- * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
14669
- * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
14670
- * set explicitly. Set it to `false` to load every visualization upfront.
14671
- * The flag has no effect unless `fullHeight` is enabled.
14672
- *
14673
- * @type {boolean}
14674
- * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
14675
- * @default true when `fullHeight` is enabled, from SDK 1.52.0
14676
- * @example
14677
- * ```js
14678
- * const embed = new LiveboardEmbed('#embed-container', {
14679
- * // ...other options
14680
- * fullHeight: true,
14681
- * lazyLoadingForFullHeight: true,
14682
- * })
14683
- * ```
14684
- */
14685
- lazyLoadingForFullHeight?: boolean;
14686
- /**
14687
- * Computes the visible region of the embed against its scrollable and
14688
- * clipping ancestors, instead of treating the browser window as the only
14689
- * viewport, and tracks scroll and resize on those ancestors.
14690
- *
14691
- * From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
14692
- * `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
14693
- * set explicitly. Set it to `false` when the page scrolls with the window
14694
- * and the embed has no clipping ancestor, to skip the extra ancestor
14695
- * tracking.
14696
- *
14697
- * @type {boolean}
14698
- * @default true when `fullHeight` is enabled, from SDK 1.52.0
14699
- */
14700
- enableScrollableContainerLazyLoading?: boolean;
14701
- /**
14702
- * How far outside the viewport a visualization starts loading, when
14703
- * {@link lazyLoadingForFullHeight} is enabled.
14704
- *
14705
- * For example, if the margin is set to '10px',
14706
- * the visualization will be loaded 10px before its top edge is visible in the
14707
- * viewport.
14708
- *
14709
- * The format is similar to CSS margin, so `'500px 0px'` extends the
14710
- * prefetch 500px above and below the viewport and not sideways. Accepted
14711
- * units are `px`, `em`, `rem`, `%`, `vh` and `vw`, plus bare `0` and
14712
- * `auto`; an invalid value is logged and ignored.
14713
- *
14714
- * From SDK 1.52.0 this defaults to `'500px 0px'` — roughly one
14715
- * visualization ahead of the scroll position, so a chart has usually
14716
- * finished loading by the time it scrolls into view. Use a smaller margin
14717
- * to cut warehouse queries further, or `'0px'` to load a visualization
14718
- * only once it is actually visible.
14719
- *
14720
- * @type {string}
14721
- * @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
14722
- * @default '500px 0px' when `fullHeight` is enabled, from SDK 1.52.0
14723
- * @example
14724
- * ```js
14725
- * const embed = new LiveboardEmbed('#embed-container', {
14726
- * // ...other options
14727
- * fullHeight: true,
14728
- * lazyLoadingForFullHeight: true,
14729
- * // Using 0px, the visualization will be only loaded when it's visible in the viewport.
14730
- * lazyLoadingMargin: '0px',
14731
- * })
14732
- * ```
14733
- */
14734
- lazyLoadingMargin?: string;
14735
15542
  /**
14736
15543
  * showSpotterLimitations : show limitation text
14737
15544
  * of the spotter underneath the chat input.
@@ -14870,9 +15677,7 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
14870
15677
  }
14871
15678
  declare class LiveboardEmbed extends V1Embed {
14872
15679
  protected viewConfig: LiveboardViewConfig;
14873
- private defaultHeight;
14874
- private lazyLoadScrollContainers;
14875
- private lazyLoadResizeObserver;
15680
+ private readonly fullHeightController?;
14876
15681
  constructor(domSelector: DOMSelector, viewConfig: LiveboardViewConfig);
14877
15682
  protected getAppInitData(): Promise<LiveboardEmbedAppInitData>;
14878
15683
  /**
@@ -14882,27 +15687,11 @@ declare class LiveboardEmbed extends V1Embed {
14882
15687
  protected getEmbedParams(): string;
14883
15688
  protected getEmbedParamsObject(): any;
14884
15689
  private getIframeSuffixSrc;
14885
- private sendFullHeightLazyLoadData;
14886
- /**
14887
- * This is a handler for the RequestVisibleEmbedCoordinates event.
14888
- * It is used to send the visible coordinates data to the host application.
14889
- * @param data The event payload
14890
- * @param responder The responder function
14891
- */
14892
- private requestVisibleEmbedCoordinatesHandler;
14893
15690
  /**
14894
15691
  * Construct the URL of the embedded ThoughtSpot Liveboard or visualization
14895
15692
  * to be loaded within the iFrame.
14896
15693
  */
14897
15694
  private getIFrameSrc;
14898
- /**
14899
- * Set the iframe height as per the computed height received
14900
- * from the ThoughtSpot app.
14901
- * @param data The event payload
14902
- */
14903
- private updateIFrameHeight;
14904
- private embedIframeCenter;
14905
- private setIframeHeightForNonEmbedLiveboard;
14906
15695
  private setActiveTab;
14907
15696
  private showPreviewLoader;
14908
15697
  /**
@@ -14917,22 +15706,23 @@ declare class LiveboardEmbed extends V1Embed {
14917
15706
  personalizedViewId: string;
14918
15707
  };
14919
15708
  protected beforePrerenderVisible(): void;
15709
+ private isShowingLiveboardRoute;
14920
15710
  protected handleRenderForPrerender(): Promise<TsEmbed>;
14921
15711
  /**
14922
15712
  * Triggers an event to the embedded app
15713
+ * Payload typing follows {@link TsEmbed.trigger}: unknown fields fail to compile
15714
+ * from SDK 1.52.0; strict contract checks land in SDK 1.54.0.
14923
15715
  * @param {HostEvent} messageType The event type
14924
- * @param {any} data The payload to send with the message
15716
+ * @param {TriggerData} data The payload, typed against the event's contract
14925
15717
  * @returns A promise that resolves with the response from the embedded app
14926
15718
  */
14927
- trigger<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(messageType: HostEventT, data?: TriggerPayload<PayloadT, HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextT>>;
15719
+ trigger<HostEventT extends HostEvent, PayloadT = HostEventRequest<HostEventT>, ContextT extends ContextType = ContextType>(messageType: HostEventT, data?: TriggerData<HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextT>>;
14928
15720
  /**
14929
15721
  * Destroys the ThoughtSpot embed, and remove any nodes from the DOM.
14930
15722
  * @version SDK: 1.39.0 | ThoughtSpot: 10.10.0.cl
14931
15723
  */
14932
15724
  destroy(): void;
14933
15725
  private postRender;
14934
- private registerLazyLoadEvents;
14935
- private unregisterLazyLoadEvents;
14936
15726
  /**
14937
15727
  * Render an embedded ThoughtSpot Liveboard or visualization
14938
15728
  * @param renderOptions An object specifying the Liveboard ID,
@@ -15135,9 +15925,9 @@ export interface SearchProps extends EmbedProps, SearchViewConfig {
15135
15925
  }
15136
15926
  /**
15137
15927
  * The PreRendered components require a preRender id. It can be supplied either
15138
- * through `preRenderConfig.preRenderId` (SDK: 1.52.0 and later) or through the
15928
+ * through `preRenderConfig.id` (SDK: 1.52.0 and later) or through the
15139
15929
  * top-level `preRenderId` prop (SDK: 1.25.0 and later, now deprecated).
15140
- * `preRenderConfig.preRenderId` takes precedence when both are set.
15930
+ * `preRenderConfig.id` takes precedence when both are set.
15141
15931
  *
15142
15932
  * Use PreRender to render the embed in the background and then
15143
15933
  * show or hide the rendered embed using showPreRender or hidePreRender respectively.
@@ -15146,14 +15936,14 @@ export interface SearchProps extends EmbedProps, SearchViewConfig {
15146
15936
  * // Preferred, SDK: 1.52.0 and later.
15147
15937
  * function LandingPageComponent() {
15148
15938
  * return <PreRenderedLiveboardEmbed
15149
- * preRenderConfig={{ preRenderId: "someId" }}
15939
+ * preRenderConfig={{ id: "someId" }}
15150
15940
  * liveboardId="libId"
15151
15941
  * />
15152
15942
  * }
15153
15943
  *
15154
15944
  * function MyComponent() {
15155
15945
  * return <LiveboardEmbed
15156
- * preRenderConfig={{ preRenderId: "someId" }}
15946
+ * preRenderConfig={{ id: "someId" }}
15157
15947
  * liveboardId="libId"
15158
15948
  * />
15159
15949
  * }
@@ -15170,7 +15960,7 @@ export type PreRenderProps = {
15170
15960
  /**
15171
15961
  * PreRender id to be used for PreRendering the embed.
15172
15962
  * @version SDK: 1.25.0 | ThoughtSpot: 9.6.0.cl
15173
- * @deprecated Use `preRenderConfig.preRenderId` instead.
15963
+ * @deprecated Use `preRenderConfig.id` instead.
15174
15964
  */
15175
15965
  preRenderId: string;
15176
15966
  /**
@@ -15183,17 +15973,17 @@ export type PreRenderProps = {
15183
15973
  /**
15184
15974
  * PreRender id to be used for PreRendering the embed.
15185
15975
  * @version SDK: 1.25.0 | ThoughtSpot: 9.6.0.cl
15186
- * @deprecated Use `preRenderConfig.preRenderId` instead.
15976
+ * @deprecated Use `preRenderConfig.id` instead.
15187
15977
  */
15188
15978
  preRenderId?: string;
15189
15979
  /**
15190
- * Configuration for the pre-render wrapper element. `preRenderId` is
15980
+ * Configuration for the pre-render wrapper element. `id` is
15191
15981
  * required here when the top-level `preRenderId` prop is not passed.
15192
15982
  * See {@link PreRenderConfig} for available options.
15193
15983
  * @version SDK: 1.52.0
15194
15984
  */
15195
15985
  preRenderConfig: PreRenderConfig & {
15196
- preRenderId: string;
15986
+ id: string;
15197
15987
  };
15198
15988
  };
15199
15989
  /**