> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.tabs.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.tabs.com/_mcp/server.

# Create contract billing term

POST https://integrators.prod.api.tabsplatform.com/v3/contracts/{id}/billing-terms
Content-Type: application/json

Reference: https://docs.tabs.com/api-reference/contracts/createBillingTerm

## Authentication

- `Authorization` header (required)

## Request

### Path parameters

- `id` (string, required) — Contract Id

### Body (application/json)

- `billingStartDate` (string, required) — Billing start date
- `isRecurring` (boolean, required) — Is recurring billing
- `interval` (enum, required) — Interval unit
  - Allowed values: `NONE`, `DAY`, `MONTH`, `HOUR`, `YEAR`, `QUARTER`, `SEMI_MONTH`, `WEEK`
- `intervalFrequency` (double, required) — Interval frequency
- `invoiceDateStrategy` (enum, required) — Invoice date strategy
  - Allowed values: `FIRST_OF_PERIOD`, `LAST_OF_PERIOD`, `ARREARS`, `ADVANCED_DUE_START`
- `netPaymentTerms` (double, required) — Days between invoice issue and due date
- `quantity` (double, required) — Quantity; set to 0 for UNIT billingType
- `billingType` (enum, required) — Billing type
  - Allowed values: `UNIT`, `FLAT`
- `pricingType` (enum, required) — Pricing type. For TIERED and VOLUME, supply 2+ pricing entries with `tier` indices that are 0-indexed and contiguous (0, 1, 2, …) and `tierMinimum` values starting at 0 and strictly increasing.
  - Allowed values: `SIMPLE`, `TIERED`, `VOLUME`
- `pricing` (list of object, required) — Pricing tiers
  - `tier` (double, required) — Tier Number
  - `amount` (double, required) — Amount
  - `amountType` (enum, required) — Amount Type
    - Allowed values: `PER_ITEM`, `TOTAL_INVOICE`
  - `tierMinimum` (double, required) — Tier Minimum
- `name` (string, optional) — Line item name. Required unless `productId` is provided, in which case it is populated from the product's display name.
- `description` (string, optional) — Line item description
- `includeInArr` (boolean, optional) — Whether this billing term contributes to ARR (Annual Recurring Revenue). Defaults based on billing type and interval when omitted (usage and one-time terms default to false).
- `duration` (double, optional, default: 0) — Number of billing periods
- `eventTypeId` (string, optional) — Usage event type ID
- `itemId` (string, optional) — ERP item ID for the line item
- `productId` (string, optional, nullable) — Product ID from /v3/products. When set, name/description/itemId/classId are populated from the product for any not provided on the billing term. To ensure revenue reporting accuracy, associate the billing term with a product whenever applicable.
- `classId` (string, optional) — ERP class ID
- `departmentId` (string, optional) — Department ID
- `projectId` (string, optional) — Project ID
- `discount` (object, optional) — Discount configuration
  - `type` (enum, optional) — The type of discount
    - Allowed values: `PERCENTAGE`, `FIXED`
  - `amount` (string, optional) — The discount amount (stored as mantissa in database with exponent 0)
  - `note` (string, optional) — Optional note about the discount
- `billingTermGroupId` (string, optional) — Billing term group ID. If provided, the BT joins an existing group. If omitted, a new group is created.
- `seatConfig` (object, optional) — Seat-based billing configuration. When provided, the billing term is created as seat-based and seat changes are managed via the seat-amendment endpoints.
  - `isMovingMinimum` (boolean, required) — Whether we need to update minimums on a moving basis
  - `minQuantity` (double, required) — Minimum quantity to bill for, regardless of current # of seats
  - `defaultProrationPolicy` (enum, required) — Default proration policy
    - Allowed values: `NONE`, `DAY`, `MONTH`, `YEAR`
  - `defaultTrueUpTiming` (enum, required) — Default true up timing
    - Allowed values: `IMMEDIATE`, `CO_TERM`

## Response

### 201

Billing term created

