-
Notifications
You must be signed in to change notification settings - Fork 248
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add decode utils for response body v2 of app store #156
Comments
@takecy I was trying to figure this out, here's a gist of where I am: https://gist.github.com/thilonel/7b7285b9bad211cc88a1b8ccfdbe9e0e What do you think? |
Thanks! Looks like a good example 👀 I have used this package which is very similar. This package made by squre also seems to be used a lot. |
@takecy The about section of https://github.com/dgrijalva/jwt-go links to golang-jwt, which I've used. It's practically the same, just got cloned to a community maintained repo. I also checked go-jose, but ended up with this. 🤷♂️ Will you integrate this functionality into go-iap or do you want me to fork and PR? I'd say with the help of the gist, you're gonna be way faster by yourself :) No forth and back on anything :) |
any update bro? |
@RealLau , I try to add the method |
@richzw hi, thx for your method. But could you give me an example about how to decode |
Here is one sample code to use tokenStr := SignedRenewalInfo // or SignedTransactionInfo
if err := c.ParseNotificationV2(tokenStr, result); err != nil {
}
if !result.Valid {
}
claims := result.Claims.(jwt.MapClaims)
for key, val := range claims {
fmt.Printf("Key: %v, value: %v\n", key, val) // key value of SignedRenewalInfo
} |
The text was updated successfully, but these errors were encountered: