This version is in beta - expect some breaking changes.

CIS Deductions (MTD) API

Dates and amounts
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

Under the Construction Industry Scheme (CIS), contractors deduct money from a subcontractor’s payments and pass it to HM Revenue and Customs (HMRC). The deductions count as advance payments towards the subcontractor’s tax and National Insurance.

This API allows the developer to:

  • retrieve details of the data the contractor has submitted to HMRC
  • retrieve a list of CIS deductions
  • create CIS deductions
  • remove CIS deductions
  • override previous CIS deductions (after the tax year has ended)

For information on how to connect to this API see the Income Tax MTD end-to-end service guide.

Versioning

When an API changes in a way that is backwards-incompatible, we increase the version number of the API. See our reference guide for more on versioning.

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"         }     ] }

Changelog

You can find the changelog in the income-tax-mtd-changelog GitHub wiki.

Support

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.

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.

Skip to main content

Endpoints

/individuals/deductions/cis/{nino}/current-position

Retrieve CIS Deductions for Subcontractor
GET

This endpoint allows a developer to retrieve a customer's latest CIS deductions data and whether it was submitted by a contractor or user. A National Insurance number and submission ID must be provided.

Authorisation

This endpoint is user-restricted and requires an Authorization header containing an OAuth 2.0 Bearer Token with the read:self-assessment scope.

Path parameters

Path parameters table
Name Description
nino
string
required

National Insurance number in the format AA999999A.

For example: TC663795B

Query parameters

Query parameters table
Name Description
fromDate
string
required

CIS tax year start date.

Date in the format: YYYY-MM-DD

For example: 2020-04-06

toDate
string
required

CIS tax year end date.

Date in the format: YYYY-MM-DD

For example: 2021-04-05

source
string
optional

The source of amended data. Defaults to all. Limited to the following possible values:

  • all
  • contractor
  • customer

Request headers

Request headers Table
Name Description
Accept
required

Specifies the response format and the version of the API to be used.

For example: application/vnd.hmrc.1.0+json
Gov-Test-Scenario
optional

Only in sandbox environment. See Test Data table for all header values.

For example: -
Content-Type
required

Specifies the format of the request body, which must be JSON.

For example: application/json
Authorization
required
An OAuth 2.0 Bearer Token with the read:self-assessment scope.

For example: Bearer bb7fed3fe10dd235a2ccda3d50fb

See also fraud prevention.

Response headers

Response headers Table
Name Description
X-CorrelationId
required

Unique ID for operation tracking
String, 36 characters.

For example: c75f40a6-a3df-4429-a697-471eeec46435

See also fraud prevention.

Response

HTTP status: 200 (OK)

