Skip to content

Commit

Permalink
update douyin miniapp openapi
Browse files Browse the repository at this point in the history
  • Loading branch information
xnzone committed Jul 11, 2023
0 parents commit 8bf8589
Show file tree
Hide file tree
Showing 19 changed files with 4,175 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.vscode
.idea
.DS_Store
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# dyma

微信小程序接口,使用protobuf生成的

生成工具是[protoc-gen-go_api](https://github.com/dev-openapi/protoc-gen-go_api)


## 如何使用

在自己的项目中添加此包 github.com/dev-openapi/douyin-miniapp

初始化包 `dyLoginService := miniapp.NewLoginService()`

然后根据自己的需要,用`dyLoginService`去调用想用的接口

## 如何添加新接口

首先要安装protoc,protoc-gen-go和protoc-gen-go_api。前面两个如何安装,请参考网上教程搜索

```shell
go install github.com/dev-openapi/protoc-gen-go_api@latest
```

下载[protocol](https://github.com/dev-openapi/protocol)仓库

下载本项目,与protocol是同一级目录

然后根据文档在protocol项目中写好proto文件,再执行make gen-dyma会自动生成到本项目目录,最后提交两个项目即可
80 changes: 80 additions & 0 deletions credential.api.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

171 changes: 171 additions & 0 deletions credential.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

95 changes: 95 additions & 0 deletions customer.api.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 8bf8589

Please sign in to comment.