When building a product or service that requires your users to pay for something, there are many ways that things can go wrong, such as delayed payments, fraud, or other such issues.
Thus, it is crucial to track these events in real-time and alert you and your team in the event of a problem.
Palzin Track lets you track payment events such as User Subscription, User Purchase, User Cancellation, and User Redemption directly from your Go application.
Using Go with Native
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.palzin.live/v1/log"
method := "POST"
payload := strings.NewReader(`{"project":"my-project","channel":"payments","event":"Successful Payment","description":"[email protected] - ($19.99)","icon":"💸","notify":true}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Authorization", "Bearer YOUR_API_TOKEN")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
Connect Palzin Track to your Go code to easily track and keep a record of your product's payment events. With Palzin Track, you can create simple charts and journeys to help you better understand your product. Palzin Track also allows you to receive real-time push notifications on your desktop and mobile devices whenever a new payment event occurs.
Palzin Track reveals the human stories behind your data. Make user-centric decisions that drive growth.