https://github.com/redislabs/rediscloud-go-api
Go SDK for Redis Enterprise Cloud Pro
https://github.com/redislabs/rediscloud-go-api
Last synced: about 1 year ago
JSON representation
Go SDK for Redis Enterprise Cloud Pro
- Host: GitHub
- URL: https://github.com/redislabs/rediscloud-go-api
- Owner: RedisLabs
- License: apache-2.0
- Created: 2020-10-28T12:49:33.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-04-22T08:05:09.000Z (about 1 year ago)
- Last Synced: 2025-04-22T09:24:17.102Z (about 1 year ago)
- Language: Go
- Homepage:
- Size: 374 KB
- Stars: 4
- Watchers: 8
- Forks: 3
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
- Code of conduct: .github/CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# rediscloud-go-api
This repository is a Go SDK for the [Redis Cloud REST API](https://docs.redislabs.com/latest/rc/api/).
## Getting Started
### Installing
You can use this module by using `go get` to add it to either your `GOPATH` workspace or
the project's dependencies.
```shell script
go get github.com/RedisLabs/rediscloud-go-api
```
### Example
This is an example of using the SDK
```go
package main
import (
"context"
"fmt"
rediscloud_api "github.com/RedisLabs/rediscloud-go-api"
"github.com/RedisLabs/rediscloud-go-api/service/subscriptions"
)
func main() {
// The client will use the credentials from `REDISCLOUD_ACCESS_KEY` and `REDISCLOUD_SECRET_KEY` by default
client, err := rediscloud_api.NewClient()
if err != nil {
panic(err)
}
id, err := client.Subscription.Create(context.TODO(), subscriptions.CreateSubscription{
// ...
})
if err != nil {
panic(err)
}
fmt.Printf("Created subscription: %d", id)
}
```