Skip to main content
POST
/
rr
/
api
/
v1
/
modify-subscription-schedule
Modify Subscription Schedule
curl --request POST \
  --url https://api.meetcampfire.com/rr/api/v1/modify-subscription-schedule \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "start_date": "2023-12-25",
  "total_value": 0,
  "end_date": "2023-12-25",
  "mrr": 0,
  "use_daily_accounting": false,
  "use_catchup": false,
  "catchup_date": "2023-12-25",
  "modified_subscription": 123,
  "does_modify_contract_end_date": false,
  "apply_prospectively": false
}
'
import requests

url = "https://api.meetcampfire.com/rr/api/v1/modify-subscription-schedule"

payload = {
"start_date": "2023-12-25",
"total_value": 0,
"end_date": "2023-12-25",
"mrr": 0,
"use_daily_accounting": False,
"use_catchup": False,
"catchup_date": "2023-12-25",
"modified_subscription": 123,
"does_modify_contract_end_date": False,
"apply_prospectively": False
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
start_date: '2023-12-25',
total_value: 0,
end_date: '2023-12-25',
mrr: 0,
use_daily_accounting: false,
use_catchup: false,
catchup_date: '2023-12-25',
modified_subscription: 123,
does_modify_contract_end_date: false,
apply_prospectively: false
})
};

fetch('https://api.meetcampfire.com/rr/api/v1/modify-subscription-schedule', 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.meetcampfire.com/rr/api/v1/modify-subscription-schedule",
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([
'start_date' => '2023-12-25',
'total_value' => 0,
'end_date' => '2023-12-25',
'mrr' => 0,
'use_daily_accounting' => false,
'use_catchup' => false,
'catchup_date' => '2023-12-25',
'modified_subscription' => 123,
'does_modify_contract_end_date' => false,
'apply_prospectively' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.meetcampfire.com/rr/api/v1/modify-subscription-schedule"

payload := strings.NewReader("{\n \"start_date\": \"2023-12-25\",\n \"total_value\": 0,\n \"end_date\": \"2023-12-25\",\n \"mrr\": 0,\n \"use_daily_accounting\": false,\n \"use_catchup\": false,\n \"catchup_date\": \"2023-12-25\",\n \"modified_subscription\": 123,\n \"does_modify_contract_end_date\": false,\n \"apply_prospectively\": false\n}")

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

req.Header.Add("Authorization", "<api-key>")
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.meetcampfire.com/rr/api/v1/modify-subscription-schedule")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"start_date\": \"2023-12-25\",\n \"total_value\": 0,\n \"end_date\": \"2023-12-25\",\n \"mrr\": 0,\n \"use_daily_accounting\": false,\n \"use_catchup\": false,\n \"catchup_date\": \"2023-12-25\",\n \"modified_subscription\": 123,\n \"does_modify_contract_end_date\": false,\n \"apply_prospectively\": false\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.meetcampfire.com/rr/api/v1/modify-subscription-schedule")

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

request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"start_date\": \"2023-12-25\",\n \"total_value\": 0,\n \"end_date\": \"2023-12-25\",\n \"mrr\": 0,\n \"use_daily_accounting\": false,\n \"use_catchup\": false,\n \"catchup_date\": \"2023-12-25\",\n \"modified_subscription\": 123,\n \"does_modify_contract_end_date\": false,\n \"apply_prospectively\": false\n}"

response = http.request(request)
puts response.read_body
[
  {
    "start_date": "2023-12-25",
    "end_date": "2023-12-25",
    "total_value": 0,
    "id": 123,
    "original_value": 0,
    "original_mrr": 0,
    "mrr": 0,
    "original_quantity": 0,
    "quantity": 0,
    "original_rate": 0,
    "rate": 0,
    "use_daily_accounting": false,
    "is_contract_amendment": false
  }
]

Authorizations

Authorization
string
header
required

Token-based authentication with required prefix "Token"

Body

start_date
string<date>
required

Start date of the subscription period.

total_value
number<double>
required

Total contract value for the subscription period.

Required range: -1000000000000000000 < x < 1000000000000000000
end_date
string<date> | null

End date of the subscription period. Defaults to 1 year from start date if not provided.

mrr
number<double>

Monthly recurring revenue. If not provided, it is calculated from total_value and the subscription period.

Required range: -1000000000000000000 < x < 1000000000000000000
use_daily_accounting
boolean
default:false

Whether to use daily (vs monthly) revenue recognition.

proration_method

Proration method. When provided, takes precedence over use_daily_accounting (DAILY↔True, STANDARD/THIRTY_DAY↔False).

  • standard - Standard (actual month length)
  • thirty_day - Fixed 30-day month
  • daily - Daily
Available options:
standard,
thirty_day,
daily
use_catchup
boolean
default:false

Enable catch-up accounting for retroactive amendments.

catchup_date
string<date> | null

Date from which to apply catch-up adjustments. Required if use_catchup is true.

modified_subscription
integer | null

ID of the existing contract subscription being modified.

does_modify_contract_end_date
boolean
default:false

Whether this modification changes the contract end date.

apply_prospectively
boolean
default:false

Apply changes prospectively from catchup_date instead of retroactively. Only valid when use_catchup is true.

Response

200 - application/json
start_date
string<date>
required
end_date
string<date>
required
total_value
number<double>
required
Required range: -1000000000000000000 < x < 1000000000000000000
id
integer | null
original_value
number<double> | null
Required range: -1000000000000000000 < x < 1000000000000000000
original_mrr
number<double> | null
Required range: -1000000000000000000 < x < 1000000000000000000
mrr
number<double>
Required range: -1000000000000000000 < x < 1000000000000000000
original_quantity
number<double> | null
Required range: -100000000000000 < x < 100000000000000
quantity
number<double> | null
Required range: -100000000000000 < x < 100000000000000
original_rate
number<double> | null
Required range: -10000000000000 < x < 10000000000000
rate
number<double> | null
Required range: -10000000000000 < x < 10000000000000
use_daily_accounting
boolean
default:false
is_contract_amendment
boolean
default:false