2021-07-26 17:54:24 +00:00
|
|
|
package api
|
|
|
|
|
|
|
|
import (
|
|
|
|
"net/http"
|
|
|
|
|
|
|
|
"github.com/julienschmidt/httprouter"
|
|
|
|
)
|
|
|
|
|
2021-07-27 19:28:10 +00:00
|
|
|
const receiptResponse = `{
|
|
|
|
"products": [
|
|
|
|
{
|
|
|
|
"name": "ultra",
|
|
|
|
"status": "SANBOX",
|
|
|
|
"subscription_type": "SANDBOX"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "pro",
|
|
|
|
"status": "SANDBOX"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "community_icons",
|
|
|
|
"status": "SANDBOX"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "spca",
|
|
|
|
"status": "SANDBOX"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}`
|
|
|
|
|
2021-07-26 17:54:24 +00:00
|
|
|
func (a *api) checkReceiptHandler(w http.ResponseWriter, r *http.Request, ps httprouter.Params) {
|
2021-07-27 19:28:10 +00:00
|
|
|
w.Write([]byte(receiptResponse))
|
2021-07-26 17:54:24 +00:00
|
|
|
w.WriteHeader(http.StatusOK)
|
|
|
|
}
|