Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/iktakahiro/revcatgo
A helper library for integrating server-side apps with the RevenueCat webhook service.
https://github.com/iktakahiro/revcatgo
go golang revenuecat
Last synced: about 2 months ago
JSON representation
A helper library for integrating server-side apps with the RevenueCat webhook service.
- Host: GitHub
- URL: https://github.com/iktakahiro/revcatgo
- Owner: iktakahiro
- License: mit
- Created: 2020-11-16T01:50:06.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2023-04-23T06:40:47.000Z (over 1 year ago)
- Last Synced: 2024-06-20T02:11:15.260Z (7 months ago)
- Topics: go, golang, revenuecat
- Language: Go
- Homepage: https://pkg.go.dev/github.com/iktakahiro/revcatgo
- Size: 48.8 KB
- Stars: 10
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# revcatgo
[![GoDev][godev-image]][godev-url]
![Run test](https://github.com/iktakahiro/revcatgo/workflows/Run%20test/badge.svg?branch=main)
A helper library for integrating server-side apps with the [RevenueCat](https://www.revenuecat.com) webhook service.
```bash
go get "github.com/iktakahiro/[email protected]"
```## Receiving webhooks
```go
func bind(w http.ResponseWriter, r *http.Request) error {
var webhookEvent revcatgo.WebhookEventerr := json.NewDecoder(r.Body).Decode(&webhookEvent)
if err != nil {
return err
}
fmt.Println(webhookEvent.Type) // e.g. "INITIAL_PURCHASE"
return nil
}
```## RevenueCat webhooks specifications
Refer to the official documentation:
*
[godev-image]: https://pkg.go.dev/badge/github.com/iktakahiro/revcatgo
[godev-url]: https://pkg.go.dev/github.com/iktakahiro/revcatgo