@voiceflow/sdk-runtime 1.3.2 → 1.3.4

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.
Files changed (87) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/build/cjs/runtime/runtime.interface.d.ts +5 -67
  3. package/build/cjs/runtime/runtime.interface.d.ts.map +1 -1
  4. package/build/cjs/runtime/runtime.interface.js +4 -29
  5. package/build/cjs/trace/components/card.component.d.ts +7 -2
  6. package/build/cjs/trace/components/card.component.d.ts.map +1 -1
  7. package/build/cjs/trace/components/cardV2.component.d.ts +3 -0
  8. package/build/cjs/trace/components/cardV2.component.d.ts.map +1 -0
  9. package/build/cjs/trace/components/cardV2.component.js +6 -0
  10. package/build/cjs/trace/components/choice.component.d.ts +2 -2
  11. package/build/cjs/trace/components/choice.component.d.ts.map +1 -1
  12. package/build/cjs/trace/components/choice.component.js +2 -1
  13. package/build/cjs/trace/components/end.component.d.ts +2 -2
  14. package/build/cjs/trace/components/end.component.d.ts.map +1 -1
  15. package/build/cjs/trace/components/end.component.js +2 -1
  16. package/build/cjs/trace/components/index.d.ts +1 -1
  17. package/build/cjs/trace/components/index.d.ts.map +1 -1
  18. package/build/cjs/trace/components/index.js +1 -1
  19. package/build/cjs/trace/components/speak.component.d.ts +2 -2
  20. package/build/cjs/trace/components/speak.component.d.ts.map +1 -1
  21. package/build/cjs/trace/components/speak.component.js +2 -1
  22. package/build/cjs/trace/components/stream.component.d.ts +2 -2
  23. package/build/cjs/trace/components/stream.component.d.ts.map +1 -1
  24. package/build/cjs/trace/components/stream.component.js +2 -1
  25. package/build/cjs/trace/components/text.component.d.ts +2 -2
  26. package/build/cjs/trace/components/text.component.d.ts.map +1 -1
  27. package/build/cjs/trace/components/text.component.js +2 -1
  28. package/build/cjs/trace/components/visual.component.d.ts +4 -2
  29. package/build/cjs/trace/components/visual.component.d.ts.map +1 -1
  30. package/build/cjs/trace/components/visual.component.js +2 -1
  31. package/build/cjs/trace/trace.component.d.ts +5 -5
  32. package/build/cjs/trace/trace.component.d.ts.map +1 -1
  33. package/build/cjs/trace/trace.interface.d.ts +6 -6
  34. package/build/cjs/trace/trace.interface.d.ts.map +1 -1
  35. package/build/esm/runtime/runtime.interface.d.ts +5 -67
  36. package/build/esm/runtime/runtime.interface.d.ts.map +1 -1
  37. package/build/esm/runtime/runtime.interface.js +3 -21
  38. package/build/esm/trace/components/card.component.d.ts +7 -2
  39. package/build/esm/trace/components/card.component.d.ts.map +1 -1
  40. package/build/esm/trace/components/cardV2.component.d.ts +3 -0
  41. package/build/esm/trace/components/cardV2.component.d.ts.map +1 -0
  42. package/build/esm/trace/components/cardV2.component.js +3 -0
  43. package/build/esm/trace/components/choice.component.d.ts +2 -2
  44. package/build/esm/trace/components/choice.component.d.ts.map +1 -1
  45. package/build/esm/trace/components/choice.component.js +2 -1
  46. package/build/esm/trace/components/end.component.d.ts +2 -2
  47. package/build/esm/trace/components/end.component.d.ts.map +1 -1
  48. package/build/esm/trace/components/end.component.js +2 -1
  49. package/build/esm/trace/components/index.d.ts +1 -1
  50. package/build/esm/trace/components/index.d.ts.map +1 -1
  51. package/build/esm/trace/components/index.js +1 -1
  52. package/build/esm/trace/components/speak.component.d.ts +2 -2
  53. package/build/esm/trace/components/speak.component.d.ts.map +1 -1
  54. package/build/esm/trace/components/speak.component.js +2 -1
  55. package/build/esm/trace/components/stream.component.d.ts +2 -2
  56. package/build/esm/trace/components/stream.component.d.ts.map +1 -1
  57. package/build/esm/trace/components/stream.component.js +2 -1
  58. package/build/esm/trace/components/text.component.d.ts +2 -2
  59. package/build/esm/trace/components/text.component.d.ts.map +1 -1
  60. package/build/esm/trace/components/text.component.js +2 -1
  61. package/build/esm/trace/components/visual.component.d.ts +4 -2
  62. package/build/esm/trace/components/visual.component.d.ts.map +1 -1
  63. package/build/esm/trace/components/visual.component.js +2 -1
  64. package/build/esm/trace/trace.component.d.ts +5 -5
  65. package/build/esm/trace/trace.component.d.ts.map +1 -1
  66. package/build/esm/trace/trace.interface.d.ts +6 -6
  67. package/build/esm/trace/trace.interface.d.ts.map +1 -1
  68. package/package.json +4 -3
  69. package/src/runtime/runtime.interface.ts +7 -102
  70. package/src/trace/components/card.component.ts +2 -2
  71. package/src/trace/components/cardV2.component.ts +5 -0
  72. package/src/trace/components/choice.component.ts +2 -2
  73. package/src/trace/components/end.component.ts +2 -2
  74. package/src/trace/components/index.ts +1 -1
  75. package/src/trace/components/speak.component.ts +2 -2
  76. package/src/trace/components/stream.component.ts +2 -2
  77. package/src/trace/components/text.component.ts +2 -2
  78. package/src/trace/components/visual.component.ts +6 -2
  79. package/src/trace/trace.component.ts +6 -8
  80. package/src/trace/trace.interface.ts +7 -7
  81. package/build/cjs/trace/components/payload.component.d.ts +0 -3
  82. package/build/cjs/trace/components/payload.component.d.ts.map +0 -1
  83. package/build/cjs/trace/components/payload.component.js +0 -5
  84. package/build/esm/trace/components/payload.component.d.ts +0 -3
  85. package/build/esm/trace/components/payload.component.d.ts.map +0 -1
  86. package/build/esm/trace/components/payload.component.js +0 -2
  87. package/src/trace/components/payload.component.ts +0 -5
