@headspace/protos-events 1.785.0 → 1.786.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/lib/index.d.ts CHANGED
@@ -67331,6 +67331,172 @@ export namespace coaching {
67331
67331
  COACHING_AVAILABILITY_TYPE_VIDEO = 2
67332
67332
  }
67333
67333
 
67334
+ /** ItmsSessionCreatedReason enum. */
67335
+ enum ItmsSessionCreatedReason {
67336
+ ITMS_SESSION_CREATED_REASON_UNKNOWN = 0,
67337
+ ITMS_SESSION_CREATED_REASON_ITMS = 1,
67338
+ ITMS_SESSION_CREATED_REASON_SI = 2
67339
+ }
67340
+
67341
+ /** Properties of an ItmsCoachingSession. */
67342
+ interface IItmsCoachingSession {
67343
+
67344
+ /** ItmsCoachingSession dropinSessionId */
67345
+ dropinSessionId?: (string|null);
67346
+
67347
+ /** ItmsCoachingSession coachId */
67348
+ coachId?: (string|null);
67349
+
67350
+ /** ItmsCoachingSession gingerMemberId */
67351
+ gingerMemberId?: (number|null);
67352
+
67353
+ /** ItmsCoachingSession hsUserId */
67354
+ hsUserId?: (string|null);
67355
+
67356
+ /** ItmsCoachingSession createdAt */
67357
+ createdAt?: (number|Long|null);
67358
+
67359
+ /** ItmsCoachingSession engagedAt */
67360
+ engagedAt?: (number|Long|null);
67361
+
67362
+ /** ItmsCoachingSession coachEngagedAt */
67363
+ coachEngagedAt?: (number|Long|null);
67364
+
67365
+ /** ItmsCoachingSession closedAt */
67366
+ closedAt?: (number|Long|null);
67367
+
67368
+ /**
67369
+ * A conversation between a Listener and a Caller is represented by a unique ChatConversation
67370
+ * See apps.listenerapp.models.ChatConversation
67371
+ */
67372
+ chatConversationId?: (string|null);
67373
+
67374
+ /** ItmsCoachingSession createdReason */
67375
+ createdReason?: (coaching.ItmsSessionCreatedReason|null);
67376
+
67377
+ /** ItmsCoachingSession createdReasonDetails */
67378
+ createdReasonDetails?: (string|null);
67379
+ }
67380
+
67381
+ /**
67382
+ * In-the-moment support / drop-in coaching session (not scheduled).
67383
+ * Model: listener-server.apps.listenerapp.models.OneTimeCheckin
67384
+ */
67385
+ class ItmsCoachingSession implements IItmsCoachingSession {
67386
+
67387
+ /**
67388
+ * Constructs a new ItmsCoachingSession.
67389
+ * @param [properties] Properties to set
67390
+ */
67391
+ constructor(properties?: coaching.IItmsCoachingSession);
67392
+
67393
+ /** ItmsCoachingSession dropinSessionId. */
67394
+ public dropinSessionId: string;
67395
+
67396
+ /** ItmsCoachingSession coachId. */
67397
+ public coachId: string;
67398
+
67399
+ /** ItmsCoachingSession gingerMemberId. */
67400
+ public gingerMemberId: number;
67401
+
67402
+ /** ItmsCoachingSession hsUserId. */
67403
+ public hsUserId: string;
67404
+
67405
+ /** ItmsCoachingSession createdAt. */
67406
+ public createdAt: (number|Long);
67407
+
67408
+ /** ItmsCoachingSession engagedAt. */
67409
+ public engagedAt: (number|Long);
67410
+
67411
+ /** ItmsCoachingSession coachEngagedAt. */
67412
+ public coachEngagedAt: (number|Long);
67413
+
67414
+ /** ItmsCoachingSession closedAt. */
67415
+ public closedAt: (number|Long);
67416
+
67417
+ /**
67418
+ * A conversation between a Listener and a Caller is represented by a unique ChatConversation
67419
+ * See apps.listenerapp.models.ChatConversation
67420
+ */
67421
+ public chatConversationId: string;
67422
+
67423
+ /** ItmsCoachingSession createdReason. */
67424
+ public createdReason: coaching.ItmsSessionCreatedReason;
67425
+
67426
+ /** ItmsCoachingSession createdReasonDetails. */
67427
+ public createdReasonDetails: string;
67428
+
67429
+ /**
67430
+ * Creates a new ItmsCoachingSession instance using the specified properties.
67431
+ * @param [properties] Properties to set
67432
+ * @returns ItmsCoachingSession instance
67433
+ */
67434
+ public static create(properties?: coaching.IItmsCoachingSession): coaching.ItmsCoachingSession;
67435
+
67436
+ /**
67437
+ * Encodes the specified ItmsCoachingSession message. Does not implicitly {@link coaching.ItmsCoachingSession.verify|verify} messages.
67438
+ * @param message ItmsCoachingSession message or plain object to encode
67439
+ * @param [writer] Writer to encode to
67440
+ * @returns Writer
67441
+ */
67442
+ public static encode(message: coaching.IItmsCoachingSession, writer?: $protobuf.Writer): $protobuf.Writer;
67443
+
67444
+ /**
67445
+ * Encodes the specified ItmsCoachingSession message, length delimited. Does not implicitly {@link coaching.ItmsCoachingSession.verify|verify} messages.
67446
+ * @param message ItmsCoachingSession message or plain object to encode
67447
+ * @param [writer] Writer to encode to
67448
+ * @returns Writer
67449
+ */
67450
+ public static encodeDelimited(message: coaching.IItmsCoachingSession, writer?: $protobuf.Writer): $protobuf.Writer;
67451
+
67452
+ /**
67453
+ * Decodes an ItmsCoachingSession message from the specified reader or buffer.
67454
+ * @param reader Reader or buffer to decode from
67455
+ * @param [length] Message length if known beforehand
67456
+ * @returns ItmsCoachingSession
67457
+ * @throws {Error} If the payload is not a reader or valid buffer
67458
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
67459
+ */
67460
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): coaching.ItmsCoachingSession;
67461
+
67462
+ /**
67463
+ * Decodes an ItmsCoachingSession message from the specified reader or buffer, length delimited.
67464
+ * @param reader Reader or buffer to decode from
67465
+ * @returns ItmsCoachingSession
67466
+ * @throws {Error} If the payload is not a reader or valid buffer
67467
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
67468
+ */
67469
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): coaching.ItmsCoachingSession;
67470
+
67471
+ /**
67472
+ * Verifies an ItmsCoachingSession message.
67473
+ * @param message Plain object to verify
67474
+ * @returns `null` if valid, otherwise the reason why it is not
67475
+ */
67476
+ public static verify(message: { [k: string]: any }): (string|null);
67477
+
67478
+ /**
67479
+ * Creates an ItmsCoachingSession message from a plain object. Also converts values to their respective internal types.
67480
+ * @param object Plain object
67481
+ * @returns ItmsCoachingSession
67482
+ */
67483
+ public static fromObject(object: { [k: string]: any }): coaching.ItmsCoachingSession;
67484
+
67485
+ /**
67486
+ * Creates a plain object from an ItmsCoachingSession message. Also converts values to other types if specified.
67487
+ * @param message ItmsCoachingSession
67488
+ * @param [options] Conversion options
67489
+ * @returns Plain object
67490
+ */
67491
+ public static toObject(message: coaching.ItmsCoachingSession, options?: $protobuf.IConversionOptions): { [k: string]: any };
67492
+
67493
+ /**
67494
+ * Converts this ItmsCoachingSession to JSON.
67495
+ * @returns JSON object
67496
+ */
67497
+ public toJSON(): { [k: string]: any };
67498
+ }
67499
+
67334
67500
  /** Properties of a ScheduledCoachingSession. */
