You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
sdk.window.showToast("OpenAI is not configured", { variant: "warning" });
40
+
}
41
+
```
42
+
15
43
::: tip
16
44
The AI provider is compatible with all features of the `ai` library, including text generation, streaming, tool calling, and more. Refer to the [ai SDK documentation](https://ai-sdk.dev/) for advanced usage.
Indicators are visual badges displayed next to rule names in the collections tree. They're useful for highlighting important rules or showing status information.
This example creates a plugin that reacts to context changes:
232
+
233
+
```ts
234
+
importtype { Caido } from"@caido/sdk-frontend";
235
+
236
+
exporttypeCaidoSDK=Caido;
237
+
238
+
exportconst init = (sdk:CaidoSDK) => {
239
+
sdk.window.onContextChange((context) => {
240
+
if (context.page) {
241
+
switch (context.page.kind) {
242
+
case"Replay":
243
+
sdk.log.info("User is on the Replay page");
244
+
break;
245
+
case"HTTPHistory":
246
+
sdk.log.info("User is on the HTTP History page");
247
+
break;
248
+
case"Sitemap":
249
+
sdk.log.info("User is on the Sitemap page");
250
+
break;
251
+
default:
252
+
sdk.log.info(`User is on the ${context.page.kind} page`);
253
+
}
254
+
} else {
255
+
sdk.log.info("User is not on a specific page");
256
+
}
257
+
});
258
+
};
259
+
```
260
+
193
261
## Interacting with Windows and Editors
194
262
195
263
Used to interact with text within the application environment, allowing text selection, replacement, read permission designations, focusing and editor related messaging.
Indicators are visual badges displayed next to session names in the collections tree. They're useful for highlighting important sessions or showing status information.
0 commit comments