@petercatai/whisker-client 0.1.202508050830-dev → 0.1.202508110245

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.
package/dist/api.d.ts CHANGED
@@ -3067,6 +3067,15 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
3067
3067
  * @request POST:/api/v1/agent/pro_research
3068
3068
  */
3069
3069
  proResearchApiV1AgentProResearchPost: (data: IProResearchRequest, params?: RequestParams) => Promise<HttpResponse<any, void | IHTTPValidationError>>;
3070
+ /**
3071
+ * @description whisker 通用 webhook
3072
+ *
3073
+ * @tags webhook
3074
+ * @name HandleWebhookApiV1WebhookWebhookTypeSourceAuthInfoKnowledgeBaseIdPost
3075
+ * @summary 通用webhook处理器
3076
+ * @request POST:/api/v1/webhook/{webhook_type}/{source}/{auth_info}/{knowledge_base_id}
3077
+ */
3078
+ handleWebhookApiV1WebhookWebhookTypeSourceAuthInfoKnowledgeBaseIdPost: (webhookType: string, source: string, authInfo: string, knowledgeBaseId: string, data: Record<string, any>, params?: RequestParams) => Promise<HttpResponse<any, void | IHTTPValidationError>>;
3070
3079
  };
3071
3080
  rule: {
3072
3081
  /**
package/dist/api.js CHANGED
@@ -198,15 +198,20 @@ class HttpClient {
198
198
  [ContentType.Text]: (input) => input !== null && typeof input !== "string"
199
199
  ? JSON.stringify(input)
200
200
  : input,
201
- [ContentType.FormData]: (input) => Object.keys(input || {}).reduce((formData, key) => {
202
- const property = input[key];
203
- formData.append(key, property instanceof Blob
204
- ? property
205
- : typeof property === "object" && property !== null
206
- ? JSON.stringify(property)
207
- : `${property}`);
208
- return formData;
209
- }, new FormData()),
201
+ [ContentType.FormData]: (input) => {
202
+ if (input instanceof FormData) {
203
+ return input;
204
+ }
205
+ return Object.keys(input || {}).reduce((formData, key) => {
206
+ const property = input[key];
207
+ formData.append(key, property instanceof Blob
208
+ ? property
209
+ : typeof property === "object" && property !== null
210
+ ? JSON.stringify(property)
211
+ : `${property}`);
212
+ return formData;
213
+ }, new FormData());
214
+ },
210
215
  [ContentType.UrlEncoded]: (input) => this.toQueryString(input),
211
216
  };
212
217
  this.createAbortSignal = (cancelToken) => {
@@ -646,6 +651,15 @@ class Api extends HttpClient {
646
651
  * @request POST:/api/v1/agent/pro_research
647
652
  */
648
653
  proResearchApiV1AgentProResearchPost: (data, params = {}) => this.request(Object.assign({ path: `/api/v1/agent/pro_research`, method: "POST", body: data, type: ContentType.Json, format: "json" }, params)),
654
+ /**
655
+ * @description whisker 通用 webhook
656
+ *
657
+ * @tags webhook
658
+ * @name HandleWebhookApiV1WebhookWebhookTypeSourceAuthInfoKnowledgeBaseIdPost
659
+ * @summary 通用webhook处理器
660
+ * @request POST:/api/v1/webhook/{webhook_type}/{source}/{auth_info}/{knowledge_base_id}
661
+ */
662
+ handleWebhookApiV1WebhookWebhookTypeSourceAuthInfoKnowledgeBaseIdPost: (webhookType, source, authInfo, knowledgeBaseId, data, params = {}) => this.request(Object.assign({ path: `/api/v1/webhook/${webhookType}/${source}/${authInfo}/${knowledgeBaseId}`, method: "POST", body: data, type: ContentType.Json, format: "json" }, params)),
649
663
  };
650
664
  this.rule = {
651
665
  /**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@petercatai/whisker-client",
3
- "version": "0.1.202508050830-dev",
4
- "description": "Generated API client (preview)",
3
+ "version": "0.1.202508110245",
4
+ "description": "Generated API client (Production)",
5
5
  "main": "dist/api.js",
6
6
  "types": "dist/api.d.ts",
7
7
  "files": [
@@ -13,10 +13,10 @@
13
13
  },
14
14
  "publishConfig": {
15
15
  "access": "public",
16
- "tag": "dev"
16
+ "tag": "latest"
17
17
  },
18
18
  "devDependencies": {
19
- "@types/node": "^24.2.0",
19
+ "@types/node": "^24.2.1",
20
20
  "axios": "^1.11.0",
21
21
  "typescript": "^5.9.2"
22
22
  }