@babelforce/babelconnect-sdk 0.13.0 → 0.15.0
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/embed/iife-entry.d.ts +1 -1
- package/dist/embed/iife-entry.js +1 -1
- package/dist/embed/index.d.ts +8 -8
- package/dist/embed/index.js +1 -1
- package/dist/gen/babelconnect/v1/babelconnect_connect.d.ts +9 -15
- package/dist/gen/babelconnect/v1/babelconnect_connect.js +9 -15
- package/dist/gen/babelconnect/v1/babelconnect_pb.d.ts +58 -86
- package/dist/gen/babelconnect/v1/babelconnect_pb.js +59 -86
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* class exported as `BabelconnectEmbed` from `@babelforce/babelconnect-sdk/embed`,
|
|
15
15
|
* so `BabelconnectEmbed.mount({...})` here is identical to the ESM
|
|
16
16
|
* `BabelconnectEmbed.mount({...})`. The name is deliberately **distinct** from the
|
|
17
|
-
*
|
|
17
|
+
* previous embedded phone widget's global (`BabelconnectConnect`) — the two APIs
|
|
18
18
|
* differ and a compatibility shim is out of scope; see EMBEDDING.md for the
|
|
19
19
|
* migration.
|
|
20
20
|
*
|
package/dist/embed/iife-entry.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* class exported as `BabelconnectEmbed` from `@babelforce/babelconnect-sdk/embed`,
|
|
15
15
|
* so `BabelconnectEmbed.mount({...})` here is identical to the ESM
|
|
16
16
|
* `BabelconnectEmbed.mount({...})`. The name is deliberately **distinct** from the
|
|
17
|
-
*
|
|
17
|
+
* previous embedded phone widget's global (`BabelconnectConnect`) — the two APIs
|
|
18
18
|
* differ and a compatibility shim is out of scope; see EMBEDDING.md for the
|
|
19
19
|
* migration.
|
|
20
20
|
*
|
package/dist/embed/index.d.ts
CHANGED
|
@@ -30,14 +30,14 @@ export interface EmbedOptions {
|
|
|
30
30
|
/** Optional initial shared context (also settable later via {@link context}). */
|
|
31
31
|
context?: Record<string, unknown>;
|
|
32
32
|
/**
|
|
33
|
-
* The `agent.loaded`/`user.loaded` event-payload schema version
|
|
33
|
+
* The `agent.loaded`/`user.loaded` event-payload schema version.
|
|
34
34
|
* Omit for the app's current default (`"v3"` — just the top-level
|
|
35
35
|
* `agentId`, no legacy struct nesting). Pass `"v1"` to opt into the
|
|
36
|
-
*
|
|
37
|
-
* agent:{id,name,email,number}}`,
|
|
38
|
-
* user:{email}}`) for a host still
|
|
39
|
-
* or routing by number. See the Embedding guide,
|
|
40
|
-
* version".
|
|
36
|
+
* legacy shape used by the previous embedded phone widget
|
|
37
|
+
* (`agent.loaded` → `{agentId, agent:{id,name,email,number}}`,
|
|
38
|
+
* `user.loaded` → `{agentId, user:{email}}`) for a host still matching
|
|
39
|
+
* CRM users by email or routing by number. See the Embedding guide,
|
|
40
|
+
* "Loaded event schema version".
|
|
41
41
|
*/
|
|
42
42
|
eventsVersion?: string;
|
|
43
43
|
/** Path within the app (default `/`). */
|
|
@@ -55,7 +55,7 @@ export interface AuthSetArgs {
|
|
|
55
55
|
session?: Record<string, unknown>;
|
|
56
56
|
/** Updated shared context. Omit to leave the currently-tracked value unchanged. */
|
|
57
57
|
context?: Record<string, unknown>;
|
|
58
|
-
/** Updated events-schema version (
|
|
58
|
+
/** Updated events-schema version (see {@link EmbedOptions.eventsVersion}). Only takes
|
|
59
59
|
* effect on the NEXT `ready` handshake (an iframe reload) — a live session's already-emitted
|
|
60
60
|
* `agent.loaded`/`user.loaded` don't refire. Omit to leave the currently-tracked value unchanged. */
|
|
61
61
|
eventsVersion?: string;
|
|
@@ -83,7 +83,7 @@ export declare class BabelconnectEmbed {
|
|
|
83
83
|
* Refresh the bearer token (and optionally session/context) mid-session —
|
|
84
84
|
* e.g. ahead of expiry on a long shift. Posts `auth.set` immediately; the
|
|
85
85
|
* live app applies it in place without interrupting the session or any
|
|
86
|
-
* active call
|
|
86
|
+
* active call. Also remembers the values as *current*, so if the
|
|
87
87
|
* iframe later reloads and re-emits `ready`, the handshake hands off this
|
|
88
88
|
* refreshed token rather than the one passed to {@link BabelconnectEmbed.mount}.
|
|
89
89
|
*/
|
package/dist/embed/index.js
CHANGED
|
@@ -64,7 +64,7 @@ export class BabelconnectEmbed {
|
|
|
64
64
|
* Refresh the bearer token (and optionally session/context) mid-session —
|
|
65
65
|
* e.g. ahead of expiry on a long shift. Posts `auth.set` immediately; the
|
|
66
66
|
* live app applies it in place without interrupting the session or any
|
|
67
|
-
* active call
|
|
67
|
+
* active call. Also remembers the values as *current*, so if the
|
|
68
68
|
* iframe later reloads and re-emits `ready`, the handshake hands off this
|
|
69
69
|
* refreshed token rather than the one passed to {@link BabelconnectEmbed.mount}.
|
|
70
70
|
*/
|
|
@@ -90,13 +90,11 @@ export declare const Agent: {
|
|
|
90
90
|
};
|
|
91
91
|
/**
|
|
92
92
|
* GetTransferTargets autocompletes blind-transfer / add-member targets as the
|
|
93
|
-
* agent types — agents, raw numbers, and IVR applications
|
|
94
|
-
* /
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
* separate, already-server-computed flag the client applies itself
|
|
99
|
-
* (CallState.can_transfer_to_application hides APPLICATION results — CALL-I3).
|
|
93
|
+
* agent types — agents, raw numbers, and IVR applications. `query` filters
|
|
94
|
+
* server-side (substring across name/email/number for agents, name for
|
|
95
|
+
* applications); the lookup has no call-context param, so eligibility by call
|
|
96
|
+
* direction is a separate, already-server-computed flag the client applies
|
|
97
|
+
* itself (CallState.can_transfer_to_application hides APPLICATION results).
|
|
100
98
|
*
|
|
101
99
|
* @generated from rpc babelconnect.v1.Agent.GetTransferTargets
|
|
102
100
|
*/
|
|
@@ -135,9 +133,8 @@ export declare const Agent: {
|
|
|
135
133
|
};
|
|
136
134
|
/**
|
|
137
135
|
* ListCampaigns lists the outbound-dialer campaigns the agent may join (the
|
|
138
|
-
* Outbound tab's campaign picker
|
|
139
|
-
* GetPhonebook/GetTransferTargets
|
|
140
|
-
* campaigns?active=true (sbf/services ObdController#listCampaigns).
|
|
136
|
+
* Outbound tab's campaign picker) — on-demand reference data like
|
|
137
|
+
* GetPhonebook/GetTransferTargets.
|
|
141
138
|
*
|
|
142
139
|
* @generated from rpc babelconnect.v1.Agent.ListCampaigns
|
|
143
140
|
*/
|
|
@@ -149,11 +146,8 @@ export declare const Agent: {
|
|
|
149
146
|
};
|
|
150
147
|
/**
|
|
151
148
|
* ListDispositions lists the available call-outcome codes for the disposition
|
|
152
|
-
* picker
|
|
153
|
-
*
|
|
154
|
-
* ObdController#listDispositions). Grounded: the `{id}` path segment is never
|
|
155
|
-
* read server-side — the list is a static global, not campaign-scoped — so the
|
|
156
|
-
* request carries no campaign id either.
|
|
149
|
+
* picker — on-demand reference data like ListCampaigns. The list is a static
|
|
150
|
+
* global, not campaign-scoped, so the request carries no campaign id.
|
|
157
151
|
*
|
|
158
152
|
* @generated from rpc babelconnect.v1.Agent.ListDispositions
|
|
159
153
|
*/
|
|
@@ -124,13 +124,11 @@ export const Agent = {
|
|
|
124
124
|
},
|
|
125
125
|
/**
|
|
126
126
|
* GetTransferTargets autocompletes blind-transfer / add-member targets as the
|
|
127
|
-
* agent types — agents, raw numbers, and IVR applications
|
|
128
|
-
* /
|
|
129
|
-
*
|
|
130
|
-
*
|
|
131
|
-
*
|
|
132
|
-
* separate, already-server-computed flag the client applies itself
|
|
133
|
-
* (CallState.can_transfer_to_application hides APPLICATION results — CALL-I3).
|
|
127
|
+
* agent types — agents, raw numbers, and IVR applications. `query` filters
|
|
128
|
+
* server-side (substring across name/email/number for agents, name for
|
|
129
|
+
* applications); the lookup has no call-context param, so eligibility by call
|
|
130
|
+
* direction is a separate, already-server-computed flag the client applies
|
|
131
|
+
* itself (CallState.can_transfer_to_application hides APPLICATION results).
|
|
134
132
|
*
|
|
135
133
|
* @generated from rpc babelconnect.v1.Agent.GetTransferTargets
|
|
136
134
|
*/
|
|
@@ -169,9 +167,8 @@ export const Agent = {
|
|
|
169
167
|
},
|
|
170
168
|
/**
|
|
171
169
|
* ListCampaigns lists the outbound-dialer campaigns the agent may join (the
|
|
172
|
-
* Outbound tab's campaign picker
|
|
173
|
-
* GetPhonebook/GetTransferTargets
|
|
174
|
-
* campaigns?active=true (sbf/services ObdController#listCampaigns).
|
|
170
|
+
* Outbound tab's campaign picker) — on-demand reference data like
|
|
171
|
+
* GetPhonebook/GetTransferTargets.
|
|
175
172
|
*
|
|
176
173
|
* @generated from rpc babelconnect.v1.Agent.ListCampaigns
|
|
177
174
|
*/
|
|
@@ -183,11 +180,8 @@ export const Agent = {
|
|
|
183
180
|
},
|
|
184
181
|
/**
|
|
185
182
|
* ListDispositions lists the available call-outcome codes for the disposition
|
|
186
|
-
* picker
|
|
187
|
-
*
|
|
188
|
-
* ObdController#listDispositions). Grounded: the `{id}` path segment is never
|
|
189
|
-
* read server-side — the list is a static global, not campaign-scoped — so the
|
|
190
|
-
* request carries no campaign id either.
|
|
183
|
+
* picker — on-demand reference data like ListCampaigns. The list is a static
|
|
184
|
+
* global, not campaign-scoped, so the request carries no campaign id.
|
|
191
185
|
*
|
|
192
186
|
* @generated from rpc babelconnect.v1.Agent.ListDispositions
|
|
193
187
|
*/
|
|
@@ -38,9 +38,8 @@ export declare enum AgentState {
|
|
|
38
38
|
BUSY = 7
|
|
39
39
|
}
|
|
40
40
|
/**
|
|
41
|
-
* CampaignMemberState
|
|
42
|
-
*
|
|
43
|
-
* membership lifecycle: offline -> logging_in -> waiting -> in_progress ->
|
|
41
|
+
* CampaignMemberState is the predictive-dialer campaign membership
|
|
42
|
+
* lifecycle: offline -> logging_in -> waiting -> in_progress ->
|
|
44
43
|
* disposition (-> waiting for the next lead), with idle as the paused branch
|
|
45
44
|
* (waiting/logging_in <-> idle via pause/resume) and leave returning to
|
|
46
45
|
* offline from any state.
|
|
@@ -80,10 +79,9 @@ export declare enum CampaignMemberState {
|
|
|
80
79
|
DISPOSITION = 6
|
|
81
80
|
}
|
|
82
81
|
/**
|
|
83
|
-
* TransferTargetKind discriminates a TransferTarget.
|
|
84
|
-
*
|
|
85
|
-
* "phonebook"
|
|
86
|
-
* wire type only ever carries these three).
|
|
82
|
+
* TransferTargetKind discriminates a TransferTarget. The wire type only ever
|
|
83
|
+
* carries agent / number / application (a UI may group results differently,
|
|
84
|
+
* e.g. a "phonebook" section, but that is presentation only).
|
|
87
85
|
*
|
|
88
86
|
* @generated from enum babelconnect.v1.TransferTargetKind
|
|
89
87
|
*/
|
|
@@ -423,8 +421,7 @@ export declare class Identity extends Message<Identity> {
|
|
|
423
421
|
}
|
|
424
422
|
/**
|
|
425
423
|
* Account is one tenant the signed-in agent can operate in — the switchable set
|
|
426
|
-
* (agent-role only) surfaced for the account picker
|
|
427
|
-
* GET /api/v2/user/accounts.
|
|
424
|
+
* (agent-role only) surfaced for the account picker.
|
|
428
425
|
*
|
|
429
426
|
* @generated from message babelconnect.v1.Account
|
|
430
427
|
*/
|
|
@@ -653,6 +650,14 @@ export declare class FeatureAccount extends Message<FeatureAccount> {
|
|
|
653
650
|
* @generated from field: bool allow_account_switch = 4;
|
|
654
651
|
*/
|
|
655
652
|
allowAccountSwitch: boolean;
|
|
653
|
+
/**
|
|
654
|
+
* Agents may change their own presence via the status picker. When false
|
|
655
|
+
* the picker is locked: still visible, shows the current status, but not
|
|
656
|
+
* interactive. Defaults to allowed.
|
|
657
|
+
*
|
|
658
|
+
* @generated from field: bool allow_status_change = 5;
|
|
659
|
+
*/
|
|
660
|
+
allowStatusChange: boolean;
|
|
656
661
|
constructor(data?: PartialMessage<FeatureAccount>);
|
|
657
662
|
static readonly runtime: typeof proto3;
|
|
658
663
|
static readonly typeName = "babelconnect.v1.FeatureAccount";
|
|
@@ -839,37 +844,32 @@ export declare class AgentInfo extends Message<AgentInfo> {
|
|
|
839
844
|
lineBlocked: boolean;
|
|
840
845
|
/**
|
|
841
846
|
* Accounts this agent may switch to without re-logging-in (agent-role only,
|
|
842
|
-
* resolved at auth
|
|
843
|
-
*
|
|
847
|
+
* resolved at auth). One is marked `current`. Drives the Account tab's
|
|
848
|
+
* switcher; empty/single ⇒ no picker.
|
|
844
849
|
*
|
|
845
850
|
* @generated from field: repeated babelconnect.v1.Account accounts = 19;
|
|
846
851
|
*/
|
|
847
852
|
accounts: Account[];
|
|
848
853
|
/**
|
|
849
|
-
* The agent's own email
|
|
850
|
-
*
|
|
851
|
-
*
|
|
852
|
-
* (EMB20, bc-connect parity) — bc-connect hosts match/route on it.
|
|
854
|
+
* The agent's own email — distinct from `username`, which is the *login*
|
|
855
|
+
* identity and may differ. Populated for the embedding bridge's legacy-shaped
|
|
856
|
+
* `agent.loaded` payload so host pages can match/route on it.
|
|
853
857
|
*
|
|
854
858
|
* @generated from field: string email = 20;
|
|
855
859
|
*/
|
|
856
860
|
email: string;
|
|
857
861
|
/**
|
|
858
|
-
* Subset of `available_numbers` the
|
|
859
|
-
* /
|
|
860
|
-
*
|
|
861
|
-
* composer's From picker (SMSC4); empty/unknown ⇒ client falls back to
|
|
862
|
-
* `available_numbers` (see docs/designs/messaging.md).
|
|
862
|
+
* Subset of `available_numbers` the platform marks SMS-capable. Drives the
|
|
863
|
+
* SMS composer's From picker; empty/unknown ⇒ client falls back to
|
|
864
|
+
* `available_numbers`.
|
|
863
865
|
*
|
|
864
866
|
* @generated from field: repeated string sms_capable_numbers = 21;
|
|
865
867
|
*/
|
|
866
868
|
smsCapableNumbers: string[];
|
|
867
869
|
/**
|
|
868
|
-
* Outbound-dialer (predictive campaign) membership state
|
|
869
|
-
*
|
|
870
|
-
*
|
|
871
|
-
* campaign this session; explicit OFFLINE means they left/aren't in one.
|
|
872
|
-
* See docs/designs/obd.md.
|
|
870
|
+
* Outbound-dialer (predictive campaign) membership state, kept live by the
|
|
871
|
+
* server. Unset/UNSPECIFIED means the agent has never touched a campaign
|
|
872
|
+
* this session; explicit OFFLINE means they left/aren't in one.
|
|
873
873
|
*
|
|
874
874
|
* @generated from field: babelconnect.v1.CampaignStatus campaign_status = 22;
|
|
875
875
|
*/
|
|
@@ -884,19 +884,13 @@ export declare class AgentInfo extends Message<AgentInfo> {
|
|
|
884
884
|
static equals(a: AgentInfo | PlainMessage<AgentInfo> | undefined, b: AgentInfo | PlainMessage<AgentInfo> | undefined): boolean;
|
|
885
885
|
}
|
|
886
886
|
/**
|
|
887
|
-
* CampaignStatus is the agent's outbound-dialer campaign membership envelope
|
|
888
|
-
*
|
|
889
|
-
*
|
|
890
|
-
*
|
|
891
|
-
*
|
|
892
|
-
*
|
|
893
|
-
*
|
|
894
|
-
* "unreachable", "no_answer", "busy", "answer", "hungup", "none") — kept as a
|
|
895
|
-
* string rather than a wire enum since the client only ever compares it
|
|
896
|
-
* against "unreachable" for the OBDA4 toast. `paused` is a convenience mirror
|
|
897
|
-
* of `state == CAMPAIGN_MEMBER_STATE_IDLE`. The lead the agent is currently
|
|
898
|
-
* dialing, disposition reasons, and live campaign metrics are additive fields
|
|
899
|
-
* below (OBDB1/OBDD1) layered on top of this envelope.
|
|
887
|
+
* CampaignStatus is the agent's outbound-dialer campaign membership envelope,
|
|
888
|
+
* kept live by the server. `last_reason` is the platform's last dial-outcome
|
|
889
|
+
* as a lowercase string (e.g. "unreachable", "no_answer", "busy", "answer",
|
|
890
|
+
* "hungup", "none") — a string rather than a wire enum on purpose. `paused`
|
|
891
|
+
* is a convenience mirror of `state == CAMPAIGN_MEMBER_STATE_IDLE`. The lead
|
|
892
|
+
* the agent is currently dialing, disposition reasons, and live campaign
|
|
893
|
+
* metrics are additive fields below, layered on top of this envelope.
|
|
900
894
|
*
|
|
901
895
|
* @generated from message babelconnect.v1.CampaignStatus
|
|
902
896
|
*/
|
|
@@ -928,12 +922,9 @@ export declare class CampaignStatus extends Message<CampaignStatus> {
|
|
|
928
922
|
*/
|
|
929
923
|
since: bigint;
|
|
930
924
|
/**
|
|
931
|
-
* lead is the customer the dialer connected the agent to
|
|
932
|
-
*
|
|
933
|
-
*
|
|
934
|
-
* `cti.outbound.lead` Faye event — sbf/services AgentCtiService#pushLead,
|
|
935
|
-
* CTIA3) that arrives the moment the dialer connects a lead, ahead of the
|
|
936
|
-
* next enrichment poll.
|
|
925
|
+
* lead is the customer the dialer connected the agent to — set while a lead
|
|
926
|
+
* is being worked (IN_PROGRESS/DISPOSITION), unset otherwise. Updated the
|
|
927
|
+
* moment the dialer connects a lead.
|
|
937
928
|
*
|
|
938
929
|
* @generated from field: babelconnect.v1.Lead lead = 7;
|
|
939
930
|
*/
|
|
@@ -957,14 +948,10 @@ export declare class CampaignStatus extends Message<CampaignStatus> {
|
|
|
957
948
|
static equals(a: CampaignStatus | PlainMessage<CampaignStatus> | undefined, b: CampaignStatus | PlainMessage<CampaignStatus> | undefined): boolean;
|
|
958
949
|
}
|
|
959
950
|
/**
|
|
960
|
-
* Lead is the customer the outbound dialer connected the agent to
|
|
961
|
-
*
|
|
962
|
-
*
|
|
963
|
-
*
|
|
964
|
-
* shape; `id`/`rank` are only present on the richer (list-enriched) form the
|
|
965
|
-
* GET read can return. `id` is the internal lead-list-item id — DISTINCT from
|
|
966
|
-
* `uid`, the customer-provided identifier the OBDB1 acceptance calls the
|
|
967
|
-
* lead's "id" in the UI.
|
|
951
|
+
* Lead is the customer the outbound dialer connected the agent to. `id`/`rank`
|
|
952
|
+
* are only present on the richer (list-enriched) form some reads return. `id`
|
|
953
|
+
* is the internal lead-list-item id — DISTINCT from `uid`, the
|
|
954
|
+
* customer-provided identifier shown as the lead's id in the UI.
|
|
968
955
|
*
|
|
969
956
|
* @generated from message babelconnect.v1.Lead
|
|
970
957
|
*/
|
|
@@ -1007,10 +994,8 @@ export declare class Lead extends Message<Lead> {
|
|
|
1007
994
|
static equals(a: Lead | PlainMessage<Lead> | undefined, b: Lead | PlainMessage<Lead> | undefined): boolean;
|
|
1008
995
|
}
|
|
1009
996
|
/**
|
|
1010
|
-
* CampaignMetrics is the campaign's live pacing snapshot
|
|
1011
|
-
*
|
|
1012
|
-
* ObdController#metrics, itself a filtered subset of Vicidial's realtime
|
|
1013
|
-
* report) — always this exact 6-key subset, never more.
|
|
997
|
+
* CampaignMetrics is the campaign's live pacing snapshot — always this exact
|
|
998
|
+
* 6-key subset, never more.
|
|
1014
999
|
*
|
|
1015
1000
|
* @generated from message babelconnect.v1.CampaignMetrics
|
|
1016
1001
|
*/
|
|
@@ -2433,9 +2418,7 @@ export declare class SetAgentNumber extends Message<SetAgentNumber> {
|
|
|
2433
2418
|
}
|
|
2434
2419
|
/**
|
|
2435
2420
|
* Campaign is one outbound-dialer campaign the agent may join (the picker's
|
|
2436
|
-
* entries). `test_mode` drives the "name (live)" / "name (test)" label
|
|
2437
|
-
* (OBDA1). Sourced from GET /api/v2/agent/outbound/campaigns (sbf/services
|
|
2438
|
-
* ObdController#listCampaigns / ObdModel.Campaign.Simple).
|
|
2421
|
+
* entries). `test_mode` drives the "name (live)" / "name (test)" label.
|
|
2439
2422
|
*
|
|
2440
2423
|
* @generated from message babelconnect.v1.Campaign
|
|
2441
2424
|
*/
|
|
@@ -2501,11 +2484,8 @@ export declare class ListCampaignsResponse extends Message<ListCampaignsResponse
|
|
|
2501
2484
|
static equals(a: ListCampaignsResponse | PlainMessage<ListCampaignsResponse> | undefined, b: ListCampaignsResponse | PlainMessage<ListCampaignsResponse> | undefined): boolean;
|
|
2502
2485
|
}
|
|
2503
2486
|
/**
|
|
2504
|
-
* JoinCampaign enters a campaign
|
|
2505
|
-
*
|
|
2506
|
-
* "unpause" — bc-v2's client sent that stale name, which the backend command
|
|
2507
|
-
* object silently ignores, defaulting `paused` true); the client normally
|
|
2508
|
-
* sends false so the agent starts `waiting` for a lead right away.
|
|
2487
|
+
* JoinCampaign enters a campaign. The client normally sends `paused` false so
|
|
2488
|
+
* the agent starts `waiting` for a lead right away.
|
|
2509
2489
|
*
|
|
2510
2490
|
* @generated from message babelconnect.v1.JoinCampaign
|
|
2511
2491
|
*/
|
|
@@ -2528,10 +2508,9 @@ export declare class JoinCampaign extends Message<JoinCampaign> {
|
|
|
2528
2508
|
static equals(a: JoinCampaign | PlainMessage<JoinCampaign> | undefined, b: JoinCampaign | PlainMessage<JoinCampaign> | undefined): boolean;
|
|
2529
2509
|
}
|
|
2530
2510
|
/**
|
|
2531
|
-
* LeaveCampaign exits the current campaign (
|
|
2532
|
-
* — no body; the backend resolves the agent's current campaign server-side).
|
|
2511
|
+
* LeaveCampaign exits the current campaign (the server resolves which one).
|
|
2533
2512
|
* Available both from the campaign selector row and from within an active
|
|
2534
|
-
* call
|
|
2513
|
+
* call.
|
|
2535
2514
|
*
|
|
2536
2515
|
* @generated from message babelconnect.v1.LeaveCampaign
|
|
2537
2516
|
*/
|
|
@@ -2567,12 +2546,10 @@ export declare class PauseCampaign extends Message<PauseCampaign> {
|
|
|
2567
2546
|
static equals(a: PauseCampaign | PlainMessage<PauseCampaign> | undefined, b: PauseCampaign | PlainMessage<PauseCampaign> | undefined): boolean;
|
|
2568
2547
|
}
|
|
2569
2548
|
/**
|
|
2570
|
-
* EndCampaignCall ends the agent's live campaign call
|
|
2571
|
-
*
|
|
2572
|
-
*
|
|
2573
|
-
*
|
|
2574
|
-
* member-state transition to DISPOSITION (sbf/services), neither of which a
|
|
2575
|
-
* plain SIP/media-plane hangup would trigger.
|
|
2549
|
+
* EndCampaignCall ends the agent's live campaign call. Deliberately distinct
|
|
2550
|
+
* from the generic Hangup: it also releases the dialer's channel and drives
|
|
2551
|
+
* the campaign member-state transition to DISPOSITION, neither of which a
|
|
2552
|
+
* plain media-plane hangup would trigger.
|
|
2576
2553
|
*
|
|
2577
2554
|
* @generated from message babelconnect.v1.EndCampaignCall
|
|
2578
2555
|
*/
|
|
@@ -2587,14 +2564,10 @@ export declare class EndCampaignCall extends Message<EndCampaignCall> {
|
|
|
2587
2564
|
static equals(a: EndCampaignCall | PlainMessage<EndCampaignCall> | undefined, b: EndCampaignCall | PlainMessage<EndCampaignCall> | undefined): boolean;
|
|
2588
2565
|
}
|
|
2589
2566
|
/**
|
|
2590
|
-
* DisposeCall records the outcome of a campaign call
|
|
2591
|
-
*
|
|
2592
|
-
* is one of ListDispositionsResponse's codes (e.g. "no_answer", "callback").
|
|
2567
|
+
* DisposeCall records the outcome of a campaign call. `code` is one of
|
|
2568
|
+
* ListDispositionsResponse's codes (e.g. "no_answer", "callback").
|
|
2593
2569
|
* `callback_date` is ISO `YYYY-MM-DDTHH:mmZZ` and is set ONLY for the
|
|
2594
|
-
* "callback" disposition
|
|
2595
|
-
* backend command object's own optional field (grounded: a `pause` field also
|
|
2596
|
-
* exists on the backend but is `@ApiStatus(not_implemented)`, so it is
|
|
2597
|
-
* intentionally not exposed here).
|
|
2570
|
+
* "callback" disposition — omitted (empty) otherwise.
|
|
2598
2571
|
*
|
|
2599
2572
|
* @generated from message babelconnect.v1.DisposeCall
|
|
2600
2573
|
*/
|
|
@@ -3042,12 +3015,11 @@ export declare class StartConference extends Message<StartConference> {
|
|
|
3042
3015
|
* AddConferenceMember invites a participant — exactly one of agent_id / number.
|
|
3043
3016
|
* Starts a conference first if none is active. `hold_others` parks every other
|
|
3044
3017
|
* live, non-held member of the CURRENT conference before the invite goes out
|
|
3045
|
-
* (
|
|
3046
|
-
*
|
|
3047
|
-
*
|
|
3048
|
-
*
|
|
3049
|
-
*
|
|
3050
|
-
* already parks the original party unconditionally in that case.
|
|
3018
|
+
* (default off) so they don't overhear the new invitee ringing; the server
|
|
3019
|
+
* unholds them again once the invitee reaches a terminal state (added =
|
|
3020
|
+
* joined, or failed/removed = rejected/timed out). No effect when starting a
|
|
3021
|
+
* brand-new conference: StartConference(hold=true) already parks the original
|
|
3022
|
+
* party unconditionally in that case.
|
|
3051
3023
|
*
|
|
3052
3024
|
* @generated from message babelconnect.v1.AddConferenceMember
|
|
3053
3025
|
*/
|
|
@@ -53,9 +53,8 @@ proto3.util.setEnumType(AgentState, "babelconnect.v1.AgentState", [
|
|
|
53
53
|
{ no: 7, name: "AGENT_STATE_BUSY" },
|
|
54
54
|
]);
|
|
55
55
|
/**
|
|
56
|
-
* CampaignMemberState
|
|
57
|
-
*
|
|
58
|
-
* membership lifecycle: offline -> logging_in -> waiting -> in_progress ->
|
|
56
|
+
* CampaignMemberState is the predictive-dialer campaign membership
|
|
57
|
+
* lifecycle: offline -> logging_in -> waiting -> in_progress ->
|
|
59
58
|
* disposition (-> waiting for the next lead), with idle as the paused branch
|
|
60
59
|
* (waiting/logging_in <-> idle via pause/resume) and leave returning to
|
|
61
60
|
* offline from any state.
|
|
@@ -106,10 +105,9 @@ proto3.util.setEnumType(CampaignMemberState, "babelconnect.v1.CampaignMemberStat
|
|
|
106
105
|
{ no: 6, name: "CAMPAIGN_MEMBER_STATE_DISPOSITION" },
|
|
107
106
|
]);
|
|
108
107
|
/**
|
|
109
|
-
* TransferTargetKind discriminates a TransferTarget.
|
|
110
|
-
*
|
|
111
|
-
* "phonebook"
|
|
112
|
-
* wire type only ever carries these three).
|
|
108
|
+
* TransferTargetKind discriminates a TransferTarget. The wire type only ever
|
|
109
|
+
* carries agent / number / application (a UI may group results differently,
|
|
110
|
+
* e.g. a "phonebook" section, but that is presentation only).
|
|
113
111
|
*
|
|
114
112
|
* @generated from enum babelconnect.v1.TransferTargetKind
|
|
115
113
|
*/
|
|
@@ -600,8 +598,7 @@ export class Identity extends Message {
|
|
|
600
598
|
}
|
|
601
599
|
/**
|
|
602
600
|
* Account is one tenant the signed-in agent can operate in — the switchable set
|
|
603
|
-
* (agent-role only) surfaced for the account picker
|
|
604
|
-
* GET /api/v2/user/accounts.
|
|
601
|
+
* (agent-role only) surfaced for the account picker.
|
|
605
602
|
*
|
|
606
603
|
* @generated from message babelconnect.v1.Account
|
|
607
604
|
*/
|
|
@@ -924,6 +921,14 @@ export class FeatureAccount extends Message {
|
|
|
924
921
|
* @generated from field: bool allow_account_switch = 4;
|
|
925
922
|
*/
|
|
926
923
|
allowAccountSwitch = false;
|
|
924
|
+
/**
|
|
925
|
+
* Agents may change their own presence via the status picker. When false
|
|
926
|
+
* the picker is locked: still visible, shows the current status, but not
|
|
927
|
+
* interactive. Defaults to allowed.
|
|
928
|
+
*
|
|
929
|
+
* @generated from field: bool allow_status_change = 5;
|
|
930
|
+
*/
|
|
931
|
+
allowStatusChange = false;
|
|
927
932
|
constructor(data) {
|
|
928
933
|
super();
|
|
929
934
|
proto3.util.initPartial(data, this);
|
|
@@ -935,6 +940,7 @@ export class FeatureAccount extends Message {
|
|
|
935
940
|
{ no: 2, name: "allow_device_switch", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
|
936
941
|
{ no: 3, name: "show_status", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
|
937
942
|
{ no: 4, name: "allow_account_switch", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
|
943
|
+
{ no: 5, name: "allow_status_change", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
|
938
944
|
]);
|
|
939
945
|
static fromBinary(bytes, options) {
|
|
940
946
|
return new FeatureAccount().fromBinary(bytes, options);
|
|
@@ -1167,37 +1173,32 @@ export class AgentInfo extends Message {
|
|
|
1167
1173
|
lineBlocked = false;
|
|
1168
1174
|
/**
|
|
1169
1175
|
* Accounts this agent may switch to without re-logging-in (agent-role only,
|
|
1170
|
-
* resolved at auth
|
|
1171
|
-
*
|
|
1176
|
+
* resolved at auth). One is marked `current`. Drives the Account tab's
|
|
1177
|
+
* switcher; empty/single ⇒ no picker.
|
|
1172
1178
|
*
|
|
1173
1179
|
* @generated from field: repeated babelconnect.v1.Account accounts = 19;
|
|
1174
1180
|
*/
|
|
1175
1181
|
accounts = [];
|
|
1176
1182
|
/**
|
|
1177
|
-
* The agent's own email
|
|
1178
|
-
*
|
|
1179
|
-
*
|
|
1180
|
-
* (EMB20, bc-connect parity) — bc-connect hosts match/route on it.
|
|
1183
|
+
* The agent's own email — distinct from `username`, which is the *login*
|
|
1184
|
+
* identity and may differ. Populated for the embedding bridge's legacy-shaped
|
|
1185
|
+
* `agent.loaded` payload so host pages can match/route on it.
|
|
1181
1186
|
*
|
|
1182
1187
|
* @generated from field: string email = 20;
|
|
1183
1188
|
*/
|
|
1184
1189
|
email = "";
|
|
1185
1190
|
/**
|
|
1186
|
-
* Subset of `available_numbers` the
|
|
1187
|
-
* /
|
|
1188
|
-
*
|
|
1189
|
-
* composer's From picker (SMSC4); empty/unknown ⇒ client falls back to
|
|
1190
|
-
* `available_numbers` (see docs/designs/messaging.md).
|
|
1191
|
+
* Subset of `available_numbers` the platform marks SMS-capable. Drives the
|
|
1192
|
+
* SMS composer's From picker; empty/unknown ⇒ client falls back to
|
|
1193
|
+
* `available_numbers`.
|
|
1191
1194
|
*
|
|
1192
1195
|
* @generated from field: repeated string sms_capable_numbers = 21;
|
|
1193
1196
|
*/
|
|
1194
1197
|
smsCapableNumbers = [];
|
|
1195
1198
|
/**
|
|
1196
|
-
* Outbound-dialer (predictive campaign) membership state
|
|
1197
|
-
*
|
|
1198
|
-
*
|
|
1199
|
-
* campaign this session; explicit OFFLINE means they left/aren't in one.
|
|
1200
|
-
* See docs/designs/obd.md.
|
|
1199
|
+
* Outbound-dialer (predictive campaign) membership state, kept live by the
|
|
1200
|
+
* server. Unset/UNSPECIFIED means the agent has never touched a campaign
|
|
1201
|
+
* this session; explicit OFFLINE means they left/aren't in one.
|
|
1201
1202
|
*
|
|
1202
1203
|
* @generated from field: babelconnect.v1.CampaignStatus campaign_status = 22;
|
|
1203
1204
|
*/
|
|
@@ -1246,19 +1247,13 @@ export class AgentInfo extends Message {
|
|
|
1246
1247
|
}
|
|
1247
1248
|
}
|
|
1248
1249
|
/**
|
|
1249
|
-
* CampaignStatus is the agent's outbound-dialer campaign membership envelope
|
|
1250
|
-
*
|
|
1251
|
-
*
|
|
1252
|
-
*
|
|
1253
|
-
*
|
|
1254
|
-
*
|
|
1255
|
-
*
|
|
1256
|
-
* "unreachable", "no_answer", "busy", "answer", "hungup", "none") — kept as a
|
|
1257
|
-
* string rather than a wire enum since the client only ever compares it
|
|
1258
|
-
* against "unreachable" for the OBDA4 toast. `paused` is a convenience mirror
|
|
1259
|
-
* of `state == CAMPAIGN_MEMBER_STATE_IDLE`. The lead the agent is currently
|
|
1260
|
-
* dialing, disposition reasons, and live campaign metrics are additive fields
|
|
1261
|
-
* below (OBDB1/OBDD1) layered on top of this envelope.
|
|
1250
|
+
* CampaignStatus is the agent's outbound-dialer campaign membership envelope,
|
|
1251
|
+
* kept live by the server. `last_reason` is the platform's last dial-outcome
|
|
1252
|
+
* as a lowercase string (e.g. "unreachable", "no_answer", "busy", "answer",
|
|
1253
|
+
* "hungup", "none") — a string rather than a wire enum on purpose. `paused`
|
|
1254
|
+
* is a convenience mirror of `state == CAMPAIGN_MEMBER_STATE_IDLE`. The lead
|
|
1255
|
+
* the agent is currently dialing, disposition reasons, and live campaign
|
|
1256
|
+
* metrics are additive fields below, layered on top of this envelope.
|
|
1262
1257
|
*
|
|
1263
1258
|
* @generated from message babelconnect.v1.CampaignStatus
|
|
1264
1259
|
*/
|
|
@@ -1290,12 +1285,9 @@ export class CampaignStatus extends Message {
|
|
|
1290
1285
|
*/
|
|
1291
1286
|
since = protoInt64.zero;
|
|
1292
1287
|
/**
|
|
1293
|
-
* lead is the customer the dialer connected the agent to
|
|
1294
|
-
*
|
|
1295
|
-
*
|
|
1296
|
-
* `cti.outbound.lead` Faye event — sbf/services AgentCtiService#pushLead,
|
|
1297
|
-
* CTIA3) that arrives the moment the dialer connects a lead, ahead of the
|
|
1298
|
-
* next enrichment poll.
|
|
1288
|
+
* lead is the customer the dialer connected the agent to — set while a lead
|
|
1289
|
+
* is being worked (IN_PROGRESS/DISPOSITION), unset otherwise. Updated the
|
|
1290
|
+
* moment the dialer connects a lead.
|
|
1299
1291
|
*
|
|
1300
1292
|
* @generated from field: babelconnect.v1.Lead lead = 7;
|
|
1301
1293
|
*/
|
|
@@ -1339,14 +1331,10 @@ export class CampaignStatus extends Message {
|
|
|
1339
1331
|
}
|
|
1340
1332
|
}
|
|
1341
1333
|
/**
|
|
1342
|
-
* Lead is the customer the outbound dialer connected the agent to
|
|
1343
|
-
*
|
|
1344
|
-
*
|
|
1345
|
-
*
|
|
1346
|
-
* shape; `id`/`rank` are only present on the richer (list-enriched) form the
|
|
1347
|
-
* GET read can return. `id` is the internal lead-list-item id — DISTINCT from
|
|
1348
|
-
* `uid`, the customer-provided identifier the OBDB1 acceptance calls the
|
|
1349
|
-
* lead's "id" in the UI.
|
|
1334
|
+
* Lead is the customer the outbound dialer connected the agent to. `id`/`rank`
|
|
1335
|
+
* are only present on the richer (list-enriched) form some reads return. `id`
|
|
1336
|
+
* is the internal lead-list-item id — DISTINCT from `uid`, the
|
|
1337
|
+
* customer-provided identifier shown as the lead's id in the UI.
|
|
1350
1338
|
*
|
|
1351
1339
|
* @generated from message babelconnect.v1.Lead
|
|
1352
1340
|
*/
|
|
@@ -1404,10 +1392,8 @@ export class Lead extends Message {
|
|
|
1404
1392
|
}
|
|
1405
1393
|
}
|
|
1406
1394
|
/**
|
|
1407
|
-
* CampaignMetrics is the campaign's live pacing snapshot
|
|
1408
|
-
*
|
|
1409
|
-
* ObdController#metrics, itself a filtered subset of Vicidial's realtime
|
|
1410
|
-
* report) — always this exact 6-key subset, never more.
|
|
1395
|
+
* CampaignMetrics is the campaign's live pacing snapshot — always this exact
|
|
1396
|
+
* 6-key subset, never more.
|
|
1411
1397
|
*
|
|
1412
1398
|
* @generated from message babelconnect.v1.CampaignMetrics
|
|
1413
1399
|
*/
|
|
@@ -3042,9 +3028,7 @@ export class SetAgentNumber extends Message {
|
|
|
3042
3028
|
}
|
|
3043
3029
|
/**
|
|
3044
3030
|
* Campaign is one outbound-dialer campaign the agent may join (the picker's
|
|
3045
|
-
* entries). `test_mode` drives the "name (live)" / "name (test)" label
|
|
3046
|
-
* (OBDA1). Sourced from GET /api/v2/agent/outbound/campaigns (sbf/services
|
|
3047
|
-
* ObdController#listCampaigns / ObdModel.Campaign.Simple).
|
|
3031
|
+
* entries). `test_mode` drives the "name (live)" / "name (test)" label.
|
|
3048
3032
|
*
|
|
3049
3033
|
* @generated from message babelconnect.v1.Campaign
|
|
3050
3034
|
*/
|
|
@@ -3150,11 +3134,8 @@ export class ListCampaignsResponse extends Message {
|
|
|
3150
3134
|
}
|
|
3151
3135
|
}
|
|
3152
3136
|
/**
|
|
3153
|
-
* JoinCampaign enters a campaign
|
|
3154
|
-
*
|
|
3155
|
-
* "unpause" — bc-v2's client sent that stale name, which the backend command
|
|
3156
|
-
* object silently ignores, defaulting `paused` true); the client normally
|
|
3157
|
-
* sends false so the agent starts `waiting` for a lead right away.
|
|
3137
|
+
* JoinCampaign enters a campaign. The client normally sends `paused` false so
|
|
3138
|
+
* the agent starts `waiting` for a lead right away.
|
|
3158
3139
|
*
|
|
3159
3140
|
* @generated from message babelconnect.v1.JoinCampaign
|
|
3160
3141
|
*/
|
|
@@ -3191,10 +3172,9 @@ export class JoinCampaign extends Message {
|
|
|
3191
3172
|
}
|
|
3192
3173
|
}
|
|
3193
3174
|
/**
|
|
3194
|
-
* LeaveCampaign exits the current campaign (
|
|
3195
|
-
* — no body; the backend resolves the agent's current campaign server-side).
|
|
3175
|
+
* LeaveCampaign exits the current campaign (the server resolves which one).
|
|
3196
3176
|
* Available both from the campaign selector row and from within an active
|
|
3197
|
-
* call
|
|
3177
|
+
* call.
|
|
3198
3178
|
*
|
|
3199
3179
|
* @generated from message babelconnect.v1.LeaveCampaign
|
|
3200
3180
|
*/
|
|
@@ -3254,12 +3234,10 @@ export class PauseCampaign extends Message {
|
|
|
3254
3234
|
}
|
|
3255
3235
|
}
|
|
3256
3236
|
/**
|
|
3257
|
-
* EndCampaignCall ends the agent's live campaign call
|
|
3258
|
-
*
|
|
3259
|
-
*
|
|
3260
|
-
*
|
|
3261
|
-
* member-state transition to DISPOSITION (sbf/services), neither of which a
|
|
3262
|
-
* plain SIP/media-plane hangup would trigger.
|
|
3237
|
+
* EndCampaignCall ends the agent's live campaign call. Deliberately distinct
|
|
3238
|
+
* from the generic Hangup: it also releases the dialer's channel and drives
|
|
3239
|
+
* the campaign member-state transition to DISPOSITION, neither of which a
|
|
3240
|
+
* plain media-plane hangup would trigger.
|
|
3263
3241
|
*
|
|
3264
3242
|
* @generated from message babelconnect.v1.EndCampaignCall
|
|
3265
3243
|
*/
|
|
@@ -3285,14 +3263,10 @@ export class EndCampaignCall extends Message {
|
|
|
3285
3263
|
}
|
|
3286
3264
|
}
|
|
3287
3265
|
/**
|
|
3288
|
-
* DisposeCall records the outcome of a campaign call
|
|
3289
|
-
*
|
|
3290
|
-
* is one of ListDispositionsResponse's codes (e.g. "no_answer", "callback").
|
|
3266
|
+
* DisposeCall records the outcome of a campaign call. `code` is one of
|
|
3267
|
+
* ListDispositionsResponse's codes (e.g. "no_answer", "callback").
|
|
3291
3268
|
* `callback_date` is ISO `YYYY-MM-DDTHH:mmZZ` and is set ONLY for the
|
|
3292
|
-
* "callback" disposition
|
|
3293
|
-
* backend command object's own optional field (grounded: a `pause` field also
|
|
3294
|
-
* exists on the backend but is `@ApiStatus(not_implemented)`, so it is
|
|
3295
|
-
* intentionally not exposed here).
|
|
3269
|
+
* "callback" disposition — omitted (empty) otherwise.
|
|
3296
3270
|
*
|
|
3297
3271
|
* @generated from message babelconnect.v1.DisposeCall
|
|
3298
3272
|
*/
|
|
@@ -3937,12 +3911,11 @@ export class StartConference extends Message {
|
|
|
3937
3911
|
* AddConferenceMember invites a participant — exactly one of agent_id / number.
|
|
3938
3912
|
* Starts a conference first if none is active. `hold_others` parks every other
|
|
3939
3913
|
* live, non-held member of the CURRENT conference before the invite goes out
|
|
3940
|
-
* (
|
|
3941
|
-
*
|
|
3942
|
-
*
|
|
3943
|
-
*
|
|
3944
|
-
*
|
|
3945
|
-
* already parks the original party unconditionally in that case.
|
|
3914
|
+
* (default off) so they don't overhear the new invitee ringing; the server
|
|
3915
|
+
* unholds them again once the invitee reaches a terminal state (added =
|
|
3916
|
+
* joined, or failed/removed = rejected/timed out). No effect when starting a
|
|
3917
|
+
* brand-new conference: StartConference(hold=true) already parks the original
|
|
3918
|
+
* party unconditionally in that case.
|
|
3946
3919
|
*
|
|
3947
3920
|
* @generated from message babelconnect.v1.AddConferenceMember
|
|
3948
3921
|
*/
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.
|
|
1
|
+
export declare const SDK_VERSION = "0.15.0";
|
package/dist/version.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@babelforce/babelconnect-sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "TypeScript SDK for babelconnect — server-authoritative agent state over gRPC-web, native WebRTC audio, and an embeddable widget (iframe + postMessage) for the Flutter web app.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://babelforce.github.io/babelconnect-sdk/",
|