@replit/protocol 0.3.7 → 0.3.8

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/main/index.d.ts CHANGED
@@ -22700,6 +22700,12 @@ export namespace replit {
22700
22700
 
22701
22701
  /** GovalReplIdentity buildInfo */
22702
22702
  buildInfo?: (replit.goval.api.repl.BuildInfo|replit.goval.api.repl.IBuildInfo|null);
22703
+
22704
+ /** GovalReplIdentity isTeam */
22705
+ isTeam?: (boolean|null);
22706
+
22707
+ /** GovalReplIdentity roles */
22708
+ roles?: (string[]|null);
22703
22709
  }
22704
22710
 
22705
22711
  /** Represents a GovalReplIdentity. */
@@ -22735,6 +22741,12 @@ export namespace replit {
22735
22741
  /** GovalReplIdentity buildInfo. */
22736
22742
  public buildInfo?: (replit.goval.api.repl.BuildInfo|null);
22737
22743
 
22744
+ /** GovalReplIdentity isTeam. */
22745
+ public isTeam: boolean;
22746
+
22747
+ /** GovalReplIdentity roles. */
22748
+ public roles: string[];
22749
+
22738
22750
  /**
22739
22751
  * Creates a new GovalReplIdentity instance using the specified properties.
22740
22752
  * @param [properties] Properties to set
package/main/index.js CHANGED
@@ -56642,6 +56642,8 @@
56642
56642
  * @property {string|null} [originReplid] GovalReplIdentity originReplid
56643
56643
  * @property {number|null} [userId] GovalReplIdentity userId
56644
56644
  * @property {replit.goval.api.repl.BuildInfo|replit.goval.api.repl.IBuildInfo|null} [buildInfo] GovalReplIdentity buildInfo
56645
+ * @property {boolean|null} [isTeam] GovalReplIdentity isTeam
56646
+ * @property {Array.<string>|null} [roles] GovalReplIdentity roles
56645
56647
  */
56646
56648
 
56647
56649
  /**
@@ -56652,6 +56654,7 @@
56652
56654
  * @param {replit.goval.api.IGovalReplIdentity=} [properties] Properties to set
56653
56655
  */
56654
56656
  function GovalReplIdentity(properties) {
56657
+ this.roles = [];
56655
56658
  if (properties)
56656
56659
  for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
56657
56660
  if (properties[keys[i]] != null)
@@ -56722,6 +56725,22 @@
56722
56725
  */
56723
56726
  GovalReplIdentity.prototype.buildInfo = null;
56724
56727
 
56728
+ /**
56729
+ * GovalReplIdentity isTeam.
56730
+ * @member {boolean} isTeam
56731
+ * @memberof replit.goval.api.GovalReplIdentity
56732
+ * @instance
56733
+ */
56734
+ GovalReplIdentity.prototype.isTeam = false;
56735
+
56736
+ /**
56737
+ * GovalReplIdentity roles.
56738
+ * @member {Array.<string>} roles
56739
+ * @memberof replit.goval.api.GovalReplIdentity
56740
+ * @instance
56741
+ */
56742
+ GovalReplIdentity.prototype.roles = $util.emptyArray;
56743
+
56725
56744
  /**
56726
56745
  * Creates a new GovalReplIdentity instance using the specified properties.
56727
56746
  * @function create
@@ -56762,6 +56781,11 @@
56762
56781
  writer.uint32(/* id 7, wireType 0 =*/56).int64(message.userId);
56763
56782
  if (message.buildInfo != null && Object.hasOwnProperty.call(message, "buildInfo"))
56764
56783
  $root.replit.goval.api.repl.BuildInfo.encode(message.buildInfo, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim();
56784
+ if (message.isTeam != null && Object.hasOwnProperty.call(message, "isTeam"))
56785
+ writer.uint32(/* id 9, wireType 0 =*/72).bool(message.isTeam);
56786
+ if (message.roles != null && message.roles.length)
56787
+ for (var i = 0; i < message.roles.length; ++i)
56788
+ writer.uint32(/* id 10, wireType 2 =*/82).string(message.roles[i]);
56765
56789
  return writer;
56766
56790
  };
56767
56791
 
@@ -56820,6 +56844,14 @@
56820
56844
  case 8:
56821
56845
  message.buildInfo = $root.replit.goval.api.repl.BuildInfo.decode(reader, reader.uint32());
56822
56846
  break;
56847
+ case 9:
56848
+ message.isTeam = reader.bool();
56849
+ break;
56850
+ case 10:
56851
+ if (!(message.roles && message.roles.length))
56852
+ message.roles = [];
56853
+ message.roles.push(reader.string());
56854
+ break;
56823
56855
  default:
56824
56856
  reader.skipType(tag & 7);
56825
56857
  break;
@@ -56881,6 +56913,16 @@
56881
56913
  if (error)
56882
56914
  return "buildInfo." + error;
56883
56915
  }