67335
67501
  interface IScheduledCoachingSession {
67336
67502
 
package/lib/index.js CHANGED
@@ -194104,6 +194104,507 @@ $root.coaching = (function() {
194104
194104
  return values;
194105
194105
  })();
194106
194106
 
194107
+ /**
194108
+ * ItmsSessionCreatedReason enum.
194109
+ * @name coaching.ItmsSessionCreatedReason
194110
+ * @enum {string}
194111
+ * @property {number} ITMS_SESSION_CREATED_REASON_UNKNOWN=0 ITMS_SESSION_CREATED_REASON_UNKNOWN value
194112
+ * @property {number} ITMS_SESSION_CREATED_REASON_ITMS=1 ITMS_SESSION_CREATED_REASON_ITMS value
194113
+ * @property {number} ITMS_SESSION_CREATED_REASON_SI=2 ITMS_SESSION_CREATED_REASON_SI value
194114
+ */
194115
+ coaching.ItmsSessionCreatedReason = (function() {
194116
+ var valuesById = {}, values = Object.create(valuesById);
194117
+ values[valuesById[0] = "ITMS_SESSION_CREATED_REASON_UNKNOWN"] = 0;
194118
+ values[valuesById[1] = "ITMS_SESSION_CREATED_REASON_ITMS"] = 1;
194119
+ values[valuesById[2] = "ITMS_SESSION_CREATED_REASON_SI"] = 2;
194120
+ return values;
194121
+ })();
194122
+
194123
+ coaching.ItmsCoachingSession = (function() {
194124
+
194125
+ /**
194126
+ * Properties of an ItmsCoachingSession.
194127
+ * @memberof coaching
194128
+ * @interface IItmsCoachingSession
194129
+ * @property {string|null} [dropinSessionId] ItmsCoachingSession dropinSessionId
194130
+ * @property {string|null} [coachId] ItmsCoachingSession coachId
194131
+ * @property {number|null} [gingerMemberId] ItmsCoachingSession gingerMemberId
194132
+ * @property {string|null} [hsUserId] ItmsCoachingSession hsUserId
194133
+ * @property {number|Long|null} [createdAt] ItmsCoachingSession createdAt
194134
+ * @property {number|Long|null} [engagedAt] ItmsCoachingSession engagedAt
194135
+ * @property {number|Long|null} [coachEngagedAt] ItmsCoachingSession coachEngagedAt
194136
+ * @property {number|Long|null} [closedAt] ItmsCoachingSession closedAt
194137
+ * @property {string|null} [chatConversationId] A conversation between a Listener and a Caller is represented by a unique ChatConversation
194138
+ * See apps.listenerapp.models.ChatConversation
194139
+ * @property {coaching.ItmsSessionCreatedReason|null} [createdReason] ItmsCoachingSession createdReason
194140
+ * @property {string|null} [createdReasonDetails] ItmsCoachingSession createdReasonDetails
194141
+ */
194142
+
194143
+ /**
194144
+ * Constructs a new ItmsCoachingSession.
194145
+ * @memberof coaching
194146
+ * @classdesc In-the-moment support / drop-in coaching session (not scheduled).
194147
+ * Model: listener-server.apps.listenerapp.models.OneTimeCheckin
194148
+ * @implements IItmsCoachingSession
194149
+ * @constructor
194150
+ * @param {coaching.IItmsCoachingSession=} [properties] Properties to set
194151
+ */
194152
+ function ItmsCoachingSession(properties) {
194153
+ if (properties)
194154
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
194155
+ if (properties[keys[i]] != null)
194156
+ this[keys[i]] = properties[keys[i]];
194157
+ }
194158
+
194159
+ /**
194160
+ * ItmsCoachingSession dropinSessionId.
194161
+ * @member {string} dropinSessionId
194162
+ * @memberof coaching.ItmsCoachingSession
194163
+ * @instance
194164
+ */
194165
+ ItmsCoachingSession.prototype.dropinSessionId = "";
194166
+
194167
+ /**
194168
+ * ItmsCoachingSession coachId.
194169
+ * @member {string} coachId
194170
+ * @memberof coaching.ItmsCoachingSession
194171
+ * @instance
194172
+ */
194173
+ ItmsCoachingSession.prototype.coachId = "";
194174
+
194175
+ /**
194176
+ * ItmsCoachingSession gingerMemberId.
194177
+ * @member {number} gingerMemberId
194178
+ * @memberof coaching.ItmsCoachingSession
194179
+ * @instance
194180
+ */
194181
+ ItmsCoachingSession.prototype.gingerMemberId = 0;
194182
+
194183
+ /**
194184
+ * ItmsCoachingSession hsUserId.
194185
+ * @member {string} hsUserId
194186
+ * @memberof coaching.ItmsCoachingSession
194187
+ * @instance
194188
+ */
194189
+ ItmsCoachingSession.prototype.hsUserId = "";
194190
+
194191
+ /**
194192
+ * ItmsCoachingSession createdAt.
194193
+ * @member {number|Long} createdAt
194194
+ * @memberof coaching.ItmsCoachingSession
194195
+ * @instance
194196
+ */
194197
+ ItmsCoachingSession.prototype.createdAt = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
194198
+
194199
+ /**
194200
+ * ItmsCoachingSession engagedAt.
194201
+ * @member {number|Long} engagedAt
194202
+ * @memberof coaching.ItmsCoachingSession
194203
+ * @instance
194204
+ */
194205
+ ItmsCoachingSession.prototype.engagedAt = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
194206
+
194207
+ /**
194208
+ * ItmsCoachingSession coachEngagedAt.
194209
+ * @member {number|Long} coachEngagedAt
194210
+ * @memberof coaching.ItmsCoachingSession
194211
+ * @instance
194212
+ */
194213
+ ItmsCoachingSession.prototype.coachEngagedAt = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
194214
+
194215
+ /**
194216
+ * ItmsCoachingSession closedAt.
194217
+ * @member {number|Long} closedAt
194218
+ * @memberof coaching.ItmsCoachingSession
194219
+ * @instance
194220
+ */
194221
+ ItmsCoachingSession.prototype.closedAt = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
194222
+
194223
+ /**
194224
+ * A conversation between a Listener and a Caller is represented by a unique ChatConversation
194225
+ * See apps.listenerapp.models.ChatConversation
194226
+ * @member {string} chatConversationId
194227
+ * @memberof coaching.ItmsCoachingSession
194228
+ * @instance
194229
+ */
194230
+ ItmsCoachingSession.prototype.chatConversationId = "";
194231
+
194232
+ /**
194233
+ * ItmsCoachingSession createdReason.
194234
+ * @member {coaching.ItmsSessionCreatedReason} createdReason
194235
+ * @memberof coaching.ItmsCoachingSession
194236
+ * @instance
194237
+ */
194238
+ ItmsCoachingSession.prototype.createdReason = 0;
194239
+
194240
+ /**
194241
+ * ItmsCoachingSession createdReasonDetails.
194242
+ * @member {string} createdReasonDetails
194243
+ * @memberof coaching.ItmsCoachingSession
194244
+ * @instance
194245
+ */
194246
+ ItmsCoachingSession.prototype.createdReasonDetails = "";
194247
+
194248
+ /**
194249
+ * Creates a new ItmsCoachingSession instance using the specified properties.
194250
+ * @function create
194251
+ * @memberof coaching.ItmsCoachingSession
194252
+ * @static
194253
+ * @param {coaching.IItmsCoachingSession=} [properties] Properties to set
194254
+ * @returns {coaching.ItmsCoachingSession} ItmsCoachingSession instance
194255
+ */
194256
+ ItmsCoachingSession.create = function create(properties) {
194257
+ return new ItmsCoachingSession(properties);
194258
+ };
194259
+
194260
+ /**
194261
+ * Encodes the specified ItmsCoachingSession message. Does not implicitly {@link coaching.ItmsCoachingSession.verify|verify} messages.
194262
+ * @function encode
194263
+ * @memberof coaching.ItmsCoachingSession
194264
+ * @static
194265
+ * @param {coaching.IItmsCoachingSession} message ItmsCoachingSession message or plain object to encode
194266
+ * @param {$protobuf.Writer} [writer] Writer to encode to
194267
+ * @returns {$protobuf.Writer} Writer
194268
+ */
194269
+ ItmsCoachingSession.encode = function encode(message, writer) {
194270
+ if (!writer)
194271
+ writer = $Writer.create();
194272
+ if (message.dropinSessionId != null && message.hasOwnProperty("dropinSessionId"))
194273
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.dropinSessionId);
194274
+ if (message.coachId != null && message.hasOwnProperty("coachId"))
194275
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.coachId);
194276
+ if (message.gingerMemberId != null && message.hasOwnProperty("gingerMemberId"))
194277
+ writer.uint32(/* id 3, wireType 0 =*/24).uint32(message.gingerMemberId);
194278
+ if (message.hsUserId != null && message.hasOwnProperty("hsUserId"))
194279
+ writer.uint32(/* id 4, wireType 2 =*/34).string(message.hsUserId);
194280
+ if (message.createdAt != null && message.hasOwnProperty("createdAt"))
194281
+ writer.uint32(/* id 5, wireType 0 =*/40).uint64(message.createdAt);
194282
+ if (message.engagedAt != null && message.hasOwnProperty("engagedAt"))
194283
+ writer.uint32(/* id 6, wireType 0 =*/48).uint64(message.engagedAt);
194284
+ if (message.coachEngagedAt != null && message.hasOwnProperty("coachEngagedAt"))
194285
+ writer.uint32(/* id 7, wireType 0 =*/56).uint64(message.coachEngagedAt);
194286
+ if (message.closedAt != null && message.hasOwnProperty("closedAt"))
194287
+ writer.uint32(/* id 8, wireType 0 =*/64).uint64(message.closedAt);
194288
+ if (message.chatConversationId != null && message.hasOwnProperty("chatConversationId"))
194289
+ writer.uint32(/* id 9, wireType 2 =*/74).string(message.chatConversationId);
194290
+ if (message.createdReason != null && message.hasOwnProperty("createdReason"))
194291
+ writer.uint32(/* id 10, wireType 0 =*/80).int32(message.createdReason);
194292
+ if (message.createdReasonDetails != null && message.hasOwnProperty("createdReasonDetails"))
194293
+ writer.uint32(/* id 11, wireType 2 =*/90).string(message.createdReasonDetails);
194294
+ return writer;
194295
+ };
194296
+
194297
+ /**
194298
+ * Encodes the specified ItmsCoachingSession message, length delimited. Does not implicitly {@link coaching.ItmsCoachingSession.verify|verify} messages.
194299
+ * @function encodeDelimited
194300
+ * @memberof coaching.ItmsCoachingSession
194301
+ * @static
194302
+ * @param {coaching.IItmsCoachingSession} message ItmsCoachingSession message or plain object to encode
194303
+ * @param {$protobuf.Writer} [writer] Writer to encode to
194304
+ * @returns {$protobuf.Writer} Writer
194305
+ */
194306
+ ItmsCoachingSession.encodeDelimited = function encodeDelimited(message, writer) {
194307
+ return this.encode(message, writer).ldelim();
194308
+ };
194309
+
194310
+ /**
194311
+ * Decodes an ItmsCoachingSession message from the specified reader or buffer.
194312
+ * @function decode
194313
+ * @memberof coaching.ItmsCoachingSession
194314
+ * @static
194315
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
194316
+ * @param {number} [length] Message length if known beforehand
194317
+ * @returns {coaching.ItmsCoachingSession} ItmsCoachingSession
194318
+ * @throws {Error} If the payload is not a reader or valid buffer
194319
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
194320
+ */
194321
+ ItmsCoachingSession.decode = function decode(reader, length) {
194322
+ if (!(reader instanceof $Reader))
194323
+ reader = $Reader.create(reader);
194324
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.coaching.ItmsCoachingSession();
194325
+ while (reader.pos < end) {
194326
+ var tag = reader.uint32();
194327
+ switch (tag >>> 3) {
194328
+ case 1:
194329
+ message.dropinSessionId = reader.string();
194330
+ break;
194331
+ case 2:
194332
+ message.coachId = reader.string();
194333
+ break;
194334
+ case 3:
194335
+ message.gingerMemberId = reader.uint32();
194336
+ break;
194337
+ case 4:
194338
+ message.hsUserId = reader.string();
194339
+ break;
194340
+ case 5:
194341
+ message.createdAt = reader.uint64();
194342
+ break;
194343
+ case 6:
194344
+ message.engagedAt = reader.uint64();
194345
+ break;
194346
+ case 7:
194347
+ message.coachEngagedAt = reader.uint64();
194348
+ break;
194349
+ case 8:
194350
+ message.closedAt = reader.uint64();
194351
+ break;
194352
+ case 9:
194353
+ message.chatConversationId = reader.string();
194354
+ break;
194355
+ case 10:
194356
+ message.createdReason = reader.int32();
194357
+ break;
194358
+ case 11:
194359
+ message.createdReasonDetails = reader.string();
194360
+ break;
194361
+ default:
194362
+ reader.skipType(tag & 7);
194363
+ break;
194364
+ }
194365
+ }
194366
+ return message;
194367
+ };
194368
+
194369
+ /**
194370
+ * Decodes an ItmsCoachingSession message from the specified reader or buffer, length delimited.
194371
+ * @function decodeDelimited
194372
+ * @memberof coaching.ItmsCoachingSession
194373
+ * @static
194374
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
194375
+ * @returns {coaching.ItmsCoachingSession} ItmsCoachingSession
194376
+ * @throws {Error} If the payload is not a reader or valid buffer
194377
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
194378
+ */
194379
+ ItmsCoachingSession.decodeDelimited = function decodeDelimited(reader) {
194380
+ if (!(reader instanceof $Reader))
194381
+ reader = new $Reader(reader);
194382
+ return this.decode(reader, reader.uint32());
194383
+ };
194384
+
194385
+ /**
194386
+ * Verifies an ItmsCoachingSession message.
194387
+ * @function verify
194388
+ * @memberof coaching.ItmsCoachingSession
194389
+ * @static
194390
+ * @param {Object.<string,*>} message Plain object to verify
194391
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
194392
+ */
194393
+ ItmsCoachingSession.verify = function verify(message) {
194394
+ if (typeof message !== "object" || message === null)
194395
+ return "object expected";
194396
+ if (message.dropinSessionId != null && message.hasOwnProperty("dropinSessionId"))
194397
+ if (!$util.isString(message.dropinSessionId))
194398
+ return "dropinSessionId: string expected";
194399
+ if (message.coachId != null && message.hasOwnProperty("coachId"))
194400
+ if (!$util.isString(message.coachId))
194401
+ return "coachId: string expected";
194402
+ if (message.gingerMemberId != null && message.hasOwnProperty("gingerMemberId"))
194403
+ if (!$util.isInteger(message.gingerMemberId))
194404
+ return "gingerMemberId: integer expected";
194405
+ if (message.hsUserId != null && message.hasOwnProperty("hsUserId"))
194406
+ if (!$util.isString(message.hsUserId))
194407
+ return "hsUserId: string expected";
194408
+ if (message.createdAt != null && message.hasOwnProperty("createdAt"))
194409
+ if (!$util.isInteger(message.createdAt) && !(message.createdAt && $util.isInteger(message.createdAt.low) && $util.isInteger(message.createdAt.high)))
194410
+ return "createdAt: integer|Long expected";
194411
+ if (message.engagedAt != null && message.hasOwnProperty("engagedAt"))
194412
+ if (!$util.isInteger(message.engagedAt) && !(message.engagedAt && $util.isInteger(message.engagedAt.low) && $util.isInteger(message.engagedAt.high)))
194413
+ return "engagedAt: integer|Long expected";
194414
+ if (message.coachEngagedAt != null && message.hasOwnProperty("coachEngagedAt"))
194415
+ if (!$util.isInteger(message.coachEngagedAt) && !(message.coachEngagedAt && $util.isInteger(message.coachEngagedAt.low) && $util.isInteger(message.coachEngagedAt.high)))
194416
+ return "coachEngagedAt: integer|Long expected";
194417
+ if (message.closedAt != null && message.hasOwnProperty("closedAt"))
194418
+ if (!$util.isInteger(message.closedAt) && !(message.closedAt && $util.isInteger(message.closedAt.low) && $util.isInteger(message.closedAt.high)))
194419
+ return "closedAt: integer|Long expected";
194420
+ if (message.chatConversationId != null && message.hasOwnProperty("chatConversationId"))
194421
+ if (!$util.isString(message.chatConversationId))
194422
+ return "chatConversationId: string expected";
194423
+ if (message.createdReason != null && message.hasOwnProperty("createdReason"))
194424
+ switch (message.createdReason) {
194425
+ default:
194426
+ return "createdReason: enum value expected";
194427
+ case 0:
194428
+ case 1:
194429
+ case 2:
194430
+ break;
194431
+ }
194432
+ if (message.createdReasonDetails != null && message.hasOwnProperty("createdReasonDetails"))
194433
+ if (!$util.isString(message.createdReasonDetails))
194434
+ return "createdReasonDetails: string expected";
194435
+ return null;
194436
+ };
194437
+
194438
+ /**
194439
+ * Creates an ItmsCoachingSession message from a plain object. Also converts values to their respective internal types.
194440
+ * @function fromObject
194441
+ * @memberof coaching.ItmsCoachingSession
194442
+ * @static
194443
+ * @param {Object.<string,*>} object Plain object
194444
+ * @returns {coaching.ItmsCoachingSession} ItmsCoachingSession
194445
+ */
194446
+ ItmsCoachingSession.fromObject = function fromObject(object) {
194447
+ if (object instanceof $root.coaching.ItmsCoachingSession)
194448
+ return object;
194449
+ var message = new $root.coaching.ItmsCoachingSession();
194450
+ if (object.dropinSessionId != null)
194451
+ message.dropinSessionId = String(object.dropinSessionId);
194452
+ if (object.coachId != null)
194453
+ message.coachId = String(object.coachId);
194454
+ if (object.gingerMemberId != null)
194455
+ message.gingerMemberId = object.gingerMemberId >>> 0;
194456
+ if (object.hsUserId != null)
194457
+ message.hsUserId = String(object.hsUserId);
194458
+ if (object.createdAt != null)
194459
+ if ($util.Long)
194460
+ (message.createdAt = $util.Long.fromValue(object.createdAt)).unsigned = true;
194461
+ else if (typeof object.createdAt === "string")
194462
+ message.createdAt = parseInt(object.createdAt, 10);
194463
+ else if (typeof object.createdAt === "number")
194464
+ message.createdAt = object.createdAt;
194465
+ else if (typeof object.createdAt === "object")
194466
+ message.createdAt = new $util.LongBits(object.createdAt.low >>> 0, object.createdAt.high >>> 0).toNumber(true);
194467
+ if (object.engagedAt != null)
194468
+ if ($util.Long)
194469
+ (message.engagedAt = $util.Long.fromValue(object.engagedAt)).unsigned = true;
194470
+ else if (typeof object.engagedAt === "string")
194471
+ message.engagedAt = parseInt(object.engagedAt, 10);
194472
+ else if (typeof object.engagedAt === "number")
194473
+ message.engagedAt = object.engagedAt;
194474
+ else if (typeof object.engagedAt === "object")
194475
+ message.engagedAt = new $util.LongBits(object.engagedAt.low >>> 0, object.engagedAt.high >>> 0).toNumber(true);
194476
+ if (object.coachEngagedAt != null)
194477
+ if ($util.Long)
194478
+ (message.coachEngagedAt = $util.Long.fromValue(object.coachEngagedAt)).unsigned = true;
194479
+ else if (typeof object.coachEngagedAt === "string")
194480
+ message.coachEngagedAt = parseInt(object.coachEngagedAt, 10);
194481
+ else if (typeof object.coachEngagedAt === "number")
194482
+ message.coachEngagedAt = object.coachEngagedAt;
194483
+ else if (typeof object.coachEngagedAt === "object")
194484
+ message.coachEngagedAt = new $util.LongBits(object.coachEngagedAt.low >>> 0, object.coachEngagedAt.high >>> 0).toNumber(true);
194485
+ if (object.closedAt != null)
194486
+ if ($util.Long)
194487
+ (message.closedAt = $util.Long.fromValue(object.closedAt)).unsigned = true;
194488
+ else if (typeof object.closedAt === "string")
194489
+ message.closedAt = parseInt(object.closedAt, 10);
194490
+ else if (typeof object.closedAt === "number")
194491
+ message.closedAt = object.closedAt;
194492
+ else if (typeof object.closedAt === "object")
194493
+ message.closedAt = new $util.LongBits(object.closedAt.low >>> 0, object.closedAt.high >>> 0).toNumber(true);
194494
+ if (object.chatConversationId != null)
194495
+ message.chatConversationId = String(object.chatConversationId);
194496
+ switch (object.createdReason) {
194497
+ case "ITMS_SESSION_CREATED_REASON_UNKNOWN":
194498
+ case 0:
194499
+ message.createdReason = 0;
194500
+ break;
194501
+ case "ITMS_SESSION_CREATED_REASON_ITMS":
194502
+ case 1:
194503
+ message.createdReason = 1;
194504
+ break;
194505
+ case "ITMS_SESSION_CREATED_REASON_SI":
194506
+ case 2:
194507
+ message.createdReason = 2;
194508
+ break;
194509
+ }
194510
+ if (object.createdReasonDetails != null)
194511
+ message.createdReasonDetails = String(object.createdReasonDetails);
194512
+ return message;
194513
+ };
194514
+
194515
+ /**
194516
+ * Creates a plain object from an ItmsCoachingSession message. Also converts values to other types if specified.
194517
+ * @function toObject
194518
+ * @memberof coaching.ItmsCoachingSession
194519
+ * @static
194520
+ * @param {coaching.ItmsCoachingSession} message ItmsCoachingSession
194521
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
194522
+ * @returns {Object.<string,*>} Plain object
194523
+ */
194524
+ ItmsCoachingSession.toObject = function toObject(message, options) {
194525
+ if (!options)
194526
+ options = {};
194527
+ var object = {};
194528
+ if (options.defaults) {
194529
+ object.dropinSessionId = "";
194530
+ object.coachId = "";
194531
+ object.gingerMemberId = 0;
194532
+ object.hsUserId = "";
194533
+ if ($util.Long) {
194534
+ var long = new $util.Long(0, 0, true);
194535
+ object.createdAt = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
194536
+ } else
194537
+ object.createdAt = options.longs === String ? "0" : 0;
194538
+ if ($util.Long) {
194539
+ var long = new $util.Long(0, 0, true);
194540
+ object.engagedAt = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
194541
+ } else
194542
+ object.engagedAt = options.longs === String ? "0" : 0;
194543
+ if ($util.Long) {
194544
+ var long = new $util.Long(0, 0, true);
194545
+ object.coachEngagedAt = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
194546
+ } else
194547
+ object.coachEngagedAt = options.longs === String ? "0" : 0;
194548
+ if ($util.Long) {
194549
+ var long = new $util.Long(0, 0, true);
194550
+ object.closedAt = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
194551
+ } else
194552
+ object.closedAt = options.longs === String ? "0" : 0;
194553
+ object.chatConversationId = "";
194554
+ object.createdReason = options.enums === String ? "ITMS_SESSION_CREATED_REASON_UNKNOWN" : 0;
194555
+ object.createdReasonDetails = "";
194556
+ }
194557
+ if (message.dropinSessionId != null && message.hasOwnProperty("dropinSessionId"))
194558
+ object.dropinSessionId = message.dropinSessionId;
194559
+ if (message.coachId != null && message.hasOwnProperty("coachId"))
194560
+ object.coachId = message.coachId;
194561
+ if (message.gingerMemberId != null && message.hasOwnProperty("gingerMemberId"))
194562
+ object.gingerMemberId = message.gingerMemberId;
194563
+ if (message.hsUserId != null && message.hasOwnProperty("hsUserId"))
194564
+ object.hsUserId = message.hsUserId;
194565
+ if (message.createdAt != null && message.hasOwnProperty("createdAt"))
194566
+ if (typeof message.createdAt === "number")
194567
+ object.createdAt = options.longs === String ? String(message.createdAt) : message.createdAt;
194568
+ else
194569
+ object.createdAt = options.longs === String ? $util.Long.prototype.toString.call(message.createdAt) : options.longs === Number ? new $util.LongBits(message.createdAt.low >>> 0, message.createdAt.high >>> 0).toNumber(true) : message.createdAt;
194570
+ if (message.engagedAt != null && message.hasOwnProperty("engagedAt"))
194571
+ if (typeof message.engagedAt === "number")
194572
+ object.engagedAt = options.longs === String ? String(message.engagedAt) : message.engagedAt;
194573
+ else
194574
+ object.engagedAt = options.longs === String ? $util.Long.prototype.toString.call(message.engagedAt) : options.longs === Number ? new $util.LongBits(message.engagedAt.low >>> 0, message.engagedAt.high >>> 0).toNumber(true) : message.engagedAt;
194575
+ if (message.coachEngagedAt != null && message.hasOwnProperty("coachEngagedAt"))
194576
+ if (typeof message.coachEngagedAt === "number")
194577
+ object.coachEngagedAt = options.longs === String ? String(message.coachEngagedAt) : message.coachEngagedAt;
194578
+ else
194579
+ object.coachEngagedAt = options.longs === String ? $util.Long.prototype.toString.call(message.coachEngagedAt) : options.longs === Number ? new $util.LongBits(message.coachEngagedAt.low >>> 0, message.coachEngagedAt.high >>> 0).toNumber(true) : message.coachEngagedAt;
194580
+ if (message.closedAt != null && message.hasOwnProperty("closedAt"))
194581
+ if (typeof message.closedAt === "number")
194582
+ object.closedAt = options.longs === String ? String(message.closedAt) : message.closedAt;
194583
+ else
194584
+ object.closedAt = options.longs === String ? $util.Long.prototype.toString.call(message.closedAt) : options.longs === Number ? new $util.LongBits(message.closedAt.low >>> 0, message.closedAt.high >>> 0).toNumber(true) : message.closedAt;
194585
+ if (message.chatConversationId != null && message.hasOwnProperty("chatConversationId"))
194586
+ object.chatConversationId = message.chatConversationId;
194587
+ if (message.createdReason != null && message.hasOwnProperty("createdReason"))
194588
+ object.createdReason = options.enums === String ? $root.coaching.ItmsSessionCreatedReason[message.createdReason] : message.createdReason;
194589
+ if (message.createdReasonDetails != null && message.hasOwnProperty("createdReasonDetails"))
194590
+ object.createdReasonDetails = message.createdReasonDetails;
194591
+ return object;
194592
+ };
194593
+
194594
+ /**
194595
+ * Converts this ItmsCoachingSession to JSON.
194596
+ * @function toJSON
194597
+ * @memberof coaching.ItmsCoachingSession
194598
+ * @instance
194599
+ * @returns {Object.<string,*>} JSON object
194600
+ */
194601
+ ItmsCoachingSession.prototype.toJSON = function toJSON() {
194602
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
194603
+ };
194604
+
194605
+ return ItmsCoachingSession;
194606
+ })();
194607
+
194107
194608
  coaching.ScheduledCoachingSession = (function() {
194108
194609
 
194109
194610
  /**
package/package.json CHANGED
@@ -16,5 +16,5 @@
16
16
  "main": "lib/index.js",
17
17
  "name": "@headspace/protos-events",
18
18
  "typings": "lib/index.d.ts",
19
- "version": "1.785.0"
19
+ "version": "1.786.0"
20
20
  }