Skip to main content
POST
/
api
/
Subscriptions
/
{subscriptionId}
/
billing-plans
Create Subscription Billing Plan
curl --request POST \
  --url https://api-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans \
  --header 'Content-Type: application/json-patch+json' \
  --header 'x-revolv3-token: <api-key>' \
  --data '
{
  "name": "New Billing Plan",
  "value": 5.99,
  "cycleCount": 12,
  "valueType": "Standard",
  "startCycleDelay": 0
}
'
import requests

url = "https://api-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans"

payload = {
"name": "New Billing Plan",
"value": 5.99,
"cycleCount": 12,
"valueType": "Standard",
"startCycleDelay": 0
}
headers = {
"x-revolv3-token": "<api-key>",
"Content-Type": "application/json-patch+json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {'x-revolv3-token': '<api-key>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({
name: 'New Billing Plan',
value: 5.99,
cycleCount: 12,
valueType: 'Standard',
startCycleDelay: 0
})
};

fetch('https://api-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans', 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-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans",
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([
'name' => 'New Billing Plan',
'value' => 5.99,
'cycleCount' => 12,
'valueType' => 'Standard',
'startCycleDelay' => 0
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json-patch+json",
"x-revolv3-token: <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"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans"

payload := strings.NewReader("{\n \"name\": \"New Billing Plan\",\n \"value\": 5.99,\n \"cycleCount\": 12,\n \"valueType\": \"Standard\",\n \"startCycleDelay\": 0\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("x-revolv3-token", "<api-key>")
req.Header.Add("Content-Type", "application/json-patch+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-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans")
.header("x-revolv3-token", "<api-key>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"name\": \"New Billing Plan\",\n \"value\": 5.99,\n \"cycleCount\": 12,\n \"valueType\": \"Standard\",\n \"startCycleDelay\": 0\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api-sandbox.revolv3.com/api/Subscriptions/{subscriptionId}/billing-plans")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x-revolv3-token"] = '<api-key>'
request["Content-Type"] = 'application/json-patch+json'
request.body = "{\n \"name\": \"New Billing Plan\",\n \"value\": 5.99,\n \"cycleCount\": 12,\n \"valueType\": \"Standard\",\n \"startCycleDelay\": 0\n}"

response = http.request(request)
puts response.read_body
{
  "subscriptionId": 1,
  "customerId": 1,
  "merchantSubscriptionRefId": "1234-5678-9101",
  "networkTransactionId": null,
  "billingIntervalType": "Months",
  "billingIntervalCount": 1,
  "subscriptionStatusType": "Current",
  "subscriptionCancelType": "Immediate",
  "initialBillDate": "01.07.2026",
  "nextBillDate": "01.08.2026",
  "taxAddress": null,
  "paymentMethodIds": [
    1,
    2
  ],
  "cancelledAt": null,
  "billingPlans": [
    {
      "subscriptionBillingPlanId": 1,
      "subscriptionId": 0,
      "name": "Billing Plan 1",
      "value": 10.99,
      "startDate": "01.07.2026",
      "cyclesRemaining": -1,
      "cycleCount": 0,
      "valueType": "Standard"
    },
    {
      "subscriptionBillingPlanId": 2,
      "subscriptionId": 0,
      "name": "Billing Plan 2",
      "value": 14.99,
      "startDate": "01.08.2026",
      "cyclesRemaining": 12,
      "cycleCount": 0,
      "valueType": "Standard"
    }
  ],
  "message": null,
  "paymentProcessor": null,
  "processorMerchantId": null,
  "processorRawResponse": null,
  "currency": null,
  "responseMessage": null,
  "responseCode": null
}
{
"message": "Unable to perform the request action with provided data."
}
{
"message": "Attempted to perform an unauthorized operation."
}
{
"message": "Unable to find an entity with the provided data."
}

Authorizations

x-revolv3-token
string
header
required

Path Parameters

subscriptionId
integer<int64>
required
Required range: 1 <= x <= 1000000000

Body

name
string
required
Required string length: 1 - 100
value
number<double>
required
Required range: 0 <= x <= 10000000
cycleCount
integer<int32>
default:-1
required
Required range: -1 <= x <= 100
valueType
string
default:Standard
required
Required string length: 1 - 50
startCycleDelay
integer<int32>
default:0
required
Required range: 0 <= x <= 1000000000

Response

Created

subscriptionId
integer<int64>
Required range: 1 <= x <= 1000000000
customerId
integer<int64>
Required range: 1 <= x <= 1000000000
merchantSubscriptionRefId
string | null
Maximum string length: 100
networkTransactionId
string | null
Maximum string length: 100
billingIntervalType
string | null
Maximum string length: 50
billingIntervalCount
integer<int32>
Required range: 1 <= x <= 1000000000
subscriptionStatusType
string | null
Maximum string length: 50
subscriptionCancelType
string | null
Maximum string length: 50
initialBillDate
string | null
Maximum string length: 20
nextBillDate
string | null
Maximum string length: 20
taxAddress
object
paymentMethodIds
integer<int64>[] | null
cancelledAt
string<date-time> | null
Maximum string length: 40
billingPlans
object[] | null
message
string | null
Maximum string length: 500
paymentProcessor
string | null
Maximum string length: 100
processorMerchantId
string | null
Maximum string length: 100
processorRawResponse
string | null
Maximum string length: 10000
currency
string | null
Maximum string length: 3
responseMessage
string | null
Maximum string length: 500
responseCode
string | null
Maximum string length: 10