Property Business (MTD) API
Date | Amount |
---|---|
Version and status | |
Available in Sandbox | Yes |
Sandbox base URL | https://test-api.service.hmrc.gov.uk |
Available in Production | Yes |
Production base URL | https://api.service.hmrc.gov.uk |
Overview
This API allows developers to:
- list, retrieve, create or amend an individual’s UK Property Income & Expenses Period Summaries
- retrieve, create, amend or delete an individual’s UK Property Annual Submissions
- list, retrieve, create or amend an individual’s Foreign Property Income & Expenses Period Summaries
- retrieve, create, amend or delete an individual’s Foreign Property Annual Submissions
- retrieve, create, amend or delete an individual’s Historic FHL and Non-FHL UK Property Business Annual Submissions
- list, retrieve, create or amend an individual’s Historic FHL and Non-FHL UK Property Business Income & Expenses Period Summaries
The “historic” endpoints are for data relating to tax years from 2017-18 to 2021-22. For later years, use the standard endpoints.
For information on how to connect to this API see the Income Tax MTD end-to-end service guide.
Errors
We use standard HTTP status codes to show whether an API request succeeded or not. They are usually in the range:
- 200 to 299 if it succeeded, including code 202 if it was accepted by an API that needs to wait for further action
- 400 to 499 if it failed because of a client error by your application
- 500 to 599 if it failed because of an error on our server
Errors specific to each API are shown in the Endpoints section, under Response. See our reference guide for more on errors.
Single errors will be returned in the following format:
{
"code": "FORMAT_FIELD_NAME",
"message": "The provided FieldName is invalid"
}
Where possible, multiple errors will be returned with INVALID_REQUEST
in the following format:
{
"code": "INVALID_REQUEST",
"message": "Invalid request",
"errors": [
{
"code": "RULE_FIELD_NAME",
"message": "The provided FieldName is not allowed"
},
{
"code": "FORMAT_FIELD_NAME",
"message": "The provided FieldName is invalid"
}
]
}
Testing
You can use the sandbox environment to test this API. You can use the Create Test User API or it's frontend service to create test users.
It may not be possible to test all scenarios in the sandbox. You can test some scenarios by passing the Gov-Test-Scenario header. Documentation for each endpoint includes a Test data section, which explains the scenarios that you can simulate using the Gov-Test-Scenario header.
For versions 2.0 and later, Gov-Test-Scenario values that are not supported by the sandbox will result in a status code 400 response with an error code of RULE_INCORRECT_GOV_TEST_SCENARIO.
If you have a specific testing need that is not supported in the sandbox, contact our support team.
Some APIs may be marked [test only]. This means that they are not available for use in production and may change.
Versioning
Endpoints
The way we show Property Business (MTD) API v2.0 endpoints has changed, which might look different to other Developer Hub APIs.
The API has not changed. You do not need to make any updates to your application if you already use this API.