56916
+ if (message.isTeam != null && message.hasOwnProperty("isTeam"))
56917
+ if (typeof message.isTeam !== "boolean")
56918
+ return "isTeam: boolean expected";
56919
+ if (message.roles != null && message.hasOwnProperty("roles")) {
56920
+ if (!Array.isArray(message.roles))
56921
+ return "roles: array expected";
56922
+ for (var i = 0; i < message.roles.length; ++i)
56923
+ if (!$util.isString(message.roles[i]))
56924
+ return "roles: string[] expected";
56925
+ }
56884
56926
  return null;
56885
56927
  };
56886
56928
 
@@ -56922,6 +56964,15 @@
56922
56964
  throw TypeError(".replit.goval.api.GovalReplIdentity.buildInfo: object expected");
56923
56965
  message.buildInfo = $root.replit.goval.api.repl.BuildInfo.fromObject(object.buildInfo);
56924
56966
  }
56967
+ if (object.isTeam != null)
56968
+ message.isTeam = Boolean(object.isTeam);
56969
+ if (object.roles) {
56970
+ if (!Array.isArray(object.roles))
56971
+ throw TypeError(".replit.goval.api.GovalReplIdentity.roles: array expected");
56972
+ message.roles = [];
56973
+ for (var i = 0; i < object.roles.length; ++i)
56974
+ message.roles[i] = String(object.roles[i]);
56975
+ }
56925
56976
  return message;
56926
56977
  };
56927
56978
 
@@ -56938,6 +56989,8 @@
56938
56989
  if (!options)
56939
56990
  options = {};
56940
56991
  var object = {};
56992
+ if (options.arrays || options.defaults)
56993
+ object.roles = [];
56941
56994
  if (options.defaults) {
56942
56995
  object.replid = "";
56943
56996
  object.user = "";
@@ -56951,6 +57004,7 @@
56951
57004
  } else
56952
57005
  object.userId = options.longs === String ? "0" : 0;
56953
57006
  object.buildInfo = null;
57007
+ object.isTeam = false;
56954
57008
  }
56955
57009
  if (message.replid != null && message.hasOwnProperty("replid"))
56956
57010
  object.replid = message.replid;
@@ -56971,6 +57025,13 @@
56971
57025
  object.userId = options.longs === String ? $util.Long.prototype.toString.call(message.userId) : options.longs === Number ? new $util.LongBits(message.userId.low >>> 0, message.userId.high >>> 0).toNumber() : message.userId;
56972
57026
  if (message.buildInfo != null && message.hasOwnProperty("buildInfo"))
56973
57027
  object.buildInfo = $root.replit.goval.api.repl.BuildInfo.toObject(message.buildInfo, options);
57028
+ if (message.isTeam != null && message.hasOwnProperty("isTeam"))
57029
+ object.isTeam = message.isTeam;
57030
+ if (message.roles && message.roles.length) {
57031
+ object.roles = [];
57032
+ for (var j = 0; j < message.roles.length; ++j)
57033
+ object.roles[j] = message.roles[j];
57034
+ }
56974
57035
  return object;
56975
57036
  };
56976
57037
 
@@ -32367,6 +32367,16 @@ declare type replit$goval$api$IGovalReplIdentity = {|
32367
32367
  | replit$goval$api$repl$BuildInfo
32368
32368
  | replit$goval$api$repl$IBuildInfo
32369
32369
  | null,
32370
+
32371
+ /**
32372
+ * GovalReplIdentity isTeam
32373
+ */
32374
+ isTeam?: boolean | null,
32375
+
32376
+ /**
32377
+ * GovalReplIdentity roles
32378
+ */
32379
+ roles?: string[] | null,
32370
32380
  |};
32371
32381
 
32372
32382
  /**
@@ -32419,6 +32429,16 @@ declare class replit$goval$api$GovalReplIdentity {
32419
32429
  */
32420
32430
  buildInfo?: replit$goval$api$repl$BuildInfo | null;
32421
32431
 
32432
+ /**
32433
+ * GovalReplIdentity isTeam.
32434
+ */
32435
+ isTeam: boolean;
32436
+
32437
+ /**
32438
+ * GovalReplIdentity roles.
32439
+ */
32440
+ roles: string[];
32441
+
32422
32442
  /**
32423
32443
  * Creates a new GovalReplIdentity instance using the specified properties.
32424
32444
  * @param [properties] Properties to set
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@replit/protocol",
3
- "version": "0.3.7",
3
+ "version": "0.3.8",
4
4
  "description": "JavaScript bindings for the Replit protocol",
5
5
  "main": "main/index.js",
6
6
  "repository": "https://github.com/replit/protocol",