curl --request PUT \
--url https://api.meetcampfire.com/rr/api/v1/contracts/{id} \
--header 'Content-Type: application/json' \
--data '
{
"tags": "<string>",
"currency": "USD",
"prepaid_commits": [
{
"name": "<string>",
"total_value": 0,
"start_date": "2023-12-25",
"eligible_usage_products": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"usage_pricing_terms": [
{
"usage_product": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"preview_digest": "<string>",
"preview_token": "<string>",
"confirm_price": true,
"rate_card": 123,
"schedule": {},
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirm_historical_price": false
}
],
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"drawdown_basis": "monetary",
"entity": 123,
"product": 123,
"invoice_basis": "fixed_commitment",
"first_invoice_date": "2023-12-25",
"billing_payment_term": 123,
"description": "",
"currency": "<string>",
"exchange_rate": 0,
"exchange_rate_book": 0,
"discount_percentage": 0,
"rate": 0,
"quantity": 500000000000000,
"unit": "",
"expiration_date": "2023-12-25",
"priority": 1,
"subledger": 123,
"auto_send_overage_invoices": false,
"overage_invoice_start_month": "2023-12-25",
"department": 123,
"tags": [
123
]
}
],
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": false,
"auto_send_invoices": false,
"skip_evergreen_invoice_generation": false,
"auto_apply_customer_stripe_config_to_invoices": false,
"exclude_from_tax_connection": false,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"source_deal_data": null,
"auto_renew": true,
"auto_renew_duration": -1,
"auto_renew_invoice": true,
"tag_ids": [
0
],
"tag_group_ids": [
0
],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [
123
]
}
'import requests
url = "https://api.meetcampfire.com/rr/api/v1/contracts/{id}"
payload = {
"tags": "<string>",
"currency": "USD",
"prepaid_commits": [
{
"name": "<string>",
"total_value": 0,
"start_date": "2023-12-25",
"eligible_usage_products": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"usage_pricing_terms": [
{
"usage_product": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"preview_digest": "<string>",
"preview_token": "<string>",
"confirm_price": True,
"rate_card": 123,
"schedule": {},
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirm_historical_price": False
}
],
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"drawdown_basis": "monetary",
"entity": 123,
"product": 123,
"invoice_basis": "fixed_commitment",
"first_invoice_date": "2023-12-25",
"billing_payment_term": 123,
"description": "",
"currency": "<string>",
"exchange_rate": 0,
"exchange_rate_book": 0,
"discount_percentage": 0,
"rate": 0,
"quantity": 500000000000000,
"unit": "",
"expiration_date": "2023-12-25",
"priority": 1,
"subledger": 123,
"auto_send_overage_invoices": False,
"overage_invoice_start_month": "2023-12-25",
"department": 123,
"tags": [123]
}
],
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": False,
"auto_send_invoices": False,
"skip_evergreen_invoice_generation": False,
"auto_apply_customer_stripe_config_to_invoices": False,
"exclude_from_tax_connection": False,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"source_deal_data": None,
"auto_renew": True,
"auto_renew_duration": -1,
"auto_renew_invoice": True,
"tag_ids": [0],
"tag_group_ids": [0],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [123]
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
tags: '<string>',
currency: 'USD',
prepaid_commits: [
{
name: '<string>',
total_value: 0,
start_date: '2023-12-25',
eligible_usage_products: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
usage_pricing_terms: [
{
usage_product: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
preview_digest: '<string>',
preview_token: '<string>',
confirm_price: true,
rate_card: 123,
schedule: {},
contract_usage_term: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
confirm_historical_price: false
}
],
contract_usage_term: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
drawdown_basis: 'monetary',
entity: 123,
product: 123,
invoice_basis: 'fixed_commitment',
first_invoice_date: '2023-12-25',
billing_payment_term: 123,
description: '',
currency: '<string>',
exchange_rate: 0,
exchange_rate_book: 0,
discount_percentage: 0,
rate: 0,
quantity: 500000000000000,
unit: '',
expiration_date: '2023-12-25',
priority: 1,
subledger: 123,
auto_send_overage_invoices: false,
overage_invoice_start_month: '2023-12-25',
department: 123,
tags: [123]
}
],
contract_end_date: '2023-12-25',
termination_date: '2023-12-25',
is_evergreen: false,
auto_send_invoices: false,
skip_evergreen_invoice_generation: false,
auto_apply_customer_stripe_config_to_invoices: false,
exclude_from_tax_connection: false,
usage_tiers: '<string>',
invoice_email: 'jsmith@example.com',
deal_name: '<string>',
deal_id: '<string>',
consultant: '<string>',
closed_date: '2023-12-25',
total_contract_value: 0,
contract_start_date: '2023-12-25',
exchange_rate: 0,
exchange_rate_book: 0,
crm_link: '<string>',
contract_link: '<string>',
source_deal_data: null,
auto_renew: true,
auto_renew_duration: -1,
auto_renew_invoice: true,
tag_ids: [0],
tag_group_ids: [0],
minimum_monthly_commitment_amount: 0,
minimum_monthly_commitment_quantity: 0,
purchase_order_number: '<string>',
billing_address: '<string>',
billing_addressee: '<string>',
shipping_address: '<string>',
shipping_addressee: '<string>',
invoice_cc_emails: '<string>',
vat_number: '<string>',
entity: 123,
client: 123,
default_payment_term: 123,
department: 123,
journal_entries: [123]
})
};
fetch('https://api.meetcampfire.com/rr/api/v1/contracts/{id}', 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/contracts/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'tags' => '<string>',
'currency' => 'USD',
'prepaid_commits' => [
[
'name' => '<string>',
'total_value' => 0,
'start_date' => '2023-12-25',
'eligible_usage_products' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'usage_pricing_terms' => [
[
'usage_product' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'preview_digest' => '<string>',
'preview_token' => '<string>',
'confirm_price' => true,
'rate_card' => 123,
'schedule' => [
],
'contract_usage_term' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'confirm_historical_price' => false
]
],
'contract_usage_term' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'drawdown_basis' => 'monetary',
'entity' => 123,
'product' => 123,
'invoice_basis' => 'fixed_commitment',
'first_invoice_date' => '2023-12-25',
'billing_payment_term' => 123,
'description' => '',
'currency' => '<string>',
'exchange_rate' => 0,
'exchange_rate_book' => 0,
'discount_percentage' => 0,
'rate' => 0,
'quantity' => 500000000000000,
'unit' => '',
'expiration_date' => '2023-12-25',
'priority' => 1,
'subledger' => 123,
'auto_send_overage_invoices' => false,
'overage_invoice_start_month' => '2023-12-25',
'department' => 123,
'tags' => [
123
]
]
],
'contract_end_date' => '2023-12-25',
'termination_date' => '2023-12-25',
'is_evergreen' => false,
'auto_send_invoices' => false,
'skip_evergreen_invoice_generation' => false,
'auto_apply_customer_stripe_config_to_invoices' => false,
'exclude_from_tax_connection' => false,
'usage_tiers' => '<string>',
'invoice_email' => 'jsmith@example.com',
'deal_name' => '<string>',
'deal_id' => '<string>',
'consultant' => '<string>',
'closed_date' => '2023-12-25',
'total_contract_value' => 0,
'contract_start_date' => '2023-12-25',
'exchange_rate' => 0,
'exchange_rate_book' => 0,
'crm_link' => '<string>',
'contract_link' => '<string>',
'source_deal_data' => null,
'auto_renew' => true,
'auto_renew_duration' => -1,
'auto_renew_invoice' => true,
'tag_ids' => [
0
],
'tag_group_ids' => [
0
],
'minimum_monthly_commitment_amount' => 0,
'minimum_monthly_commitment_quantity' => 0,
'purchase_order_number' => '<string>',
'billing_address' => '<string>',
'billing_addressee' => '<string>',
'shipping_address' => '<string>',
'shipping_addressee' => '<string>',
'invoice_cc_emails' => '<string>',
'vat_number' => '<string>',
'entity' => 123,
'client' => 123,
'default_payment_term' => 123,
'department' => 123,
'journal_entries' => [
123
]
]),
CURLOPT_HTTPHEADER => [
"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/contracts/{id}"
payload := strings.NewReader("{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
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.put("https://api.meetcampfire.com/rr/api/v1/contracts/{id}")
.header("Content-Type", "application/json")
.body("{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meetcampfire.com/rr/api/v1/contracts/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": 123,
"entity_name": "<string>",
"client_name": "<string>",
"client_campfire_id": "<string>",
"client_terms": "<string>",
"default_payment_term_name": "<string>",
"department_name": "<string>",
"parent_department_name": "<string>",
"parent_department": 123,
"total_revenue": 0,
"total_mrr": 0,
"total_deferred_revenue": 0,
"entity_currency": "<string>",
"attachments": [
{
"id": 123,
"customer": 123,
"created_at": "2023-11-07T05:31:56Z",
"created_by": 123,
"created_by_name": "<string>",
"created_by_email": "<string>",
"last_modified_at": "2023-11-07T05:31:56Z",
"name": "<string>",
"url": "<string>",
"s3_path": "<string>",
"app": "<string>",
"model": "<string>",
"is_deleted": false,
"deleted_at": "2023-11-07T05:31:56Z",
"s3_content_type": "<string>",
"s3_content_length": 1073741823,
"object_id": 1073741823
}
],
"last_modified_at": "2023-11-07T05:31:56Z",
"is_deleted": true,
"deleted_at": "2023-11-07T05:31:56Z",
"has_invoices": false,
"has_journal_entries": false,
"has_credit_memos": false,
"monthly_billing_alignment_locked": true,
"effective_end_date": "2023-12-25",
"working_end_date": "2023-12-25",
"evergreen_locked_date": "2023-12-25",
"tax_exempt": true,
"search_vector": "<string>",
"search_text": "<string>",
"salesforce_opportunity_id": "<string>",
"stripe_subscription_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"customer": 123,
"tags": "<string>",
"currency": "USD",
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": false,
"auto_send_invoices": false,
"skip_evergreen_invoice_generation": false,
"auto_apply_customer_stripe_config_to_invoices": false,
"exclude_from_tax_connection": false,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"billing_frequency": "monthly",
"monthly_billing_period_alignment": "anniversary",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"status": "ACTIVE",
"source": "SALESFORCE",
"source_deal_data": null,
"auto_renew": true,
"auto_renew_duration": -1,
"auto_renew_invoice": true,
"evergreen_date_boundary_mode": "CONTRACT_PERIOD",
"tag_ids": [
0
],
"tag_group_ids": [
0
],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [
123
]
}Update Contract
curl --request PUT \
--url https://api.meetcampfire.com/rr/api/v1/contracts/{id} \
--header 'Content-Type: application/json' \
--data '
{
"tags": "<string>",
"currency": "USD",
"prepaid_commits": [
{
"name": "<string>",
"total_value": 0,
"start_date": "2023-12-25",
"eligible_usage_products": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"usage_pricing_terms": [
{
"usage_product": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"preview_digest": "<string>",
"preview_token": "<string>",
"confirm_price": true,
"rate_card": 123,
"schedule": {},
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirm_historical_price": false
}
],
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"drawdown_basis": "monetary",
"entity": 123,
"product": 123,
"invoice_basis": "fixed_commitment",
"first_invoice_date": "2023-12-25",
"billing_payment_term": 123,
"description": "",
"currency": "<string>",
"exchange_rate": 0,
"exchange_rate_book": 0,
"discount_percentage": 0,
"rate": 0,
"quantity": 500000000000000,
"unit": "",
"expiration_date": "2023-12-25",
"priority": 1,
"subledger": 123,
"auto_send_overage_invoices": false,
"overage_invoice_start_month": "2023-12-25",
"department": 123,
"tags": [
123
]
}
],
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": false,
"auto_send_invoices": false,
"skip_evergreen_invoice_generation": false,
"auto_apply_customer_stripe_config_to_invoices": false,
"exclude_from_tax_connection": false,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"source_deal_data": null,
"auto_renew": true,
"auto_renew_duration": -1,
"auto_renew_invoice": true,
"tag_ids": [
0
],
"tag_group_ids": [
0
],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [
123
]
}
'import requests
url = "https://api.meetcampfire.com/rr/api/v1/contracts/{id}"
payload = {
"tags": "<string>",
"currency": "USD",
"prepaid_commits": [
{
"name": "<string>",
"total_value": 0,
"start_date": "2023-12-25",
"eligible_usage_products": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"usage_pricing_terms": [
{
"usage_product": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"preview_digest": "<string>",
"preview_token": "<string>",
"confirm_price": True,
"rate_card": 123,
"schedule": {},
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirm_historical_price": False
}
],
"contract_usage_term": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"drawdown_basis": "monetary",
"entity": 123,
"product": 123,
"invoice_basis": "fixed_commitment",
"first_invoice_date": "2023-12-25",
"billing_payment_term": 123,
"description": "",
"currency": "<string>",
"exchange_rate": 0,
"exchange_rate_book": 0,
"discount_percentage": 0,
"rate": 0,
"quantity": 500000000000000,
"unit": "",
"expiration_date": "2023-12-25",
"priority": 1,
"subledger": 123,
"auto_send_overage_invoices": False,
"overage_invoice_start_month": "2023-12-25",
"department": 123,
"tags": [123]
}
],
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": False,
"auto_send_invoices": False,
"skip_evergreen_invoice_generation": False,
"auto_apply_customer_stripe_config_to_invoices": False,
"exclude_from_tax_connection": False,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"source_deal_data": None,
"auto_renew": True,
"auto_renew_duration": -1,
"auto_renew_invoice": True,
"tag_ids": [0],
"tag_group_ids": [0],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [123]
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
tags: '<string>',
currency: 'USD',
prepaid_commits: [
{
name: '<string>',
total_value: 0,
start_date: '2023-12-25',
eligible_usage_products: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
usage_pricing_terms: [
{
usage_product: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
preview_digest: '<string>',
preview_token: '<string>',
confirm_price: true,
rate_card: 123,
schedule: {},
contract_usage_term: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
confirm_historical_price: false
}
],
contract_usage_term: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
drawdown_basis: 'monetary',
entity: 123,
product: 123,
invoice_basis: 'fixed_commitment',
first_invoice_date: '2023-12-25',
billing_payment_term: 123,
description: '',
currency: '<string>',
exchange_rate: 0,
exchange_rate_book: 0,
discount_percentage: 0,
rate: 0,
quantity: 500000000000000,
unit: '',
expiration_date: '2023-12-25',
priority: 1,
subledger: 123,
auto_send_overage_invoices: false,
overage_invoice_start_month: '2023-12-25',
department: 123,
tags: [123]
}
],
contract_end_date: '2023-12-25',
termination_date: '2023-12-25',
is_evergreen: false,
auto_send_invoices: false,
skip_evergreen_invoice_generation: false,
auto_apply_customer_stripe_config_to_invoices: false,
exclude_from_tax_connection: false,
usage_tiers: '<string>',
invoice_email: 'jsmith@example.com',
deal_name: '<string>',
deal_id: '<string>',
consultant: '<string>',
closed_date: '2023-12-25',
total_contract_value: 0,
contract_start_date: '2023-12-25',
exchange_rate: 0,
exchange_rate_book: 0,
crm_link: '<string>',
contract_link: '<string>',
source_deal_data: null,
auto_renew: true,
auto_renew_duration: -1,
auto_renew_invoice: true,
tag_ids: [0],
tag_group_ids: [0],
minimum_monthly_commitment_amount: 0,
minimum_monthly_commitment_quantity: 0,
purchase_order_number: '<string>',
billing_address: '<string>',
billing_addressee: '<string>',
shipping_address: '<string>',
shipping_addressee: '<string>',
invoice_cc_emails: '<string>',
vat_number: '<string>',
entity: 123,
client: 123,
default_payment_term: 123,
department: 123,
journal_entries: [123]
})
};
fetch('https://api.meetcampfire.com/rr/api/v1/contracts/{id}', 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/contracts/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'tags' => '<string>',
'currency' => 'USD',
'prepaid_commits' => [
[
'name' => '<string>',
'total_value' => 0,
'start_date' => '2023-12-25',
'eligible_usage_products' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'usage_pricing_terms' => [
[
'usage_product' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'preview_digest' => '<string>',
'preview_token' => '<string>',
'confirm_price' => true,
'rate_card' => 123,
'schedule' => [
],
'contract_usage_term' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'confirm_historical_price' => false
]
],
'contract_usage_term' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'drawdown_basis' => 'monetary',
'entity' => 123,
'product' => 123,
'invoice_basis' => 'fixed_commitment',
'first_invoice_date' => '2023-12-25',
'billing_payment_term' => 123,
'description' => '',
'currency' => '<string>',
'exchange_rate' => 0,
'exchange_rate_book' => 0,
'discount_percentage' => 0,
'rate' => 0,
'quantity' => 500000000000000,
'unit' => '',
'expiration_date' => '2023-12-25',
'priority' => 1,
'subledger' => 123,
'auto_send_overage_invoices' => false,
'overage_invoice_start_month' => '2023-12-25',
'department' => 123,
'tags' => [
123
]
]
],
'contract_end_date' => '2023-12-25',
'termination_date' => '2023-12-25',
'is_evergreen' => false,
'auto_send_invoices' => false,
'skip_evergreen_invoice_generation' => false,
'auto_apply_customer_stripe_config_to_invoices' => false,
'exclude_from_tax_connection' => false,
'usage_tiers' => '<string>',
'invoice_email' => 'jsmith@example.com',
'deal_name' => '<string>',
'deal_id' => '<string>',
'consultant' => '<string>',
'closed_date' => '2023-12-25',
'total_contract_value' => 0,
'contract_start_date' => '2023-12-25',
'exchange_rate' => 0,
'exchange_rate_book' => 0,
'crm_link' => '<string>',
'contract_link' => '<string>',
'source_deal_data' => null,
'auto_renew' => true,
'auto_renew_duration' => -1,
'auto_renew_invoice' => true,
'tag_ids' => [
0
],
'tag_group_ids' => [
0
],
'minimum_monthly_commitment_amount' => 0,
'minimum_monthly_commitment_quantity' => 0,
'purchase_order_number' => '<string>',
'billing_address' => '<string>',
'billing_addressee' => '<string>',
'shipping_address' => '<string>',
'shipping_addressee' => '<string>',
'invoice_cc_emails' => '<string>',
'vat_number' => '<string>',
'entity' => 123,
'client' => 123,
'default_payment_term' => 123,
'department' => 123,
'journal_entries' => [
123
]
]),
CURLOPT_HTTPHEADER => [
"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/contracts/{id}"
payload := strings.NewReader("{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
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.put("https://api.meetcampfire.com/rr/api/v1/contracts/{id}")
.header("Content-Type", "application/json")
.body("{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meetcampfire.com/rr/api/v1/contracts/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"tags\": \"<string>\",\n \"currency\": \"USD\",\n \"prepaid_commits\": [\n {\n \"name\": \"<string>\",\n \"total_value\": 0,\n \"start_date\": \"2023-12-25\",\n \"eligible_usage_products\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"usage_pricing_terms\": [\n {\n \"usage_product\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"preview_digest\": \"<string>\",\n \"preview_token\": \"<string>\",\n \"confirm_price\": true,\n \"rate_card\": 123,\n \"schedule\": {},\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"confirm_historical_price\": false\n }\n ],\n \"contract_usage_term\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"drawdown_basis\": \"monetary\",\n \"entity\": 123,\n \"product\": 123,\n \"invoice_basis\": \"fixed_commitment\",\n \"first_invoice_date\": \"2023-12-25\",\n \"billing_payment_term\": 123,\n \"description\": \"\",\n \"currency\": \"<string>\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"discount_percentage\": 0,\n \"rate\": 0,\n \"quantity\": 500000000000000,\n \"unit\": \"\",\n \"expiration_date\": \"2023-12-25\",\n \"priority\": 1,\n \"subledger\": 123,\n \"auto_send_overage_invoices\": false,\n \"overage_invoice_start_month\": \"2023-12-25\",\n \"department\": 123,\n \"tags\": [\n 123\n ]\n }\n ],\n \"contract_end_date\": \"2023-12-25\",\n \"termination_date\": \"2023-12-25\",\n \"is_evergreen\": false,\n \"auto_send_invoices\": false,\n \"skip_evergreen_invoice_generation\": false,\n \"auto_apply_customer_stripe_config_to_invoices\": false,\n \"exclude_from_tax_connection\": false,\n \"usage_tiers\": \"<string>\",\n \"invoice_email\": \"jsmith@example.com\",\n \"deal_name\": \"<string>\",\n \"deal_id\": \"<string>\",\n \"consultant\": \"<string>\",\n \"closed_date\": \"2023-12-25\",\n \"total_contract_value\": 0,\n \"contract_start_date\": \"2023-12-25\",\n \"exchange_rate\": 0,\n \"exchange_rate_book\": 0,\n \"crm_link\": \"<string>\",\n \"contract_link\": \"<string>\",\n \"source_deal_data\": null,\n \"auto_renew\": true,\n \"auto_renew_duration\": -1,\n \"auto_renew_invoice\": true,\n \"tag_ids\": [\n 0\n ],\n \"tag_group_ids\": [\n 0\n ],\n \"minimum_monthly_commitment_amount\": 0,\n \"minimum_monthly_commitment_quantity\": 0,\n \"purchase_order_number\": \"<string>\",\n \"billing_address\": \"<string>\",\n \"billing_addressee\": \"<string>\",\n \"shipping_address\": \"<string>\",\n \"shipping_addressee\": \"<string>\",\n \"invoice_cc_emails\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"entity\": 123,\n \"client\": 123,\n \"default_payment_term\": 123,\n \"department\": 123,\n \"journal_entries\": [\n 123\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": 123,
"entity_name": "<string>",
"client_name": "<string>",
"client_campfire_id": "<string>",
"client_terms": "<string>",
"default_payment_term_name": "<string>",
"department_name": "<string>",
"parent_department_name": "<string>",
"parent_department": 123,
"total_revenue": 0,
"total_mrr": 0,
"total_deferred_revenue": 0,
"entity_currency": "<string>",
"attachments": [
{
"id": 123,
"customer": 123,
"created_at": "2023-11-07T05:31:56Z",
"created_by": 123,
"created_by_name": "<string>",
"created_by_email": "<string>",
"last_modified_at": "2023-11-07T05:31:56Z",
"name": "<string>",
"url": "<string>",
"s3_path": "<string>",
"app": "<string>",
"model": "<string>",
"is_deleted": false,
"deleted_at": "2023-11-07T05:31:56Z",
"s3_content_type": "<string>",
"s3_content_length": 1073741823,
"object_id": 1073741823
}
],
"last_modified_at": "2023-11-07T05:31:56Z",
"is_deleted": true,
"deleted_at": "2023-11-07T05:31:56Z",
"has_invoices": false,
"has_journal_entries": false,
"has_credit_memos": false,
"monthly_billing_alignment_locked": true,
"effective_end_date": "2023-12-25",
"working_end_date": "2023-12-25",
"evergreen_locked_date": "2023-12-25",
"tax_exempt": true,
"search_vector": "<string>",
"search_text": "<string>",
"salesforce_opportunity_id": "<string>",
"stripe_subscription_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"customer": 123,
"tags": "<string>",
"currency": "USD",
"contract_end_date": "2023-12-25",
"termination_date": "2023-12-25",
"is_evergreen": false,
"auto_send_invoices": false,
"skip_evergreen_invoice_generation": false,
"auto_apply_customer_stripe_config_to_invoices": false,
"exclude_from_tax_connection": false,
"usage_tiers": "<string>",
"invoice_email": "jsmith@example.com",
"billing_frequency": "monthly",
"monthly_billing_period_alignment": "anniversary",
"deal_name": "<string>",
"deal_id": "<string>",
"consultant": "<string>",
"closed_date": "2023-12-25",
"total_contract_value": 0,
"contract_start_date": "2023-12-25",
"exchange_rate": 0,
"exchange_rate_book": 0,
"crm_link": "<string>",
"contract_link": "<string>",
"status": "ACTIVE",
"source": "SALESFORCE",
"source_deal_data": null,
"auto_renew": true,
"auto_renew_duration": -1,
"auto_renew_invoice": true,
"evergreen_date_boundary_mode": "CONTRACT_PERIOD",
"tag_ids": [
0
],
"tag_group_ids": [
0
],
"minimum_monthly_commitment_amount": 0,
"minimum_monthly_commitment_quantity": 0,
"purchase_order_number": "<string>",
"billing_address": "<string>",
"billing_addressee": "<string>",
"shipping_address": "<string>",
"shipping_addressee": "<string>",
"invoice_cc_emails": "<string>",
"vat_number": "<string>",
"entity": 123,
"client": 123,
"default_payment_term": 123,
"department": 123,
"journal_entries": [
123
]
}Body
For Evergreen contracts only. Set at contract creation; existing contracts cannot change this setting. False means current behavior. True skips only Campfire's auto-generated evergreen invoices; revenue transactions still generate; existing invoices are not cleaned up.
Controls service-period boundaries for monthly subscription and usage billing. Anniversary preserves contract-date boundaries; calendar month creates leading and trailing stubs.
anniversary- Contract anniversarycalendar_month- Calendar month
anniversary, calendar_month Controls evergreen subscription date boundaries. CONTRACT_PERIOD preserves contract billing-period alignment; EXACT_DATE uses the subscriptions' exact service dates.
CONTRACT_PERIOD- Contract billing periodEXACT_DATE- Exact service dates
CONTRACT_PERIOD, EXACT_DATE Contract-level default payment term for generated invoices. Currently applied only to automatically generated Evergreen invoices; other contract invoice flows retain their existing payment-term selection behavior. Support may be extended to additional contract types in the future.
Response
For Evergreen contracts only. Set at contract creation; existing contracts cannot change this setting. False means current behavior. True skips only Campfire's auto-generated evergreen invoices; revenue transactions still generate; existing invoices are not cleaned up.
Controls service-period boundaries for monthly subscription and usage billing. Anniversary preserves contract-date boundaries; calendar month creates leading and trailing stubs.
anniversary- Contract anniversarycalendar_month- Calendar month
anniversary, calendar_month Controls evergreen subscription date boundaries. CONTRACT_PERIOD preserves contract billing-period alignment; EXACT_DATE uses the subscriptions' exact service dates.
CONTRACT_PERIOD- Contract billing periodEXACT_DATE- Exact service dates
CONTRACT_PERIOD, EXACT_DATE Contract-level default payment term for generated invoices. Currently applied only to automatically generated Evergreen invoices; other contract invoice flows retain their existing payment-term selection behavior. Support may be extended to additional contract types in the future.