# Chapter 4.3.10 - Proration

Source: https://developer.avalara.com/products/communications/integration-guides/dev-guide_rest_v2/customizing-transactions/sample-transactions/proration/

-   [Previous](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/private-line/)
-   [Next](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/transaction-information/)

The Proration (`pror`) key calculates prorated taxes on a transaction that represents a partial month of service. Percentage-based taxes are prorated by way of the charge (`chg`) amount passed. However, fixed and per line taxes are subject to special prorating rules and procedures. Some tax authorities allow sellers to prorate fixed and per line taxes for partial months, but many insist on receiving the full amount. REST v2 applies these rules automatically if the pro-rating feature is used. Just specify the percentage of the month the service was active as a decimal in the `pror` key.

A few things to keep in mind:

-   If prorating **is not** allowed on a tax, the full amount is taxed.
-   If prorating **is** allowed on a tax, the fixed or per line tax applicable to the service will be returned, multiplied by the percentage supplied.
-   Remove the Proration (`prop`) key from the [line item](/communications/dev-guide_rest_v2/reference/line-item) (`itms`) if you don't want to use Proration functionality. Setting `prop` to 0 means 0% proration for pro-rateable fixed taxes.

### Prorated Adjustments

If the proration is being used for an [adjustment credit](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/adjustment/) rather than a partial charge, the ratio of the percentage applied should reflect the portion of the month in which the service was not active.

Use the Pro-rated Adjustment Type (`proadj`) to tell Communications REST v2 how to handle the return of prorated adjusted fixed taxes.

-   `0` Default
-   `1` Don't return non-proratable fixed taxes in the response
-   `2` Return non-proratable fixed taxes in the response

#### Note

Proration functionality is not supported on a Tax Inclusive (`incl` set to `true`) [line item](/communications/dev-guide_rest_v2/reference/line-item/) (`itms`) or on line items with a [quantity](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/quantity/) (`qty`) greater than 1.

### Proration Example

Proration (`pror`) is set to 50% for 10 lines (`line`).

```json
{ "cmpn": { "bscl": 1, "svcl": 0, "fclt": false, "frch": false, "reg": false }, "inv": [ { "bill": { "pcd": 534300 }, "cust": 1, "lfln": false, "date": "2018-05-15T12:00:00Z", "itms": [ { "ref": "ProrationTest", "chg": 0, "line": 10, "sale": 1, "pror": 0.50, "tran": 7, "serv": 42 } ], "invm": false, "dtl": true, "summ": false } ]}
```

#### Response

The prorated tax amounts (`tax`) are seen on Tax Type IDs (`tid`) 6 and 23.