- `payload` (object, required) — Response payload, will be empty when success is false
  - `billingStartDate` (string, required) — Billing start date
  - `isRecurring` (boolean, required) — Is recurring billing
  - `interval` (enum, required) — Interval unit
    - Allowed values: `NONE`, `DAY`, `MONTH`, `HOUR`, `YEAR`, `QUARTER`, `SEMI_MONTH`, `WEEK`
  - `intervalFrequency` (double, required) — Interval frequency
  - `netPaymentTerms` (double, required) — Days between invoice issue and due date
  - `quantity` (double, required) — Quantity; set to 0 for UNIT billingType
  - `billingType` (enum, required) — Billing type
    - Allowed values: `UNIT`, `FLAT`
  - `pricingType` (enum, required) — Pricing type. For TIERED and VOLUME, supply 2+ pricing entries with `tier` indices that are 0-indexed and contiguous (0, 1, 2, …) and `tierMinimum` values starting at 0 and strictly increasing.
    - Allowed values: `SIMPLE`, `TIERED`, `VOLUME`
  - `id` (string, required) — Billing term ID
  - `contractId` (string, required) — Contract ID
  - `name` (string, required) — Billing term name. Populated from the linked product's display name when not set on the billing term.
  - `billingEndDate` (string, required) — Billing end date
  - `createdAt` (string, required) — Created at
  - `description` (string, optional) — Line item description
  - `includeInArr` (boolean, optional) — Whether this billing term contributes to ARR (Annual Recurring Revenue). Defaults based on billing type and interval when omitted (usage and one-time terms default to false).
  - `duration` (double, optional, default: 0) — Number of billing periods
  - `eventTypeId` (string, optional) — Usage event type ID
  - `itemId` (string, optional) — ERP item ID for the line item
  - `productId` (string, optional, nullable) — Product ID from /v3/products. When set, name/description/itemId/classId are populated from the product for any not provided on the billing term. To ensure revenue reporting accuracy, associate the billing term with a product whenever applicable.
  - `classId` (string, optional) — ERP class ID
  - `departmentId` (string, optional) — Department ID
  - `projectId` (string, optional) — Project ID
  - `billingTermGroupId` (string, optional) — Billing term group ID. If provided, the BT joins an existing group. If omitted, a new group is created.
  - `seatConfig` (object, optional) — Seat-based billing configuration. When provided, the billing term is created as seat-based and seat changes are managed via the seat-amendment endpoints.
    - `isMovingMinimum` (boolean, required) — Whether we need to update minimums on a moving basis
    - `minQuantity` (double, required) — Minimum quantity to bill for, regardless of current # of seats
    - `defaultProrationPolicy` (enum, required) — Default proration policy
      - Allowed values: `NONE`, `DAY`, `MONTH`, `YEAR`
    - `defaultTrueUpTiming` (enum, required) — Default true up timing
      - Allowed values: `IMMEDIATE`, `CO_TERM`
- `success` (boolean, required) — Boolean with true=success, false=failure
- `message` (string, required) — Plain-text description of the result
- `error` (object, required) — json element with any error messages or warnings
  - `code` (double, required) — API response code
  - `message` (string, required) — API response message
  - `details` (object, optional) — Additional details about the error

## Examples

**Request**

```json
{
  "billingStartDate": "2025-01-01",
  "isRecurring": true,
  "interval": "MONTH",
  "intervalFrequency": 1,
  "invoiceDateStrategy": "FIRST_OF_PERIOD",
  "netPaymentTerms": 30,
  "quantity": 1,
  "billingType": "FLAT",
  "pricingType": "SIMPLE",
  "pricing": [
    {
      "tier": 0,
      "amount": 10000,
      "amountType": "TOTAL_INVOICE",
      "tierMinimum": 0
    }
  ]
}
```

**Response**

```json
{
  "payload": {
    "billingStartDate": "2025-01-01",
    "isRecurring": true,
    "interval": "MONTH",
    "intervalFrequency": 1,
    "netPaymentTerms": 30,
    "quantity": 1,
    "billingType": "FLAT",
    "pricingType": "SIMPLE",
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "contractId": "123e4567-e89b-12d3-a456-426614174000",
    "name": "Annual Platform License",
    "billingEndDate": "2026-01-01",
    "createdAt": "2024-06-01T12:00:00Z",
    "description": "Enterprise platform license",
    "includeInArr": true,
    "duration": 0,
    "eventTypeId": "123e4567-e89b-12d3-a456-426614174000",
    "itemId": "d4e5f6a7-8901-4abc-8def-555555555555",
    "productId": "c5f6a7b8-9012-4abc-8def-444444444444",
    "classId": "e5f6a7b8-9012-4abc-8def-666666666666",
    "departmentId": "e5f6a7b8-9012-4abc-8def-777777777777",
    "projectId": "f6a7b8c9-0123-4abc-8def-888888888888",
    "billingTermGroupId": "f0e1d2c3-4567-4abc-8def-222222222222",
    "seatConfig": {
      "isMovingMinimum": false,
      "minQuantity": 0,
      "defaultProrationPolicy": "NONE",
      "defaultTrueUpTiming": "IMMEDIATE"
    }
  },
  "success": true,
  "message": "Billing term created successfully",
  "error": {
    "code": 0,
    "message": "",
    "details": {}
  }
}
```

**SDK Code**

```python
import requests

url = "https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms"

payload = {
    "billingStartDate": "2025-01-01",
    "isRecurring": True,
    "interval": "MONTH",
    "intervalFrequency": 1,
    "invoiceDateStrategy": "FIRST_OF_PERIOD",
    "netPaymentTerms": 30,
    "quantity": 1,
    "billingType": "FLAT",
    "pricingType": "SIMPLE",
    "pricing": [
        {
            "tier": 0,
            "amount": 10000,
            "amountType": "TOTAL_INVOICE",
            "tierMinimum": 0
        }
    ]
}
headers = {
    "Authorization": "<apiKey>",
    "Content-Type": "application/json"
}

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

print(response.json())
```

