Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/traPtitech/go-traq
Go client library for the traQ API.
https://github.com/traPtitech/go-traq
traq
Last synced: 3 months ago
JSON representation
Go client library for the traQ API.
- Host: GitHub
- URL: https://github.com/traPtitech/go-traq
- Owner: traPtitech
- License: mit
- Created: 2019-07-03T06:18:31.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-07-25T07:14:55.000Z (3 months ago)
- Last Synced: 2024-07-25T08:34:11.462Z (3 months ago)
- Topics: traq
- Language: Shell
- Homepage:
- Size: 769 KB
- Stars: 3
- Watchers: 12
- Forks: 2
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go-traq
[![Go Reference][godoc-badge]][godoc] [![CI][ci-badge]][ci] [![Update][update-badge]][update]
[godoc]: https://pkg.go.dev/github.com/traPtitech/go-traq
[godoc-badge]: https://pkg.go.dev/badge/github.com/traPtitech/go-traq.svg
[ci]: https://github.com/traPtitech/go-traq/actions/workflows/main.yaml
[ci-badge]: https://github.com/traPtitech/go-traq/actions/workflows/main.yaml/badge.svg
[update]: https://github.com/traPtitech/go-traq/actions/workflows/release.yaml
[update-badge]: https://github.com/traPtitech/go-traq/actions/workflows/release.yaml/badge.svgA client library for the traQ API.
This package is updated automatically.
## How to use
See [client.md](./client.md) and [docs/](./docs/) for more information.
```shell
go get github.com/traPtitech/go-traq
``````go
package mainimport (
"context"
"fmt"traq "github.com/traPtitech/go-traq"
)const TOKEN = "/* your token */"
func main() {
client := traq.NewAPIClient(traq.NewConfiguration())
auth := context.WithValue(context.Background(), traq.ContextAccessToken, TOKEN)v, _, _ := client.ChannelApi.
GetChannels(auth).
IncludeDm(true).
Execute()
fmt.Printf("%#v", v)
}
```