1
0
mirror of https://github.com/badkaktus/gorocket.git synced 2025-03-03 14:52:40 +02:00

add changelog, update readme

This commit is contained in:
Алексей Волегов 2022-09-19 15:25:50 +03:00
parent 84215f0567
commit 6c5bc5cd30
2 changed files with 17 additions and 0 deletions

7
CHANGELOG.md Normal file
View File

@ -0,0 +1,7 @@
# CHANGELOG
## [v0.0.1] - 2022-09-20
- Add semver version `v0.0.1` (see semver.org)
- Add `NewWithOptions(url string, opts ...Option)` for custom client settings
- Rollback `go.mod` package name to `github.com/badkaktus/gorocket`

View File

@ -31,6 +31,16 @@ if err != nil {
fmt.Printf("I'm %s", lg.Data.Me.Username)
```
or
```go
client := gorocket.NewWithOptions("https://your-rocket-chat.com",
gorocket.WithUserID("my-user-id"),
gorocket.WithToken("my-bot-token"),
gorocket.WithTimeout(1 * time.Second),
)
```
## Manage user
```go
str := gorocket.NewUser{