```javascript
const url = 'https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms';
const options = {
  method: 'POST',
  headers: {Authorization: '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"billingStartDate":"2025-01-01","isRecurring":true,"interval":"MONTH","intervalFrequency":1,"invoiceDateStrategy":"FIRST_OF_PERIOD","netPaymentTerms":30,"quantity":1,"billingType":"FLAT","pricingType":"SIMPLE","pricing":[{"tier":0,"amount":10000,"amountType":"TOTAL_INVOICE","tierMinimum":0}]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms"

	payload := strings.NewReader("{\n  \"billingStartDate\": \"2025-01-01\",\n  \"isRecurring\": true,\n  \"interval\": \"MONTH\",\n  \"intervalFrequency\": 1,\n  \"invoiceDateStrategy\": \"FIRST_OF_PERIOD\",\n  \"netPaymentTerms\": 30,\n  \"quantity\": 1,\n  \"billingType\": \"FLAT\",\n  \"pricingType\": \"SIMPLE\",\n  \"pricing\": [\n    {\n      \"tier\": 0,\n      \"amount\": 10000,\n      \"amountType\": \"TOTAL_INVOICE\",\n      \"tierMinimum\": 0\n    }\n  ]\n}")

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

	req.Header.Add("Authorization", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms")

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

request = Net::HTTP::Post.new(url)
request["Authorization"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"billingStartDate\": \"2025-01-01\",\n  \"isRecurring\": true,\n  \"interval\": \"MONTH\",\n  \"intervalFrequency\": 1,\n  \"invoiceDateStrategy\": \"FIRST_OF_PERIOD\",\n  \"netPaymentTerms\": 30,\n  \"quantity\": 1,\n  \"billingType\": \"FLAT\",\n  \"pricingType\": \"SIMPLE\",\n  \"pricing\": [\n    {\n      \"tier\": 0,\n      \"amount\": 10000,\n      \"amountType\": \"TOTAL_INVOICE\",\n      \"tierMinimum\": 0\n    }\n  ]\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms")
  .header("Authorization", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"billingStartDate\": \"2025-01-01\",\n  \"isRecurring\": true,\n  \"interval\": \"MONTH\",\n  \"intervalFrequency\": 1,\n  \"invoiceDateStrategy\": \"FIRST_OF_PERIOD\",\n  \"netPaymentTerms\": 30,\n  \"quantity\": 1,\n  \"billingType\": \"FLAT\",\n  \"pricingType\": \"SIMPLE\",\n  \"pricing\": [\n    {\n      \"tier\": 0,\n      \"amount\": 10000,\n      \"amountType\": \"TOTAL_INVOICE\",\n      \"tierMinimum\": 0\n    }\n  ]\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms', [
  'body' => '{
  "billingStartDate": "2025-01-01",
  "isRecurring": true,
  "interval": "MONTH",
  "intervalFrequency": 1,
  "invoiceDateStrategy": "FIRST_OF_PERIOD",
  "netPaymentTerms": 30,
  "quantity": 1,
  "billingType": "FLAT",
  "pricingType": "SIMPLE",
  "pricing": [
    {
      "tier": 0,
      "amount": 10000,
      "amountType": "TOTAL_INVOICE",
      "tierMinimum": 0
    }
  ]
}',
  'headers' => [
    'Authorization' => '<apiKey>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"billingStartDate\": \"2025-01-01\",\n  \"isRecurring\": true,\n  \"interval\": \"MONTH\",\n  \"intervalFrequency\": 1,\n  \"invoiceDateStrategy\": \"FIRST_OF_PERIOD\",\n  \"netPaymentTerms\": 30,\n  \"quantity\": 1,\n  \"billingType\": \"FLAT\",\n  \"pricingType\": \"SIMPLE\",\n  \"pricing\": [\n    {\n      \"tier\": 0,\n      \"amount\": 10000,\n      \"amountType\": \"TOTAL_INVOICE\",\n      \"tierMinimum\": 0\n    }\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = [
  "billingStartDate": "2025-01-01",
  "isRecurring": true,
  "interval": "MONTH",
  "intervalFrequency": 1,
  "invoiceDateStrategy": "FIRST_OF_PERIOD",
  "netPaymentTerms": 30,
  "quantity": 1,
  "billingType": "FLAT",
  "pricingType": "SIMPLE",
  "pricing": [
    [
      "tier": 0,
      "amount": 10000,
      "amountType": "TOTAL_INVOICE",
      "tierMinimum": 0
    ]
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://integrators.prod.api.tabsplatform.com/v3/contracts/123e4567-e89b-12d3-a456-426614174000/billing-terms")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```