feat(sql-editor): telemetry for ai suggestion create events

This commit is contained in:
Greg Richardson committed 2023-07-31 15:04:55 -05:00
1 parent 0e55ffab53
commit f6240a2db8
1 file changed
+10
@@ -182,6 +182,16 @@ const SQLTemplates = observer(() => {
})
await handleNewQuery(formattedSql, title)
Telemetry.sendEvent(
{
category: 'sql_editor',
action: 'ai_suggestion_created',
label: 'create_snippet',
},
telemetryProps,
router
)
} catch (error: unknown) {
if (isError(error)) {
ui.setNotification({