{
  "totalDeductionAmount": 12345.56,
  "totalCostOfMaterials": 234234.33,
  "totalGrossAmountPaid": 2342424.56,
  "cisDeductions" : [
    {
      "fromDate": "2020-04-06",
      "toDate": "2021-04-05",
      "contractorName": "contractor Name",
      "employerRef": "123/AA12345",
      "totalDeductionAmount": 3543.55,
      "totalCostOfMaterials": 6644.67,
      "totalGrossAmountPaid": 3424.12,
      "periodData": [
        {
          "deductionFromDate": "2020-04-06",
          "deductionToDate": "2020-05-05",
          "deductionAmount": 4654.78,
          "costOfMaterials": 4564.89,
          "grossAmountPaid": 7878.67,
          "submissionDate": "2020-05-11T16:38:57Z",
          "submissionId": "4557ecb5-fd32-48cc-81f5-e6acd1099f3c",
          "source": "customer"
        },
        {
          "deductionFromDate": "2020-05-06",
          "deductionToDate": "2020-06-05",
          "deductionAmount": 355.00,
          "costOfMaterials": 35.00,
          "grossAmountPaid": 1457.00,
          "submissionDate": "2020-05-11T16:38:57Z",
          "source": "contractor"
        }
      ],
      "links":[
        {
          "href":"individuals/deductions/cis/TC663795B/amendments/4557ecb5-fd32-48cc-81f5-e6acd1099f3c",
          "rel":"delete-cis-deductions-for-subcontractor",
          "method":"DELETE"
        },
        {
          "href":"individuals/deductions/cis/TC663795B/amendments/4557ecb5-fd32-48cc-81f5-e6acd1099f3c",
          "rel":"amend-cis-deductions-for-subcontractor",
          "method":"PUT"
        }
      ]
    },
    {
      "fromDate": "2020-04-06",
      "toDate": "2021-04-05",
      "contractorName": "Soylent Solutions",
      "employerRef": "123/TW44355",
      "totalDeductionAmount": 3543.55,
      "totalCostOfMaterials": 6644.67,
      "totalGrossAmountPaid": 3424.12,
      "periodData": [
        {
          "deductionFromDate": "2020-07-06",
          "deductionToDate": "2020-08-05",
          "deductionAmount": 60.00,
          "costOfMaterials": 35.00,
          "grossAmountPaid": 1457.00,
          "submissionDate": "2020-05-11T16:38:57Z",
          "source": "contractor"
        },
        {
          "deductionFromDate": "2020-09-06",
          "deductionToDate": "2020-10-05",
          "deductionAmount": 60.00,
          "costOfMaterials": 35.00,
          "grossAmountPaid": 1457.00,
          "submissionDate": "2020-05-11T16:38:57Z",
          "source": "contractor"
        }
      ]
    }
  ],
  "links":[
    {
      "href": "individuals/deductions/cis/TC663795B/current-position?fromDate=2020-04-06&toDate=2021-04-05&source=all",
      "rel": "self",
      "method": "GET"
    },
    {
      "href":"individuals/deductions/cis/TC663795B/amendments",
      "rel":"create-cis-deductions-for-subcontractor",
      "method":"POST"
    }
  ]
}

Response table
Name Description
totalDeductionAmount
number
optional

The total amount of tax deducted by CIS contractors. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

totalCostOfMaterials
number
optional

The total cost of materials incurred under CIS by the subcontractor across all of the CIS contractors that they worked for. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

totalGrossAmountPaid
number
optional

The total gross amount paid by CIS contractors. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

cisDeductions
array
required

List of the components that make up the overall deductions.

fromDate
string
required

CIS start date of a tax year.

For example: 2020-04-06

toDate
string
required

CIS end date of a tax year.

For example: 2021-04-05

contractorName
string
optional

The name of the contractor the subcontractor worked for.

employerRef
string
required

A unique identifier, the contractor reference number.

Must conform to the regular expression ^[0-9]{3}\/[^ ].{0,9}$

For example: 123/AC80213

totalDeductionAmount
number
optional

The total amount of tax deducted by a CIS contractor. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

totalCostOfMaterials
number
optional

The total cost of materials incurred under CIS by the subcontractor. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

totalGrossAmountPaid
number
optional

The total gross amount paid by a CIS contractor. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

periodData
array
required

List of the components that make up the overall deductions.

deductionFromDate
string
required

The From date when the deduction was made within the CIS tax year period.

For example: 2020-07-06

deductionToDate
string
required

The To date when the deduction was made within the CIS tax year period.

For example: 2020-08-05

deductionAmount
number
optional

The amount of tax deducted by the contractor. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

costOfMaterials
number
optional

The cost of materials incurred under CIS. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 50.00

grossAmountPaid
number
optional

The gross amount paid under CIS. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

submissionDate
string
required

The date the deduction was submitted.

For example: 2020-05-11T16:38:57Z

submissionId
string
optional

The unique identifier for the submission.

For example: 4557ecb5-fd32-48cc-81f5-e6acd1099f3c

source
string
required

The source of the data.

For example: customer or contractor

links
array
optional

A list of endpoint links that indicate possible actions related to the current resource

href
string
required

The relative url of the endpoint

For example: individuals/deductions/cis/{nino}/current-position

rel
string
required

A label for the endpoint, which describes how it is related to the current resource. The rel will be self where the action is retrieval of the same resource

For example: retrieve-cis-deductions-for-subcontractor

method
string
required

The HTTP method type for the endpoint

For example: GET

links
array
required

A list of endpoint links that indicate possible actions related to the current resource

href
string
required

The relative url of the endpoint

