@trii/types 2.10.813 → 2.10.814
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/Automations/Events/Event.d.ts +3 -3
- package/dist/Contacts/CommunicationEndpoint.d.ts +9 -9
- package/dist/Conversations/Classifications/ConversationClassificationEvents.d.ts +2 -2
- package/dist/Conversations/Conversation.d.ts +8 -8
- package/dist/Conversations/InboxMongo.d.ts +154 -0
- package/dist/Conversations/InboxMongo.js +128 -0
- package/dist/Conversations/InboxProjection.d.ts +162 -0
- package/dist/Conversations/Routing.d.ts +10 -10
- package/dist/Events/DomainEventTypes.d.ts +23 -23
- package/dist/Tickets/Api.d.ts +16 -0
- package/dist/Tickets/Approval.d.ts +116 -114
- package/dist/Tickets/Approval.js +50 -17
- package/dist/Tickets/Category.d.ts +8 -0
- package/dist/Tickets/Conversation.d.ts +12 -0
- package/dist/Tickets/Roles.d.ts +91 -0
- package/dist/Tickets/Roles.js +7 -0
- package/dist/Tickets/Routing.d.ts +10 -0
- package/dist/Tickets/Routing.js +7 -1
- package/dist/Tickets/Security.d.ts +34 -0
- package/dist/Tickets/SelfService.d.ts +17 -0
- package/dist/Tickets/Ticket.d.ts +24 -3
- package/dist/Tickets/Workflow.d.ts +47 -0
- package/dist/Tickets/Workflow.js +4 -0
- package/dist/Tickets/index.d.ts +1 -0
- package/dist/Tickets/index.js +1 -0
- package/package.json +1 -1
- package/dist/AI/MapPolygon.d.ts +0 -22
- package/dist/Conversations/DashBoard/dashboardForms.d.ts +0 -44
- package/dist/Conversations/DashBoard/dashboardForms.js +0 -24
- package/dist/Conversations/Flows/Nodes/NodeAIChatBot.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeAIChatBot.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeApi.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeApi.js +0 -183
- package/dist/Conversations/Flows/Nodes/NodeBotIA.d.ts +0 -15
- package/dist/Conversations/Flows/Nodes/NodeBotIA.js +0 -6
- package/dist/Conversations/Flows/Nodes/NodeChatBotIA.d.ts +0 -15
- package/dist/Conversations/Flows/Nodes/NodeChatBotIA.js +0 -6
- package/dist/Conversations/Flows/Nodes/NodeConditional.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConditional.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeContactSearch.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeContactSearch.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeContactUpdate.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeContactUpdate.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationAssignTo.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationAssignTo.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationFinalize.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationFinalize.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationUpdate.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeConversationUpdate.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeFillForm.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeFillForm.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeFillTicket.d.ts +0 -1
- package/dist/Conversations/Flows/Nodes/NodeFillTicket.js +0 -9
- package/dist/Conversations/Flows/Nodes/NodeGoogleCalendar.d.ts +0 -20
- package/dist/Conversations/Flows/Nodes/NodeGoogleCalendar.js +0 -2
- package/dist/Conversations/Flows/Nodes/NodeGoogleMaps copy.d.ts +0 -12
- package/dist/Conversations/Flows/Nodes/NodeGoogleMaps copy.js +0 -6
- package/dist/Conversations/Flows/Nodes/NodeGoogleMaps.d.ts +0 -15
- package/dist/Conversations/Flows/Nodes/NodeGoogleMaps.js +0 -2
- package/dist/Conversations/Flows/Nodes/NodeMsgReply.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeMsgReply.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeMsgSend.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeMsgSend.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeMsgText.d.ts +0 -1
- package/dist/Conversations/Flows/Nodes/NodeMsgText.js +0 -27
- package/dist/Conversations/Flows/Nodes/NodeMsgWaitResponse.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeMsgWaitResponse.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeRedirect.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeRedirect.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeSendEmail.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeSendEmail.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeSqlQuery.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeSqlQuery.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeStart.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeStart.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeScheduleControl.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeScheduleControl.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeTimer.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeTimer.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeWaitUntil.d.ts +0 -0
- package/dist/Conversations/Flows/Nodes/NodeTimeWaitUntil.js +0 -0
- package/dist/Conversations/Flows/Nodes/NodeToolCalculator.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolCalculator.js +0 -37
- package/dist/Conversations/Flows/Nodes/NodeToolContacts.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolContacts.js +0 -59
- package/dist/Conversations/Flows/Nodes/NodeToolFunction.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolFunction.js +0 -45
- package/dist/Conversations/Flows/Nodes/NodeToolGoogleCalendar.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolGoogleCalendar.js +0 -87
- package/dist/Conversations/Flows/Nodes/NodeToolGoogleMaps.d.ts +0 -1
- package/dist/Conversations/Flows/Nodes/NodeToolGoogleMaps.js +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolKnowledge.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolKnowledge.js +0 -52
- package/dist/Conversations/Flows/Nodes/NodeToolMapsCheckPolygon.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolMapsCheckPolygon.js +0 -59
- package/dist/Conversations/Flows/Nodes/NodeToolMcpClient.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolMcpClient.js +0 -45
- package/dist/Conversations/Flows/Nodes/NodeToolShoppingCart.d.ts +0 -2
- package/dist/Conversations/Flows/Nodes/NodeToolShoppingCart.js +0 -81
- package/dist/Conversations/Flows/Nodes/index.d.ts +0 -24
- package/dist/Conversations/Flows/Nodes/index.js +0 -40
- package/dist/Conversations/InboxCounters.d.ts +0 -18
- package/dist/Conversations/InboxCounters.js +0 -2
- package/dist/Presence/ChannelRoutingState.d.ts +0 -17
- package/dist/Presence/ChannelRoutingState.js +0 -9
- package/dist/Tickets/AccessLevel.d.ts +0 -5
- package/dist/Tickets/AccessLevel.js +0 -9
- /package/dist/{AI/MapPolygon.js → Conversations/InboxProjection.js} +0 -0
package/dist/Tickets/Api.d.ts
CHANGED
|
@@ -29,8 +29,14 @@ export interface ITicketFilter {
|
|
|
29
29
|
priorities?: TicketPriority[];
|
|
30
30
|
origins?: TicketCreationMethod[];
|
|
31
31
|
contactIds?: string[];
|
|
32
|
+
/**
|
|
33
|
+
* User ids, plus two tokens tickets-api resolves per request: "@me" (the requester) and
|
|
34
|
+
* "@unassigned" (tickets without an assignee). Entries are ORed.
|
|
35
|
+
*/
|
|
32
36
|
assigneeIds?: string[];
|
|
33
37
|
assignedGroupIds?: string[];
|
|
38
|
+
/** Work queues the tickets were routed to (the ticket's routing queue). */
|
|
39
|
+
queueIds?: string[];
|
|
34
40
|
categoryIds?: string[];
|
|
35
41
|
requestTypeIds?: string[];
|
|
36
42
|
tagIds?: string[];
|
|
@@ -39,6 +45,16 @@ export interface ITicketFilter {
|
|
|
39
45
|
dueFrom?: Date;
|
|
40
46
|
dueTo?: Date;
|
|
41
47
|
includeDeleted?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* "My tickets": assigned to the requester, or waiting in a manual-pull queue they can pull
|
|
50
|
+
* from. Resolved per request from the authenticated user.
|
|
51
|
+
*/
|
|
52
|
+
mine?: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* "To approve": tickets with a pending approval the requester may decide. Resolved per
|
|
55
|
+
* request from the authenticated user.
|
|
56
|
+
*/
|
|
57
|
+
pendingMyApproval?: boolean;
|
|
42
58
|
fields?: ITicketFieldFilter[];
|
|
43
59
|
}
|
|
44
60
|
export interface ITicketQuery extends ITicketCursorRequest {
|
|
@@ -1,122 +1,150 @@
|
|
|
1
|
-
|
|
2
|
-
export declare enum TicketApprovalMode {
|
|
3
|
-
SEQUENTIAL = "SEQUENTIAL",
|
|
4
|
-
PARALLEL = "PARALLEL"
|
|
5
|
-
}
|
|
1
|
+
/** Status of an approval process. */
|
|
6
2
|
export declare enum TicketApprovalStatus {
|
|
7
3
|
PENDING = "PENDING",
|
|
8
|
-
IN_PROGRESS = "IN_PROGRESS",
|
|
9
4
|
APPROVED = "APPROVED",
|
|
10
|
-
REJECTED = "REJECTED"
|
|
11
|
-
CANCELLED = "CANCELLED",
|
|
12
|
-
EXPIRED = "EXPIRED"
|
|
5
|
+
REJECTED = "REJECTED"
|
|
13
6
|
}
|
|
7
|
+
/** The decision an approver takes. */
|
|
14
8
|
export declare enum TicketApprovalDecisionType {
|
|
15
9
|
APPROVE = "APPROVE",
|
|
16
|
-
REJECT = "REJECT"
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export declare enum
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
export
|
|
10
|
+
REJECT = "REJECT"
|
|
11
|
+
}
|
|
12
|
+
/** What a process gates: CLOSE = a transition into a CLOSED-stage status; RESOLVE = a /resolve request, only on processes started before closes were gated. */
|
|
13
|
+
export declare enum TicketApprovalAction {
|
|
14
|
+
RESOLVE = "RESOLVE",
|
|
15
|
+
CLOSE = "CLOSE"
|
|
16
|
+
}
|
|
17
|
+
/** What the replay of the approved action did; the *_FAILED values leave the process APPROVED. */
|
|
18
|
+
export declare enum TicketApprovalOutcome {
|
|
19
|
+
RESOLVED = "RESOLVED",
|
|
20
|
+
RESOLVE_FAILED = "RESOLVE_FAILED",
|
|
21
|
+
CLOSED = "CLOSED",
|
|
22
|
+
CLOSE_FAILED = "CLOSE_FAILED"
|
|
23
|
+
}
|
|
24
|
+
/** Why the caller cannot decide a process right now. */
|
|
25
|
+
export declare enum TicketApprovalViewerBlockedReason {
|
|
26
|
+
ASSIGNEE = "ASSIGNEE",
|
|
27
|
+
REQUESTER = "REQUESTER",
|
|
28
|
+
NOT_MEMBER = "NOT_MEMBER",
|
|
29
|
+
NOT_PENDING = "NOT_PENDING"
|
|
30
|
+
}
|
|
31
|
+
/** Top-level `code` of the approval runtime errors (409 APPROVAL_PENDING / APPROVAL_NOT_PENDING, 403 APPROVAL_SELF_DECISION / APPROVAL_NOT_ELIGIBLE). */
|
|
32
|
+
export declare enum TicketApprovalErrorCode {
|
|
33
|
+
APPROVAL_PENDING = "APPROVAL_PENDING",
|
|
34
|
+
APPROVAL_NOT_PENDING = "APPROVAL_NOT_PENDING",
|
|
35
|
+
APPROVAL_SELF_DECISION = "APPROVAL_SELF_DECISION",
|
|
36
|
+
APPROVAL_NOT_ELIGIBLE = "APPROVAL_NOT_ELIGIBLE"
|
|
37
|
+
}
|
|
38
|
+
/** `details[].code` of a rejected approval request (422 unless noted). */
|
|
39
|
+
export declare enum TicketApprovalErrorDetailCode {
|
|
40
|
+
REQUIRED = "REQUIRED",
|
|
41
|
+
APPROVERS_REQUIRED = "APPROVERS_REQUIRED",
|
|
42
|
+
INVALID_CATEGORY = "INVALID_CATEGORY",
|
|
43
|
+
/** 409. */
|
|
44
|
+
NAME_CONFLICT = "NAME_CONFLICT",
|
|
45
|
+
/** 409; the detail carries `categoryId` and `definitionId`. */
|
|
46
|
+
CATEGORY_HAS_APPROVAL = "CATEGORY_HAS_APPROVAL",
|
|
47
|
+
/** 422 of POST /tickets/{id}/transition: nobody but the ticket's assignee is listed as approver. */
|
|
48
|
+
APPROVAL_NO_ELIGIBLE_APPROVER = "APPROVAL_NO_ELIGIBLE_APPROVER"
|
|
49
|
+
}
|
|
50
|
+
/** `ITicketApiError.details` entry of an approval error, plus the ids that locate the offending category. */
|
|
51
|
+
export interface ITicketApprovalErrorDetail {
|
|
52
|
+
fieldName: string;
|
|
53
|
+
code: string;
|
|
54
|
+
message: string;
|
|
55
|
+
categoryId?: string;
|
|
56
|
+
definitionId?: string;
|
|
57
|
+
}
|
|
58
|
+
/** Body of GET /approval-definitions/{id} (and items of GET /approval-definitions?includeDisabled=true). */
|
|
59
|
+
export interface ITicketApprovalDefinition {
|
|
39
60
|
id: string;
|
|
40
|
-
name: string;
|
|
41
|
-
order: number;
|
|
42
|
-
approvers: ITicketApprover[];
|
|
43
|
-
quorum: ITicketApprovalQuorum;
|
|
44
|
-
expiresAfterMinutes?: number;
|
|
45
|
-
allowDelegation: boolean;
|
|
46
|
-
escalationPolicyId?: string;
|
|
47
|
-
}
|
|
48
|
-
export interface ITicketApprovalProcessDefinition extends ITicketAuditedEntity {
|
|
49
61
|
name: string;
|
|
50
62
|
description?: string;
|
|
51
63
|
categoryIds?: string[];
|
|
52
|
-
|
|
53
|
-
|
|
64
|
+
/** Users allowed to approve; at least one while the definition is enabled. */
|
|
65
|
+
approverUserIds: string[];
|
|
54
66
|
enabled: boolean;
|
|
67
|
+
createdAt: Date;
|
|
68
|
+
createdBy: string;
|
|
69
|
+
updatedAt?: Date;
|
|
70
|
+
updatedBy?: string;
|
|
55
71
|
}
|
|
56
|
-
|
|
72
|
+
/** Body of POST /approval-definitions. Unknown keys are rejected with 422. */
|
|
73
|
+
export interface ICreateTicketApprovalDefinitionDto {
|
|
57
74
|
name: string;
|
|
58
75
|
description?: string;
|
|
59
76
|
categoryIds?: string[];
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
77
|
+
/** Defaults to []; deduplicated case-insensitively, first-seen order kept. */
|
|
78
|
+
approverUserIds?: string[];
|
|
79
|
+
/** Defaults to false: a new definition starts as a draft. */
|
|
80
|
+
enabled?: boolean;
|
|
63
81
|
}
|
|
64
|
-
|
|
82
|
+
/** Body of PATCH /approval-definitions/{id}. Unknown keys are rejected with 422. */
|
|
83
|
+
export interface IUpdateTicketApprovalDefinitionDto {
|
|
65
84
|
name?: string;
|
|
66
85
|
description?: string | null;
|
|
67
86
|
categoryIds?: string[] | null;
|
|
68
|
-
|
|
69
|
-
steps?: ITicketApprovalStepDefinition[];
|
|
87
|
+
approverUserIds?: string[];
|
|
70
88
|
enabled?: boolean;
|
|
71
89
|
}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
90
|
+
/** The decision that ended a process (absent while it is PENDING). */
|
|
91
|
+
export interface ITicketApprovalDecision {
|
|
92
|
+
decision: TicketApprovalDecisionType;
|
|
93
|
+
decidedBy: string;
|
|
94
|
+
/** ISO 8601. */
|
|
95
|
+
decidedAt: string;
|
|
96
|
+
comment?: string;
|
|
97
|
+
}
|
|
98
|
+
/** Whether the caller can decide the process now. */
|
|
99
|
+
export interface ITicketApprovalViewer {
|
|
100
|
+
canDecide: boolean;
|
|
101
|
+
blockedReason?: TicketApprovalViewerBlockedReason;
|
|
77
102
|
}
|
|
103
|
+
/** Body of GET /approvals/{processId} and POST /approvals/{processId}/decisions; item of GET /tickets/{id}/approvals. */
|
|
78
104
|
export interface ITicketApprovalProcess {
|
|
79
105
|
id: string;
|
|
80
|
-
spaceId: string;
|
|
81
106
|
ticketId: string;
|
|
82
|
-
definitionId
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
mode: TicketApprovalMode;
|
|
107
|
+
definitionId: string;
|
|
108
|
+
definitionName: string;
|
|
109
|
+
action: TicketApprovalAction;
|
|
86
110
|
status: TicketApprovalStatus;
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
111
|
+
/** The definition's approvers when the process started; later edits of the definition do not apply. */
|
|
112
|
+
approverUserIds: string[];
|
|
113
|
+
/** The approvers that may decide it now: `approverUserIds` without the ticket's current assignee and the requester. */
|
|
114
|
+
eligibleApproverUserIds: string[];
|
|
115
|
+
decision?: ITicketApprovalDecision;
|
|
90
116
|
requestedBy: string;
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
117
|
+
/** ISO 8601. */
|
|
118
|
+
requestedAt: string;
|
|
119
|
+
/** ISO 8601. */
|
|
120
|
+
completedAt?: string;
|
|
121
|
+
outcome?: TicketApprovalOutcome;
|
|
122
|
+
outcomeError?: string;
|
|
123
|
+
version: number;
|
|
124
|
+
viewer: ITicketApprovalViewer;
|
|
125
|
+
}
|
|
126
|
+
/** Body of GET /tickets/{id}/approvals, newest first. */
|
|
127
|
+
export interface ITicketApprovalProcessList {
|
|
128
|
+
items: ITicketApprovalProcess[];
|
|
129
|
+
}
|
|
130
|
+
/** Body of POST /approvals/{processId}/decisions. A REJECT needs a non-blank comment. */
|
|
131
|
+
export interface IDecideTicketApprovalDto {
|
|
132
|
+
expectedVersion: number;
|
|
101
133
|
decision: TicketApprovalDecisionType;
|
|
102
134
|
comment?: string;
|
|
103
|
-
attachmentIds?: string[];
|
|
104
|
-
decidedAt: Date;
|
|
105
|
-
delegatedFromUserId?: string;
|
|
106
135
|
}
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
reason?: string;
|
|
116
|
-
delegatedAt: Date;
|
|
117
|
-
expiresAt?: Date;
|
|
118
|
-
revokedAt?: Date;
|
|
136
|
+
/** 202 body of POST /tickets/{id}/transition when a close needs an approval first: the ticket is not closed, a process was started. */
|
|
137
|
+
export interface ITicketApprovalRequiredResponse {
|
|
138
|
+
approvalRequired: true;
|
|
139
|
+
approval: ITicketApprovalProcess;
|
|
140
|
+
}
|
|
141
|
+
/** Body of GET /approvals/pending/count. */
|
|
142
|
+
export interface ITicketPendingApprovalCount {
|
|
143
|
+
total: number;
|
|
119
144
|
}
|
|
145
|
+
/**
|
|
146
|
+
* @deprecated tickets-api never emits `ITicket.approvalSummary`; read GET /tickets/{id}/approvals instead.
|
|
147
|
+
*/
|
|
120
148
|
export interface ITicketApprovalSummary {
|
|
121
149
|
pending: number;
|
|
122
150
|
approved: number;
|
|
@@ -124,29 +152,3 @@ export interface ITicketApprovalSummary {
|
|
|
124
152
|
expired: number;
|
|
125
153
|
currentProcessId?: string;
|
|
126
154
|
}
|
|
127
|
-
export interface IStartTicketApprovalDto {
|
|
128
|
-
expectedVersion: number;
|
|
129
|
-
definitionId: string;
|
|
130
|
-
comment?: string;
|
|
131
|
-
}
|
|
132
|
-
export interface IDecideTicketApprovalDto {
|
|
133
|
-
expectedVersion: number;
|
|
134
|
-
processId: string;
|
|
135
|
-
stepId: string;
|
|
136
|
-
decision: TicketApprovalDecisionType;
|
|
137
|
-
comment?: string;
|
|
138
|
-
attachmentIds?: string[];
|
|
139
|
-
}
|
|
140
|
-
export interface IDelegateTicketApprovalDto {
|
|
141
|
-
expectedVersion: number;
|
|
142
|
-
processId: string;
|
|
143
|
-
stepId: string;
|
|
144
|
-
toUserId: string;
|
|
145
|
-
reason?: string;
|
|
146
|
-
expiresAt?: Date;
|
|
147
|
-
}
|
|
148
|
-
export interface ICancelTicketApprovalDto {
|
|
149
|
-
expectedVersion: number;
|
|
150
|
-
processId: string;
|
|
151
|
-
reason: string;
|
|
152
|
-
}
|
package/dist/Tickets/Approval.js
CHANGED
|
@@ -1,30 +1,63 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
// Approvals (S18 model): a definition is bound to categories and lists the users who may approve.
|
|
3
|
+
// Closing a ticket of one of those categories starts a process that ends with ONE decision by any
|
|
4
|
+
// listed approver except the ticket's current assignee and the requester. No steps, queues, mode
|
|
5
|
+
// or quorum.
|
|
2
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
|
|
5
|
-
(function (TicketApprovalMode) {
|
|
6
|
-
TicketApprovalMode["SEQUENTIAL"] = "SEQUENTIAL";
|
|
7
|
-
TicketApprovalMode["PARALLEL"] = "PARALLEL";
|
|
8
|
-
})(TicketApprovalMode || (exports.TicketApprovalMode = TicketApprovalMode = {}));
|
|
7
|
+
exports.TicketApprovalErrorDetailCode = exports.TicketApprovalErrorCode = exports.TicketApprovalViewerBlockedReason = exports.TicketApprovalOutcome = exports.TicketApprovalAction = exports.TicketApprovalDecisionType = exports.TicketApprovalStatus = void 0;
|
|
8
|
+
/** Status of an approval process. */
|
|
9
9
|
var TicketApprovalStatus;
|
|
10
10
|
(function (TicketApprovalStatus) {
|
|
11
11
|
TicketApprovalStatus["PENDING"] = "PENDING";
|
|
12
|
-
TicketApprovalStatus["IN_PROGRESS"] = "IN_PROGRESS";
|
|
13
12
|
TicketApprovalStatus["APPROVED"] = "APPROVED";
|
|
14
13
|
TicketApprovalStatus["REJECTED"] = "REJECTED";
|
|
15
|
-
TicketApprovalStatus["CANCELLED"] = "CANCELLED";
|
|
16
|
-
TicketApprovalStatus["EXPIRED"] = "EXPIRED";
|
|
17
14
|
})(TicketApprovalStatus || (exports.TicketApprovalStatus = TicketApprovalStatus = {}));
|
|
15
|
+
/** The decision an approver takes. */
|
|
18
16
|
var TicketApprovalDecisionType;
|
|
19
17
|
(function (TicketApprovalDecisionType) {
|
|
20
18
|
TicketApprovalDecisionType["APPROVE"] = "APPROVE";
|
|
21
19
|
TicketApprovalDecisionType["REJECT"] = "REJECT";
|
|
22
|
-
TicketApprovalDecisionType["ABSTAIN"] = "ABSTAIN";
|
|
23
20
|
})(TicketApprovalDecisionType || (exports.TicketApprovalDecisionType = TicketApprovalDecisionType = {}));
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
21
|
+
/** What a process gates: CLOSE = a transition into a CLOSED-stage status; RESOLVE = a /resolve request, only on processes started before closes were gated. */
|
|
22
|
+
var TicketApprovalAction;
|
|
23
|
+
(function (TicketApprovalAction) {
|
|
24
|
+
TicketApprovalAction["RESOLVE"] = "RESOLVE";
|
|
25
|
+
TicketApprovalAction["CLOSE"] = "CLOSE";
|
|
26
|
+
})(TicketApprovalAction || (exports.TicketApprovalAction = TicketApprovalAction = {}));
|
|
27
|
+
/** What the replay of the approved action did; the *_FAILED values leave the process APPROVED. */
|
|
28
|
+
var TicketApprovalOutcome;
|
|
29
|
+
(function (TicketApprovalOutcome) {
|
|
30
|
+
TicketApprovalOutcome["RESOLVED"] = "RESOLVED";
|
|
31
|
+
TicketApprovalOutcome["RESOLVE_FAILED"] = "RESOLVE_FAILED";
|
|
32
|
+
TicketApprovalOutcome["CLOSED"] = "CLOSED";
|
|
33
|
+
TicketApprovalOutcome["CLOSE_FAILED"] = "CLOSE_FAILED";
|
|
34
|
+
})(TicketApprovalOutcome || (exports.TicketApprovalOutcome = TicketApprovalOutcome = {}));
|
|
35
|
+
/** Why the caller cannot decide a process right now. */
|
|
36
|
+
var TicketApprovalViewerBlockedReason;
|
|
37
|
+
(function (TicketApprovalViewerBlockedReason) {
|
|
38
|
+
TicketApprovalViewerBlockedReason["ASSIGNEE"] = "ASSIGNEE";
|
|
39
|
+
TicketApprovalViewerBlockedReason["REQUESTER"] = "REQUESTER";
|
|
40
|
+
TicketApprovalViewerBlockedReason["NOT_MEMBER"] = "NOT_MEMBER";
|
|
41
|
+
TicketApprovalViewerBlockedReason["NOT_PENDING"] = "NOT_PENDING";
|
|
42
|
+
})(TicketApprovalViewerBlockedReason || (exports.TicketApprovalViewerBlockedReason = TicketApprovalViewerBlockedReason = {}));
|
|
43
|
+
/** Top-level `code` of the approval runtime errors (409 APPROVAL_PENDING / APPROVAL_NOT_PENDING, 403 APPROVAL_SELF_DECISION / APPROVAL_NOT_ELIGIBLE). */
|
|
44
|
+
var TicketApprovalErrorCode;
|
|
45
|
+
(function (TicketApprovalErrorCode) {
|
|
46
|
+
TicketApprovalErrorCode["APPROVAL_PENDING"] = "APPROVAL_PENDING";
|
|
47
|
+
TicketApprovalErrorCode["APPROVAL_NOT_PENDING"] = "APPROVAL_NOT_PENDING";
|
|
48
|
+
TicketApprovalErrorCode["APPROVAL_SELF_DECISION"] = "APPROVAL_SELF_DECISION";
|
|
49
|
+
TicketApprovalErrorCode["APPROVAL_NOT_ELIGIBLE"] = "APPROVAL_NOT_ELIGIBLE";
|
|
50
|
+
})(TicketApprovalErrorCode || (exports.TicketApprovalErrorCode = TicketApprovalErrorCode = {}));
|
|
51
|
+
/** `details[].code` of a rejected approval request (422 unless noted). */
|
|
52
|
+
var TicketApprovalErrorDetailCode;
|
|
53
|
+
(function (TicketApprovalErrorDetailCode) {
|
|
54
|
+
TicketApprovalErrorDetailCode["REQUIRED"] = "REQUIRED";
|
|
55
|
+
TicketApprovalErrorDetailCode["APPROVERS_REQUIRED"] = "APPROVERS_REQUIRED";
|
|
56
|
+
TicketApprovalErrorDetailCode["INVALID_CATEGORY"] = "INVALID_CATEGORY";
|
|
57
|
+
/** 409. */
|
|
58
|
+
TicketApprovalErrorDetailCode["NAME_CONFLICT"] = "NAME_CONFLICT";
|
|
59
|
+
/** 409; the detail carries `categoryId` and `definitionId`. */
|
|
60
|
+
TicketApprovalErrorDetailCode["CATEGORY_HAS_APPROVAL"] = "CATEGORY_HAS_APPROVAL";
|
|
61
|
+
/** 422 of POST /tickets/{id}/transition: nobody but the ticket's assignee is listed as approver. */
|
|
62
|
+
TicketApprovalErrorDetailCode["APPROVAL_NO_ELIGIBLE_APPROVER"] = "APPROVAL_NO_ELIGIBLE_APPROVER";
|
|
63
|
+
})(TicketApprovalErrorDetailCode || (exports.TicketApprovalErrorDetailCode = TicketApprovalErrorDetailCode = {}));
|
|
@@ -18,6 +18,12 @@ export interface ITicketCategory extends ITicketAuditedEntity {
|
|
|
18
18
|
formRequirements?: ITicketFormRequirement[];
|
|
19
19
|
fieldDefinitionIds?: string[];
|
|
20
20
|
layoutIds?: string[];
|
|
21
|
+
/**
|
|
22
|
+
* Archived sits between disabled and soft-deleted: a disabled category hidden from the
|
|
23
|
+
* default settings list, recoverable via "show archived".
|
|
24
|
+
*/
|
|
25
|
+
archivedAt?: Date;
|
|
26
|
+
archivedBy?: string;
|
|
21
27
|
}
|
|
22
28
|
export interface ITicketResolutionType extends ITicketAuditedEntity {
|
|
23
29
|
name: string;
|
|
@@ -55,6 +61,8 @@ export interface IUpdateTicketCategoryDto {
|
|
|
55
61
|
formRequirements?: ITicketFormRequirement[] | null;
|
|
56
62
|
fieldDefinitionIds?: string[] | null;
|
|
57
63
|
layoutIds?: string[] | null;
|
|
64
|
+
/** `true` archives the category (it must be disabled); `false` restores it. */
|
|
65
|
+
archived?: boolean;
|
|
58
66
|
}
|
|
59
67
|
export interface ICreateTicketResolutionTypeDto {
|
|
60
68
|
name: string;
|
|
@@ -121,11 +121,23 @@ export interface ITicketMessageReference {
|
|
|
121
121
|
conversationId: string;
|
|
122
122
|
messageId: string;
|
|
123
123
|
}
|
|
124
|
+
/** Current state of a ticket note, carried by the timeline entry that represents it. */
|
|
125
|
+
export interface ITicketTimelineNoteProjection {
|
|
126
|
+
id: string;
|
|
127
|
+
version: number;
|
|
128
|
+
isPublic: boolean;
|
|
129
|
+
text: string;
|
|
130
|
+
}
|
|
124
131
|
export type ITicketTimelineEntry = {
|
|
125
132
|
id: string;
|
|
126
133
|
type: TicketTimelineEntryType.ACTIVITY;
|
|
127
134
|
occurredAt: Date;
|
|
128
135
|
activity: ITicketActivity;
|
|
136
|
+
/**
|
|
137
|
+
* Present only on the entry of a ticket note (activity `ticketEventType` NOTE_CREATED):
|
|
138
|
+
* the note as it is now, while `activity.comment` keeps the text it was created with.
|
|
139
|
+
*/
|
|
140
|
+
note?: ITicketTimelineNoteProjection;
|
|
129
141
|
} | {
|
|
130
142
|
id: string;
|
|
131
143
|
type: TicketTimelineEntryType.MESSAGE;
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Internal ticket roles (RBAC), owned by tickets-api: /roles, /role-assignments,
|
|
3
|
+
* /actors/{userId}/access, /me/permissions and /permissions/catalog. They are
|
|
4
|
+
* local to the tickets module and do not touch the space profiles.
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Closed permission catalog of the ticket roles (GET /permissions/catalog).
|
|
8
|
+
* There is no permission to see every ticket: that is the visibility scope `all`.
|
|
9
|
+
*/
|
|
10
|
+
export type TicketPermission = "tickets.assign_others" | "tickets.delete" | "tickets.bulk_actions" | "views.share" | "views.manage" | "reports.view" | "settings.manage";
|
|
11
|
+
/**
|
|
12
|
+
* Which tickets a role lets its holder see, narrowest to widest:
|
|
13
|
+
* `own` (assigned to the user, plus QUEUED tickets of the queues of the user's
|
|
14
|
+
* groups) and `all` (every ticket of the space).
|
|
15
|
+
*/
|
|
16
|
+
export type TicketVisibilityScope = "own" | "all";
|
|
17
|
+
/** Who holds a role assignment: a user or a ticket group. */
|
|
18
|
+
export type TicketRoleSubjectType = "user" | "group";
|
|
19
|
+
/** Number of users and groups holding a role. */
|
|
20
|
+
export interface ITicketRoleAssignmentCounts {
|
|
21
|
+
users: number;
|
|
22
|
+
groups: number;
|
|
23
|
+
}
|
|
24
|
+
/** Item of GET /roles and response of GET|POST|PATCH /roles/{roleId}. */
|
|
25
|
+
export interface ITicketRole {
|
|
26
|
+
id: string;
|
|
27
|
+
name: string;
|
|
28
|
+
description: string | null;
|
|
29
|
+
visibilityScope: TicketVisibilityScope;
|
|
30
|
+
permissions: TicketPermission[];
|
|
31
|
+
isDefault: boolean;
|
|
32
|
+
/** The seeded "Administrador" role: renamable, never reduced nor deleted. */
|
|
33
|
+
isSystem: boolean;
|
|
34
|
+
createdAt: Date;
|
|
35
|
+
createdBy: string;
|
|
36
|
+
updatedAt?: Date;
|
|
37
|
+
updatedBy?: string;
|
|
38
|
+
/** Only on GET /roles. */
|
|
39
|
+
assignmentCounts?: ITicketRoleAssignmentCounts;
|
|
40
|
+
}
|
|
41
|
+
/** Item of GET /roles/{roleId}/assignments and response of POST /roles/{roleId}/assignments. */
|
|
42
|
+
export interface ITicketRoleAssignment {
|
|
43
|
+
id: string;
|
|
44
|
+
roleId: string;
|
|
45
|
+
subjectType: TicketRoleSubjectType;
|
|
46
|
+
/** User id ('user') or ticket group id ('group'). */
|
|
47
|
+
subjectId: string;
|
|
48
|
+
createdAt: Date;
|
|
49
|
+
createdBy: string;
|
|
50
|
+
}
|
|
51
|
+
/** Item of GET /role-assignments: a direct assignment with the role it grants. */
|
|
52
|
+
export interface ITicketSubjectRoleAssignment extends ITicketRoleAssignment {
|
|
53
|
+
roleName: string;
|
|
54
|
+
isSystem: boolean;
|
|
55
|
+
isDefault: boolean;
|
|
56
|
+
}
|
|
57
|
+
/** Body of POST /roles. */
|
|
58
|
+
export interface ICreateTicketRoleDto {
|
|
59
|
+
name: string;
|
|
60
|
+
description?: string | null;
|
|
61
|
+
visibilityScope: TicketVisibilityScope;
|
|
62
|
+
permissions: TicketPermission[];
|
|
63
|
+
isDefault?: boolean;
|
|
64
|
+
}
|
|
65
|
+
/** Body of PATCH /roles/{roleId}. At least one field; `isSystem` is not editable. */
|
|
66
|
+
export type IUpdateTicketRoleDto = Partial<ICreateTicketRoleDto>;
|
|
67
|
+
/** Body of POST /roles/{roleId}/assignments. */
|
|
68
|
+
export interface ICreateTicketRoleAssignmentDto {
|
|
69
|
+
subjectType: TicketRoleSubjectType;
|
|
70
|
+
subjectId: string;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Response of GET /actors/{userId}/access and GET /me/permissions: the
|
|
74
|
+
* effective access of a user (roles assigned directly, via groups, or the default).
|
|
75
|
+
*/
|
|
76
|
+
export interface ITicketActorAccess {
|
|
77
|
+
userId: string;
|
|
78
|
+
/** Live groups the user belongs to. */
|
|
79
|
+
groupIds: string[];
|
|
80
|
+
/** Effective roles: assigned directly or through a group, else the default role. */
|
|
81
|
+
roleIds: string[];
|
|
82
|
+
scope: TicketVisibilityScope;
|
|
83
|
+
permissions: TicketPermission[];
|
|
84
|
+
/** Holds the system "Administrador" role. */
|
|
85
|
+
isAdministrador: boolean;
|
|
86
|
+
}
|
|
87
|
+
/** Response of GET /permissions/catalog. */
|
|
88
|
+
export interface ITicketPermissionCatalog {
|
|
89
|
+
permissions: TicketPermission[];
|
|
90
|
+
scopes: TicketVisibilityScope[];
|
|
91
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Internal ticket roles (RBAC), owned by tickets-api: /roles, /role-assignments,
|
|
4
|
+
* /actors/{userId}/access, /me/permissions and /permissions/catalog. They are
|
|
5
|
+
* local to the tickets module and do not touch the space profiles.
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -391,6 +391,16 @@ export interface ICreateAgentChannelCapacityDto {
|
|
|
391
391
|
reservedCapacity?: number;
|
|
392
392
|
}
|
|
393
393
|
export type IUpdateAgentChannelCapacityDto = Partial<Omit<ICreateAgentChannelCapacityDto, "userId" | "channelType">>;
|
|
394
|
+
/** Mirror of TicketSkillWarningCode for agent channel capacity. */
|
|
395
|
+
export declare enum AgentCapacityWarningCode {
|
|
396
|
+
/** The agent holds a skill a queue requires but has no capacity row configured. */
|
|
397
|
+
NO_CAPACITY_CONFIGURED = "NO_CAPACITY_CONFIGURED"
|
|
398
|
+
}
|
|
399
|
+
/** Item of GET /routing/agent-capacities/warnings (the body is a bare array). */
|
|
400
|
+
export interface IAgentCapacityWarning {
|
|
401
|
+
userId: string;
|
|
402
|
+
warning: AgentCapacityWarningCode;
|
|
403
|
+
}
|
|
394
404
|
export interface IEscalationPolicyUsageRef {
|
|
395
405
|
id: string;
|
|
396
406
|
name: string;
|
package/dist/Tickets/Routing.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EscalationPolicyWarningCode = exports.TicketSkillWarningCode = exports.TicketAssignmentEndReason = exports.TicketEscalationActionType = exports.TicketEscalationTrigger = exports.TicketSkillRelaxationMode = exports.TicketQueueOrderDirection = exports.TicketQueueOrderCriterion = exports.TicketRoutingConditionGroupOperator = exports.AgentAvailabilityStatus = exports.TicketRoutingStatus = exports.TicketQueueSystemKey = exports.TicketRoutingStrategy = void 0;
|
|
3
|
+
exports.EscalationPolicyWarningCode = exports.AgentCapacityWarningCode = exports.TicketSkillWarningCode = exports.TicketAssignmentEndReason = exports.TicketEscalationActionType = exports.TicketEscalationTrigger = exports.TicketSkillRelaxationMode = exports.TicketQueueOrderDirection = exports.TicketQueueOrderCriterion = exports.TicketRoutingConditionGroupOperator = exports.AgentAvailabilityStatus = exports.TicketRoutingStatus = exports.TicketQueueSystemKey = exports.TicketRoutingStrategy = void 0;
|
|
4
4
|
var TicketRoutingStrategy;
|
|
5
5
|
(function (TicketRoutingStrategy) {
|
|
6
6
|
TicketRoutingStrategy["ROUND_ROBIN"] = "ROUND_ROBIN";
|
|
@@ -109,6 +109,12 @@ var TicketSkillWarningCode;
|
|
|
109
109
|
TicketSkillWarningCode["DISABLED_BUT_REFERENCED"] = "DISABLED_BUT_REFERENCED";
|
|
110
110
|
TicketSkillWarningCode["REQUIRED_BY_QUEUE_BUT_UNMET"] = "REQUIRED_BY_QUEUE_BUT_UNMET";
|
|
111
111
|
})(TicketSkillWarningCode || (exports.TicketSkillWarningCode = TicketSkillWarningCode = {}));
|
|
112
|
+
/** Mirror of TicketSkillWarningCode for agent channel capacity. */
|
|
113
|
+
var AgentCapacityWarningCode;
|
|
114
|
+
(function (AgentCapacityWarningCode) {
|
|
115
|
+
/** The agent holds a skill a queue requires but has no capacity row configured. */
|
|
116
|
+
AgentCapacityWarningCode["NO_CAPACITY_CONFIGURED"] = "NO_CAPACITY_CONFIGURED";
|
|
117
|
+
})(AgentCapacityWarningCode || (exports.AgentCapacityWarningCode = AgentCapacityWarningCode = {}));
|
|
112
118
|
/** Mirror of TicketSkillWarningCode; only one member is needed today. */
|
|
113
119
|
var EscalationPolicyWarningCode;
|
|
114
120
|
(function (EscalationPolicyWarningCode) {
|
|
@@ -258,6 +258,14 @@ export interface ITicketRetentionPolicy extends ITicketAuditedEntity {
|
|
|
258
258
|
enabled: boolean;
|
|
259
259
|
version: number;
|
|
260
260
|
}
|
|
261
|
+
/**
|
|
262
|
+
* Row of GET /security/retention-policies: the policy plus its estimated reach
|
|
263
|
+
* (the same number the preview reports as `alreadyReachedCount`). Optional
|
|
264
|
+
* because the write endpoints return the bare policy without the count.
|
|
265
|
+
*/
|
|
266
|
+
export interface ITicketRetentionPolicyListEntry extends ITicketRetentionPolicy {
|
|
267
|
+
estimatedAffectedCount?: number;
|
|
268
|
+
}
|
|
261
269
|
export interface ICreateTicketRetentionPolicyDto {
|
|
262
270
|
name: string;
|
|
263
271
|
description?: string;
|
|
@@ -323,6 +331,19 @@ export interface ITicketRetentionValidationEntry {
|
|
|
323
331
|
export interface IValidateTicketRetentionResponse {
|
|
324
332
|
policies: ITicketRetentionValidationEntry[];
|
|
325
333
|
}
|
|
334
|
+
/**
|
|
335
|
+
* Body of POST /security/retention-policies/preview. At least one field is
|
|
336
|
+
* required: `policyId` previews a stored policy, `policy` an unsaved draft, and
|
|
337
|
+
* both together a draft that replaces that policy.
|
|
338
|
+
*/
|
|
339
|
+
export interface IPreviewTicketRetentionDto {
|
|
340
|
+
policyId?: string;
|
|
341
|
+
policy?: ICreateTicketRetentionPolicyDto;
|
|
342
|
+
}
|
|
343
|
+
/** Body of POST /security/retention-policies/validate. Omit `policyId` to validate every policy in the space. */
|
|
344
|
+
export interface IValidateTicketRetentionDto {
|
|
345
|
+
policyId?: string;
|
|
346
|
+
}
|
|
326
347
|
export interface ITicketFieldSecurityValidationIssue {
|
|
327
348
|
code: string;
|
|
328
349
|
severity: 'ERROR' | 'WARNING';
|
|
@@ -553,9 +574,22 @@ export interface ITicketLegalHoldsResponse {
|
|
|
553
574
|
holds: ITicketLegalHold[];
|
|
554
575
|
suspendedPolicies: ITicketSuspendedRetentionPolicy[];
|
|
555
576
|
}
|
|
577
|
+
/** Row of GET /security/legal-holds. */
|
|
556
578
|
export interface ITicketLegalHoldListEntry extends ITicketLegalHold {
|
|
557
579
|
ticketNumber: number;
|
|
558
580
|
ticketTitle: string;
|
|
581
|
+
/** Retention policies the held ticket would otherwise be subject to; shared by every hold on the same ticket. */
|
|
582
|
+
suspendedPolicies: ITicketSuspendedRetentionPolicy[];
|
|
583
|
+
}
|
|
584
|
+
/**
|
|
585
|
+
* Response of POST /tickets/{id}/legal-holds/{holdId}/release. Releasing one of
|
|
586
|
+
* several holds keeps the ticket protected: `stillOnHold` is then true and
|
|
587
|
+
* `resumedPolicies` is empty.
|
|
588
|
+
*/
|
|
589
|
+
export interface IReleaseTicketLegalHoldResponse {
|
|
590
|
+
hold: ITicketLegalHold;
|
|
591
|
+
stillOnHold: boolean;
|
|
592
|
+
resumedPolicies: ITicketSuspendedRetentionPolicy[];
|
|
559
593
|
}
|
|
560
594
|
export interface ICreateTicketDelegatedAccessDto {
|
|
561
595
|
delegateId: string;
|
|
@@ -343,6 +343,23 @@ export interface ICreateTicketPublicStatusMappingDto {
|
|
|
343
343
|
}
|
|
344
344
|
export interface IUpdateTicketPublicStatusMappingDto extends Partial<ICreateTicketPublicStatusMappingDto> {
|
|
345
345
|
}
|
|
346
|
+
/**
|
|
347
|
+
* How a scheme references a public status: by mapping internal statuses onto it
|
|
348
|
+
* (`MAPPING`) or by using it as its fallback (`SCHEME_DEFAULT`).
|
|
349
|
+
*/
|
|
350
|
+
export type PublicStatusUsageKind = "MAPPING" | "SCHEME_DEFAULT";
|
|
351
|
+
export interface IPublicStatusUsage {
|
|
352
|
+
schemeId: string;
|
|
353
|
+
schemeName: string;
|
|
354
|
+
as: PublicStatusUsageKind;
|
|
355
|
+
}
|
|
356
|
+
/**
|
|
357
|
+
* Body of GET /public-statuses/{id}/usages. A non-empty list blocks DELETE
|
|
358
|
+
* (409, same entries as `details`).
|
|
359
|
+
*/
|
|
360
|
+
export interface IPublicStatusUsages {
|
|
361
|
+
usages: IPublicStatusUsage[];
|
|
362
|
+
}
|
|
346
363
|
/** Customer-facing projection of ITicketPublicStatus: no audit or tenant fields. */
|
|
347
364
|
export interface ICustomerPublicStatusView {
|
|
348
365
|
id: string;
|