Get payment history
curl --request GET \
--url https://api.cekura.ai/test_framework/billing/payment-history/ \
--header 'X-CEKURA-API-KEY: <api-key>'import requests
url = "https://api.cekura.ai/test_framework/billing/payment-history/"
headers = {"X-CEKURA-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-CEKURA-API-KEY': '<api-key>'}};
fetch('https://api.cekura.ai/test_framework/billing/payment-history/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cekura.ai/test_framework/billing/payment-history/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-CEKURA-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.cekura.ai/test_framework/billing/payment-history/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CEKURA-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.cekura.ai/test_framework/billing/payment-history/")
.header("X-CEKURA-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cekura.ai/test_framework/billing/payment-history/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-CEKURA-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 123,
"amount": "<string>",
"currency": "<string>",
"payment_type": "auto_pay",
"description": "<string>",
"stripe_payment_intent_id": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}
]Organization
Get Payment History
Returns a paginated list of all payments (auto-pay, one-time, subscription) made by the organization.
GET
/
test_framework
/
billing
/
payment-history
/
Get payment history
curl --request GET \
--url https://api.cekura.ai/test_framework/billing/payment-history/ \
--header 'X-CEKURA-API-KEY: <api-key>'import requests
url = "https://api.cekura.ai/test_framework/billing/payment-history/"
headers = {"X-CEKURA-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-CEKURA-API-KEY': '<api-key>'}};
fetch('https://api.cekura.ai/test_framework/billing/payment-history/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cekura.ai/test_framework/billing/payment-history/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-CEKURA-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.cekura.ai/test_framework/billing/payment-history/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CEKURA-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.cekura.ai/test_framework/billing/payment-history/")
.header("X-CEKURA-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cekura.ai/test_framework/billing/payment-history/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-CEKURA-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 123,
"amount": "<string>",
"currency": "<string>",
"payment_type": "auto_pay",
"description": "<string>",
"stripe_payment_intent_id": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}
]Authorizations
api_keyoauth2supabase_session
API Key Authentication. It should be included in the header of each request.
Query Parameters
Organization ID
Response
Currency code (e.g. USD, INR)
Maximum string length:
10Type of payment (auto_pay or one_time_payment)
auto_pay- Auto Payone_time_payment- One-Time Paymentself_serve_credits- Self-Serve Creditsself_serve_member_seat- Self-Serve Member Seatsubscription- Subscriptionsubscription_member_seat- Subscription Member Seat
Available options:
auto_pay, one_time_payment, self_serve_credits, self_serve_member_seat, subscription, subscription_member_seat, null Payment description or notes
Stripe PaymentIntent ID for tracking. CAUTION: subscription renewal rows (written by StripeWebhookView.handle_invoice_paid) store the Stripe invoice id here instead of a PI id. The payment_intent.payment_failed ops alert (send_granted_before_payment_failed_alert) matches this field against PI ids and relies on renewals NOT matching — if renewals ever store real PI ids, every dunning retry on a renewal would page ops.
Maximum string length:
255