cURL
curl --request POST \
--url https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'import requests
url = "https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/', 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/subscriptions/subscriptions/{id}/restart-seat-billing/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"id": 123,
"organization": 123,
"stripe_subscription_id": "<string>",
"is_active": true,
"is_trial": "<string>",
"pack": {
"price": "<string>",
"id": 123,
"name": "<string>",
"code": "<string>",
"balance": "<string>",
"subscription_overage": "<string>",
"max_members_limit": -1,
"max_concurrent_runs_limit": -1,
"max_concurrent_chat_runs_limit": -1,
"allow_cancellation": true,
"allow_view_only_role": true,
"data_retention_days": -1,
"extra_member_price": "<string>",
"free_members_count": -1,
"one_time_credits": "<string>"
},
"next_billing_cost": "<string>",
"has_payment_method": "<string>",
"can_switch_to_payg": "<string>",
"first_paid_seat_plan_offer": "<string>",
"seat_payment_overdue_since": "2023-11-07T05:31:56Z",
"last_payment_at": "2023-11-07T05:31:56Z",
"expire_at": "2023-11-07T05:31:56Z",
"cancelled_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}Others
Restart Subscription Seat Billing
Recreate the seat subscription of a perpetual (free base) plan after its
POST
/
subscriptions
/
subscriptions
/
{id}
/
restart-seat-billing
/
cURL
curl --request POST \
--url https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'import requests
url = "https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/', 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/subscriptions/subscriptions/{id}/restart-seat-billing/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cekura.ai/subscriptions/subscriptions/{id}/restart-seat-billing/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"id": 123,
"organization": 123,
"stripe_subscription_id": "<string>",
"is_active": true,
"is_trial": "<string>",
"pack": {
"price": "<string>",
"id": 123,
"name": "<string>",
"code": "<string>",
"balance": "<string>",
"subscription_overage": "<string>",
"max_members_limit": -1,
"max_concurrent_runs_limit": -1,
"max_concurrent_chat_runs_limit": -1,
"allow_cancellation": true,
"allow_view_only_role": true,
"data_retention_days": -1,
"extra_member_price": "<string>",
"free_members_count": -1,
"one_time_credits": "<string>"
},
"next_billing_cost": "<string>",
"has_payment_method": "<string>",
"can_switch_to_payg": "<string>",
"first_paid_seat_plan_offer": "<string>",
"seat_payment_overdue_since": "2023-11-07T05:31:56Z",
"last_payment_at": "2023-11-07T05:31:56Z",
"expire_at": "2023-11-07T05:31:56Z",
"cancelled_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}Authorizations
oauth2supabase_session
OAuth access token issued by Cekura for connected apps.
Path Parameters
Body
application/jsonapplication/x-www-form-urlencodedmultipart/form-data
The body is of type object.
Response
200 - application/json
Show child attributes
Show child attributes
When a renewal payment for this perpetual plan's seat subscription first failed. Once older than SUBSCRIPTION_GRACE_PERIOD_DAYS, billable members other than the free-plan owner are blocked at the API level until the payment is fixed. Cleared when a seat invoice is paid.
Timestamp when the subscription was cancelled (is_active set to False).
⌘I