package/CHANGELOG.md CHANGED
@@ -3,6 +3,18 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.3.4](https://github.com/voiceflow/adapters/compare/@voiceflow/sdk-runtime@1.3.3...@voiceflow/sdk-runtime@1.3.4) (2022-10-06)
7
+
8
+ ### Bug Fixes
9
+
10
+ * update trace types (PL-000) ([#44](https://github.com/voiceflow/adapters/issues/44)) ([ce13855](https://github.com/voiceflow/adapters/commit/ce13855668f639e710fe1781bb68f40fabcd558c))
11
+
12
+ ## [1.3.3](https://github.com/voiceflow/adapters/compare/@voiceflow/sdk-runtime@1.3.2...@voiceflow/sdk-runtime@1.3.3) (2022-10-04)
13
+
14
+ ### Bug Fixes
15
+
16
+ * update dependencies (CT-000) ([#43](https://github.com/voiceflow/adapters/issues/43)) ([792f1a0](https://github.com/voiceflow/adapters/commit/792f1a0c905924c9844e3c16cd3008c71c0185fd))
17
+
6
18
  ## [1.3.2](https://github.com/voiceflow/adapters/compare/@voiceflow/sdk-runtime@1.3.1...@voiceflow/sdk-runtime@1.3.2) (2022-10-04)
7
19
 
8
20
  ### Bug Fixes
@@ -1,4 +1,5 @@
1
- import { BaseRequest } from '@voiceflow/base-types';
1
+ import { BaseRequest, Trace } from '@voiceflow/base-types';
2
+ export { Trace } from '@voiceflow/base-types';
2
3
  declare type FetchFn = (...parameters: any[]) => Promise<any>;
3
4
  export interface RuntimeOptions<V = AuthVerify | PublicVerify> {
4
5
  url: string;
@@ -26,7 +27,7 @@ export interface RuntimeInteractRequest {
26
27
  export interface RuntimeInteractResponse {
27
28
  state: RuntimeState;
28
29
  request: RuntimeAction;
29
- trace: RuntimeTrace[];
30
+ trace: Trace.AnyTrace[];
30
31
  }
31
32
  export declare type RuntimeAction = BaseRequest.TextRequest | BaseRequest.LaunchRequest | BaseRequest.IntentRequest | BaseRequest.ActionRequest | BaseRequest.GeneralRequest | BaseRequest.BaseRequest<unknown>;
32
33
  export declare const isRuntimeAction: (value: unknown) => value is RuntimeAction;
@@ -49,75 +50,12 @@ export interface RuntimeState {
49
50
  storage: Record<string, any>;
50
51
  variables: Record<string, any>;
51
52
  }
52
- export declare const RuntimeTraceTypeSet: Set<"speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end">;
53
- export declare type RuntimeTraceType = typeof RuntimeTraceTypeSet extends Set<infer K> ? K : never;
54
- export declare const isRuntimeTraceType: (value: unknown) => value is "speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end";
55
- export interface RuntimeTrace<T extends RuntimeTraceType = RuntimeTraceType, P = unknown> {
56
- type: T;
57
- payload: P;
58
- }
59
- export declare const isRuntimeTrace: (value: unknown) => value is RuntimeTrace<"speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end", unknown>;
60
- export interface CardTracePayload {
61
- card: {
62
- type: string;
63
- title: string;
64
- text: string;
65
- image?: {
66
- largeImageUrl: string;
67
- alt: string;
68
- };
69
- };
70
- }
71
- export declare type CardTrace = RuntimeTrace<'card', CardTracePayload>;
72
- export declare const isCardTrace: (value: unknown) => value is CardTrace;
73
- export declare type ChoiceTrace = RuntimeTrace<'choice', ChoiceTracePayload>;
74
- export interface ChoiceTracePayload {
75
- buttons: {
76
- name: string;
77
- }[];
78
- }
79
- export declare const isChoiceTrace: (value: unknown) => value is ChoiceTrace;
80
- export interface PayloadTracePayload {
81
- data: any;
82
- }
83
- export declare type EndTrace = RuntimeTrace<'end'>;
84
- export declare const isEndTrace: (value: unknown) => value is EndTrace;
85
- export declare type PayloadTrace = RuntimeTrace<'payload', PayloadTracePayload>;
86
- export declare const isPayloadTrace: (value: unknown) => value is PayloadTrace;
87
- export interface SpeakTracePayload {
88
- voice?: string;
89
- src?: string;
90
- message: string;
91
- type: 'speak' | 'audio';
92
- }
93
- export declare type SpeakTrace = RuntimeTrace<'speak', SpeakTracePayload>;
94
- export declare const isSpeakTrace: (value: unknown) => value is SpeakTrace;
95
- export interface TextTracePayload {
96
- message: string;
97
- }
98
- export declare type TextTrace = RuntimeTrace<'text', TextTracePayload>;
99
- export declare const isTextTrace: (value: unknown) => value is TextTrace;
100
- export interface VisualTracePayload {
101
- image: string;
102
- }
103
- export declare type VisualTrace = RuntimeTrace<'visual', VisualTracePayload>;
104
- export declare const isVisualTrace: (value: unknown) => value is VisualTrace;
105
- export interface StreamTracePayload {
106
- src: string;
107
- loop: boolean;
108
- description?: string;
109
- title?: string;
110
- iconImage?: string;
111
- backgroundImage?: string;
112
- action: string;
113
- }
114
- export declare type StreamTrace = RuntimeTrace<'stream', StreamTracePayload>;
115
- export declare const isStreamTrace: (value: unknown) => value is StreamTrace;
53
+ export declare const isRuntimeTraceType: (value: unknown) => value is Trace.TraceType;
54
+ export declare const isRuntimeTrace: (value: unknown) => value is Trace.BaseTraceFrame<any, import("@voiceflow/base-types/build/cjs/node/utils").BaseTraceFramePath<import("@voiceflow/base-types/build/cjs/node/utils").BaseEvent>>;
116
55
  export interface RuntimeHttpRequest {
117
56
  method?: string;
118
57
  params?: URLSearchParams;
119
58
  body?: any;
120
59
  headers?: HeadersInit;
121
60
  }
122
- export {};
123
61
  //# sourceMappingURL=runtime.interface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.interface.d.ts","sourceRoot":"","sources":["../../../src/runtime/runtime.interface.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,aAAK,OAAO,GAAG,CAAC,GAAG,UAAU,EAAE,GAAG,EAAE,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;AAEtD,MAAM,WAAW,cAAc,CAAC,CAAC,GAAG,UAAU,GAAG,YAAY;IAC3D,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,CAAC,CAAC;IAEV;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,MAAM,WAAW,UAAU;IACzB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,YAAY;IAC3B,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,oBAAoB,YACtB,eAAe,QAAQ,UAAU,GAAG,YAAY,CAAC,CAAC,0CAG5D,CAAC;AAEF,eAAO,MAAM,sBAAsB,YACxB,eAAe,QAAQ,UAAU,GAAG,YAAY,CAAC,CAAC,4CAG5D,CAAC;AAEF,MAAM,WAAW,sBAAsB;IACrC,MAAM,EAAE,aAAa,CAAC;IACtB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,GAAG,CAAC;CACd;AAED,MAAM,WAAW,uBAAuB;IACtC,KAAK,EAAE,YAAY,CAAC;IACpB,OAAO,EAAE,aAAa,CAAC;IACvB,KAAK,EAAE,YAAY,EAAE,CAAC;CAC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B;AAED,oBAAY,YAAY,GAAG,WAAW,CAAC,aAAa,CAAC;AACrD,oBAAY,UAAU,GAAG,WAAW,CAAC,WAAW,CAAC;AACjD,eAAO,MAAM,UAAU,gCAA0B,CAAC;AAElD,eAAO,MAAM,kBAAkB,YAAa,YAAY,oBAAoB,KAAG,YAAY,aAGzF,CAAC;AAEH,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAChC;AAED,eAAO,MAAM,kBAAkB,UAAW,OAAO,6BACoC,CAAC;AAEtF,eAAO,MAAM,cAAc,UAAW,OAAO,gLAGJ,CAAC;AAE1C,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,eAAe,CAAC;IACzB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,EAAE,WAAW,CAAC;CACvB"}
@@ -1,7 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isStreamTrace = exports.isVisualTrace = exports.isTextTrace = exports.isSpeakTrace = exports.isPayloadTrace = exports.isEndTrace = exports.isChoiceTrace = exports.isCardTrace = exports.isRuntimeTrace = exports.isRuntimeTraceType = exports.RuntimeTraceTypeSet = exports.createIntentAction = exports.ActionType = exports.isRuntimeAction = exports.isPublicRuntimeOptions = exports.isAuthRuntimeOptions = void 0;
3
+ exports.isRuntimeTrace = exports.isRuntimeTraceType = exports.createIntentAction = exports.ActionType = exports.isRuntimeAction = exports.isPublicRuntimeOptions = exports.isAuthRuntimeOptions = exports.Trace = void 0;
4
4
  const base_types_1 = require("@voiceflow/base-types");
5
+ var base_types_2 = require("@voiceflow/base-types");
6
+ Object.defineProperty(exports, "Trace", { enumerable: true, get: function () { return base_types_2.Trace; } });
5
7
  const isAuthRuntimeOptions = (options) => {
6
8
  return !!options?.verify?.authorization;
7
9
  };
@@ -18,36 +20,9 @@ const createIntentAction = (payload) => ({
18
20
  payload,
19
21
  });
20
22
  exports.createIntentAction = createIntentAction;
21
- exports.RuntimeTraceTypeSet = new Set([
22
- 'speak',
23
- 'text',
24
- 'choice',
25
- 'card',
26
- 'visual',
27
- 'audio',
28
- 'payload',
29
- 'stream',
30
- 'end',
31
- ]);
32
- const isRuntimeTraceType = (value) => typeof value === 'string' && exports.RuntimeTraceTypeSet.has(value);
23
+ const isRuntimeTraceType = (value) => typeof value === 'string' && Object.values(base_types_1.Trace.TraceType).includes(value);
33
24
  exports.isRuntimeTraceType = isRuntimeTraceType;
34
25
  const isRuntimeTrace = (value) => typeof value === 'object' &&
35
26
  Object.prototype.hasOwnProperty.call(value, 'type') &&
36
27
  (0, exports.isRuntimeTraceType)(value.type);
37
28
  exports.isRuntimeTrace = isRuntimeTrace;
38
- const isCardTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'card';
39
- exports.isCardTrace = isCardTrace;
40
- const isChoiceTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'choice';
41
- exports.isChoiceTrace = isChoiceTrace;
42
- const isEndTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'end';
43
- exports.isEndTrace = isEndTrace;
44
- const isPayloadTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'payload';
45
- exports.isPayloadTrace = isPayloadTrace;
46
- const isSpeakTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'speak';
47
- exports.isSpeakTrace = isSpeakTrace;
48
- const isTextTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'text';
49
- exports.isTextTrace = isTextTrace;
50
- const isVisualTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'visual';
51
- exports.isVisualTrace = isVisualTrace;
52
- const isStreamTrace = (value) => (0, exports.isRuntimeTrace)(value) && value.type === 'stream';
53
- exports.isStreamTrace = isStreamTrace;
@@ -1,3 +1,8 @@
1
- import type { CardTrace } from '../../runtime/runtime.interface.js';
2
- export declare const CardTraceComponent: import("../trace.component.js").TraceComponentOverload<CardTrace>;
1
+ import type { BaseNode } from '@voiceflow/base-types';
2
+ export declare const CardTraceComponent: import("../trace.component.js").TraceComponentOverload<{
3
+ type: 'card';
4
+ payload: {
5
+ card: BaseNode.Card.Card;
6
+ };
7
+ }>;
3
8
  //# sourceMappingURL=card.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"card.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/card.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAIhE,eAAO,MAAM,kBAAkB,mEAA0C,CAAC"}
1
+ {"version":3,"file":"card.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/card.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAItD,eAAO,MAAM,kBAAkB;UAAgC,MAAM;aAAW;QAAE,IAAI,EAAE,SAAS,IAAI,CAAC,IAAI,CAAA;KAAE;EAAW,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const CardV2TraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.CardV2>;
3
+ //# sourceMappingURL=cardV2.component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cardV2.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/cardV2.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,oBAAoB,sEAA8D,CAAC"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CardV2TraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
5
+ const trace_component_js_1 = require("../trace.component.js");
6
+ exports.CardV2TraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.CARD_V2);
@@ -1,3 +1,3 @@
1
- import type { ChoiceTrace } from '../../runtime/runtime.interface.js';
2
- export declare const ChoiceTraceComponent: import("../trace.component.js").TraceComponentOverload<ChoiceTrace>;
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const ChoiceTraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.Choice>;
3
3
  //# sourceMappingURL=choice.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"choice.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/choice.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAIlE,eAAO,MAAM,oBAAoB,qEAA8C,CAAC"}
1
+ {"version":3,"file":"choice.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/choice.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,oBAAoB,sEAA6D,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ChoiceTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.ChoiceTraceComponent = (0, trace_component_js_1.createTraceComponent)('choice');
6
+ exports.ChoiceTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.CHOICE);
@@ -1,3 +1,3 @@
1
- import type { EndTrace } from '../../runtime/runtime.interface.js';
2
- export declare const EndTraceComponent: import("../trace.component.js").TraceComponentOverload<EndTrace>;
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const EndTraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.End>;
3
3
  //# sourceMappingURL=end.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"end.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/end.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AAI/D,eAAO,MAAM,iBAAiB,kEAAwC,CAAC"}
1
+ {"version":3,"file":"end.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/end.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,iBAAiB,mEAAuD,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.EndTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.EndTraceComponent = (0, trace_component_js_1.createTraceComponent)('end');
6
+ exports.EndTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.END);
@@ -1,7 +1,7 @@
1
1
  export * from './card.component.js';
2
+ export * from './cardV2.component.js';
2
3
  export * from './choice.component.js';
3
4
  export * from './end.component.js';
4
- export * from './payload.component.js';
5
5
  export * from './speak.component.js';
6
6
  export * from './stream.component.js';
7
7
  export * from './text.component.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC"}
@@ -15,9 +15,9 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./card.component.js"), exports);
18
+ __exportStar(require("./cardV2.component.js"), exports);
18
19
  __exportStar(require("./choice.component.js"), exports);
19
20
  __exportStar(require("./end.component.js"), exports);
20
- __exportStar(require("./payload.component.js"), exports);
21
21
  __exportStar(require("./speak.component.js"), exports);
22
22
  __exportStar(require("./stream.component.js"), exports);
23
23
  __exportStar(require("./text.component.js"), exports);
@@ -1,3 +1,3 @@
1
- import type { SpeakTrace } from '../../runtime/runtime.interface.js';
2
- export declare const SpeakTraceComponent: import("../trace.component.js").TraceComponentOverload<SpeakTrace>;
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const SpeakTraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.Speak>;
3
3
  //# sourceMappingURL=speak.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"speak.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/speak.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AAIjE,eAAO,MAAM,mBAAmB,oEAA4C,CAAC"}
1
+ {"version":3,"file":"speak.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/speak.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,mBAAmB,qEAA2D,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SpeakTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.SpeakTraceComponent = (0, trace_component_js_1.createTraceComponent)('speak');
6
+ exports.SpeakTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.SPEAK);
@@ -1,3 +1,3 @@
1
- import type { StreamTrace } from '../../runtime/runtime.interface.js';
2
- export declare const StreamTraceComponent: import("../trace.component.js").TraceComponentOverload<StreamTrace>;
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const StreamTraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.Stream>;
3
3
  //# sourceMappingURL=stream.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"stream.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/stream.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAIlE,eAAO,MAAM,oBAAoB,qEAA8C,CAAC"}
1
+ {"version":3,"file":"stream.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/stream.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,oBAAoB,sEAA6D,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.StreamTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.StreamTraceComponent = (0, trace_component_js_1.createTraceComponent)('stream');
6
+ exports.StreamTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.STREAM);
@@ -1,3 +1,3 @@
1
- import type { TextTrace } from '../../runtime/runtime.interface.js';
2
- export declare const TextTraceComponent: import("../trace.component.js").TraceComponentOverload<TextTrace>;
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const TextTraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.Text>;
3
3
  //# sourceMappingURL=text.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"text.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/text.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAIhE,eAAO,MAAM,kBAAkB,mEAA0C,CAAC"}
1
+ {"version":3,"file":"text.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/text.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,kBAAkB,oEAAyD,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.TextTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.TextTraceComponent = (0, trace_component_js_1.createTraceComponent)('text');
6
+ exports.TextTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.TEXT);
@@ -1,3 +1,5 @@
1
- import type { VisualTrace } from '../../runtime/runtime.interface.js';
2
- export declare const VisualTraceComponent: import("../trace.component.js").TraceComponentOverload<VisualTrace>;
1
+ import type { BaseNode } from '@voiceflow/base-types';
2
+ export declare const VisualTraceComponent: import("../trace.component.js").TraceComponentOverload<BaseNode.Visual.TraceFrame & {
3
+ payload: BaseNode.Visual.ImageStepData;
4
+ }>;
3
5
  //# sourceMappingURL=visual.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"visual.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/visual.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAIlE,eAAO,MAAM,oBAAoB,qEAA8C,CAAC"}
1
+ {"version":3,"file":"visual.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/visual.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAMtD,eAAO,MAAM,oBAAoB;aAAkD,SAAS,MAAM,CAAC,aAAa;EAE/G,CAAC"}
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VisualTraceComponent = void 0;
4
+ const runtime_interface_js_1 = require("../../runtime/runtime.interface.js");
4
5
  const trace_component_js_1 = require("../trace.component.js");
5
- exports.VisualTraceComponent = (0, trace_component_js_1.createTraceComponent)('visual');
6
+ exports.VisualTraceComponent = (0, trace_component_js_1.createTraceComponent)(runtime_interface_js_1.Trace.TraceType.VISUAL);
@@ -1,8 +1,8 @@
1
- import type { RuntimeTrace } from '../runtime/runtime.interface.js';
1
+ import type { Trace } from '../runtime/runtime.interface.js';
2
2
  import type { TraceAccumulator, TraceDeclaration } from './trace.interface.js';
3
- export interface TraceComponentOverload<Trace extends RuntimeTrace> {
4
- <Context>(declaration: TraceDeclaration<Context, Trace>): Required<TraceDeclaration<Context, Trace>>;
5
- <Context>(handle: TraceAccumulator<Context, Trace>): Required<TraceDeclaration<Context, Trace>>;
3
+ export interface TraceComponentOverload<T extends Trace.BaseTraceFrame> {
4
+ <Context>(declaration: TraceDeclaration<Context, T>): Required<TraceDeclaration<Context, T>>;
5
+ <Context>(handle: TraceAccumulator<Context, T>): Required<TraceDeclaration<Context, T>>;
6
6
  }
7
- export declare const createTraceComponent: <Trace extends RuntimeTrace<"speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end", unknown>>(type: Trace["type"]) => TraceComponentOverload<Trace>;
7
+ export declare const createTraceComponent: <T extends Trace.BaseTraceFrame<any, import("@voiceflow/base-types/build/cjs/node/utils/trace.js").BaseTraceFramePath<import("@voiceflow/base-types/build/cjs/node/utils/event.js").BaseEvent>>>(type: T["type"]) => TraceComponentOverload<T>;
8
8
  //# sourceMappingURL=trace.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"trace.component.d.ts","sourceRoot":"","sources":["../../../src/trace/trace.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAEnE,OAAO,KAAK,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAE/E,MAAM,WAAW,sBAAsB,CAAC,KAAK,SAAS,YAAY;IAChE,CAAC,OAAO,EAAE,WAAW,EAAE,gBAAgB,CAAC,OAAO,EAAE,KAAK,CAAC,GAAG,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC;IACrG,CAAC,OAAO,EAAE,MAAM,EAAE,gBAAgB,CAAC,OAAO,EAAE,KAAK,CAAC,GAAG,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC;CACjG;AAED,eAAO,MAAM,oBAAoB,uLAa9B,CAAC"}
1
+ {"version":3,"file":"trace.component.d.ts","sourceRoot":"","sources":["../../../src/trace/trace.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAE5D,OAAO,KAAK,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAE/E,MAAM,WAAW,sBAAsB,CAAC,CAAC,SAAS,KAAK,CAAC,cAAc;IACpE,CAAC,OAAO,EAAE,WAAW,EAAE,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,GAAG,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC;IAC7F,CAAC,OAAO,EAAE,MAAM,EAAE,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,GAAG,QAAQ,CAAC,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC;CACzF;AAED,eAAO,MAAM,oBAAoB,gPAW9B,CAAC"}
@@ -1,14 +1,14 @@
1
- import type { RuntimeTrace } from '../runtime/runtime.interface';
1
+ import type { Trace } from '../runtime/runtime.interface';
2
2
  export interface TraceOptions<T> {
3
3
  traces?: TraceDeclaration<T, any>[];
4
4
  }
5
- export interface TraceDeclaration<Context, Trace extends RuntimeTrace> {
6
- canHandle: TraceCanHandle<Trace>;
7
- handle: TraceAccumulator<Context, Trace>;
5
+ export interface TraceDeclaration<Context, T extends Trace.BaseTraceFrame> {
6
+ canHandle: TraceCanHandle<T>;
7
+ handle: TraceAccumulator<Context, T>;
8
8
  }
9
- export declare type TraceCanHandle<Trace extends RuntimeTrace> = (trace: Trace) => boolean;
9
+ export declare type TraceCanHandle<T extends Trace.BaseTraceFrame> = (trace: T) => boolean;
10
10
  export interface TraceHandlerMeta<Context> {
11
11
  context: Context;
12
12
  }
13
- export declare type TraceAccumulator<Context, Trace extends RuntimeTrace> = (meta: TraceHandlerMeta<Context>, trace: Trace) => Context;
13
+ export declare type TraceAccumulator<Context, T extends Trace.BaseTraceFrame> = (meta: TraceHandlerMeta<Context>, trace: T) => Context;
14
14
  //# sourceMappingURL=trace.interface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"trace.interface.d.ts","sourceRoot":"","sources":["../../../src/trace/trace.interface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAEhE,MAAM,WAAW,YAAY,CAAC,CAAC;IAC7B,MAAM,CAAC,EAAE,gBAAgB,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,gBAAgB,CAAC,OAAO,EAAE,KAAK,SAAS,YAAY;IACnE,SAAS,EAAE,cAAc,CAAC,KAAK,CAAC,CAAC;IACjC,MAAM,EAAE,gBAAgB,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC;CAC1C;AAED,oBAAY,cAAc,CAAC,KAAK,SAAS,YAAY,IAAI,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC;AAEnF,MAAM,WAAW,gBAAgB,CAAC,OAAO;IACvC,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,oBAAY,gBAAgB,CAAC,OAAO,EAAE,KAAK,SAAS,YAAY,IAAI,CAClE,IAAI,EAAE,gBAAgB,CAAC,OAAO,CAAC,EAC/B,KAAK,EAAE,KAAK,KACT,OAAO,CAAC"}
1
+ {"version":3,"file":"trace.interface.d.ts","sourceRoot":"","sources":["../../../src/trace/trace.interface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAEzD,MAAM,WAAW,YAAY,CAAC,CAAC;IAC7B,MAAM,CAAC,EAAE,gBAAgB,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,gBAAgB,CAAC,OAAO,EAAE,CAAC,SAAS,KAAK,CAAC,cAAc;IACvE,SAAS,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;IAC7B,MAAM,EAAE,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;CACtC;AAED,oBAAY,cAAc,CAAC,CAAC,SAAS,KAAK,CAAC,cAAc,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,OAAO,CAAC;AAEnF,MAAM,WAAW,gBAAgB,CAAC,OAAO;IACvC,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,oBAAY,gBAAgB,CAAC,OAAO,EAAE,CAAC,SAAS,KAAK,CAAC,cAAc,IAAI,CACtE,IAAI,EAAE,gBAAgB,CAAC,OAAO,CAAC,EAC/B,KAAK,EAAE,CAAC,KACL,OAAO,CAAC"}
@@ -1,4 +1,5 @@
1
- import { BaseRequest } from '@voiceflow/base-types';
1
+ import { BaseRequest, Trace } from '@voiceflow/base-types';
2
+ export { Trace } from '@voiceflow/base-types';
2
3
  declare type FetchFn = (...parameters: any[]) => Promise<any>;
3
4
  export interface RuntimeOptions<V = AuthVerify | PublicVerify> {
4
5
  url: string;
@@ -26,7 +27,7 @@ export interface RuntimeInteractRequest {
26
27
  export interface RuntimeInteractResponse {
27
28
  state: RuntimeState;
28
29
  request: RuntimeAction;
29
- trace: RuntimeTrace[];
30
+ trace: Trace.AnyTrace[];
30
31
  }
31
32
  export declare type RuntimeAction = BaseRequest.TextRequest | BaseRequest.LaunchRequest | BaseRequest.IntentRequest | BaseRequest.ActionRequest | BaseRequest.GeneralRequest | BaseRequest.BaseRequest<unknown>;
32
33
  export declare const isRuntimeAction: (value: unknown) => value is RuntimeAction;
@@ -49,75 +50,12 @@ export interface RuntimeState {
49
50
  storage: Record<string, any>;
50
51
  variables: Record<string, any>;
51
52
  }
52
- export declare const RuntimeTraceTypeSet: Set<"speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end">;
53
- export declare type RuntimeTraceType = typeof RuntimeTraceTypeSet extends Set<infer K> ? K : never;
54
- export declare const isRuntimeTraceType: (value: unknown) => value is "speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end";
55
- export interface RuntimeTrace<T extends RuntimeTraceType = RuntimeTraceType, P = unknown> {
56
- type: T;
57
- payload: P;
58
- }
59
- export declare const isRuntimeTrace: (value: unknown) => value is RuntimeTrace<"speak" | "text" | "choice" | "card" | "visual" | "audio" | "payload" | "stream" | "end", unknown>;
60
- export interface CardTracePayload {
61
- card: {
62
- type: string;
63
- title: string;
64
- text: string;
65
- image?: {
66
- largeImageUrl: string;
67
- alt: string;
68
- };
69
- };
70
- }
71
- export declare type CardTrace = RuntimeTrace<'card', CardTracePayload>;
72
- export declare const isCardTrace: (value: unknown) => value is CardTrace;
73
- export declare type ChoiceTrace = RuntimeTrace<'choice', ChoiceTracePayload>;
74
- export interface ChoiceTracePayload {
75
- buttons: {
76
- name: string;
77
- }[];
78
- }
79
- export declare const isChoiceTrace: (value: unknown) => value is ChoiceTrace;
80
- export interface PayloadTracePayload {
81
- data: any;
82
- }
83
- export declare type EndTrace = RuntimeTrace<'end'>;
84
- export declare const isEndTrace: (value: unknown) => value is EndTrace;
85
- export declare type PayloadTrace = RuntimeTrace<'payload', PayloadTracePayload>;
86
- export declare const isPayloadTrace: (value: unknown) => value is PayloadTrace;
87
- export interface SpeakTracePayload {
88
- voice?: string;
89
- src?: string;
90
- message: string;
91
- type: 'speak' | 'audio';
92
- }
93
- export declare type SpeakTrace = RuntimeTrace<'speak', SpeakTracePayload>;
94
- export declare const isSpeakTrace: (value: unknown) => value is SpeakTrace;
95
- export interface TextTracePayload {
96
- message: string;
97
- }
98
- export declare type TextTrace = RuntimeTrace<'text', TextTracePayload>;
99
- export declare const isTextTrace: (value: unknown) => value is TextTrace;
100
- export interface VisualTracePayload {
101
- image: string;
102
- }
103
- export declare type VisualTrace = RuntimeTrace<'visual', VisualTracePayload>;
104
- export declare const isVisualTrace: (value: unknown) => value is VisualTrace;
105
- export interface StreamTracePayload {
106
- src: string;
107
- loop: boolean;
108
- description?: string;
109
- title?: string;
110
- iconImage?: string;
111
- backgroundImage?: string;
112
- action: string;
113
- }
114
- export declare type StreamTrace = RuntimeTrace<'stream', StreamTracePayload>;
115
- export declare const isStreamTrace: (value: unknown) => value is StreamTrace;
53
+ export declare const isRuntimeTraceType: (value: unknown) => value is Trace.TraceType;
54
+ export declare const isRuntimeTrace: (value: unknown) => value is Trace.BaseTraceFrame<any, import("@voiceflow/base-types/build/cjs/node/utils").BaseTraceFramePath<import("@voiceflow/base-types/build/cjs/node/utils").BaseEvent>>;
116
55
  export interface RuntimeHttpRequest {
117
56
  method?: string;
118
57
  params?: URLSearchParams;
119
58
  body?: any;
120
59
  headers?: HeadersInit;
121
60
  }
122
- export {};
123
61
  //# sourceMappingURL=runtime.interface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.interface.d.ts","sourceRoot":"","sources":["../../../src/runtime/runtime.interface.ts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AAS,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAChC;AAED,eAAO,MAAM,kBAAkB,UAAW,OAAO,6BACoC,CAAC;AAEtF,eAAO,MAAM,cAAc,UAAW,OAAO,gLAGJ,CAAC;AAE1C,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,eAAe,CAAC;IACzB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,EAAE,WAAW,CAAC;CACvB"}
@@ -1,4 +1,5 @@
1
- import { BaseRequest } from '@voiceflow/base-types';
1
+ import { BaseRequest, Trace } from '@voiceflow/base-types';
2
+ export { Trace } from '@voiceflow/base-types';
2
3
  export const isAuthRuntimeOptions = (options) => {
3
4
  return !!options?.verify?.authorization;
4
5
  };
@@ -11,26 +12,7 @@ export const createIntentAction = (payload) => ({
11
12
  type: ActionType.INTENT,
12
13
  payload,
13
14
  });
14
- export const RuntimeTraceTypeSet = new Set([
15
- 'speak',
16
- 'text',
17
- 'choice',
18
- 'card',
19
- 'visual',
20
- 'audio',
21
- 'payload',
22
- 'stream',
23
- 'end',
24
- ]);
25
- export const isRuntimeTraceType = (value) => typeof value === 'string' && RuntimeTraceTypeSet.has(value);
15
+ export const isRuntimeTraceType = (value) => typeof value === 'string' && Object.values(Trace.TraceType).includes(value);
26
16
  export const isRuntimeTrace = (value) => typeof value === 'object' &&
27
17
  Object.prototype.hasOwnProperty.call(value, 'type') &&
28
18
  isRuntimeTraceType(value.type);
29
- export const isCardTrace = (value) => isRuntimeTrace(value) && value.type === 'card';
30
- export const isChoiceTrace = (value) => isRuntimeTrace(value) && value.type === 'choice';
31
- export const isEndTrace = (value) => isRuntimeTrace(value) && value.type === 'end';
32
- export const isPayloadTrace = (value) => isRuntimeTrace(value) && value.type === 'payload';
33
- export const isSpeakTrace = (value) => isRuntimeTrace(value) && value.type === 'speak';
34
- export const isTextTrace = (value) => isRuntimeTrace(value) && value.type === 'text';
35
- export const isVisualTrace = (value) => isRuntimeTrace(value) && value.type === 'visual';
36
- export const isStreamTrace = (value) => isRuntimeTrace(value) && value.type === 'stream';
@@ -1,3 +1,8 @@
1
- import type { CardTrace } from '../../runtime/runtime.interface.js';
2
- export declare const CardTraceComponent: import("../trace.component.js").TraceComponentOverload<CardTrace>;
1
+ import type { BaseNode } from '@voiceflow/base-types';
2
+ export declare const CardTraceComponent: import("../trace.component.js").TraceComponentOverload<{
3
+ type: 'card';
4
+ payload: {
5
+ card: BaseNode.Card.Card;
6
+ };
7
+ }>;
3
8
  //# sourceMappingURL=card.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"card.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/card.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAIhE,eAAO,MAAM,kBAAkB,mEAA0C,CAAC"}
1
+ {"version":3,"file":"card.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/card.component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAItD,eAAO,MAAM,kBAAkB;UAAgC,MAAM;aAAW;QAAE,IAAI,EAAE,SAAS,IAAI,CAAC,IAAI,CAAA;KAAE;EAAW,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Trace } from '../../runtime/runtime.interface.js';
2
+ export declare const CardV2TraceComponent: import("../trace.component.js").TraceComponentOverload<Trace.CardV2>;
3
+ //# sourceMappingURL=cardV2.component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cardV2.component.d.ts","sourceRoot":"","sources":["../../../../src/trace/components/cardV2.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,gCAAgC,CAAC;AAIvD,eAAO,MAAM,oBAAoB,sEAA8D,CAAC"}