@juzi/wechaty-grpc 1.0.73 → 1.0.74

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.
Files changed (42) hide show
  1. package/dist/cjs/out/wechaty/puppet/room_pb.d.ts +36 -0
  2. package/dist/cjs/out/wechaty/puppet/room_pb.js +275 -0
  3. package/dist/cjs/out/wechaty/puppet.openapi.yaml +22 -1
  4. package/dist/cjs/out/wechaty/puppet.swagger.json +34 -1
  5. package/dist/cjs/out/wechaty/puppet_grpc_pb.d.ts +17 -0
  6. package/dist/cjs/out/wechaty/puppet_grpc_pb.js +33 -0
  7. package/dist/cjs/out/wechaty/puppet_pb_service.d.ts +19 -0
  8. package/dist/cjs/out/wechaty/puppet_pb_service.js +40 -0
  9. package/dist/cjs/proto/wechaty/puppet/room.proto +7 -1
  10. package/dist/cjs/proto/wechaty/puppet.proto +5 -0
  11. package/dist/cjs/src/package-json.d.ts.map +1 -1
  12. package/dist/cjs/src/package-json.js +2 -1
  13. package/dist/cjs/src/package-json.js.map +1 -1
  14. package/dist/cjs/tests/puppet-server-impl.d.ts.map +1 -1
  15. package/dist/cjs/tests/puppet-server-impl.js +5 -0
  16. package/dist/cjs/tests/puppet-server-impl.js.map +1 -1
  17. package/dist/esm/out/wechaty/puppet/room_pb.d.ts +36 -0
  18. package/dist/esm/out/wechaty/puppet/room_pb.js +275 -0
  19. package/dist/esm/out/wechaty/puppet.openapi.yaml +22 -1
  20. package/dist/esm/out/wechaty/puppet.swagger.json +34 -1
  21. package/dist/esm/out/wechaty/puppet_grpc_pb.d.ts +17 -0
  22. package/dist/esm/out/wechaty/puppet_grpc_pb.js +33 -0
  23. package/dist/esm/out/wechaty/puppet_pb_service.d.ts +19 -0
  24. package/dist/esm/out/wechaty/puppet_pb_service.js +40 -0
  25. package/dist/esm/proto/wechaty/puppet/room.proto +7 -1
  26. package/dist/esm/proto/wechaty/puppet.proto +5 -0
  27. package/dist/esm/src/package-json.d.ts.map +1 -1
  28. package/dist/esm/src/package-json.js +2 -1
  29. package/dist/esm/src/package-json.js.map +1 -1
  30. package/dist/esm/tests/puppet-server-impl.d.ts.map +1 -1
  31. package/dist/esm/tests/puppet-server-impl.js +5 -0
  32. package/dist/esm/tests/puppet-server-impl.js.map +1 -1
  33. package/out/wechaty/puppet/room_pb.d.ts +36 -0
  34. package/out/wechaty/puppet/room_pb.js +275 -0
  35. package/out/wechaty/puppet.openapi.yaml +22 -1
  36. package/out/wechaty/puppet.swagger.json +34 -1
  37. package/out/wechaty/puppet_grpc_pb.d.ts +17 -0
  38. package/out/wechaty/puppet_grpc_pb.js +33 -0
  39. package/out/wechaty/puppet_pb_service.d.ts +19 -0
  40. package/out/wechaty/puppet_pb_service.js +40 -0
  41. package/package.json +2 -1
  42. package/src/package-json.ts +2 -1
@@ -685,3 +685,39 @@ export namespace RoomAdminsResponse {
685
685
  }
686
686
  }
687
687
 