[View the Response JSON](#collapse1)

```json
{ "inv": [ { "itms": [ { "ref": "ProrationTest", "txs": [ { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "CONNECTIVITY CHARGES", "cid": 5, "name": "Telecom Relay Surcharge", "exm": 0, "lns": 10, "min": 0, "pcd": 534100, "rate": 0.1, "sur": true, "tax": 0.5, "lvl": 1, "tid": 23 }, { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "E-911 CHARGES", "cid": 7, "name": "E-911", "exm": 0, "lns": 10, "min": 0, "pcd": 534200, "rate": 0.4, "sur": false, "tax": 4, "lvl": 1, "tid": 10 }, { "bill": true, "cmpl": true, "tm": 0.5, "calc": 1, "cat": "EXCISE TAXES", "cid": 4, "name": "Federal Excise Tax", "exm": 0, "lns": 10, "min": 0, "pcd": 0, "rate": 0.03, "sur": false, "tax": 0.015, "lvl": 0, "tid": 6 } ] } ] } ]}
```

### Proration Adjustment Example

Proration (`pror`) is set to 50% for 10 lines (`line`) and the adjustment flag (`adj`) is set to `true`.

-   Line Item 001 (ProAdjTest-0) sets the Pro-rated Adjustment Type (`proadj`) to `0`
-   Line Item 002 (ProAdjTest-1) sets the Pro-rated Adjustment Type (`proadj`) to `1`
-   Line Item 003 (ProAdjTest-2) sets the Pro-rated Adjustment Type (`proadj`) to `2`

```json
{ "cmpn": { "bscl": 1, "svcl": 0, "fclt": false, "frch": false, "reg": false }, "inv": [ { "bill": { "pcd": 534300 }, "cust": 1, "lfln": false, "date": "2018-05-15T12:00:00Z", "itms": [ { "ref": "ProAdjTest-0", "chg": 0, "line": 10, "sale": 1, "pror": 0.50, "proadj": 0, "tran": 7, "serv": 42, "adj": true, "adjm": 0, "disc": 0 } , { "ref": "ProAdjTest-1", "chg": 0, "line": 10, "sale": 1, "pror": 0.50, "proadj": 1, "tran": 7, "serv": 42, "adj": true, "adjm": 0, "disc": 0 }, { "ref": "ProAdjTest-2", "chg": 0, "line": 10, "sale": 1, "pror": 0.50, "proadj": 2, "tran": 7, "serv": 42, "adj": true, "adjm": 0, "disc": 0 } ], "invm": false, "dtl": true, "summ": false } ]}
```

#### Response

The fixed tax amounts (`tax`) for Tax Type ID (`tid`) 10 are set to 0 when `proadj` is set to `0` and `1`. The fixed tax amount (`tax`) for Tax Type ID (`tid`) 10 is returned with the negative tax amount when `proadj` is set to `2`.  

[View the Response JSON](#collapse2)

```json
{ "inv": [ { "itms": [ { "ref": "ProAdjTest-0", "txs": [ { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "CONNECTIVITY CHARGES", "cid": 5, "name": "Telecom Relay Surcharge", "exm": 0, "lns": -10, "min": 0, "pcd": 534100, "rate": 0.1, "sur": true, "tax": -0.5, "lvl": 1, "tid": 23 }, { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "E-911 CHARGES", "cid": 7, "name": "E-911", "exm": 0, "lns": -10, "min": 0, "pcd": 534200, "rate": 0.4, "sur": false, "tax": 0, "lvl": 1, "tid": 10 }, { "bill": true, "cmpl": true, "tm": 0.5, "calc": 1, "cat": "EXCISE TAXES", "cid": 4, "name": "Federal Excise Tax", "exm": 0, "lns": -10, "min": 0, "pcd": 0, "rate": 0.03, "sur": false, "tax": -0.015, "lvl": 0, "tid": 6 } ] }, { "ref": "ProAdjTest-1", "txs": [ { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "CONNECTIVITY CHARGES", "cid": 5, "name": "Telecom Relay Surcharge", "exm": 0, "lns": -10, "min": 0, "pcd": 534100, "rate": 0.1, "sur": true, "tax": -0.5, "lvl": 1, "tid": 23 }, { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "E-911 CHARGES", "cid": 7, "name": "E-911", "exm": 0, "lns": -10, "min": 0, "pcd": 534200, "rate": 0.4, "sur": false, "tax": 0, "lvl": 1, "tid": 10 }, { "bill": true, "cmpl": true, "tm": 0.5, "calc": 1, "cat": "EXCISE TAXES", "cid": 4, "name": "Federal Excise Tax", "exm": 0, "lns": -10, "min": 0, "pcd": 0, "rate": 0.03, "sur": false, "tax": -0.015, "lvl": 0, "tid": 6 } ] }, { "ref": "ProAdjTest-2", "txs": [ { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "CONNECTIVITY CHARGES", "cid": 5, "name": "Telecom Relay Surcharge", "exm": 0, "lns": -10, "min": 0, "pcd": 534100, "rate": 0.1, "sur": true, "tax": -0.5, "lvl": 1, "tid": 23 }, { "bill": true, "cmpl": true, "tm": 0, "calc": 4, "cat": "E-911 CHARGES", "cid": 7, "name": "E-911", "exm": 0, "lns": -10, "min": 0, "pcd": 534200, "rate": 0.4, "sur": false, "tax": -4, "lvl": 1, "tid": 10 }, { "bill": true, "cmpl": true, "tm": 0.5, "calc": 1, "cat": "EXCISE TAXES", "cid": 4, "name": "Federal Excise Tax", "exm": 0, "lns": -10, "min": 0, "pcd": 0, "rate": 0.03, "sur": false, "tax": -0.015, "lvl": 0, "tid": 6 } ] } ] } ]}
```

### See Also

#### Input Objects

-   [`CalcTaxes` request](/communications/dev-guide_rest_v2/reference/calc-taxes-request/)
-   [Invoice](/communications/dev-guide_rest_v2/reference/invoice/)
-   [Line item](/communications/dev-guide_rest_v2/reference/line-item/)

#### Output Objects

-   [`CalcTaxes` response](/communications/dev-guide_rest_v2/reference/calc-taxes-response/)
-   [Detailed tax results](/communications/dev-guide_rest_v2/reference/detailed-tax-result/)

-   [Previous](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/private-line/)
-   [Next](/communications/dev-guide_rest_v2/customizing-transactions/sample-transactions/transaction-information/)