@yaakapp/api 0.4.1 → 0.5.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.
@@ -466,7 +466,7 @@ export type InternalEvent = {
466
466
  pluginRefId: string;
467
467
  pluginName: string;
468
468
  replyId: string | null;
469
- windowContext: WindowContext;
469
+ windowContext: PluginWindowContext;
470
470
  payload: InternalEventPayload;
471
471
  };
472
472
  export type InternalEventPayload = {
@@ -552,6 +552,8 @@ export type InternalEventPayload = {
552
552
  } & OpenWindowRequest | {
553
553
  "type": "window_navigate_event";
554
554
  } & WindowNavigateEvent | {
555
+ "type": "window_close_event";
556
+ } | {
555
557
  "type": "close_window_request";
556
558
  } & CloseWindowRequest | {
557
559
  "type": "template_render_request";
@@ -587,6 +589,14 @@ export type OpenWindowRequest = {
587
589
  label: string;
588
590
  title?: string;
589
591
  size?: WindowSize;
592
+ dataDirKey?: string;
593
+ };
594
+ export type PluginWindowContext = {
595
+ "type": "none";
596
+ } | {
597
+ "type": "label";
598
+ label: string;
599
+ workspace_id: string | null;
590
600
  };
591
601
  export type PromptTextRequest = {
592
602
  id: string;
@@ -643,8 +653,12 @@ export type TemplateFunction = {
643
653
  * tags when changing the `name` property
644
654
  */
645
655
  aliases?: Array<string>;
646
- args: Array<FormInput>;
656
+ args: Array<TemplateFunctionArg>;
647
657
  };
658
+ /**
659
+ * Similar to FormInput, but contains
660
+ */
661
+ export type TemplateFunctionArg = FormInput;
648
662
  export type TemplateRenderRequest = {
649
663
  data: JsonValue;
650
664
  purpose: RenderPurpose;
@@ -652,12 +666,6 @@ export type TemplateRenderRequest = {
652
666
  export type TemplateRenderResponse = {
653
667
  data: JsonValue;
654
668
  };
655
- export type WindowContext = {
656
- "type": "none";
657
- } | {
658
- "type": "label";
659
- label: string;
660
- };
661
669
  export type WindowNavigateEvent = {
662
670
  url: string;
663
671
  };
@@ -2,10 +2,11 @@ export type Environment = {
2
2
  model: "environment";
3
3
  id: string;
4
4
  workspaceId: string;
5
- environmentId: string | null;
6
5
  createdAt: string;
7
6
  updatedAt: string;
8
7
  name: string;
8
+ public: boolean;
9
+ base: boolean;
9
10
  variables: Array<EnvironmentVariable>;
10
11
  };
11
12
  export type EnvironmentVariable = {
@@ -129,6 +130,7 @@ export type Workspace = {
129
130
  updatedAt: string;
130
131
  name: string;
131
132
  description: string;
133
+ encryptionKeyChallenge: string | null;
132
134
  settingValidateCertificates: boolean;
133
135
  settingFollowRedirects: boolean;
134
136
  settingRequestTimeout: number;
@@ -1,3 +1,3 @@
1
- export type JsonValue = number | string | Array<JsonValue> | {
1
+ export type JsonValue = number | string | boolean | Array<JsonValue> | {
2
2
  [key in string]?: JsonValue;
3
- };
3
+ } | null;
@@ -19,6 +19,7 @@ export interface Context {
19
19
  onNavigate?: (args: {
20
20
  url: string;
21
21
  }) => void;
22
+ onClose: () => void;
22
23
  }): Promise<{
23
24
  close: () => void;
24
25
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yaakapp/api",
3
- "version": "0.4.1",
3
+ "version": "0.5.1",
4
4
  "main": "lib/index.js",
5
5
  "typings": "./lib/index.d.ts",
6
6
  "files": [
@@ -20,8 +20,6 @@
20
20
  "@types/node": "^22.5.4"
21
21
  },
22
22
  "devDependencies": {
23
- "cpy-cli": "^5.0.0",
24
- "npm-run-all": "^4.1.5",
25
- "typescript": "^5.6.2"
23
+ "cpy-cli": "^5.0.0"
26
24
  }
27
25
  }