688
+ export class RoomDismissRequest extends jspb.Message {
689
+ getId(): string;
690
+ setId(value: string): void;
691
+
692
+ serializeBinary(): Uint8Array;
693
+ toObject(includeInstance?: boolean): RoomDismissRequest.AsObject;
694
+ static toObject(includeInstance: boolean, msg: RoomDismissRequest): RoomDismissRequest.AsObject;
695
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
696
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
697
+ static serializeBinaryToWriter(message: RoomDismissRequest, writer: jspb.BinaryWriter): void;
698
+ static deserializeBinary(bytes: Uint8Array): RoomDismissRequest;
699
+ static deserializeBinaryFromReader(message: RoomDismissRequest, reader: jspb.BinaryReader): RoomDismissRequest;
700
+ }
701
+
702
+ export namespace RoomDismissRequest {
703
+ export type AsObject = {
704
+ id: string,
705
+ }
706
+ }
707
+
708
+ export class RoomDismissResponse extends jspb.Message {
709
+ serializeBinary(): Uint8Array;
710
+ toObject(includeInstance?: boolean): RoomDismissResponse.AsObject;
711
+ static toObject(includeInstance: boolean, msg: RoomDismissResponse): RoomDismissResponse.AsObject;
712
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
713
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
714
+ static serializeBinaryToWriter(message: RoomDismissResponse, writer: jspb.BinaryWriter): void;
715
+ static deserializeBinary(bytes: Uint8Array): RoomDismissResponse;
716
+ static deserializeBinaryFromReader(message: RoomDismissResponse, reader: jspb.BinaryReader): RoomDismissResponse;
717
+ }
718
+
719
+ export namespace RoomDismissResponse {
720
+ export type AsObject = {
721
+ }
722
+ }
723
+
@@ -31,6 +31,8 @@ goog.exportSymbol('proto.wechaty.puppet.RoomCreateRequest', null, global);
31
31
  goog.exportSymbol('proto.wechaty.puppet.RoomCreateResponse', null, global);
32
32
  goog.exportSymbol('proto.wechaty.puppet.RoomDelRequest', null, global);
33
33
  goog.exportSymbol('proto.wechaty.puppet.RoomDelResponse', null, global);
34
+ goog.exportSymbol('proto.wechaty.puppet.RoomDismissRequest', null, global);
35
+ goog.exportSymbol('proto.wechaty.puppet.RoomDismissResponse', null, global);
34
36
  goog.exportSymbol('proto.wechaty.puppet.RoomListRequest', null, global);
35
37
  goog.exportSymbol('proto.wechaty.puppet.RoomListResponse', null, global);
36
38
  goog.exportSymbol('proto.wechaty.puppet.RoomOwnerTransferRequest', null, global);
@@ -635,6 +637,48 @@ if (goog.DEBUG && !COMPILED) {
635
637
  */
636
638
  proto.wechaty.puppet.RoomAdminsResponse.displayName = 'proto.wechaty.puppet.RoomAdminsResponse';
637
639
  }
640
+ /**
641
+ * Generated by JsPbCodeGenerator.
642
+ * @param {Array=} opt_data Optional initial data array, typically from a
643
+ * server response, or constructed directly in Javascript. The array is used
644
+ * in place and becomes part of the constructed object. It is not cloned.
645
+ * If no data is provided, the constructed object will be empty, but still
646
+ * valid.
647
+ * @extends {jspb.Message}
648
+ * @constructor
649
+ */
650
+ proto.wechaty.puppet.RoomDismissRequest = function(opt_data) {
651
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
652
+ };
653
+ goog.inherits(proto.wechaty.puppet.RoomDismissRequest, jspb.Message);
654
+ if (goog.DEBUG && !COMPILED) {
655
+ /**
656
+ * @public
657
+ * @override
658
+ */
659
+ proto.wechaty.puppet.RoomDismissRequest.displayName = 'proto.wechaty.puppet.RoomDismissRequest';
660
+ }
661
+ /**
662
+ * Generated by JsPbCodeGenerator.
663
+ * @param {Array=} opt_data Optional initial data array, typically from a
664
+ * server response, or constructed directly in Javascript. The array is used
665
+ * in place and becomes part of the constructed object. It is not cloned.
666
+ * If no data is provided, the constructed object will be empty, but still
667
+ * valid.
668
+ * @extends {jspb.Message}
669
+ * @constructor
670
+ */
671
+ proto.wechaty.puppet.RoomDismissResponse = function(opt_data) {
672
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
673
+ };
674
+ goog.inherits(proto.wechaty.puppet.RoomDismissResponse, jspb.Message);
675
+ if (goog.DEBUG && !COMPILED) {
676
+ /**
677
+ * @public
678
+ * @override
679
+ */
680
+ proto.wechaty.puppet.RoomDismissResponse.displayName = 'proto.wechaty.puppet.RoomDismissResponse';
681
+ }
638
682
 
639
683
 
640
684
 
@@ -5271,4 +5315,235 @@ proto.wechaty.puppet.RoomAdminsResponse.serializeBinaryToWriter = function(messa
5271
5315
  };
5272
5316
 
5273
5317
 