For example: individuals/deductions/cis/{nino}/current-position

rel
string
required

A label for the endpoint, which describes how it is related to the current resource. The rel will be self where the action is retrieval of the same resource

For example: retrieve-cis-deductions-for-subcontractor

method
string
required

The HTTP method type for the endpoint

For example: GET

Error scenarios

Error scenarios table
Scenario HTTP status Code

The format of the supplied NINO field is not valid

400 (Bad Request)

FORMAT_NINO

The From date is not a valid format

400 (Bad Request)

FORMAT_FROM_DATE

The From date parameter is missing

400 (Bad Request)

MISSING_FROM_DATE

The To date is not a valid format

400 (Bad Request)

FORMAT_TO_DATE

The To date parameter is missing

400 (Bad Request)

MISSING_TO_DATE

The source of data should be one of these All (Blended view), Customer or Contractor

400 (Bad Request)

RULE_SOURCE_INVALID

The remote endpoint has indicated that no data can be found for the given period.

404 (Not Found)

MATCHING_RESOURCE_NOT_FOUND

The specified date range is invalid

403 (Forbidden)

RULE_DATE_RANGE_INVALID

The specified date range is outside the allowable tax years (the current tax year minus four years).

403 (Forbidden)

RULE_DATE_RANGE_OUT_OF_DATE

The client or agent is not authorised. This is because: the client is not subscribed to MTD, the agent is not subscribed to Agent Services, or the client has not authorised the agent to act on their behalf

403 (Forbidden)

CLIENT_OR_AGENT_NOT_AUTHORISED

For error scenarios that are common across all APIs, and for error formats, see our reference guide.

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

Simulate success response with customer and contractor deductions.

N/A - DEFAULT
using source all

Simulate success response with customer and contractor deductions.

N/A - DEFAULT
using source contractor

Simulate success response with contractor deductions.

N/A - DEFAULT
using source customer

Simulate success response with customer deductions.

DATE_RANGE_OUT_OF_DATE

Simulate error when retrieving data which is outside the allowable tax years.

NOT_FOUND

Simulate the scenario where no data is found.


Close Section
/individuals/deductions/cis/{nino}/amendments

Create CIS Deductions for Subcontractor
POST

This endpoint allows a developer to create a customer’s CIS deductions that have been previously populated. A National Insurance number must be provided.

Authorisation

This endpoint is user-restricted and requires an Authorization header containing an OAuth 2.0 Bearer Token with the write:self-assessment scope.

Path parameters

Path parameters table
Name Description
nino
string
required

National Insurance number in the format AA999999A.

For example: TC663795B

Request headers

Request headers Table
Name Description
Accept
required

Specifies the response format and the version of the API to be used.

For example: application/vnd.hmrc.1.0+json
Gov-Test-Scenario
optional

Only in sandbox environment. See Test Data table for all header values.

For example: -
Content-Type
required

Specifies the format of the request body, which must be JSON.

For example: application/json
Authorization
required
An OAuth 2.0 Bearer Token with the write:self-assessment scope.

For example: Bearer bb7fed3fe10dd235a2ccda3d50fb

See also fraud prevention.

Request

Scenario: Create CIS request

{
  "fromDate": "2020-04-06",
  "toDate": "2021-04-05",
  "contractorName": "ContractorA",
  "employerRef": "123/AB56797",
  "periodData": [
    {
      "deductionAmount": 355.00,
      "deductionFromDate": "2020-06-06",
      "deductionToDate": "2020-07-05",
      "costOfMaterials": 35.00,
      "grossAmountPaid": 1457.00
    }
  ]
}

Request table
Name Description
fromDate
string
required

CIS tax year start date. The minimum tax year is 2020-21. The minimum tax year in Sandbox is 2019-20.

For example: 2020-04-06

toDate
string
required

CIS tax year end date. The minimum tax year is 2020-21. The minimum tax year in Sandbox is 2019-20.

For example: 2021-04-05

contractorName
string
required

The name of the contractor the subcontractor worked for.

employerRef
string
required

A unique identifier, the contractor reference number.

Must conform to the regular expression ^[0-9]{3}\/[^ ].{0,9}$

