@magemetrics/core 0.5.1 → 0.5.2
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/index.d.ts +61 -0
- package/dist/index.js +5 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -212,6 +212,13 @@ declare interface components {
|
|
|
212
212
|
sampledCount: number;
|
|
213
213
|
};
|
|
214
214
|
};
|
|
215
|
+
/** @description Prompt starter template */
|
|
216
|
+
PromptStarter: {
|
|
217
|
+
id: number;
|
|
218
|
+
title: string;
|
|
219
|
+
template: string;
|
|
220
|
+
is_default: boolean;
|
|
221
|
+
};
|
|
215
222
|
/** @description Starter recommendations */
|
|
216
223
|
StarterRecommendation: {
|
|
217
224
|
starter: string;
|
|
@@ -1898,6 +1905,43 @@ declare interface operations {
|
|
|
1898
1905
|
};
|
|
1899
1906
|
};
|
|
1900
1907
|
};
|
|
1908
|
+
getPromptStarters: {
|
|
1909
|
+
parameters: {
|
|
1910
|
+
query?: {
|
|
1911
|
+
input?: string;
|
|
1912
|
+
};
|
|
1913
|
+
header: {
|
|
1914
|
+
"sp-access-token": string;
|
|
1915
|
+
};
|
|
1916
|
+
path?: never;
|
|
1917
|
+
cookie?: never;
|
|
1918
|
+
};
|
|
1919
|
+
requestBody?: never;
|
|
1920
|
+
responses: {
|
|
1921
|
+
/** @description List available prompt starters */
|
|
1922
|
+
200: {
|
|
1923
|
+
headers: {
|
|
1924
|
+
[name: string]: unknown;
|
|
1925
|
+
};
|
|
1926
|
+
content: {
|
|
1927
|
+
"application/json": {
|
|
1928
|
+
starters: components["schemas"]["PromptStarter"][];
|
|
1929
|
+
};
|
|
1930
|
+
};
|
|
1931
|
+
};
|
|
1932
|
+
/** @description Something wrong happened */
|
|
1933
|
+
500: {
|
|
1934
|
+
headers: {
|
|
1935
|
+
[name: string]: unknown;
|
|
1936
|
+
};
|
|
1937
|
+
content: {
|
|
1938
|
+
"application/json": {
|
|
1939
|
+
error: string;
|
|
1940
|
+
};
|
|
1941
|
+
};
|
|
1942
|
+
};
|
|
1943
|
+
};
|
|
1944
|
+
};
|
|
1901
1945
|
retrieveChatMessages: {
|
|
1902
1946
|
parameters: {
|
|
1903
1947
|
query?: never;
|
|
@@ -2214,6 +2258,7 @@ declare interface operations {
|
|
|
2214
2258
|
variables: {
|
|
2215
2259
|
[key: string]: string;
|
|
2216
2260
|
};
|
|
2261
|
+
applicationName?: string;
|
|
2217
2262
|
};
|
|
2218
2263
|
};
|
|
2219
2264
|
};
|
|
@@ -3561,6 +3606,22 @@ declare interface paths {
|
|
|
3561
3606
|
patch?: never;
|
|
3562
3607
|
trace?: never;
|
|
3563
3608
|
};
|
|
3609
|
+
"/api/v1/prompt-starters": {
|
|
3610
|
+
parameters: {
|
|
3611
|
+
query?: never;
|
|
3612
|
+
header?: never;
|
|
3613
|
+
path?: never;
|
|
3614
|
+
cookie?: never;
|
|
3615
|
+
};
|
|
3616
|
+
get: operations["getPromptStarters"];
|
|
3617
|
+
put?: never;
|
|
3618
|
+
post?: never;
|
|
3619
|
+
delete?: never;
|
|
3620
|
+
options?: never;
|
|
3621
|
+
head?: never;
|
|
3622
|
+
patch?: never;
|
|
3623
|
+
trace?: never;
|
|
3624
|
+
};
|
|
3564
3625
|
"/api/v1/chat/{flowId}/messages": {
|
|
3565
3626
|
parameters: {
|
|
3566
3627
|
query?: never;
|
package/dist/index.js
CHANGED
|
@@ -2408,7 +2408,8 @@ createRoute({
|
|
|
2408
2408
|
// ../shared/dist/src/endpoints/companion/triggers.routes.js
|
|
2409
2409
|
var TriggerFlowBody = z5.object({
|
|
2410
2410
|
triggerId: z5.string(),
|
|
2411
|
-
variables: z5.record(z5.string(), z5.string())
|
|
2411
|
+
variables: z5.record(z5.string(), z5.string()),
|
|
2412
|
+
applicationName: z5.string().optional()
|
|
2412
2413
|
});
|
|
2413
2414
|
var TriggerFlow = createRoute({
|
|
2414
2415
|
method: "post",
|
|
@@ -3150,7 +3151,7 @@ var toSearchParams = ({ cursor, filters, sorting, limit }) => {
|
|
|
3150
3151
|
|
|
3151
3152
|
// package.json
|
|
3152
3153
|
var package_default = {
|
|
3153
|
-
version: "0.5.
|
|
3154
|
+
version: "0.5.2"};
|
|
3154
3155
|
var MageMetricsChatTransport = class extends DefaultChatTransport {
|
|
3155
3156
|
constructor(apiUrl, flowId, options) {
|
|
3156
3157
|
super({
|
|
@@ -3433,7 +3434,8 @@ var MageMetricsClient = class {
|
|
|
3433
3434
|
{
|
|
3434
3435
|
body: {
|
|
3435
3436
|
triggerId,
|
|
3436
|
-
variables
|
|
3437
|
+
variables,
|
|
3438
|
+
applicationName: this.config.applicationName
|
|
3437
3439
|
}
|
|
3438
3440
|
}
|
|
3439
3441
|
);
|