@onereach/types-hitl-api 1.0.11-rc.13 → 1.0.11-rc.16

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.
@@ -0,0 +1,44 @@
1
+ import { ITargetAccountId, ITimestamps } from './common';
2
+ export interface IAgentGroup extends ITimestamps {
3
+ readonly id: string;
4
+ readonly name: string;
5
+ readonly meta: object;
6
+ }
7
+ export interface IAgentGroupMember {
8
+ id: string;
9
+ agentGroupId: string;
10
+ agentId: string;
11
+ }
12
+ export interface IAgentGroupWithMembers extends IAgentGroup {
13
+ readonly agentIds: string[];
14
+ }
15
+ export interface IGetAgentGroupQuery extends ITargetAccountId {
16
+ readonly id?: string;
17
+ readonly agentIds?: string[];
18
+ readonly name?: string;
19
+ readonly offset?: number;
20
+ readonly limit?: number;
21
+ readonly orderBy?: string;
22
+ readonly order?: string;
23
+ }
24
+ export interface IGetAgentGroupsResponse {
25
+ readonly data: IAgentGroupWithMembers[];
26
+ }
27
+ export type ICreateAgentGroupQuery = ITargetAccountId;
28
+ export interface ICreateAgentGroupBody {
29
+ readonly id?: string;
30
+ readonly name: string;
31
+ readonly meta: object;
32
+ readonly agentIds: string[];
33
+ }
34
+ export type IUpdateAgentGroupQuery = ITargetAccountId;
35
+ export interface IPatchGroupMembers {
36
+ readonly addAgentIds?: string[];
37
+ readonly removeAgentIds?: string[];
38
+ }
39
+ export interface IUpdateAgentGroupBody extends IAgentGroup {
40
+ readonly agentIds: string[] | IPatchGroupMembers;
41
+ }
42
+ export interface IDeleteAgentGroupQuery extends ITargetAccountId {
43
+ readonly id: string;
44
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=agent-groups.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-groups.js","sourceRoot":"","sources":["../../../../src/interfaces/api/agent-groups.ts"],"names":[],"mappings":""}
@@ -20,3 +20,4 @@ export * as ContactRuleGroups from './contact-rule-groups';
20
20
  export * as SessionRelations from './session-relations';
21
21
  export * as Contacts from './contacts';
22
22
  export * as DraftMessages from './draft-messages';
23
+ export * as AgentGroups from './agent-groups';
@@ -36,7 +36,7 @@ var __importStar = (this && this.__importStar) || (function () {
36
36
  };
37
37
  })();
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.DraftMessages = exports.Contacts = exports.SessionRelations = exports.ContactRuleGroups = exports.Versions = exports.ContactsMeta = exports.Helpers = exports.Tasks = exports.Commands = exports.ReadEvents = exports.SessionEvents = exports.Sessions = exports.Listeners = exports.CannedMessages = exports.Filters = exports.Conferences = exports.EventTemplates = exports.RuleGroups = exports.Agents = exports.Migrations = exports.Settings = void 0;
39
+ exports.AgentGroups = exports.DraftMessages = exports.Contacts = exports.SessionRelations = exports.ContactRuleGroups = exports.Versions = exports.ContactsMeta = exports.Helpers = exports.Tasks = exports.Commands = exports.ReadEvents = exports.SessionEvents = exports.Sessions = exports.Listeners = exports.CannedMessages = exports.Filters = exports.Conferences = exports.EventTemplates = exports.RuleGroups = exports.Agents = exports.Migrations = exports.Settings = void 0;
40
40
  __exportStar(require("./common"), exports);
41
41
  exports.Settings = __importStar(require("./settings"));
42
42
  exports.Migrations = __importStar(require("./migrations"));
@@ -59,4 +59,5 @@ exports.ContactRuleGroups = __importStar(require("./contact-rule-groups"));
59
59
  exports.SessionRelations = __importStar(require("./session-relations"));
60
60
  exports.Contacts = __importStar(require("./contacts"));
61
61
  exports.DraftMessages = __importStar(require("./draft-messages"));
62
+ exports.AgentGroups = __importStar(require("./agent-groups"));
62
63
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/interfaces/api/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,uDAAuC;AACvC,2DAA2C;AAC3C,mDAAmC;AACnC,4DAA4C;AAC5C,oEAAoD;AACpD,6DAA6C;AAC7C,qDAAqC;AACrC,oEAAoD;AACpD,yDAAyC;AACzC,uDAAuC;AACvC,kEAAkD;AAClD,4DAA4C;AAC5C,uDAAuC;AACvC,iDAAiC;AACjC,qDAAqC;AACrC,gEAAgD;AAChD,uDAAuC;AACvC,2EAA2D;AAC3D,wEAAwD;AACxD,uDAAuC;AACvC,kEAAkD"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/interfaces/api/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,uDAAuC;AACvC,2DAA2C;AAC3C,mDAAmC;AACnC,4DAA4C;AAC5C,oEAAoD;AACpD,6DAA6C;AAC7C,qDAAqC;AACrC,oEAAoD;AACpD,yDAAyC;AACzC,uDAAuC;AACvC,kEAAkD;AAClD,4DAA4C;AAC5C,uDAAuC;AACvC,iDAAiC;AACjC,qDAAqC;AACrC,gEAAgD;AAChD,uDAAuC;AACvC,2EAA2D;AAC3D,wEAAwD;AACxD,uDAAuC;AACvC,kEAAkD;AAClD,8DAA8C"}
@@ -4,6 +4,8 @@ export interface ISession<Meta = any> extends ITimestamps {
4
4
  readonly hitlSessionId: string;
5
5
  readonly claimedBy: string[];
6
6
  readonly claimedByHistory: string[];
7
+ readonly claimedByGroups: string[];
8
+ readonly claimedByGroupAgents: string[];
7
9
  readonly contactId: string;
8
10
  readonly closedAt?: Date | null;
9
11
  readonly isArchived: boolean;
@@ -119,6 +121,7 @@ export interface ISearchSessionsOptions {
119
121
  readonly dateRange?: IDateRangeOptions;
120
122
  readonly claimedBy?: string;
121
123
  readonly claimedByHistory?: string;
124
+ readonly claimedByGroups?: string;
122
125
  readonly tags?: string[] | ITagsQuery;
123
126
  readonly status?: string[];
124
127
  readonly needsAction?: boolean;
@@ -146,6 +149,7 @@ export interface ISessionSearchGroupedByContactsOptions {
146
149
  export interface ISearchSessionsGroupedByContactsOptions {
147
150
  readonly accountId: string;
148
151
  readonly agentId: string;
152
+ readonly claimedByGroupsAnyOf?: string[];
149
153
  readonly claimedBy?: string[];
150
154
  readonly claimedByAnyOf?: string[];
151
155
  readonly tags?: string[] | ITagsQuery;
@@ -214,6 +218,7 @@ export interface ITriggersResponse {
214
218
  export type IGetInitTriggersResponse = ITriggersResponse[];
215
219
  export interface IClaimSessionQuery extends ITargetAccountId {
216
220
  readonly claimBy?: string[];
221
+ readonly claimByGroups?: string[];
217
222
  }
218
223
  export interface IClaimSessionBody {
219
224
  readonly params?: object;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onereach/types-hitl-api",
3
- "version": "1.0.11-rc.13",
3
+ "version": "1.0.11-rc.16",
4
4
  "author": "OneReach.ai",
5
5
  "main": "dist/types/index.types.js",
6
6
  "types": "dist/types/index.types.d.ts",