For example: 123/AB56797

periodData
array
required

List of items that make up the overall deductions.

deductionAmount
number
required

The amount of tax deducted by the contractor. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

deductionFromDate
string
required

The From date when the deduction was made within the CIS tax year period.

For example: 2020-07-06

deductionToDate
string
required

The To date when the deduction was made within the CIS tax year period.

For example: 2020-08-05

costOfMaterials
number
optional

The cost of materials incurred under CIS. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

grossAmountPaid
number
optional

The gross amount paid under CIS. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

Response headers

Response headers Table
Name Description
X-CorrelationId
required

Unique ID for operation tracking
String, 36 characters.

For example: c75f40a6-a3df-4429-a697-471eeec46435

See also fraud prevention.

Response

HTTP status: 200 (OK)

{
  "submissionId": "db854aaa-65dc-488c-9120-e63fea14b9f1",
  "links": [
    {
      "href": "/individuals/deductions/cis/TC663795B/current-position?fromDate=2020-04-06&toDate=2021-04-05",
      "rel": "retrieve-cis-deductions-for-subcontractor",
      "method": "GET"
    }
  ]
}

Response table
Name Description
submissionId
string
required

A unique identifier for the customer provided CIS deduction amendment.

Must conform to the regular expression ^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$

For example: ab123aaa-65ab-488c-9120-f63abc14b9n1

links
array
optional

A list of endpoint links that indicate possible actions related to the current resource

href
string
required

The relative url of the endpoint

For example: /individuals/deductions/cis/{nino}/current-position

rel
string
required

A label for the endpoint, which describes how it is related to the current resource. The rel will be self where the action is retrieval of the same resource

For example: retrieve-cis-deductions-for-subcontractor

method
string
required

The HTTP method type for the endpoint

For example: GET

Error scenarios

Error scenarios table
Scenario HTTP status Code

The format of the supplied NINO field is not valid

400 (Bad Request)

FORMAT_NINO

An empty or non-matching body was submitted

400 (Bad Request)

RULE_INCORRECT_OR_EMPTY_BODY_SUBMITTED

The deductions From date is not a valid date format

400 (Bad Request)

FORMAT_DEDUCTIONS_FROM_DATE

The deductions To date is not a valid date format

400 (Bad Request)

FORMAT_DEDUCTIONS_TO_DATE

The format of the Employer Reference number is invalid

400 (Bad Request)

FORMAT_EMPLOYER_REFERENCE

The From date is not a valid format

400 (Bad Request)

FORMAT_FROM_DATE

The To date is not a valid format

400 (Bad Request)

FORMAT_TO_DATE

The deductions amount should be a positive number less than 99999999999.99 up to 2 decimal places.

400 (Bad Request)

RULE_DEDUCTIONS_AMOUNT

The cost of materials should be a positive number less than 99999999999.99 up to 2 decimal places

400 (Bad Request)

RULE_COST_OF_MATERIALS

The gross amount should be a positive number less than 99999999999.99 up to 2 decimal places

400 (Bad Request)

RULE_GROSS_AMOUNT_PAID

The specified tax year is not supported. That is, the tax year specified is before the minimum tax year value.

400 (Bad Request)

RULE_TAX_YEAR_NOT_SUPPORTED

The specified date range is invalid

403 (Forbidden)

RULE_DATE_RANGE_INVALID

The deductions periods do not align with the tax year supplied

403 (Forbidden)

RULE_UNALIGNED_DEDUCTIONS_PERIOD

The deductions period does not align from the 6th of one month to the 5th of the following month

403 (Forbidden)

RULE_DEDUCTIONS_DATE_RANGE_INVALID

The submission has been made before the tax year has ended

403 (Forbidden)

RULE_TAX_YEAR_NOT_ENDED

CIS deductions already exists for this tax year

403 (Forbidden)

RULE_DUPLICATE_SUBMISSION

More than one deduction period has been supplied for the same month or period

403 (Forbidden)

RULE_DUPLICATE_PERIOD

The client or agent is not authorised. This is because: the client is not subscribed to MTD, the agent is not subscribed to Agent Services, or the client has not authorised the agent to act on their behalf