5318
+
5319
+
5320
+
5321
+ if (jspb.Message.GENERATE_TO_OBJECT) {
5322
+ /**
5323
+ * Creates an object representation of this proto.
5324
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
5325
+ * Optional fields that are not set will be set to undefined.
5326
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
5327
+ * For the list of reserved names please see:
5328
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
5329
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
5330
+ * JSPB instance for transitional soy proto support:
5331
+ * http://goto/soy-param-migration
5332
+ * @return {!Object}
5333
+ */
5334
+ proto.wechaty.puppet.RoomDismissRequest.prototype.toObject = function(opt_includeInstance) {
5335
+ return proto.wechaty.puppet.RoomDismissRequest.toObject(opt_includeInstance, this);
5336
+ };
5337
+
5338
+
5339
+ /**
5340
+ * Static version of the {@see toObject} method.
5341
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
5342
+ * the JSPB instance for transitional soy proto support:
5343
+ * http://goto/soy-param-migration
5344
+ * @param {!proto.wechaty.puppet.RoomDismissRequest} msg The msg instance to transform.
5345
+ * @return {!Object}
5346
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5347
+ */
5348
+ proto.wechaty.puppet.RoomDismissRequest.toObject = function(includeInstance, msg) {
5349
+ var f, obj = {
5350
+ id: jspb.Message.getFieldWithDefault(msg, 1, "")
5351
+ };
5352
+
5353
+ if (includeInstance) {
5354
+ obj.$jspbMessageInstance = msg;
5355
+ }
5356
+ return obj;
5357
+ };
5358
+ }
5359
+
5360
+
5361
+ /**
5362
+ * Deserializes binary data (in protobuf wire format).
5363
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
5364
+ * @return {!proto.wechaty.puppet.RoomDismissRequest}
5365
+ */
5366
+ proto.wechaty.puppet.RoomDismissRequest.deserializeBinary = function(bytes) {
5367
+ var reader = new jspb.BinaryReader(bytes);
5368
+ var msg = new proto.wechaty.puppet.RoomDismissRequest;
5369
+ return proto.wechaty.puppet.RoomDismissRequest.deserializeBinaryFromReader(msg, reader);
5370
+ };
5371
+
5372
+
5373
+ /**
5374
+ * Deserializes binary data (in protobuf wire format) from the
5375
+ * given reader into the given message object.
5376
+ * @param {!proto.wechaty.puppet.RoomDismissRequest} msg The message object to deserialize into.
5377
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
5378
+ * @return {!proto.wechaty.puppet.RoomDismissRequest}
5379
+ */
5380
+ proto.wechaty.puppet.RoomDismissRequest.deserializeBinaryFromReader = function(msg, reader) {
5381
+ while (reader.nextField()) {
5382
+ if (reader.isEndGroup()) {
5383
+ break;
5384
+ }
5385
+ var field = reader.getFieldNumber();
5386
+ switch (field) {
5387
+ case 1:
5388
+ var value = /** @type {string} */ (reader.readString());
5389
+ msg.setId(value);
5390
+ break;
5391
+ default:
5392
+ reader.skipField();
5393
+ break;
5394
+ }
5395
+ }
5396
+ return msg;
5397
+ };
5398
+
5399
+
5400
+ /**
5401
+ * Serializes the message to binary data (in protobuf wire format).
5402
+ * @return {!Uint8Array}
5403
+ */
5404
+ proto.wechaty.puppet.RoomDismissRequest.prototype.serializeBinary = function() {
5405
+ var writer = new jspb.BinaryWriter();
5406
+ proto.wechaty.puppet.RoomDismissRequest.serializeBinaryToWriter(this, writer);
5407
+ return writer.getResultBuffer();
5408
+ };
5409
+
5410
+
5411
+ /**
5412
+ * Serializes the given message to binary data (in protobuf wire
5413
+ * format), writing to the given BinaryWriter.
5414
+ * @param {!proto.wechaty.puppet.RoomDismissRequest} message
5415
+ * @param {!jspb.BinaryWriter} writer
5416
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5417
+ */
5418
+ proto.wechaty.puppet.RoomDismissRequest.serializeBinaryToWriter = function(message, writer) {
5419
+ var f = undefined;
5420
+ f = message.getId();
5421
+ if (f.length > 0) {
5422
+ writer.writeString(
5423
+ 1,
5424
+ f
5425
+ );
5426
+ }
5427
+ };
5428
+
5429
+
5430
+ /**
5431
+ * optional string id = 1;
5432
+ * @return {string}
5433
+ */
5434
+ proto.wechaty.puppet.RoomDismissRequest.prototype.getId = function() {
5435
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
5436
+ };
5437
+
5438
+
5439
+ /**
5440
+ * @param {string} value
5441
+ * @return {!proto.wechaty.puppet.RoomDismissRequest} returns this
5442
+ */
5443
+ proto.wechaty.puppet.RoomDismissRequest.prototype.setId = function(value) {
5444
+ return jspb.Message.setProto3StringField(this, 1, value);
5445
+ };
5446
+
5447
+
5448
+
5449
+
5450
+
5451
+ if (jspb.Message.GENERATE_TO_OBJECT) {
5452
+ /**
5453
+ * Creates an object representation of this proto.
5454
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
5455
+ * Optional fields that are not set will be set to undefined.
5456
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
5457
+ * For the list of reserved names please see:
5458
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
5459
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
5460
+ * JSPB instance for transitional soy proto support:
5461
+ * http://goto/soy-param-migration
5462
+ * @return {!Object}
5463
+ */
5464
+ proto.wechaty.puppet.RoomDismissResponse.prototype.toObject = function(opt_includeInstance) {
5465
+ return proto.wechaty.puppet.RoomDismissResponse.toObject(opt_includeInstance, this);
5466
+ };
5467
+
5468
+
5469
+ /**
5470
+ * Static version of the {@see toObject} method.
5471
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
5472
+ * the JSPB instance for transitional soy proto support:
5473
+ * http://goto/soy-param-migration
5474
+ * @param {!proto.wechaty.puppet.RoomDismissResponse} msg The msg instance to transform.
5475
+ * @return {!Object}
5476
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5477
+ */
5478
+ proto.wechaty.puppet.RoomDismissResponse.toObject = function(includeInstance, msg) {
5479
+ var f, obj = {
5480
+
5481
+ };
5482
+
5483
+ if (includeInstance) {
5484
+ obj.$jspbMessageInstance = msg;
5485
+ }
5486
+ return obj;
5487
+ };
5488
+ }
5489
+
5490
+
5491
+ /**
5492
+ * Deserializes binary data (in protobuf wire format).
5493
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
5494
+ * @return {!proto.wechaty.puppet.RoomDismissResponse}
5495
+ */
5496
+ proto.wechaty.puppet.RoomDismissResponse.deserializeBinary = function(bytes) {
5497
+ var reader = new jspb.BinaryReader(bytes);
5498
+ var msg = new proto.wechaty.puppet.RoomDismissResponse;
5499
+ return proto.wechaty.puppet.RoomDismissResponse.deserializeBinaryFromReader(msg, reader);
5500
+ };
5501
+
5502
+
5503
+ /**
5504
+ * Deserializes binary data (in protobuf wire format) from the
5505
+ * given reader into the given message object.
5506
+ * @param {!proto.wechaty.puppet.RoomDismissResponse} msg The message object to deserialize into.
5507
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
5508
+ * @return {!proto.wechaty.puppet.RoomDismissResponse}
5509
+ */
5510
+ proto.wechaty.puppet.RoomDismissResponse.deserializeBinaryFromReader = function(msg, reader) {
5511
+ while (reader.nextField()) {
5512
+ if (reader.isEndGroup()) {
5513
+ break;
5514
+ }
5515
+ var field = reader.getFieldNumber();
5516
+ switch (field) {
5517
+ default:
5518
+ reader.skipField();
5519
+ break;
5520
+ }
5521
+ }
5522
+ return msg;
5523
+ };
5524
+
5525
+
5526
+ /**
5527
+ * Serializes the message to binary data (in protobuf wire format).
5528
+ * @return {!Uint8Array}
5529
+ */
5530
+ proto.wechaty.puppet.RoomDismissResponse.prototype.serializeBinary = function() {
5531
+ var writer = new jspb.BinaryWriter();
5532
+ proto.wechaty.puppet.RoomDismissResponse.serializeBinaryToWriter(this, writer);
5533
+ return writer.getResultBuffer();
5534
+ };
5535
+
5536
+
5537
+ /**
5538
+ * Serializes the given message to binary data (in protobuf wire
5539
+ * format), writing to the given BinaryWriter.
5540
+ * @param {!proto.wechaty.puppet.RoomDismissResponse} message
5541
+ * @param {!jspb.BinaryWriter} writer
5542
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5543
+ */
5544
+ proto.wechaty.puppet.RoomDismissResponse.serializeBinaryToWriter = function(message, writer) {
5545
+ var f = undefined;
5546
+ };
5547
+
5548
+
5274
5549
  goog.object.extend(exports, proto.wechaty.puppet);
