Billing
GET
https://referally.15.204.158.166.sslip.io /t/{orgToken}/mobile/resolve GET /t/{orgToken}/mobile/resolve
Parameters
orgTokenstringpathrequiredCode samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/resolve"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"matched": true,
"clickId": "string",
"code": "string",
"destination": "string"
}Schema
matchedbooleanrequiredclickIdstringcodestringdestinationstringdefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /t/{orgToken}/mobile/install POST /t/{orgToken}/mobile/install
Parameters
orgTokenstringpathrequiredRequest body application/json
programIdstringrequiredcustomerRefstringrequiredclickIdstringdeviceIdstringidempotencyKeystring{
"programId": "string",
"customerRef": "string",
"clickId": "string",
"deviceId": "string",
"idempotencyKey": "string"
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install" \
-H "Content-Type: application/json" \
-d '{"programId":"string","customerRef":"string","clickId":"string","deviceId":"string","idempotencyKey":"string"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"programId":"string","customerRef":"string","clickId":"string","deviceId":"string","idempotencyKey":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install",
headers={
"Content-Type": "application/json",
},
json={"programId": "string", "customerRef": "string", "clickId": "string", "deviceId": "string", "idempotencyKey": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install", strings.NewReader(`{"programId":"string","customerRef":"string","clickId":"string","deviceId":"string","idempotencyKey":"string"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"programId":"string","customerRef":"string","clickId":"string","deviceId":"string","idempotencyKey":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"programId":"string","customerRef":"string","clickId":"string","deviceId":"string","idempotencyKey":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/install"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"programId\":\"string\",\"customerRef\":\"string\",\"clickId\":\"string\",\"deviceId\":\"string\",\"idempotencyKey\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"attributed": true,
"referralId": "string",
"partnerId": "string"
}Schema
attributedbooleanrequiredreferralIdstringrequiredpartnerIdstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /t/{orgToken}/mobile/event POST /t/{orgToken}/mobile/event
Parameters
orgTokenstringpathrequiredCode samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/t/{orgToken}/mobile/event"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
default Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/mobile/purchases Report a validated in-app purchase or refund (server-side)
Request body application/json
eventIdstringrequiredcustomerRefstringrequiredtypestringamountMinorintegerrequiredcurrencystringproductRefstring{
"eventId": "string",
"customerRef": "string",
"type": "purchase",
"amountMinor": 0,
"currency": "usd",
"productRef": "string"
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/mobile/purchases" \
-H "Content-Type: application/json" \
-d '{"eventId":"string","customerRef":"string","type":"purchase","amountMinor":0,"currency":"usd","productRef":"string"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/mobile/purchases', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"eventId":"string","customerRef":"string","type":"purchase","amountMinor":0,"currency":"usd","productRef":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/mobile/purchases",
headers={
"Content-Type": "application/json",
},
json={"eventId": "string", "customerRef": "string", "type": "purchase", "amountMinor": 0, "currency": "usd", "productRef": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/mobile/purchases", strings.NewReader(`{"eventId":"string","customerRef":"string","type":"purchase","amountMinor":0,"currency":"usd","productRef":"string"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/mobile/purchases');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"eventId":"string","customerRef":"string","type":"purchase","amountMinor":0,"currency":"usd","productRef":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/mobile/purchases')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"eventId":"string","customerRef":"string","type":"purchase","amountMinor":0,"currency":"usd","productRef":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/mobile/purchases"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"eventId\":\"string\",\"customerRef\":\"string\",\"type\":\"purchase\",\"amountMinor\":0,\"currency\":\"usd\",\"productRef\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"conversions": 0,
"linesCreated": 0,
"reversals": 0
}Schema
conversionsintegerrequiredlinesCreatedintegerrequiredreversalsintegerrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
GET
https://referally.15.204.158.166.sslip.io /v1/billing/connections GET /v1/billing/connections
Code samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/v1/billing/connections"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/v1/billing/connections", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 A page of the list. Under referally-version 2026-10-21 the body is the plain array instead.
Example
{
"object": "string",
"data": [
{
"id": "string",
"provider": "string",
"name": "string",
"status": "active",
"createdAt": "2024-01-01T00:00:00Z",
"webhookUrl": "string",
"needsCredentials": true,
"hasCredentials": true,
"rotation": {
"inProgress": true,
"previousSecretExpiresAt": "2024-01-01T00:00:00Z"
}
}
],
"has_more": true,
"next_cursor": "string"
}Schema
objectstringrequireddataBillingConnection[]requiredShow child parameters
idstringrequiredproviderstringrequirednamestringrequiredstatusstringrequiredpaused: its webhook URL refuses events until resumed.
createdAtstringrequiredwebhookUrlstringrequiredneedsCredentialsbooleanrequiredThe provider sends thin webhooks: set API credentials (Recurly, BigCommerce).
hasCredentialsbooleanrequiredrotationobjectrequiredShow child parameters
inProgressbooleanrequiredpreviousSecretExpiresAtstringhas_morebooleanrequiredWhether another page follows; pass next_cursor as starting_after to get it.
next_cursorstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/billing/connections Create a billing connection (webhook secret)
Request body application/json
providerstringrequirednamestringwebhookSecretstring{
"provider": "stripe",
"name": "",
"webhookSecret": "string"
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/billing/connections" \
-H "Content-Type: application/json" \
-d '{"provider":"stripe","name":"","webhookSecret":"string"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"provider":"stripe","name":"","webhookSecret":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections",
headers={
"Content-Type": "application/json",
},
json={"provider": "stripe", "name": "", "webhookSecret": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/billing/connections", strings.NewReader(`{"provider":"stripe","name":"","webhookSecret":"string"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"provider":"stripe","name":"","webhookSecret":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"provider":"stripe","name":"","webhookSecret":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"provider\":\"stripe\",\"name\":\"\",\"webhookSecret\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"webhookSecret": "string",
"webhookUrl": "string"
}Schema
idstringrequiredproviderstringrequiredwebhookSecretstringrequiredReturned only here.
webhookUrlstringrequiredPath to register with the provider.
default Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
PUT
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id}/secret PUT /v1/billing/connections/{id}/secret
Parameters
idstringpathrequiredRequest body application/json
webhookSecretstringrequired{
"webhookSecret": "string"
}Code samples
cURL
curl -X PUT "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret" \
-H "Content-Type: application/json" \
-d '{"webhookSecret":"string"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret', {
method: 'PUT',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"webhookSecret":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"PUT",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret",
headers={
"Content-Type": "application/json",
},
json={"webhookSecret": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("PUT", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret", strings.NewReader(`{"webhookSecret":"string"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"webhookSecret":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret')
req = Net::HTTP::Put.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"webhookSecret":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/secret"))
.header("Content-Type", "application/json")
.method("PUT", BodyPublishers.ofString("{\"webhookSecret\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"ok": true
}Schema
idstringrequiredproviderstringrequiredokbooleanrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
PUT
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id}/credentials PUT /v1/billing/connections/{id}/credentials
Parameters
idstringpathrequiredRequest body application/json
apiKeystringapiTokenstringstoreHashstringregionstring{
"apiKey": "string",
"apiToken": "string",
"storeHash": "string",
"region": "us"
}Code samples
cURL
curl -X PUT "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials" \
-H "Content-Type: application/json" \
-d '{"apiKey":"string","apiToken":"string","storeHash":"string","region":"us"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials', {
method: 'PUT',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"apiKey":"string","apiToken":"string","storeHash":"string","region":"us"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"PUT",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials",
headers={
"Content-Type": "application/json",
},
json={"apiKey": "string", "apiToken": "string", "storeHash": "string", "region": "us"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("PUT", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials", strings.NewReader(`{"apiKey":"string","apiToken":"string","storeHash":"string","region":"us"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"apiKey":"string","apiToken":"string","storeHash":"string","region":"us"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials')
req = Net::HTTP::Put.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"apiKey":"string","apiToken":"string","storeHash":"string","region":"us"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/credentials"))
.header("Content-Type", "application/json")
.method("PUT", BodyPublishers.ofString("{\"apiKey\":\"string\",\"apiToken\":\"string\",\"storeHash\":\"string\",\"region\":\"us\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"ok": true
}Schema
idstringrequiredproviderstringrequiredokbooleanrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
GET
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id} GET /v1/billing/connections/{id}
Parameters
idstringpathrequiredCode samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"name": "string",
"status": "active",
"createdAt": "2024-01-01T00:00:00Z",
"webhookUrl": "string",
"needsCredentials": true,
"hasCredentials": true,
"rotation": {
"inProgress": true,
"previousSecretExpiresAt": "2024-01-01T00:00:00Z"
}
}Schema
idstringrequiredproviderstringrequirednamestringrequiredstatusstringrequiredpaused: its webhook URL refuses events until resumed.
createdAtstringrequiredwebhookUrlstringrequiredneedsCredentialsbooleanrequiredThe provider sends thin webhooks: set API credentials (Recurly, BigCommerce).
hasCredentialsbooleanrequiredrotationobjectrequiredShow child parameters
inProgressbooleanrequiredpreviousSecretExpiresAtstringdefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
DELETE
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id} DELETE /v1/billing/connections/{id}
Parameters
idstringpathrequiredCode samples
cURL
curl -X DELETE "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}', {
method: 'DELETE',
});
const data = await res.json();Python
import requests
res = requests.request(
"DELETE",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'DELETE');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}')
req = Net::HTTP::Delete.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}"))
.method("DELETE", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"ok": true
}Schema
okbooleanrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
PATCH
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id} PATCH /v1/billing/connections/{id}
Parameters
idstringpathrequiredRequest body application/json
statusstringnamestring{
"status": "active",
"name": "string"
}Code samples
cURL
curl -X PATCH "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}" \
-H "Content-Type: application/json" \
-d '{"status":"active","name":"string"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}', {
method: 'PATCH',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"status":"active","name":"string"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"PATCH",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}",
headers={
"Content-Type": "application/json",
},
json={"status": "active", "name": "string"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("PATCH", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}", strings.NewReader(`{"status":"active","name":"string"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PATCH');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"status":"active","name":"string"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}')
req = Net::HTTP::Patch.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"status":"active","name":"string"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}"))
.header("Content-Type", "application/json")
.method("PATCH", BodyPublishers.ofString("{\"status\":\"active\",\"name\":\"string\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"name": "string",
"status": "active",
"createdAt": "2024-01-01T00:00:00Z",
"webhookUrl": "string",
"needsCredentials": true,
"hasCredentials": true,
"rotation": {
"inProgress": true,
"previousSecretExpiresAt": "2024-01-01T00:00:00Z"
}
}Schema
idstringrequiredproviderstringrequirednamestringrequiredstatusstringrequiredpaused: its webhook URL refuses events until resumed.
createdAtstringrequiredwebhookUrlstringrequiredneedsCredentialsbooleanrequiredThe provider sends thin webhooks: set API credentials (Recurly, BigCommerce).
hasCredentialsbooleanrequiredrotationobjectrequiredShow child parameters
inProgressbooleanrequiredpreviousSecretExpiresAtstringdefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/billing/connections/{id}/rotate-secret POST /v1/billing/connections/{id}/rotate-secret
Parameters
idstringpathrequiredCode samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/connections/{id}/rotate-secret"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"provider": "string",
"webhookSecret": "string",
"previousSecretExpiresAt": "2024-01-01T00:00:00Z"
}Schema
idstringrequiredproviderstringrequiredwebhookSecretstringrequiredReturned only here. The previous secret keeps verifying until previousSecretExpiresAt.
previousSecretExpiresAtstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
GET
https://referally.15.204.158.166.sslip.io /v1/billing/events GET /v1/billing/events
Code samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/v1/billing/events"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/events', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/v1/billing/events",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/v1/billing/events", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/events');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/events')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/events"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 A page of the list. Under referally-version 2026-10-21 the body is the plain array instead.
Example
{
"object": "string",
"data": [
{
"id": "string",
"provider": "string",
"type": "string",
"customerRef": "string",
"invoiceRef": "string",
"amountGross": 0,
"tax": 0,
"fees": 0,
"currency": "string",
"occurredAt": "2024-01-01T00:00:00Z"
}
],
"has_more": true,
"next_cursor": "string"
}Schema
objectstringrequireddataBillingEvent[]requiredShow child parameters
idstringrequiredproviderstringrequiredtypestringrequiredcustomerRefstringrequiredinvoiceRefstringrequiredamountGrossintegerrequiredInteger minor units (cents).
taxintegerrequiredInteger minor units (cents).
feesintegerrequiredInteger minor units (cents).
currencystringrequiredoccurredAtstringrequiredhas_morebooleanrequiredWhether another page follows; pass next_cursor as starting_after to get it.
next_cursorstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/sandbox/simulate Generate deterministic sandbox billing history
Request body application/json
programIdstringrequiredpartnerIdstringrequiredscenariostringpriceMinorintegermonthsinteger{
"programId": "string",
"partnerId": "string",
"scenario": "subscription",
"priceMinor": 9900,
"months": 3
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate" \
-H "Content-Type: application/json" \
-d '{"programId":"string","partnerId":"string","scenario":"subscription","priceMinor":9900,"months":3}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"programId":"string","partnerId":"string","scenario":"subscription","priceMinor":9900,"months":3}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate",
headers={
"Content-Type": "application/json",
},
json={"programId": "string", "partnerId": "string", "scenario": "subscription", "priceMinor": 9900, "months": 3},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate", strings.NewReader(`{"programId":"string","partnerId":"string","scenario":"subscription","priceMinor":9900,"months":3}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"programId":"string","partnerId":"string","scenario":"subscription","priceMinor":9900,"months":3}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"programId":"string","partnerId":"string","scenario":"subscription","priceMinor":9900,"months":3}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/sandbox/simulate"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"programId\":\"string\",\"partnerId\":\"string\",\"scenario\":\"subscription\",\"priceMinor\":9900,\"months\":3}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"customerRef": "string",
"events": 0,
"conversions": 0,
"linesCreated": 0,
"reversals": 0
}Schema
customerRefstringrequiredeventsintegerrequiredconversionsintegerrequiredlinesCreatedintegerrequiredreversalsintegerrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
GET
https://referally.15.204.158.166.sslip.io /v1/billing/plan GET /v1/billing/plan
Code samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/v1/billing/plan"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/plan', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/v1/billing/plan",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/v1/billing/plan", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/plan');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/plan')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/plan"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"plan": "string",
"planStatus": "string",
"periodEnd": "2024-01-01T00:00:00Z",
"limits": {},
"usage": {
"programs": 0,
"partners": 0
},
"catalog": {},
"subscribed": true,
"canActivate": true
}Schema
planstringrequiredplanStatusstringrequiredperiodEndstringrequiredlimitsobjectrequiredusageobjectrequiredShow child parameters
programsintegerrequiredpartnersintegerrequiredcatalogobjectrequiredsubscribedbooleanrequiredcanActivatebooleanrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/billing/checkout POST /v1/billing/checkout
Request body application/json
planstringrequired{
"plan": "growth"
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/billing/checkout" \
-H "Content-Type: application/json" \
-d '{"plan":"growth"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/checkout', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"plan":"growth"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/billing/checkout",
headers={
"Content-Type": "application/json",
},
json={"plan": "growth"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/billing/checkout", strings.NewReader(`{"plan":"growth"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/checkout');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"plan":"growth"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/checkout')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"plan":"growth"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/checkout"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"plan\":\"growth\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"url": "string",
"sessionId": "string"
}Schema
urlstringsessionIdstringdefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/billing/portal POST /v1/billing/portal
Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/billing/portal"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/portal', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/billing/portal",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/billing/portal", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/portal');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/portal')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/portal"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"url": "string"
}Schema
urlstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/billing/activate POST /v1/billing/activate
Request body application/json
planstringrequired{
"plan": "free"
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/billing/activate" \
-H "Content-Type: application/json" \
-d '{"plan":"free"}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/billing/activate', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"plan":"free"}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/billing/activate",
headers={
"Content-Type": "application/json",
},
json={"plan": "free"},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/billing/activate", strings.NewReader(`{"plan":"free"}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/billing/activate');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"plan":"free"}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/billing/activate')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"plan":"free"}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/billing/activate"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"plan\":\"free\"}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"plan": "string",
"planStatus": "string"
}Schema
planstringrequiredplanStatusstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
GET
https://referally.15.204.158.166.sslip.io /v1/onchain/connections GET /v1/onchain/connections
Code samples
cURL
curl -X GET "https://referally.15.204.158.166.sslip.io/v1/onchain/connections"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/onchain/connections', {
method: 'GET',
});
const data = await res.json();Python
import requests
res = requests.request(
"GET",
"https://referally.15.204.158.166.sslip.io/v1/onchain/connections",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://referally.15.204.158.166.sslip.io/v1/onchain/connections", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/onchain/connections');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/onchain/connections')
req = Net::HTTP::Get.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/onchain/connections"))
.GET()
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 A page of the list. Under referally-version 2026-10-21 the body is the plain array instead.
Example
{
"object": "string",
"data": [
{
"id": "string",
"programId": "string",
"name": "string",
"status": "string",
"createdAt": "2024-01-01T00:00:00Z"
}
],
"has_more": true,
"next_cursor": "string"
}Schema
objectstringrequireddataobject[]requiredShow child parameters
idstringrequiredprogramIdstringrequirednamestringrequiredstatusstringrequiredcreatedAtstringrequiredhas_morebooleanrequiredWhether another page follows; pass next_cursor as starting_after to get it.
next_cursorstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /v1/onchain/connections POST /v1/onchain/connections
Request body application/json
programIdstringrequirednamestringsecretstringdecimalsobject{
"programId": "string",
"name": "",
"secret": "string",
"decimals": {
"usd": 2
}
}Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/v1/onchain/connections" \
-H "Content-Type: application/json" \
-d '{"programId":"string","name":"","secret":"string","decimals":{"usd":2}}'TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/v1/onchain/connections', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({"programId":"string","name":"","secret":"string","decimals":{"usd":2}}),
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/v1/onchain/connections",
headers={
"Content-Type": "application/json",
},
json={"programId": "string", "name": "", "secret": "string", "decimals": {"usd": 2}},
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/v1/onchain/connections", strings.NewReader(`{"programId":"string","name":"","secret":"string","decimals":{"usd":2}}`))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/v1/onchain/connections');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"programId":"string","name":"","secret":"string","decimals":{"usd":2}}');
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/v1/onchain/connections')
req = Net::HTTP::Post.new(uri)
req['Content-Type'] = 'application/json'
req.body = '{"programId":"string","name":"","secret":"string","decimals":{"usd":2}}'
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/v1/onchain/connections"))
.header("Content-Type", "application/json")
.method("POST", BodyPublishers.ofString("{\"programId\":\"string\",\"name\":\"\",\"secret\":\"string\",\"decimals\":{\"usd\":2}}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"id": "string",
"secret": "string",
"webhookUrl": "string"
}Schema
idstringrequiredsecretstringrequiredwebhookUrlstringrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /webhooks/billing/{connectionId} Inbound billing webhook (HMAC)
Parameters
connectionIdstringpathrequiredCode samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/webhooks/billing/{connectionId}"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"received": 0,
"results": [
{
"duplicate": true,
"billingEventId": "string",
"conversions": 0,
"linesCreated": 0,
"reversals": 0
}
]
}Schema
receivedintegerrequiredresultsobject[]requiredShow child parameters
duplicatebooleanrequiredbillingEventIdstringrequiredconversionsintegerrequiredlinesCreatedintegerrequiredreversalsintegerrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /webhooks/onchain/{connectionId} On-chain conversion webhook (indexer)
Parameters
connectionIdstringpathrequiredCode samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/webhooks/onchain/{connectionId}"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"received": 0,
"results": [
{
"txHash": "string",
"wallet": "string",
"amountMinor": 0,
"attributed": true,
"linesCreated": 0,
"duplicate": true
}
]
}Schema
receivedintegerrequiredresultsobject[]requiredShow child parameters
txHashstringrequiredwalletstringrequiredamountMinorintegerrequiredInteger minor units (cents).
attributedbooleanrequiredlinesCreatedintegerrequiredduplicatebooleanrequireddefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
POST
https://referally.15.204.158.166.sslip.io /webhooks/stripe-billing POST /webhooks/stripe-billing
Code samples
cURL
curl -X POST "https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing"TypeScript
const res = await fetch('https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing', {
method: 'POST',
});
const data = await res.json();Python
import requests
res = requests.request(
"POST",
"https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing",
)
data = res.json()Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing", nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Ruby
require 'net/http'
require 'uri'
uri = URI('https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing')
req = Net::HTTP::Post.new(uri)
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == 'https') do |http|
http.request(req)
end
puts res.bodyJava
import java.net.URI;
import java.net.http.*;
import java.net.http.HttpRequest.BodyPublishers;
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://referally.15.204.158.166.sslip.io/webhooks/stripe-billing"))
.method("POST", BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Responses
200 OK
Example
{
"received": true,
"duplicate": true,
"ignored": true,
"reason": "string",
"orgId": "string",
"plan": "string",
"planStatus": "string"
}Schema
receivedbooleanrequiredduplicatebooleanignoredbooleanreasonstringorgIdstringplanstringplanStatusstringdefault Error
Example
{
"error": {
"code": "string",
"message": "string",
"details": {},
"requestId": "string",
"docs_url": "string"
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsrequestIdstringdocs_urlstringrequiredThe docs entry for this error code: what it means and how to fix it.
Updated