403 (Forbidden)

CLIENT_OR_AGENT_NOT_AUTHORISED

For error scenarios that are common across all APIs, and for error formats, see our reference guide.

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

Simulate success response.

DEDUCTIONS_DATE_RANGE_INVALID

Simulate the scenario where the deductions period does not align from the 6th of one month to the 5th of the following month.

UNALIGNED_DEDUCTIONS_PERIOD

Simulate the scenario where the deductions periods do not align with the tax year supplied.

TAX_YEAR_NOT_ENDED

Simulate the scenario where the submission is for tax year that has not ended.

DUPLICATE_SUBMISSION

Simulate the scenario where CIS deductions already exists for this tax year.

DUPLICATE_PERIOD

Simulate the scenario where CIS deductions already exists for this period.


Close Section
/individuals/deductions/cis/{nino}/amendments/{submissionId}

Amend CIS Deductions for Subcontractor
PUT

This endpoint allows a developer to amend a customer’s CIS deductions data that has been previously populated. A National Insurance number and submission ID must be provided.

Authorisation

This endpoint is user-restricted and requires an Authorization header containing an OAuth 2.0 Bearer Token with the write:self-assessment scope.

Path parameters

Path parameters table
Name Description
nino
string
required

National Insurance number in the format AA999999A.

For example: TC663795B

submissionId
string
required

A unique identifier for the customer provided CIS deduction amendment.

For example: 4557ecb5-fd32-48cc-81f5-e6acd1099f3c

Request headers

Request headers Table
Name Description
Accept
required

Specifies the response format and the version of the API to be used.

For example: application/vnd.hmrc.1.0+json
Gov-Test-Scenario
optional

Only in sandbox environment. See Test Data table for all header values.

For example: -
Content-Type
required

Specifies the format of the request body, which must be JSON.

For example: application/json
Authorization
required
An OAuth 2.0 Bearer Token with the write:self-assessment scope.

For example: Bearer bb7fed3fe10dd235a2ccda3d50fb

See also fraud prevention.

Request

Scenario: Amend CIS request

{
  "periodData": [
    {
      "deductionAmount": 355.00,
      "deductionFromDate": "2020-06-06",
      "deductionToDate": "2020-07-05",
      "costOfMaterials": 35.00,
      "grossAmountPaid": 1457.00
    },
    {
      "deductionAmount": 355.00,
      "deductionFromDate": "2020-07-06",
      "deductionToDate": "2020-08-05",
      "costOfMaterials": 35.00,
      "grossAmountPaid": 1457.00
    }
  ]
}

Request table
Name Description
periodData
array
required

List of the components that make up the overall deductions.

deductionAmount
number
required

The amount of tax deducted by the contractor. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

deductionFromDate
string
required

The From date when the deduction was made within the CIS tax year period.

For example: 2020-04-06

deductionToDate
string
required

The To date when the deduction was made within the CIS tax year period.

For example: 2020-04-05

costOfMaterials
number
optional

The cost of materials incurred under CIS. This value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

grossAmountPaid
number
optional

The gross amount paid under CIS. The value must be between 0 and 99999999999.99 up to 2 decimal places.

For example: 5000.99

Response headers

Response headers Table
Name Description
X-CorrelationId
required

Unique ID for operation tracking
String, 36 characters.

For example: c75f40a6-a3df-4429-a697-471eeec46435

See also fraud prevention.

Response

HTTP status: 204 (No Content)

Error scenarios

Error scenarios table
Scenario HTTP status Code

The format of the supplied NINO field is not valid

400 (Bad Request)

FORMAT_NINO

An empty or non-matching body was submitted

400 (Bad Request)

RULE_INCORRECT_OR_EMPTY_BODY_SUBMITTED

The deductions From date is not a valid date format

400 (Bad Request)

FORMAT_DEDUCTIONS_FROM_DATE

The deductions To date is not a valid date format

400 (Bad Request)

FORMAT_DEDUCTIONS_TO_DATE

The deductions amount should be a positive number less than 99999999999.99 up to 2 decimal places.

400 (Bad Request)

RULE_DEDUCTIONS_AMOUNT

