@giosg/types 6.2.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/CHANGELOG.md +218 -0
- package/README.md +16 -0
- package/lib/.teams.d.ts.swp +0 -0
- package/lib/actions.d.ts +72 -0
- package/lib/actions.d.ts.map +1 -0
- package/lib/actions.js +60 -0
- package/lib/apps.d.ts +99 -0
- package/lib/apps.d.ts.map +1 -0
- package/lib/apps.js +1 -0
- package/lib/assets.d.ts +144 -0
- package/lib/assets.d.ts.map +1 -0
- package/lib/assets.js +1 -0
- package/lib/brands.d.ts +41 -0
- package/lib/brands.d.ts.map +1 -0
- package/lib/brands.js +1 -0
- package/lib/canned_answers.d.ts +26 -0
- package/lib/canned_answers.d.ts.map +1 -0
- package/lib/canned_answers.js +1 -0
- package/lib/chat.d.ts +1069 -0
- package/lib/chat.d.ts.map +1 -0
- package/lib/chat.js +1 -0
- package/lib/common.d.ts +7 -0
- package/lib/common.d.ts.map +1 -0
- package/lib/common.js +625 -0
- package/lib/conditions.d.ts +98 -0
- package/lib/conditions.d.ts.map +1 -0
- package/lib/conditions.js +77 -0
- package/lib/customer.d.ts +519 -0
- package/lib/customer.d.ts.map +1 -0
- package/lib/customer.js +1 -0
- package/lib/customership.d.ts +79 -0
- package/lib/customership.d.ts.map +1 -0
- package/lib/customership.js +1 -0
- package/lib/email.d.ts +47 -0
- package/lib/email.d.ts.map +1 -0
- package/lib/email.js +1 -0
- package/lib/experiments.d.ts +168 -0
- package/lib/experiments.d.ts.map +1 -0
- package/lib/experiments.js +1 -0
- package/lib/goals.d.ts +126 -0
- package/lib/goals.d.ts.map +1 -0
- package/lib/goals.js +1 -0
- package/lib/index.d.ts +34 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +6 -0
- package/lib/leadforms.d.ts +30 -0
- package/lib/leadforms.d.ts.map +1 -0
- package/lib/leadforms.js +1 -0
- package/lib/linkpreview.d.ts +16 -0
- package/lib/linkpreview.d.ts.map +1 -0
- package/lib/linkpreview.js +1 -0
- package/lib/oath.d.ts +75 -0
- package/lib/oath.d.ts.map +1 -0
- package/lib/oath.js +22 -0
- package/lib/partnerships.d.ts +54 -0
- package/lib/partnerships.d.ts.map +1 -0
- package/lib/partnerships.js +1 -0
- package/lib/permissions.d.ts +26 -0
- package/lib/permissions.d.ts.map +1 -0
- package/lib/permissions.js +1 -0
- package/lib/public.d.ts +387 -0
- package/lib/public.d.ts.map +1 -0
- package/lib/public.js +9 -0
- package/lib/rooms.d.ts +199 -0
- package/lib/rooms.d.ts.map +1 -0
- package/lib/rooms.js +1 -0
- package/lib/routers.d.ts +76 -0
- package/lib/routers.d.ts.map +1 -0
- package/lib/routers.js +1 -0
- package/lib/rules.d.ts +229 -0
- package/lib/rules.d.ts.map +1 -0
- package/lib/rules.js +1 -0
- package/lib/sharing.d.ts +111 -0
- package/lib/sharing.d.ts.map +1 -0
- package/lib/sharing.js +1 -0
- package/lib/shoppingcarts.d.ts +33 -0
- package/lib/shoppingcarts.d.ts.map +1 -0
- package/lib/shoppingcarts.js +1 -0
- package/lib/system.d.ts +21 -0
- package/lib/system.d.ts.map +1 -0
- package/lib/system.js +1 -0
- package/lib/target.d.ts +105 -0
- package/lib/target.d.ts.map +1 -0
- package/lib/target.js +1 -0
- package/lib/teams.d.ts +78 -0
- package/lib/teams.d.ts.map +1 -0
- package/lib/teams.js +1 -0
- package/lib/types.d.ts +223 -0
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +26 -0
- package/lib/uploads.d.ts +55 -0
- package/lib/uploads.d.ts.map +1 -0
- package/lib/uploads.js +1 -0
- package/lib/userclients.d.ts +79 -0
- package/lib/userclients.d.ts.map +1 -0
- package/lib/userclients.js +1 -0
- package/lib/variables.d.ts +41 -0
- package/lib/variables.d.ts.map +1 -0
- package/lib/variables.js +1 -0
- package/lib/visitor.d.ts +210 -0
- package/lib/visitor.d.ts.map +1 -0
- package/lib/visitor.js +1 -0
- package/lib/webhooks.d.ts +61 -0
- package/lib/webhooks.d.ts.map +1 -0
- package/lib/webhooks.js +1 -0
- package/package.json +23 -0
package/lib/routers.d.ts
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { UserUid, OrganizationUid, TeamUid, RouterUid, RouterStepUid } from "./types";
|
|
2
|
+
import { NestedUser, NestedOrganization } from "./customer";
|
|
3
|
+
import { NestedTeam } from "./teams";
|
|
4
|
+
export interface RouterStepPrecondition {
|
|
5
|
+
/** Type of precondition. Can be one of the following: users_offline, users_absent, task_waited */
|
|
6
|
+
type: "users_offline" | "users_absent" | "task_waited";
|
|
7
|
+
/** The value of the precondition. The interpretation depends on the precondition type:
|
|
8
|
+
users_offline: Percentage (%) of users that are offline in all previous steps. Value of 100 means that 100% of users are offline in all previous steps. Value of 0 means that all users are online in all previous steps.
|
|
9
|
+
users_absent: Percentage (%) of users that are absent in all previous steps. Value of 100 means that 100% of users are absent in all previous steps. Value of 0 means that all users are present in all previous steps.
|
|
10
|
+
task_waited: How many seconds the task has waited all in all. Value of 100 means that the task has waited for 100 seconds all in all.
|
|
11
|
+
Values are always integers!
|
|
12
|
+
*/
|
|
13
|
+
value: number;
|
|
14
|
+
}
|
|
15
|
+
export interface RouterStep {
|
|
16
|
+
/** The time when the router step was created */
|
|
17
|
+
created_at: string;
|
|
18
|
+
/** The user who created the router step */
|
|
19
|
+
created_by_user: NestedUser;
|
|
20
|
+
/** The id of the user who created the router step */
|
|
21
|
+
created_by_user_id: UserUid;
|
|
22
|
+
/** The unique identifier of this routing step */
|
|
23
|
+
id: RouterStepUid;
|
|
24
|
+
/** Index of the routing step relative to other routing steps in a router. Index is set automatically when router is created or updated. The first item in the router's steps array will get index of 0. */
|
|
25
|
+
index: number;
|
|
26
|
+
/** Array of organization IDs that tasks will be routed to. Can contain only your organization and your partner organizations. Can be an empty array. */
|
|
27
|
+
organization_ids: OrganizationUid[];
|
|
28
|
+
/** The organizations for which the router step may direct tasks */
|
|
29
|
+
organizations: NestedOrganization[];
|
|
30
|
+
/** Array of RouterStepPrecondition objects for this step. This should be an empty array for the first step. Otherwise it should contain at least one RouterStepPrecondition object! */
|
|
31
|
+
preconditions: RouterStepPrecondition[];
|
|
32
|
+
/** Array of team IDs that tasks will be routed to. Can contain only your organization's teams. Can be an empty array. */
|
|
33
|
+
team_ids: TeamUid[];
|
|
34
|
+
/** The teams for which the router step may direct tasks */
|
|
35
|
+
teams: NestedTeam[];
|
|
36
|
+
/** The time when the router step was last updated */
|
|
37
|
+
updated_at: string;
|
|
38
|
+
/** The user who last updated the router step */
|
|
39
|
+
updated_by_user: NestedUser;
|
|
40
|
+
/** The id of the user who last updated the router step */
|
|
41
|
+
updated_by_user_id: UserUid;
|
|
42
|
+
/** Array of user IDs that tasks will be routed to. Can contain only your organization's users. Can be an empty array. */
|
|
43
|
+
user_ids: UserUid[];
|
|
44
|
+
/** The users for which the router step may direct tasks */
|
|
45
|
+
users: NestedUser[];
|
|
46
|
+
}
|
|
47
|
+
export declare type RouterStepPayload = Pick<RouterStep, "organization_ids" | "preconditions" | "team_ids" | "user_ids">;
|
|
48
|
+
export interface Router {
|
|
49
|
+
/** The time when the router was created */
|
|
50
|
+
created_at: string;
|
|
51
|
+
/** The user who created the router */
|
|
52
|
+
created_by_user: NestedUser;
|
|
53
|
+
/** The id of the user who created the router */
|
|
54
|
+
created_by_user_id: UserUid;
|
|
55
|
+
/** The id of the router */
|
|
56
|
+
id: RouterUid;
|
|
57
|
+
/** The name of the router */
|
|
58
|
+
name: string;
|
|
59
|
+
/** The organization which owns the router */
|
|
60
|
+
organization: NestedOrganization;
|
|
61
|
+
/** The id of the organization which owns the router */
|
|
62
|
+
organization_id: OrganizationUid;
|
|
63
|
+
/** The router steps which belong to the router */
|
|
64
|
+
steps: RouterStep[];
|
|
65
|
+
/** The time when the router was last updated */
|
|
66
|
+
updated_at: string;
|
|
67
|
+
/** The user who last updated the router */
|
|
68
|
+
updated_by_user: NestedUser;
|
|
69
|
+
/** The id of the user who last updated the router */
|
|
70
|
+
updated_by_user_id: UserUid;
|
|
71
|
+
}
|
|
72
|
+
export interface RouterPayload extends Pick<Router, "name"> {
|
|
73
|
+
steps: RouterStepPayload[];
|
|
74
|
+
}
|
|
75
|
+
export declare type NestedRouter = Pick<Router, "id" | "name" | "organization" | "organization_id">;
|
|
76
|
+
//# sourceMappingURL=routers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"routers.d.ts","sourceRoot":"","sources":["../src/routers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACtF,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,MAAM,WAAW,sBAAsB;IACrC,kGAAkG;IAClG,IAAI,EAAE,eAAe,GAAG,cAAc,GAAG,aAAa,CAAC;IACvD;;;;;QAKI;IACJ,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,UAAU;IACzB,gDAAgD;IAChD,UAAU,EAAE,MAAM,CAAC;IACnB,2CAA2C;IAC3C,eAAe,EAAE,UAAU,CAAC;IAC5B,qDAAqD;IACrD,kBAAkB,EAAE,OAAO,CAAC;IAC5B,iDAAiD;IACjD,EAAE,EAAE,aAAa,CAAC;IAClB,2MAA2M;IAC3M,KAAK,EAAE,MAAM,CAAC;IACd,wJAAwJ;IACxJ,gBAAgB,EAAE,eAAe,EAAE,CAAC;IACpC,mEAAmE;IACnE,aAAa,EAAE,kBAAkB,EAAE,CAAC;IACpC,uLAAuL;IACvL,aAAa,EAAE,sBAAsB,EAAE,CAAC;IACxC,yHAAyH;IACzH,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,2DAA2D;IAC3D,KAAK,EAAE,UAAU,EAAE,CAAC;IACpB,qDAAqD;IACrD,UAAU,EAAE,MAAM,CAA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rganization, NestedUser } from "./customer";
|
|
3
|
+
import { NestedRoom } from "./rooms";
|
|
4
|
+
import { RuleUid, OrganizationUid, RoomUid, GoalUid, UserUid, RuleConditionUid, RuleActionUid } from "./types";
|
|
5
|
+
import { ConditionType, ConditionSettingsType } from "./conditions";
|
|
6
|
+
import { ActionType, ActionSettingsType } from "./actions";
|
|
7
|
+
export interface ExperimentRuleCondition {
|
|
8
|
+
/** Unique identifier of the rule condition */
|
|
9
|
+
id: RuleConditionUid;
|
|
10
|
+
/** Together with other conditions’ indices, defines the order in which the conditions are matched in the rule. Set automatically from the order of the conditions array */
|
|
11
|
+
index: number;
|
|
12
|
+
/** Defines whether the default or opposite match type shall be used */
|
|
13
|
+
is_opposite: boolean;
|
|
14
|
+
/** Type of the condition */
|
|
15
|
+
type: ConditionType;
|
|
16
|
+
/** The value related to the type. Required with most types */
|
|
17
|
+
value: string | null;
|
|
18
|
+
/** Other condition settings. Required with some condition types */
|
|
19
|
+
settings: ConditionSettingsType;
|
|
20
|
+
}
|
|
21
|
+
export interface ExperimentRuleConditionPayload {
|
|
22
|
+
/** Defines whether the default or opposite match type shall be used */
|
|
23
|
+
is_opposite?: boolean;
|
|
24
|
+
/** Type of the condition */
|
|
25
|
+
type: ConditionType;
|
|
26
|
+
/** The value related to the type. Required with most types */
|
|
27
|
+
value?: string | null;
|
|
28
|
+
/** Other condition settings. Required with some condition types */
|
|
29
|
+
settings?: ConditionSettingsType;
|
|
30
|
+
}
|
|
31
|
+
export interface ExperimentRule {
|
|
32
|
+
/** Unique identifier of the rule */
|
|
33
|
+
id: RuleUid;
|
|
34
|
+
/** Name of the rule */
|
|
35
|
+
name: string;
|
|
36
|
+
/** Organization that owns the rule */
|
|
37
|
+
organization: NestedOrganization;
|
|
38
|
+
/** Unique identifier of the organization that owns the rule */
|
|
39
|
+
organization_id: OrganizationUid;
|
|
40
|
+
/** Ordered list of conditions of the rule. The list order defines the matching order */
|
|
41
|
+
conditions: ExperimentRuleCondition[];
|
|
42
|
+
/** Ordered list of actions of the rule. The list order defines the execution order */
|
|
43
|
+
actions: RuleAction[];
|
|
44
|
+
/** A list of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
45
|
+
rooms: NestedRoom[];
|
|
46
|
+
/** A list of unique identifiers of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
47
|
+
room_ids: RoomUid[];
|
|
48
|
+
/** The goal set for the rule */
|
|
49
|
+
goal: NestedGoal;
|
|
50
|
+
/** Unique identifier of the goal set for the rule */
|
|
51
|
+
goal_id: GoalUid;
|
|
52
|
+
/** Type of the rule */
|
|
53
|
+
type: "experiment";
|
|
54
|
+
/** How often the rule can match. By default is null and the rule can match every time the conditions change or the page is loaded */
|
|
55
|
+
match_once_per: "session" | "page" | "visitor" | null;
|
|
56
|
+
/** Defines whether the rule was created automatically instead of being created from the Rule management UI */
|
|
57
|
+
is_auto_generated: boolean;
|
|
58
|
+
/** Defines whether the rule is protected and cannot be deleted */
|
|
59
|
+
is_protected: boolean;
|
|
60
|
+
/** Defines whether the rule is currently enabled */
|
|
61
|
+
is_enabled: boolean;
|
|
62
|
+
/** Defines whether the rule can be triggered in all of the organization’s rooms */
|
|
63
|
+
is_global: boolean;
|
|
64
|
+
/** Date when the rule was created */
|
|
65
|
+
created_at: string;
|
|
66
|
+
/** Date when the rule was changed for the last time */
|
|
67
|
+
updated_at: string;
|
|
68
|
+
/** User who created the rule*/
|
|
69
|
+
created_by_user: NestedUser;
|
|
70
|
+
/** Unique identifier of the user who created the rule */
|
|
71
|
+
created_by_user_id: UserUid;
|
|
72
|
+
/** User who changed the rule for the last time */
|
|
73
|
+
updated_by_user: NestedUser;
|
|
74
|
+
/** Unique identifier of the user who changed the rule for the last time */
|
|
75
|
+
updated_by_user_id: UserUid;
|
|
76
|
+
}
|
|
77
|
+
export interface ExperimentRulePayload {
|
|
78
|
+
/** Name of the rule */
|
|
79
|
+
name: string;
|
|
80
|
+
/** Ordered list of conditions of the rule. The list order defines the matching order */
|
|
81
|
+
conditions?: ExperimentRuleConditionPayload[];
|
|
82
|
+
/** Ordered list of actions of the rule. The list order defines the execution order */
|
|
83
|
+
actions: RuleActionPayload[];
|
|
84
|
+
/** A list of unique identifiers of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
85
|
+
room_ids?: RoomUid[];
|
|
86
|
+
/** Unique identifier of the goal set for the rule */
|
|
87
|
+
goal_id?: GoalUid;
|
|
88
|
+
/** Type of the rule */
|
|
89
|
+
type?: "experiment";
|
|
90
|
+
/** How often the rule can match. By default is null and the rule can match every time the conditions change or the page is loaded */
|
|
91
|
+
match_once_per?: "session" | "page" | "visitor" | null;
|
|
92
|
+
/** Defines whether the rule is currently enabled */
|
|
93
|
+
is_enabled?: boolean;
|
|
94
|
+
/** Defines whether the rule can be triggered in all of the organization’s rooms */
|
|
95
|
+
is_global?: boolean;
|
|
96
|
+
}
|
|
97
|
+
export interface RuleAction {
|
|
98
|
+
/** Unique identifier of the rule action */
|
|
99
|
+
id: RuleActionUid;
|
|
100
|
+
/** Together with other actions’ indices, defines the order in which the actions are executed in the rule. Set automatically from the order of the conditions array */
|
|
101
|
+
index: number;
|
|
102
|
+
/** Type of the action */
|
|
103
|
+
type: ActionType;
|
|
104
|
+
/** The value related to the type. Required with most types */
|
|
105
|
+
value: string | null;
|
|
106
|
+
/** Other action settings. Required with some action types */
|
|
107
|
+
settings: ActionSettingsType;
|
|
108
|
+
}
|
|
109
|
+
export interface RuleActionPayload {
|
|
110
|
+
/** Type of the action */
|
|
111
|
+
type: ActionType;
|
|
112
|
+
/** The value related to the type. Required with most types */
|
|
113
|
+
value?: string | null;
|
|
114
|
+
/** Other action settings. Required with some action types */
|
|
115
|
+
settings?: ActionSettingsType;
|
|
116
|
+
/** Order of the rule action */
|
|
117
|
+
index?: number;
|
|
118
|
+
}
|
|
119
|
+
export interface RuleCondition {
|
|
120
|
+
/** Unique identifier of the rule */
|
|
121
|
+
id: RuleConditionUid;
|
|
122
|
+
/** Together with other conditions’ indices, defines the order in which the conditions are matched in the rule. Set automatically from the order of the conditions array */
|
|
123
|
+
index: number;
|
|
124
|
+
/** Defines whether the default or opposite match type shall be used */
|
|
125
|
+
is_opposite: boolean;
|
|
126
|
+
/** Type of the condition */
|
|
127
|
+
type: ConditionType;
|
|
128
|
+
/** The value related to the type. Required with most types */
|
|
129
|
+
value: string | null;
|
|
130
|
+
/** Other condition settings. Required with some condition types */
|
|
131
|
+
settings: ConditionSettingsType;
|
|
132
|
+
}
|
|
133
|
+
export interface RuleConditionPayload {
|
|
134
|
+
/** Defines whether the default or opposite match type shall be used */
|
|
135
|
+
is_opposite?: boolean;
|
|
136
|
+
/** Type of the condition */
|
|
137
|
+
type: ConditionType;
|
|
138
|
+
/** The value related to the type. Required with most types */
|
|
139
|
+
value?: string | null;
|
|
140
|
+
/** Other condition settings. Required with some condition types */
|
|
141
|
+
settings?: ConditionSettingsType;
|
|
142
|
+
}
|
|
143
|
+
export interface Rule {
|
|
144
|
+
/** Unique identifier of the rule */
|
|
145
|
+
id: RuleUid;
|
|
146
|
+
/** Name of the rule */
|
|
147
|
+
name: string;
|
|
148
|
+
/** Organization that owns the rule */
|
|
149
|
+
organization: NestedOrganization;
|
|
150
|
+
/** Unique identifier of the organization that owns the rule */
|
|
151
|
+
organization_id: OrganizationUid;
|
|
152
|
+
/** Ordered list of conditions of the rule. The list order defines the matching order */
|
|
153
|
+
conditions: RuleCondition[];
|
|
154
|
+
/** Ordered list of actions of the rule. The list order defines the execution order */
|
|
155
|
+
actions: RuleAction[];
|
|
156
|
+
/** A list of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
157
|
+
rooms: NestedRoom[];
|
|
158
|
+
/** A list of unique identifiers of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
159
|
+
room_ids: RoomUid[];
|
|
160
|
+
/** The goal set for the rule */
|
|
161
|
+
goal: NestedGoal;
|
|
162
|
+
/** Unique identifier of the goal set for the rule */
|
|
163
|
+
goal_id: GoalUid;
|
|
164
|
+
/** Type of the rule */
|
|
165
|
+
type: "normal" | "target" | "experiment";
|
|
166
|
+
/** How often the rule can match. By default is null and the rule can match every time the conditions change or the page is loaded */
|
|
167
|
+
match_once_per: "session" | "page" | "visitor" | null;
|
|
168
|
+
/** Defines whether the rule was created automatically instead of being created from the rule management UI */
|
|
169
|
+
is_auto_generated: boolean;
|
|
170
|
+
/** Defines whether the rule is protected and cannot be deleted */
|
|
171
|
+
is_protected: boolean;
|
|
172
|
+
/** Defines whether the rule is currently enabled */
|
|
173
|
+
is_enabled: boolean;
|
|
174
|
+
/** Defines whether the rule can be triggered in all of the organization’s rooms */
|
|
175
|
+
is_global: boolean;
|
|
176
|
+
/** Date when the rule was created */
|
|
177
|
+
created_at: string;
|
|
178
|
+
/** Date when the rule was changed for the last time */
|
|
179
|
+
updated_at: string;
|
|
180
|
+
/** User who created the rule*/
|
|
181
|
+
created_by_user: NestedUser;
|
|
182
|
+
/** Unique identifier of the user who created the rule*/
|
|
183
|
+
created_by_user_id: UserUid;
|
|
184
|
+
/** User who changed the rule for the last time*/
|
|
185
|
+
updated_by_user: NestedUser;
|
|
186
|
+
/** Unique identifier of the user who changed the rule for the last time*/
|
|
187
|
+
updated_by_user_id: UserUid;
|
|
188
|
+
}
|
|
189
|
+
export interface RulePayload {
|
|
190
|
+
/** Name of the rule */
|
|
191
|
+
name: string;
|
|
192
|
+
/** Ordered list of conditions of the rule. The list order defines the matching order */
|
|
193
|
+
conditions?: RuleConditionPayload[];
|
|
194
|
+
/** Ordered list of actions of the rule. The list order defines the execution order */
|
|
195
|
+
actions: RuleActionPayload[];
|
|
196
|
+
/** A list of unique identifiers of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
197
|
+
room_ids?: RoomUid[];
|
|
198
|
+
/** Unique identifier of the goal set for the rule */
|
|
199
|
+
goal_id?: GoalUid;
|
|
200
|
+
/** Type of the rule */
|
|
201
|
+
type?: "normal" | "target";
|
|
202
|
+
/** How often the rule can match. By default is null and the rule can match every time the conditions change or the page is loaded */
|
|
203
|
+
match_once_per?: "session" | "page" | "visitor" | null;
|
|
204
|
+
/** Defines whether the rule is currently enabled */
|
|
205
|
+
is_enabled?: boolean;
|
|
206
|
+
/** Defines whether the rule can be triggered in all of the organization’s rooms */
|
|
207
|
+
is_global?: boolean;
|
|
208
|
+
}
|
|
209
|
+
export interface RuleUpdatePayload {
|
|
210
|
+
/** Name of the rule */
|
|
211
|
+
name?: string;
|
|
212
|
+
/** Ordered list of conditions of the rule. The list order defines the matching order */
|
|
213
|
+
conditions?: RuleConditionPayload[];
|
|
214
|
+
/** Ordered list of actions of the rule. The list order defines the execution order */
|
|
215
|
+
actions?: RuleActionPayload[];
|
|
216
|
+
/** A list of unique identifiers of rooms where the rule can be triggered. Can only be set if "is_global" is false */
|
|
217
|
+
room_ids?: RoomUid[];
|
|
218
|
+
/** Unique identifier of the goal set for the rule */
|
|
219
|
+
goal_id?: GoalUid;
|
|
220
|
+
/** Type of the rule */
|
|
221
|
+
type?: "normal" | "target";
|
|
222
|
+
/** How often the rule can match. By default is null and the rule can match every time the conditions change or the page is loaded */
|
|
223
|
+
match_once_per?: "session" | "page" | "visitor" | null;
|
|
224
|
+
/** Defines whether the rule is currently enabled */
|
|
225
|
+
is_enabled?: boolean;
|
|
226
|
+
/** Defines whether the rule can be triggered in all of the organization’s rooms */
|
|
227
|
+
is_global?: boolean;
|
|
228
|
+
}
|
|
229
|
+
//# sourceMappingURL=rules.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rules.d.ts","sourceRoot":"","sources":["../src/rules.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EACL,OAAO,EACP,eAAe,EACf,OAAO,EACP,OAAO,EACP,OAAO,EACP,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uB;IACvB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAE3B,qIAAqI;IACrI,cAAc,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;IAEvD,oDAAoD;IACpD,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB,mFAAmF;IACnF,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,MAAM,WAAW,iBAAiB;IAChC,uBAAuB;IACvB,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,wFAAwF;IACxF,UAAU,CAAC,EAAE,oBAAoB,EAAE,CAAC;IAEpC,sFAAsF;IACtF,OAAO,CAAC,EAAE,iBAAiB,EAAE,CAAC;IAE9B,qHAAqH;IACrH,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAC;IAErB,qDAAqD;IACrD,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB,uBAAuB;IACvB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAE3B,qIAAqI;IACrI,cAAc,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;IAEvD,oDAAoD;IACpD,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB,mFAAmF;IACnF,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB"}
|
package/lib/rules.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/lib/sharing.d.ts
ADDED
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { NestedGiosgApp } from "./apps";
|
|
2
|
+
import { NestedOrganization, NestedUser } from "./customer";
|
|
3
|
+
import { NestedRoom } from "./rooms";
|
|
4
|
+
import { OrganizationUid, AppShareUid, RoomShareUid, RoomUid, UserUid, RouterUid, TeamShareUid, TeamUid } from "./types";
|
|
5
|
+
import { Router } from "./routers";
|
|
6
|
+
import { NestedTeam, NestedIncomingSharedTeam } from "./teams";
|
|
7
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
8
|
+
export interface AppShare {
|
|
9
|
+
id: AppShareUid;
|
|
10
|
+
organization_id: OrganizationUid;
|
|
11
|
+
organization: NestedOrganization;
|
|
12
|
+
app_id: string;
|
|
13
|
+
app: NestedGiosgApp;
|
|
14
|
+
app_organization_id: OrganizationUid;
|
|
15
|
+
app_organization: NestedOrganization;
|
|
16
|
+
created_at: string;
|
|
17
|
+
updated_at: string;
|
|
18
|
+
created_by_user_id: string;
|
|
19
|
+
created_by_user: NestedUser;
|
|
20
|
+
updated_by_user_id: string;
|
|
21
|
+
updated_by_user: NestedUser;
|
|
22
|
+
}
|
|
23
|
+
export interface AppSharePayload {
|
|
24
|
+
organization_id: OrganizationUid;
|
|
25
|
+
}
|
|
26
|
+
interface RoomShare {
|
|
27
|
+
/** Unique identifier for the share resource. */
|
|
28
|
+
id: RoomShareUid;
|
|
29
|
+
/** ID of the partner organization to whom the room resource is shared. Must be an existing partner. Cannot be changed after creation. */
|
|
30
|
+
organization_id: OrganizationUid;
|
|
31
|
+
/** The organization object to whom the room resource was shared. */
|
|
32
|
+
organization: NestedOrganization;
|
|
33
|
+
/** ID of the organization who shared the room resource. */
|
|
34
|
+
room_organization_id: OrganizationUid;
|
|
35
|
+
/** The organization object who shared the room resource. */
|
|
36
|
+
room_organization: NestedOrganization;
|
|
37
|
+
/** ID of the room resource. */
|
|
38
|
+
room_id: RoomUid;
|
|
39
|
+
/** The room object. */
|
|
40
|
+
room: NestedRoom;
|
|
41
|
+
/** When the room resource was shared. */
|
|
42
|
+
created_at: string;
|
|
43
|
+
/** When was the last time the sharing was updated. This cannot change currently after creation. */
|
|
44
|
+
updated_at: string;
|
|
45
|
+
/** ID of the user who shared the room resource. */
|
|
46
|
+
created_by_user_id: UserUid;
|
|
47
|
+
/** The user resource who shared the room resource, with all of the available attributes. */
|
|
48
|
+
created_by_user: NestedUser;
|
|
49
|
+
/** ID of the last user which updated this room share resource. */
|
|
50
|
+
updated_by_user_id: UserUid;
|
|
51
|
+
/** Last user which updated this room share resource. This cannot change currently after creation. */
|
|
52
|
+
updated_by_user: NestedUser;
|
|
53
|
+
}
|
|
54
|
+
export declare type RoomSharePayload = Pick<RoomShare, "organization_id" | "room_id">;
|
|
55
|
+
export interface OutgoingRoomShare extends RoomShare {
|
|
56
|
+
/** The router resource which is set to this room resource by the organization for whom the room is shared to. */
|
|
57
|
+
organization_router: {
|
|
58
|
+
/** The ID of the router resource. */
|
|
59
|
+
id: RouterUid;
|
|
60
|
+
};
|
|
61
|
+
/** The router resource which is set to this room resource by the room owner organization. */
|
|
62
|
+
room_organization_router: Router;
|
|
63
|
+
}
|
|
64
|
+
export interface IncomingRoomShare extends RoomShare {
|
|
65
|
+
/** The router resource which is set to this room resource by the organization for whom the room is shared to. */
|
|
66
|
+
organization_router: Router;
|
|
67
|
+
/** The router resource which is set to this room resource by the room owner organization. */
|
|
68
|
+
room_organization_router: {
|
|
69
|
+
/** The ID of the router resource. */
|
|
70
|
+
id: RouterUid;
|
|
71
|
+
/** Defines whether the router resource is routing tasks to the organization for whom the room is shared to. */
|
|
72
|
+
is_routing_to_receiver_organization: boolean;
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
interface TeamShare {
|
|
76
|
+
/** Unique identifier for the shared resource. */
|
|
77
|
+
id: TeamShareUid;
|
|
78
|
+
/** ID of the partner organization to whom the team resource is shared. Must be an existing partner. Cannot be changed after creation. */
|
|
79
|
+
organization_id: OrganizationUid;
|
|
80
|
+
/** The organization object to whom the team resource was shared. */
|
|
81
|
+
organization: NestedOrganization;
|
|
82
|
+
/** ID of the organization who shared the team resource. */
|
|
83
|
+
team_organization_id: OrganizationUid;
|
|
84
|
+
/** The organization object who shared the team resource. */
|
|
85
|
+
team_organization: NestedOrganization;
|
|
86
|
+
/** ID of the team resource. */
|
|
87
|
+
team_id: TeamUid;
|
|
88
|
+
/** When the team resource was shared. */
|
|
89
|
+
created_at: string;
|
|
90
|
+
/** When was the last time the sharing was updated. This cannot change currently after creation. */
|
|
91
|
+
updated_at: string;
|
|
92
|
+
/** ID of the user who shared the team resource. */
|
|
93
|
+
created_by_user_id: UserUid;
|
|
94
|
+
/** The user resource who shared the team resource, with all of the available attributes. */
|
|
95
|
+
created_by_user: NestedUser;
|
|
96
|
+
/** ID of the last user which updated this team share resource. */
|
|
97
|
+
updated_by_user_id: UserUid;
|
|
98
|
+
/** Last user which updated this team share resource. This cannot change currently after creation. */
|
|
99
|
+
updated_by_user: NestedUser;
|
|
100
|
+
}
|
|
101
|
+
export interface IncomingTeamShare extends TeamShare {
|
|
102
|
+
/** The team object. */
|
|
103
|
+
team: NestedIncomingSharedTeam;
|
|
104
|
+
}
|
|
105
|
+
export interface OutgoingTeamShare extends TeamShare {
|
|
106
|
+
/** The team object. */
|
|
107
|
+
team: NestedTeam;
|
|
108
|
+
}
|
|
109
|
+
export declare type TeamSharePayload = Pick<TeamShare, "organization_id" | "team_id">;
|
|
110
|
+
export {};
|
|
111
|
+
//# sourceMappingURL=sharing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharing.d.ts","sourceRoot":"","sources":["../src/sharing.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EACL,eAAe,EACf,WAAW,EACX,YAAY,EACZ,OAAO,EACP,OAAO,EACP,SAAS,EACT,YAAY,EACZ,OAAO,EACR,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAE/D,uDAAuD;AACvD,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,WAAW,CAAC;IAChB,eAAe,EAAE,eAAe,CAAC;IACjC,YAAY,EAAE,kB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1,33 @@
|
|
|
1
|
+
import { ShoppingCartProductUid, ShoppingCartUid, VisitorCid, VisitorSessionCid } from "./types";
|
|
2
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
3
|
+
export interface ShoppingCartProduct {
|
|
4
|
+
id: ShoppingCartProductUid;
|
|
5
|
+
shopping_cart_id: ShoppingCartUid;
|
|
6
|
+
created_at: string;
|
|
7
|
+
updated_at: string;
|
|
8
|
+
is_deleted: boolean;
|
|
9
|
+
deleted_at: string | null;
|
|
10
|
+
name: string;
|
|
11
|
+
description: string;
|
|
12
|
+
category_name: string;
|
|
13
|
+
value: string;
|
|
14
|
+
subscription_value: string;
|
|
15
|
+
product_number: string;
|
|
16
|
+
quantity: number;
|
|
17
|
+
monthly_quantity: number;
|
|
18
|
+
stock_balance: number;
|
|
19
|
+
}
|
|
20
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
21
|
+
export interface ShoppingCart {
|
|
22
|
+
id: ShoppingCartUid;
|
|
23
|
+
visitor_id: VisitorCid;
|
|
24
|
+
session_id: VisitorSessionCid;
|
|
25
|
+
created_at: string;
|
|
26
|
+
updated_at: string;
|
|
27
|
+
total_value: string;
|
|
28
|
+
total_subscription_value: string;
|
|
29
|
+
currency: string;
|
|
30
|
+
is_locked: boolean;
|
|
31
|
+
locked_at: string | null;
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=shoppingcarts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shoppingcarts.d.ts","sourceRoot":"","sources":["../src/shoppingcarts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEjG,uDAAuD;AACvD,MAAM,WAAW,mBAAmB;IAClC,EAAE,EAAE,sBAAsB,CAAC;IAC3B,gBAAgB,EAAE,eAAe,CAAC;IAClC,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB,EAAE,MAAM,CAAC;IAC3B,cAAc,EAAE,MAAM,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,gBAAgB,EAAE,MAAM,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,uDAAuD;AACvD,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,eAAe,CAAC;IACpB,UAAU,EAAE,UAAU,CAAC;IACvB,UAAU,EAAE,iBAAiB,CAAC;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,wBAAwB,EAAE,MAAM,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;CAC1B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/lib/system.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { LanguageCode } from "./common";
|
|
2
|
+
import { UserPermissionScope } from "./types";
|
|
3
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
4
|
+
export interface EndpointMethod {
|
|
5
|
+
name: string;
|
|
6
|
+
scopes: UserPermissionScope[];
|
|
7
|
+
}
|
|
8
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
9
|
+
export interface Endpoint {
|
|
10
|
+
url_pattern: string;
|
|
11
|
+
methods: EndpointMethod[];
|
|
12
|
+
comment: string;
|
|
13
|
+
}
|
|
14
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
15
|
+
export interface Language {
|
|
16
|
+
rfc_3066: LanguageCode;
|
|
17
|
+
name: string;
|
|
18
|
+
is_ui_language: boolean;
|
|
19
|
+
language_bidi: string;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=system.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../src/system.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAE9C,uDAAuD;AACvD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,mBAAmB,EAAE,CAAC;CAC/B;AAED,uDAAuD;AACvD,MAAM,WAAW,QAAQ;IACvB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,cAAc,EAAE,CAAC;IAC1B,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,uDAAuD;AACvD,MAAM,WAAW,QAAQ;IACvB,QAAQ,EAAE,YAAY,CAAC;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,cAAc,EAAE,OAAO,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;CACvB"}
|
package/lib/system.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/lib/target.d.ts
ADDED
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { Experiment } from "./experiments";
|
|
2
|
+
import { NestedOrganization } from "./customer";
|
|
3
|
+
import { NestedUser } from "./customer";
|
|
4
|
+
import { RuleUid, ExperimentUid, RoomUid, OrganizationUid, UserUid, VisitorGid, TargetConfigUid, VisitorPredictionUid, VisitorSessionPredictionUid, VisitorSessionGid } from "./types";
|
|
5
|
+
import { NestedRoom } from "./rooms";
|
|
6
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
7
|
+
export interface NestedTargetRule {
|
|
8
|
+
uuid: RuleUid;
|
|
9
|
+
name: string;
|
|
10
|
+
}
|
|
11
|
+
export declare type TargetAlgorithmVersion = "1.0" | "1.1";
|
|
12
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
13
|
+
export interface NestedTargetConfig {
|
|
14
|
+
id: TargetConfigUid;
|
|
15
|
+
algorithm_version: TargetAlgorithmVersion;
|
|
16
|
+
}
|
|
17
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
18
|
+
export interface TargetConfig {
|
|
19
|
+
id: TargetConfigUid;
|
|
20
|
+
algorithm_version: TargetAlgorithmVersion;
|
|
21
|
+
/** Decimal value which is serialized into string to preserve accuracy. */
|
|
22
|
+
prediction_threshold_low: string;
|
|
23
|
+
/** Decimal value which is serialized into string to preserve accuracy. */
|
|
24
|
+
prediction_threshold_high: string;
|
|
25
|
+
pageviews_before_prediction_count: number;
|
|
26
|
+
experiment_id: ExperimentUid | null;
|
|
27
|
+
is_enabled: boolean;
|
|
28
|
+
room_ids: RoomUid[];
|
|
29
|
+
rooms: NestedRoom[];
|
|
30
|
+
organization_id: OrganizationUid;
|
|
31
|
+
organization: NestedOrganization;
|
|
32
|
+
updated_at: string;
|
|
33
|
+
updated_by_user_id: UserUid;
|
|
34
|
+
updated_by_user: NestedUser;
|
|
35
|
+
created_at: string;
|
|
36
|
+
created_by_user_id: UserUid;
|
|
37
|
+
created_by_user: NestedUser;
|
|
38
|
+
treatment_rule: NestedTargetRule | null;
|
|
39
|
+
}
|
|
40
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
41
|
+
export interface TargetExperiment {
|
|
42
|
+
id: ExperimentUid;
|
|
43
|
+
created_at: string;
|
|
44
|
+
updated_at: string;
|
|
45
|
+
target_id: TargetConfigUid;
|
|
46
|
+
experiment: Experiment;
|
|
47
|
+
target_mode: "data_collection" | "ab_test";
|
|
48
|
+
}
|
|
49
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
50
|
+
export interface TargetedAction {
|
|
51
|
+
type: string;
|
|
52
|
+
rule_id: RuleUid;
|
|
53
|
+
}
|
|
54
|
+
export interface TargetedActionPayload {
|
|
55
|
+
type: string;
|
|
56
|
+
rule_id: RuleUid;
|
|
57
|
+
}
|
|
58
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
59
|
+
export interface VisitorPredictionList {
|
|
60
|
+
id: VisitorPredictionUid;
|
|
61
|
+
created_at: string;
|
|
62
|
+
room_id: RoomUid;
|
|
63
|
+
rule_id: RuleUid;
|
|
64
|
+
}
|
|
65
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
66
|
+
export interface VisitorPrediction {
|
|
67
|
+
room_id: RoomUid;
|
|
68
|
+
visitor_id: VisitorGid;
|
|
69
|
+
session_id: VisitorSessionGid;
|
|
70
|
+
prediction_value: boolean;
|
|
71
|
+
is_random_group: boolean;
|
|
72
|
+
targeted_action: TargetedAction;
|
|
73
|
+
}
|
|
74
|
+
export interface VisitorPredictionPayload {
|
|
75
|
+
room_id: RoomUid;
|
|
76
|
+
visitor_id: VisitorGid;
|
|
77
|
+
session_id: VisitorSessionGid;
|
|
78
|
+
prediction_value: boolean;
|
|
79
|
+
is_random_group: boolean;
|
|
80
|
+
targeted_action: TargetedAction;
|
|
81
|
+
}
|
|
82
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
83
|
+
export interface VisitorSessionPrediction {
|
|
84
|
+
id: VisitorSessionPredictionUid;
|
|
85
|
+
visitor_id: VisitorGid;
|
|
86
|
+
session_id: VisitorSessionGid;
|
|
87
|
+
created_at: string;
|
|
88
|
+
type: string;
|
|
89
|
+
/** TODO: Type me if you can! */
|
|
90
|
+
value: {
|
|
91
|
+
[key: string]: any;
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
/** TODO: Add jsdocs and check nullability of fields */
|
|
95
|
+
export interface VisitorSessionPredictionPayload {
|
|
96
|
+
visitor_id: VisitorGid;
|
|
97
|
+
session_id: VisitorSessionGid;
|
|
98
|
+
created_at: string;
|
|
99
|
+
type: string;
|
|
100
|
+
/** TODO: Type me if you can! */
|
|
101
|
+
value: {
|
|
102
|
+
[key: string]: any;
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
//# sourceMappingURL=target.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../src/target.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AACxC,OAAO,EACL,OAAO,EACP,aAAa,EACb,OAAO,EACP,eAAe,EACf,OAAO,EACP,UAAU,EACV,eAAe,EACf,oBAAoB,EACpB,2BAA2B,EAC3B,iBAAiB,EAClB,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,uDAAuD;AACvD,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,OAAO,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CACd;AAED,oBAAY,sBAAsB,GAAG,KAAK,GAAG,KAAK,CAAC;AAEnD,uDAAuD;AACvD,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,eAAe,CAAC;IACpB,iBAAiB,EAAE,sBAAsB,CAAC;CAC3C;AAED,uDAAuD;AACvD,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,eAAe,CAAC;IACpB,iBAAiB,EAAE,sBAAsB,CAAC;IAE1C,0EAA0E;IAC1E,wBAAwB,EAAE,MAAM,CAAC;IAEjC,0EAA0E;IAC1E,yBAAyB,EAAE,MAAM,CAAC;IAClC,iCAAiC,EAAE,MAAM,CAAC;IAC1C,aAAa,EAAE,aAAa,GAAG,IAAI,CAAC;IACpC,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,KAAK,EAAE,UAAU,EAAE,CAAC;IACpB,eAAe,EAAE,eAAe,CAAC;IAC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