v1
latestOpenAPI 3.0.32026-07-1342625.4 MBTrigger a Self Assessment Tax Calculation
This endpoint allows the user to trigger a self assessment tax calculation for a given tax year. It should be called whenever income data is updated through a periodic or annual endpoint. To trigger a final declaration self assessment tax calculation, you must set the calculationType path parameter to intent-to-finalise.
A National Insurance number and tax year must be provided.
The tax calculation process is asynchronous, so it is recommended you wait at least 5 seconds before calling the retrieval endpoint. The result of the calculation can be seen using the “Retrieve a Self Assessment Tax Calculation” endpoint.
Test data
Scenario simulations using Gov-Test-Scenario headers is only available in the sandbox environment.
| Header Value (Gov-Test-Scenario) | Scenario |
|---|---|
| N/A - DEFAULT | Simulates success response. |
| NO_INCOME_SUBMISSIONS_EXIST | Simulates the scenario where no income submissions exist for the tax year. |
| FINAL_DECLARATION_RECEIVED | Simulates the scenario where a final declaration has already been received. |
| INCOME_SOURCES_CHANGED | Simulates the scenario where income sources data has changed. |
| RECENT_SUBMISSIONS_EXIST | Simulates the scenario where more recent submissions exist. |
| RESIDENCY_CHANGED | Simulates the scenario where residency has changed. |
| CALCULATION_IN_PROGRESS | Simulates the scenario where a calculation is in progress. |
| BUSINESS_VALIDATION_FAILURE | Simulates the scenario where there is a generic business validation rule failure. |
| TAX_YEAR_NOT_ENDED | Simulates the scenario where a triggering for a final declaration is performed before the tax year has ended. |
Path parameters
National Insurance number, in the format AA999999A
The tax year the data applies to, for example, 2021-22. The start year and end year must not span two tax years. The minimum tax year is 2017-18. No gaps are allowed, for example, 2020-22 is not valid.
Defines the calculation type requested.
Tax years 2023-24 & 2024-25 will accept the following values:
- in-year
- intent-to-finalise
Tax years 2025-26 onwards will accept the following values:
- in-year
- intent-to-finalise
- intent-to-amend
Headers
Specifies the response format and the version of the API to be used.
An OAuth 2.0 Bearer Token with the write:self-assessment scope.
Only in sandbox environment. See Test Data table for all header values.
Response
Success
Example response
{
"calculationId": "f2fb30e5-4ab6-4a29-b3c1-c7264259ff1c"
}