Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: ✨ add tag modify api #57

Merged
merged 2 commits into from
Feb 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@juzi/wechaty-grpc",
"version": "1.0.76",
"version": "1.0.77",
"description": "gRPC for Wechaty",
"type": "module",
"exports": {
Expand Down
7 changes: 7 additions & 0 deletions proto/wechaty/puppet.proto
Original file line number Diff line number Diff line change
Expand Up @@ -649,6 +649,13 @@ service Puppet {
};
}

rpc tagTagModify (puppet.TagTagModifyRequest) returns (puppet.TagTagModifyResponse) {
option (google.api.http) = {
post: "/tag/modify"
body: "*"
};
}

rpc TagPayload (puppet.TagPayloadRequest) returns (puppet.TagPayloadResponse) {
option (google.api.http) = {
post: "/tag/payload"
Expand Down
10 changes: 10 additions & 0 deletions proto/wechaty/puppet/tag.proto
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,16 @@ message TagTagDeleteRequest {
message TagTagDeleteResponse {
}

message TagTagModifyRequest {
string tag_id = 1;
string tag_new_name = 2;
}

message TagTagModifyResponse {
string tag_id = 1;
string tag_name = 2;
}

message TagGroupListRequest {
}

Expand Down
8 changes: 7 additions & 1 deletion tests/puppet-server-impl.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable sort-keys */
import type {
puppet,
} from '../src/mod.js'
} from '../src/mod.js'

type IPuppetServer = puppet.IPuppetServer

Expand Down Expand Up @@ -478,6 +478,12 @@ export const puppetServerImpl: IPuppetServer = {
throw new Error('not implemented.')
},

tagTagModify: (call, callback) => {
void call
void callback
throw new Error('not implemented.')
},

tagGroupList: (call, callback) => {
void call
void callback
Expand Down
Loading