The cost of materials should be a positive number less than 99999999999.99 up to 2 decimal places

400 (Bad Request)

RULE_COST_OF_MATERIALS

The gross amount should be a positive number less than 99999999999.99 up to 2 decimal places

400 (Bad Request)

RULE_GROSS_AMOUNT_PAID

The format of the submission ID is not valid.

400 (Bad Request)

FORMAT_SUBMISSION_ID

The deductions period does not align from the 6th of one month to the 5th of the following month

403 (Forbidden)

RULE_DEDUCTIONS_DATE_RANGE_INVALID

The deductions periods do not align with the tax year supplied

403 (Forbidden)

RULE_UNALIGNED_DEDUCTIONS_PERIOD

More than one deduction period has been supplied for the same month or period

403 (Forbidden)

RULE_DUPLICATE_PERIOD

The client or agent is not authorised. This is because: the client is not subscribed to MTD, the agent is not subscribed to Agent Services, or the client has not authorised the agent to act on their behalf

403 (Forbidden)

CLIENT_OR_AGENT_NOT_AUTHORISED

The remote endpoint has indicated that no data can be found for the given period.

404 (Not Found)

MATCHING_RESOURCE_NOT_FOUND

For error scenarios that are common across all APIs, and for error formats, see our reference guide.

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

Simulate success response.

DEDUCTIONS_DATE_RANGE_INVALID

Simulate the scenario where the deductions period does not align from the 6th of one month to the 5th of the following month.

UNALIGNED_DEDUCTIONS_PERIOD

Simulate the scenario where the deductions periods do not align with the tax year supplied.

DUPLICATE_PERIOD

Simulate the scenario where CIS deductions already exists for this period.

NOT_FOUND

Simulate the scenario where the CIS deduction was not found.


Close Section
/individuals/deductions/cis/{nino}/amendments/{submissionId}

Delete CIS Deductions for Subcontractor
DELETE

This endpoint allows a developer to remove a customer’s CIS deductions data that has been previously populated. A National Insurance number and submission ID must be provided.

Authorisation

This endpoint is user-restricted and requires an Authorization header containing an OAuth 2.0 Bearer Token with the write:self-assessment scope.

Path parameters

Path parameters table
Name Description
nino
string
required

National Insurance number in the format AA999999A.

For example: TC663795B

submissionId
string
required

A unique identifier for the customer provided CIS deduction amendment.

For example: 4557ecb5-fd32-48cc-81f5-e6acd1099f3c

Request headers

Request headers Table
Name Description
Accept
required

Specifies the response format and the version of the API to be used.

For example: application/vnd.hmrc.1.0+json
Gov-Test-Scenario
optional

Only in sandbox environment. See Test Data table for all header values.

For example: -
Content-Type
required

Specifies the format of the request body, which must be JSON.

For example: application/json
Authorization
required
An OAuth 2.0 Bearer Token with the write:self-assessment scope.

For example: Bearer bb7fed3fe10dd235a2ccda3d50fb

See also fraud prevention.

Response headers

Response headers Table
Name Description
X-CorrelationId
required

Unique ID for operation tracking
String, 36 characters.

For example: a1e8057e-fbbc-47a8-a8b4-78d9f015c253

See also fraud prevention.

Response

HTTP status: 204 (No Content)

Error scenarios

Error scenarios table
Scenario HTTP status Code

The format of the supplied NINO field is not valid

400 (Bad Request)

FORMAT_NINO

The format of the submission ID is not valid.

400 (Bad Request)

FORMAT_SUBMISSION_ID

The client or agent is not authorised. This is because: the client is not subscribed to MTD, the agent is not subscribed to Agent Services, or the client has not authorised the agent to act on their behalf

403 (Forbidden)

CLIENT_OR_AGENT_NOT_AUTHORISED

The remote endpoint has indicated that no data can be found for the given period.

404 (Not Found)

MATCHING_RESOURCE_NOT_FOUND

For error scenarios that are common across all APIs, and for error formats, see our reference guide.

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

Simulate successfully deleting CIS deductions.

NOT_FOUND

Simulate the scenario where the CIS deduction was not found.


Close Section

Skip to main content