curl --request POST \
--url https://app.trustivan.com/api/v1/billing/webhookimport requests
url = "https://app.trustivan.com/api/v1/billing/webhook"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://app.trustivan.com/api/v1/billing/webhook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/billing/webhook"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Payment provider webhook receiver
Unauthenticated by necessity (a payment provider has no session and no API key) and safe only because the adapter verifies the provider’s signature before anything is believed. A deployment with no signing secret rejects every payload; the manual provider that ships by default rejects all of them, because an endpoint that parses unauthenticated payloads into subscription changes is a way to grant yourself an Enterprise plan.
Delivery is at-least-once, so an event is applied exactly once and a
retry is answered duplicate. unmatched is also a 200: the event is
verified and well-formed, TRUSTIVAN simply has no tenant for it, and
retrying would produce the same answer forever.
curl --request POST \
--url https://app.trustivan.com/api/v1/billing/webhookimport requests
url = "https://app.trustivan.com/api/v1/billing/webhook"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://app.trustivan.com/api/v1/billing/webhook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trustivan.com/api/v1/billing/webhook"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Response
Settled. Body carries the outcome: applied, duplicate, ignored or unmatched.