@@ -9,7 +9,7 @@ info:
9
9
 
10
10
  Wechaty Puppet Service is the RESTful API for Wechaty API, which is build on
11
11
  top of the Wechaty Puppet Abstraction and the gRPC proto definition.
12
- version: 1.0.73
12
+ version: 1.0.74
13
13
  contact:
14
14
  name: Wechaty
15
15
  url: https://github.com/wechaty/openapi
@@ -1683,6 +1683,25 @@ paths:
1683
1683
  $ref: '#/definitions/puppetRoomCreateRequest'
1684
1684
  tags:
1685
1685
  - Puppet
1686
+ /rooms/{id_1}:
1687
+ delete:
1688
+ operationId: Puppet_RoomDismiss
1689
+ responses:
1690
+ '200':
1691
+ description: A successful response.
1692
+ schema:
1693
+ $ref: '#/definitions/puppetRoomDismissResponse'
1694
+ default:
1695
+ description: An unexpected error response.
1696
+ schema:
1697
+ $ref: '#/definitions/rpcStatus'
1698
+ parameters:
1699
+ - name: id_1
1700
+ in: path
1701
+ required: true
1702
+ type: string
1703
+ tags:
1704
+ - Puppet
1686
1705
  /rooms/{id}:
1687
1706
  get:
1688
1707
  summary: '*'
@@ -3738,6 +3757,8 @@ definitions:
3738
3757
  type: string
3739
3758
  puppetRoomDelResponse:
3740
3759
  type: object
3760
+ puppetRoomDismissResponse:
3761
+ type: object
3741
3762
  puppetRoomInvitationAcceptResponse:
3742
3763
  type: object
3743
3764
  puppetRoomInvitationPayloadResponse:
@@ -3,7 +3,7 @@
3
3
  "info": {
4
4
  "title": "Wechaty Puppet Service OpenAPI Specification",
5
5
  "description": "Wechaty is a Conversational RPA SDK for chatbot makers. With only 6 lines of code, you can create a bot on the most popular IMs like WeChat, Whatsapp, WeCom, Gitter, etc.\n\nWechaty Puppet Service is the RESTful API for Wechaty API, which is build on top of the Wechaty Puppet Abstraction and the gRPC proto definition.",
6
- "version": "1.0.73",
6
+ "version": "1.0.74",
7
7
  "contact": {
8
8
  "name": "Wechaty",
9
9
  "url": "https://github.com/wechaty/openapi",
@@ -2495,6 +2495,36 @@
2495
2495
  ]
2496
2496
  }
2497
2497
  },
2498
+ "/rooms/{id_1}": {
2499
+ "delete": {
2500
+ "operationId": "Puppet_RoomDismiss",
2501
+ "responses": {
2502
+ "200": {
2503
+ "description": "A successful response.",
2504
+ "schema": {
2505
+ "$ref": "#/definitions/puppetRoomDismissResponse"
2506
+ }
2507
+ },
2508
+ "default": {
2509
+ "description": "An unexpected error response.",
2510
+ "schema": {
2511
+ "$ref": "#/definitions/rpcStatus"
2512
+ }
2513
+ }
2514
+ },
2515
+ "parameters": [
2516
+ {
2517
+ "name": "id_1",
2518
+ "in": "path",
2519
+ "required": true,
2520
+ "type": "string"
2521
+ }
2522
+ ],
2523
+ "tags": [
2524
+ "Puppet"
2525
+ ]
2526
+ }
2527
+ },
2498
2528
  "/rooms/{id}": {
2499
2529
  "get": {
2500
2530
  "summary": "*",
@@ -5296,6 +5326,9 @@
5296
5326
  "puppetRoomDelResponse": {
5297
5327
  "type": "object"
5298
5328
  },
5329
+ "puppetRoomDismissResponse": {
5330
+ "type": "object"
5331
+ },
5299
5332
  "puppetRoomInvitationAcceptResponse": {
5300
5333
  "type": "object"
5301
5334
  },
@@ -95,6 +95,7 @@ interface IPuppetService extends grpc.ServiceDefinition<grpc.UntypedServiceImple
95
95
  roomPermission: IPuppetService_IRoomPermission;
96
96
  roomAddAdmins: IPuppetService_IRoomAddAdmins;
97
97
  roomDelAdmins: IPuppetService_IRoomDelAdmins;
98
+ roomDismiss: IPuppetService_IRoomDismiss;
98
99
  roomMemberPayload: IPuppetService_IRoomMemberPayload;
99
100
  roomMemberList: IPuppetService_IRoomMemberList;
100
101
  roomInvitationPayload: IPuppetService_IRoomInvitationPayload;
@@ -764,6 +765,15 @@ interface IPuppetService_IRoomDelAdmins extends grpc.MethodDefinition<wechaty_pu
764
765
  responseSerialize: grpc.serialize<wechaty_puppet_room_pb.RoomAdminsResponse>;
765
766
  responseDeserialize: grpc.deserialize<wechaty_puppet_room_pb.RoomAdminsResponse>;
766
767
  }
768
+ interface IPuppetService_IRoomDismiss extends grpc.MethodDefinition<wechaty_puppet_room_pb.RoomDismissRequest, wechaty_puppet_room_pb.RoomDismissResponse> {
769
+ path: "/wechaty.Puppet/RoomDismiss";
770
+ requestStream: false;
771
+ responseStream: false;
772
+ requestSerialize: grpc.serialize<wechaty_puppet_room_pb.RoomDismissRequest>;
773
+ requestDeserialize: grpc.deserialize<wechaty_puppet_room_pb.RoomDismissRequest>;
774
+ responseSerialize: grpc.serialize<wechaty_puppet_room_pb.RoomDismissResponse>;
775
+ responseDeserialize: grpc.deserialize<wechaty_puppet_room_pb.RoomDismissResponse>;
776
+ }
767
777
  interface IPuppetService_IRoomMemberPayload extends grpc.MethodDefinition<wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, wechaty_puppet_room_member_pb.RoomMemberPayloadResponse> {
768
778
  path: "/wechaty.Puppet/RoomMemberPayload";
769
779
  requestStream: false;
@@ -1091,6 +1101,7 @@ export interface IPuppetServer extends grpc.UntypedServiceImplementation {
1091
1101
  roomPermission: grpc.handleUnaryCall<wechaty_puppet_room_pb.RoomPermissionRequest, wechaty_puppet_room_pb.RoomPermissionResponse>;
1092
1102
  roomAddAdmins: grpc.handleUnaryCall<wechaty_puppet_room_pb.RoomAdminsRequest, wechaty_puppet_room_pb.RoomAdminsResponse>;
1093
1103
  roomDelAdmins: grpc.handleUnaryCall<wechaty_puppet_room_pb.RoomAdminsRequest, wechaty_puppet_room_pb.RoomAdminsResponse>;
1104
+ roomDismiss: grpc.handleUnaryCall<wechaty_puppet_room_pb.RoomDismissRequest, wechaty_puppet_room_pb.RoomDismissResponse>;
1094
1105
  roomMemberPayload: grpc.handleUnaryCall<wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, wechaty_puppet_room_member_pb.RoomMemberPayloadResponse>;
1095
1106
  roomMemberList: grpc.handleUnaryCall<wechaty_puppet_room_member_pb.RoomMemberListRequest, wechaty_puppet_room_member_pb.RoomMemberListResponse>;
1096
1107
  roomInvitationPayload: grpc.handleUnaryCall<wechaty_puppet_room_invitation_pb.RoomInvitationPayloadRequest, wechaty_puppet_room_invitation_pb.RoomInvitationPayloadResponse>;
@@ -1334,6 +1345,9 @@ export interface IPuppetClient {
1334
1345
  roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1335
1346
  roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1336
1347
  roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1348
+ roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1349
+ roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1350
+ roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1337
1351
  roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
1338
1352
  roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
1339
1353
  roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
@@ -1634,6 +1648,9 @@ export class PuppetClient extends grpc.Client implements IPuppetClient {
1634
1648
  public roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1635
1649
  public roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1636
1650
  public roomDelAdmins(request: wechaty_puppet_room_pb.RoomAdminsRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomAdminsResponse) => void): grpc.ClientUnaryCall;
1651
+ public roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1652
+ public roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1653
+ public roomDismiss(request: wechaty_puppet_room_pb.RoomDismissRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_pb.RoomDismissResponse) => void): grpc.ClientUnaryCall;
1637
1654
  public roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
1638
1655
  public roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
1639
1656
  public roomMemberPayload(request: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: wechaty_puppet_room_member_pb.RoomMemberPayloadResponse) => void): grpc.ClientUnaryCall;
@@ -1517,6 +1517,28 @@ function deserialize_wechaty_puppet_RoomDelResponse(buffer_arg) {
1517
1517
  return wechaty_puppet_room_pb.RoomDelResponse.deserializeBinary(new Uint8Array(buffer_arg));
1518
1518
  }
1519
1519
 
1520
+ function serialize_wechaty_puppet_RoomDismissRequest(arg) {
1521
+ if (!(arg instanceof wechaty_puppet_room_pb.RoomDismissRequest)) {
1522
+ throw new Error('Expected argument of type wechaty.puppet.RoomDismissRequest');
1523
+ }
1524
+ return Buffer.from(arg.serializeBinary());
1525
+ }
1526
+
1527
+ function deserialize_wechaty_puppet_RoomDismissRequest(buffer_arg) {
1528
+ return wechaty_puppet_room_pb.RoomDismissRequest.deserializeBinary(new Uint8Array(buffer_arg));
1529
+ }
1530
+
1531
+ function serialize_wechaty_puppet_RoomDismissResponse(arg) {
1532
+ if (!(arg instanceof wechaty_puppet_room_pb.RoomDismissResponse)) {
1533
+ throw new Error('Expected argument of type wechaty.puppet.RoomDismissResponse');
1534
+ }
1535
+ return Buffer.from(arg.serializeBinary());
1536
+ }
1537
+
1538
+ function deserialize_wechaty_puppet_RoomDismissResponse(buffer_arg) {
1539
+ return wechaty_puppet_room_pb.RoomDismissResponse.deserializeBinary(new Uint8Array(buffer_arg));
1540
+ }
1541
+
1520
1542
  function serialize_wechaty_puppet_RoomInvitationAcceptRequest(arg) {
1521
1543
  if (!(arg instanceof wechaty_puppet_room$invitation_pb.RoomInvitationAcceptRequest)) {
1522
1544
  throw new Error('Expected argument of type wechaty.puppet.RoomInvitationAcceptRequest');
@@ -2976,6 +2998,17 @@ roomPayload: {
2976
2998
  responseSerialize: serialize_wechaty_puppet_RoomAdminsResponse,
2977
2999
  responseDeserialize: deserialize_wechaty_puppet_RoomAdminsResponse,
2978
3000
  },
3001
+ roomDismiss: {
3002
+ path: '/wechaty.Puppet/RoomDismiss',
3003
+ requestStream: false,
3004
+ responseStream: false,
3005
+ requestType: wechaty_puppet_room_pb.RoomDismissRequest,
3006
+ responseType: wechaty_puppet_room_pb.RoomDismissResponse,
3007
+ requestSerialize: serialize_wechaty_puppet_RoomDismissRequest,
3008
+ requestDeserialize: deserialize_wechaty_puppet_RoomDismissRequest,
3009
+ responseSerialize: serialize_wechaty_puppet_RoomDismissResponse,
3010
+ responseDeserialize: deserialize_wechaty_puppet_RoomDismissResponse,
3011
+ },
2979
3012
  // *
2980
3013
  //
2981
3014
  // Room Member
@@ -658,6 +658,15 @@ type PuppetRoomDelAdmins = {
658
658
  readonly responseType: typeof wechaty_puppet_room_pb.RoomAdminsResponse;
659
659
  };
660
660
 
661
+ type PuppetRoomDismiss = {
662
+ readonly methodName: string;
663
+ readonly service: typeof Puppet;
664
+ readonly requestStream: false;
665
+ readonly responseStream: false;
666
+ readonly requestType: typeof wechaty_puppet_room_pb.RoomDismissRequest;
667
+ readonly responseType: typeof wechaty_puppet_room_pb.RoomDismissResponse;
668
+ };
669
+
661
670
  type PuppetRoomMemberPayload = {
662
671
  readonly methodName: string;
663
672
  readonly service: typeof Puppet;
@@ -983,6 +992,7 @@ export class Puppet {
983
992
  static readonly RoomPermission: PuppetRoomPermission;
984
993
  static readonly RoomAddAdmins: PuppetRoomAddAdmins;
985
994
  static readonly RoomDelAdmins: PuppetRoomDelAdmins;
995
+ static readonly RoomDismiss: PuppetRoomDismiss;
986
996
  static readonly RoomMemberPayload: PuppetRoomMemberPayload;
987
997
  static readonly RoomMemberList: PuppetRoomMemberList;
988
998
  static readonly RoomInvitationPayload: PuppetRoomInvitationPayload;
@@ -1676,6 +1686,15 @@ export class PuppetClient {
1676
1686
  requestMessage: wechaty_puppet_room_pb.RoomAdminsRequest,
1677
1687
  callback: (error: ServiceError|null, responseMessage: wechaty_puppet_room_pb.RoomAdminsResponse|null) => void
1678
1688
  ): UnaryResponse;
1689
+ roomDismiss(
1690
+ requestMessage: wechaty_puppet_room_pb.RoomDismissRequest,
1691
+ metadata: grpc.Metadata,
1692
+ callback: (error: ServiceError|null, responseMessage: wechaty_puppet_room_pb.RoomDismissResponse|null) => void
1693
+ ): UnaryResponse;
1694
+ roomDismiss(
1695
+ requestMessage: wechaty_puppet_room_pb.RoomDismissRequest,
1696
+ callback: (error: ServiceError|null, responseMessage: wechaty_puppet_room_pb.RoomDismissResponse|null) => void
1697
+ ): UnaryResponse;
1679
1698
  roomMemberPayload(
1680
1699
  requestMessage: wechaty_puppet_room_member_pb.RoomMemberPayloadRequest,
1681
1700
  metadata: grpc.Metadata,
@@ -664,6 +664,15 @@ Puppet.RoomDelAdmins = {
664
664
  responseType: wechaty_puppet_room_pb.RoomAdminsResponse
665
665
  };
666
666
 
667
+ Puppet.RoomDismiss = {
668
+ methodName: "RoomDismiss",
669
+ service: Puppet,
670
+ requestStream: false,
671
+ responseStream: false,
672
+ requestType: wechaty_puppet_room_pb.RoomDismissRequest,
673
+ responseType: wechaty_puppet_room_pb.RoomDismissResponse
674
+ };
675
+
667
676
  Puppet.RoomMemberPayload = {
668
677
  methodName: "RoomMemberPayload",
669
678
  service: Puppet,
@@ -3132,6 +3141,37 @@ PuppetClient.prototype.roomDelAdmins = function roomDelAdmins(requestMessage, me
3132
3141
  };
3133
3142
  };
3134
3143
 
3144
+ PuppetClient.prototype.roomDismiss = function roomDismiss(requestMessage, metadata, callback) {
3145
+ if (arguments.length === 2) {
3146
+ callback = arguments[1];
3147
+ }
3148
+ var client = grpc.unary(Puppet.RoomDismiss, {
3149
+ request: requestMessage,
3150
+ host: this.serviceHost,
3151
+ metadata: metadata,
3152
+ transport: this.options.transport,
3153
+ debug: this.options.debug,
3154
+ onEnd: function (response) {
3155
+ if (callback) {
3156
+ if (response.status !== grpc.Code.OK) {
3157
+ var err = new Error(response.statusMessage);
3158
+ err.code = response.status;
3159
+ err.metadata = response.trailers;
3160
+ callback(err, null);
3161
+ } else {
3162
+ callback(null, response.message);
3163
+ }
3164
+ }
3165
+ }
3166
+ });
3167
+ return {
3168
+ cancel: function () {
3169
+ callback = null;
3170
+ client.close();
3171
+ }
3172
+ };
3173
+ };
3174
+
3135
3175
  PuppetClient.prototype.roomMemberPayload = function roomMemberPayload(requestMessage, metadata, callback) {
3136
3176
  if (arguments.length === 2) {
3137
3177
  callback = arguments[1];
@@ -126,4 +126,10 @@ message RoomAdminsRequest {
126
126
  repeated string contact_ids = 2;
127
127
  }
128
128
 
129
- message RoomAdminsResponse {}
129
+ message RoomAdminsResponse {}
130
+
131
+ message RoomDismissRequest {
132
+ string id = 1;
133
+ }
134
+
135
+ message RoomDismissResponse {}
@@ -556,6 +556,11 @@ service Puppet {
556
556
  };
557
557
  }
558
558
 
559
+ rpc RoomDismiss (puppet.RoomDismissRequest) returns (puppet.RoomDismissResponse) {
560
+ option (google.api.http) = {
561
+ delete: "/rooms/{id}"
562
+ };
563
+ }
559
564
  /**
560
565
  *
561
566
  * Room Member
@@ -1 +1 @@
1
- {"version":3,"file":"package-json.d.ts","sourceRoot":"","sources":["../../../src/package-json.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAC5C,eAAO,MAAM,WAAW,EAAE,WA+FlB,CAAA"}
1
+ {"version":3,"file":"package-json.d.ts","sourceRoot":"","sources":["../../../src/package-json.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAC5C,eAAO,MAAM,WAAW,EAAE,WAgGlB,CAAA"}
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.packageJson = void 0;
4
4
  exports.packageJson = {
5
5
  "name": "@juzi/wechaty-grpc",
6
- "version": "1.0.73",
6
+ "version": "1.0.74",
7
7
  "description": "gRPC for Wechaty",
8
8
  "type": "module",
9
9
  "exports": {
@@ -79,6 +79,7 @@ exports.packageJson = {
79
79
  "npm-run-all": "^4.1.5",
80
80
  "request": "^2.88.2",
81
81
  "shx": "^0.3.3",
82
+ "ts-node": "10.9.1",
82
83
  "ts-protoc-gen": "^0.15.0",
83
84
  "tstest": "^0.7.3",
84
85
  "typescript": "^4.7.3"