openapi: 3.0.3 info: title: Safety and security import control entry summary declaration outcomes contact: {} version: "1.0" servers: - url: https://test-api.service.hmrc.gov.uk description: Sandbox - url: https://api.service.hmrc.gov.uk description: Production tags: - name: customs description: "" paths: /customs/imports/outcomes/: get: tags: - customs summary: Get a list of outcomes description: | This endpoint allows a developer to get a list of outcomes for submissions that are yet to be acknowledged. operationId: Getalistofoutcomes parameters: - name: Accept in: header description: | Specifies the response format and the [version](/api-documentation/docs/reference-guide#versioning) of the API to be used. For example: application/vnd.hmrc.1.0+xml required: true style: simple explode: false schema: type: string enum: - application/vnd.hmrc.1.0+xml - name: Authorization in: header description: | An [OAuth 2.0 Bearer Token](/api-documentation/docs/authorisation/user-restricted-endpoints) with the write:import-control-system scope. For example: Bearer bb7fed3fe10dd235a2ccda3d50fb required: true style: simple explode: false schema: type: string enum: - Bearer bb7fed3fe10dd235a2ccda3d50fb responses: "200": description: OK content: application/xml: schema: required: - entryDeclarationResponses properties: entryDeclarationResponses: required: - response type: object properties: response: type: array description: "" xml: namespace: "" attribute: false wrapped: false items: title: response required: - correlationId - link type: object properties: correlationId: type: string xml: name: correlationId namespace: "" attribute: false wrapped: false link: type: string xml: name: link namespace: "" attribute: false wrapped: false MRN: type: string xml: name: MRN namespace: "" attribute: false wrapped: false xml: name: response namespace: "" attribute: false wrapped: false examples: successResponse: description: | A list of Correlation IDs for unacknowledged outcomes (schema [here](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/outcomes.xsd)). These Correlation IDs correspond to values returned in responses to previously submitted ENS declarations. Outcomes that are successful (accepted) will have a Movement Reference Number (MRN) associated with the Correlation ID in the XML. Outcomes that are unsuccessful (rejected) will have no Movement Reference Number. A maximum of 100 outcomes will be returned in each response. value: | 1234567890 /customs/imports/outcomes/1234567890 1234567890 0987654321 /customs/imports/outcomes/0987654321 "204": description: No Content - There are no outcomes available deprecated: false security: - User-Restricted: - write:import-control-system /customs/imports/outcomes/{correlationId}: get: tags: - customs summary: Retrieve an outcome description: | This endpoint allows a developer to get the outcome for given Correlation ID. operationId: Retrieveanoutcome parameters: - name: correlationId in: path description: The Correlation ID corresponding to an ENS declaration. required: true style: simple explode: false schema: type: string - name: Accept in: header description: | Specifies the response format and the [version](/api-documentation/docs/reference-guide#versioning) of the API to be used. For example: application/vnd.hmrc.1.0+xml required: true style: simple explode: false schema: type: string enum: - application/vnd.hmrc.1.0+xml - name: Authorization in: header description: | An [OAuth 2.0 Bearer Token](/api-documentation/docs/authorisation/user-restricted-endpoints) with the write:import-control-system scope. For example: Bearer bb7fed3fe10dd235a2ccda3d50fb required: true style: simple explode: false schema: type: string enum: - Bearer bb7fed3fe10dd235a2ccda3d50fb responses: "200": description: OK content: application/xml: schema: required: - outcomeResponse properties: outcomeResponse: required: - acknowledgement - response type: object properties: response: required: - CC328A type: object properties: CC328A: required: - CUSOFFFENT730 - CUSOFFLON - CorIdeMES25 - DatOfPreMES9 - HEAHEA - MesIdeMES19 - MesRecMES6 - MesSenMES3 - MesTypMES20 - PERLODSUMDEC - TimOfPreMES10 type: object properties: MesSenMES3: type: string xml: name: MesSenMES3 namespace: "" attribute: false wrapped: false MesRecMES6: type: string xml: name: MesRecMES6 namespace: "" attribute: false wrapped: false DatOfPreMES9: type: string format: date xml: name: DatOfPreMES9 namespace: "" attribute: false wrapped: false TimOfPreMES10: type: string xml: name: TimOfPreMES10 namespace: "" attribute: false wrapped: false MesIdeMES19: type: string xml: name: MesIdeMES19 namespace: "" attribute: false wrapped: false MesTypMES20: type: string xml: name: MesTypMES20 namespace: "" attribute: false wrapped: false CorIdeMES25: type: string xml: name: CorIdeMES25 namespace: "" attribute: false wrapped: false HEAHEA: required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false CUSOFFLON: required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false PERLODSUMDEC: required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false CUSOFFFENT730: required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false acknowledgement: required: - href - method type: object properties: method: type: string xml: name: method attribute: true wrapped: false href: type: string xml: name: href attribute: true wrapped: false examples: successResponse: description: | The outcome for the Correlation ID (schema [here](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/pollingResponse.xsd)). An accepted outcome which is successful will contain a Movement Reference Number. A rejected outcome will contain one or more errors. Accordingly, the content of response element will be based on one of the following schemas: * New submission accepted: schema [http://ics.dgtaxud.ec/CC328A.](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/CC328A-v10-0.xsd) * New submission rejected: schema [http://ics.dgtaxud.ec/CC316A.](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/CC316A-v10-0.xsd) * Amended submission accepted: schema [http://ics.dgtaxud.ec/CC304A.](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/CC304A-v10-0.xsd) * Amended submission rejected: schema [http://ics.dgtaxud.ec/CC305A.](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/CC305A-v10-0.xsd) These schemas import a number of other schemas: * [http://ics.dgtaxud.ec/doc](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/doc-v10-0.xsd) * [http://ics.dgtaxud.ec/complex_ics](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/complex_types_ics-v10-0.xsd) * [http://ics.dgtaxud.ec/simple](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/simple_types-v10-0.xsd) * [http://ics.dgtaxud.ec/simple_ics](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/simple_types_ics-v10-0.xsd) * [http://ics.dgtaxud.ec/tcl](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/tcl-v10-0.xsd) * [http://ics.dgtaxud.ec/tcl_ics](https://developer.service.hmrc.gov.uk/api-documentation/docs/api/download/import-control-entry-declaration-outcome/1.0/schemas/tcl_ics-v10-0.xsd) value: | GB000012340003/1234567890 GB000012340003/1234567890 190114 0945 MSUI11235227 CC328A 0JRF7UncK0t004 Preeti_315A_TC001 10GB08I01234567891 201901140945 ES000055 GB000012340002 GB000011 "404": description: Not Found content: application/xml: schema: required: - error properties: error: required: - code - message type: object properties: code: type: string description: The error code message: type: string description: The error message examples: notFound: description: | No outcome for the submission with the specified Correlation ID is currently available or the outcome has already been acknowledged. value: | OUTCOME_NOT_FOUND No unacknowledged outcome found deprecated: false security: - User-Restricted: - write:import-control-system delete: tags: - customs summary: Acknowledge an outcome description: | This endpoint allows a developer to acknowledge an outcome using a given correlation ID. After calling this endpoint the outcome will no longer be retrievable and will no longer appear in the list of outcomes. operationId: Acknowledgeanoutcome parameters: - name: correlationId in: path description: The Correlation ID corresponding to an ENS declaration. required: true style: simple explode: false schema: type: string - name: Accept in: header description: | Specifies the response format and the [version](/api-documentation/docs/reference-guide#versioning) of the API to be used. For example: application/vnd.hmrc.1.0+xml required: true style: simple explode: false schema: type: string enum: - application/vnd.hmrc.1.0+xml - name: Authorization in: header description: | An [OAuth 2.0 Bearer Token](/api-documentation/docs/authorisation/user-restricted-endpoints) with the write:import-control-system scope. For example: Bearer bb7fed3fe10dd235a2ccda3d50fb required: true style: simple explode: false schema: type: string enum: - Bearer bb7fed3fe10dd235a2ccda3d50fb responses: "200": description: OK - The outcome has successfully been acknowledged. "404": description: Not Found content: application/xml: schema: required: - error properties: error: required: - code - message type: object properties: code: type: string description: The error code message: type: string description: The error message examples: notFound: description: | No outcome for the submission with the specified Correlation ID is currently available or the outcome has already been acknowledged. value: | OUTCOME_NOT_FOUND No unacknowledged outcome found deprecated: false security: - User-Restricted: - write:import-control-system components: schemas: errorResponse: title: error required: - code - message type: object properties: code: type: string description: The error code message: type: string description: The error message acknowledgement: title: acknowledgement required: - href - method type: object properties: method: type: string xml: name: method attribute: true wrapped: false href: type: string xml: name: href attribute: true wrapped: false xml: name: acknowledgement namespace: "" attribute: false wrapped: false CC328A: title: CC328A required: - CUSOFFFENT730 - CUSOFFLON - CorIdeMES25 - DatOfPreMES9 - HEAHEA - MesIdeMES19 - MesRecMES6 - MesSenMES3 - MesTypMES20 - PERLODSUMDEC - TimOfPreMES10 type: object properties: MesSenMES3: type: string xml: name: MesSenMES3 namespace: "" attribute: false wrapped: false MesRecMES6: type: string xml: name: MesRecMES6 namespace: "" attribute: false wrapped: false DatOfPreMES9: type: string format: date xml: name: DatOfPreMES9 namespace: "" attribute: false wrapped: false TimOfPreMES10: type: string xml: name: TimOfPreMES10 namespace: "" attribute: false wrapped: false MesIdeMES19: type: string xml: name: MesIdeMES19 namespace: "" attribute: false wrapped: false MesTypMES20: type: string xml: name: MesTypMES20 namespace: "" attribute: false wrapped: false CorIdeMES25: type: string xml: name: CorIdeMES25 namespace: "" attribute: false wrapped: false HEAHEA: required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false CUSOFFLON: required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false PERLODSUMDEC: required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false CUSOFFFENT730: required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false xml: name: CC328A namespace: http://ics.dgtaxud.ec/CC328A prefix: cc3 attribute: false wrapped: false CUSOFFFENT730: title: CUSOFFFENT730 required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false xml: name: CUSOFFFENT730 namespace: "" attribute: false wrapped: false CUSOFFLON: title: CUSOFFLON required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false xml: name: CUSOFFLON namespace: "" attribute: false wrapped: false entryDeclarationResponses: title: entryDeclarationResponses required: - response type: object properties: response: type: array description: "" xml: namespace: "" attribute: false wrapped: false items: title: response required: - correlationId - link type: object properties: correlationId: type: string xml: name: correlationId namespace: "" attribute: false wrapped: false link: type: string xml: name: link namespace: "" attribute: false wrapped: false MRN: type: string xml: name: MRN namespace: "" attribute: false wrapped: false xml: name: response namespace: "" attribute: false wrapped: false xml: name: entryDeclarationResponses namespace: "" attribute: false wrapped: false HEAHEA: title: HEAHEA required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false xml: name: HEAHEA namespace: "" attribute: false wrapped: false outcomeResponse: title: outcomeResponse required: - acknowledgement - response type: object properties: response: required: - CC328A type: object properties: CC328A: required: - CUSOFFFENT730 - CUSOFFLON - CorIdeMES25 - DatOfPreMES9 - HEAHEA - MesIdeMES19 - MesRecMES6 - MesSenMES3 - MesTypMES20 - PERLODSUMDEC - TimOfPreMES10 type: object properties: MesSenMES3: type: string xml: name: MesSenMES3 namespace: "" attribute: false wrapped: false MesRecMES6: type: string xml: name: MesRecMES6 namespace: "" attribute: false wrapped: false DatOfPreMES9: type: string format: date xml: name: DatOfPreMES9 namespace: "" attribute: false wrapped: false TimOfPreMES10: type: string xml: name: TimOfPreMES10 namespace: "" attribute: false wrapped: false MesIdeMES19: type: string xml: name: MesIdeMES19 namespace: "" attribute: false wrapped: false MesTypMES20: type: string xml: name: MesTypMES20 namespace: "" attribute: false wrapped: false CorIdeMES25: type: string xml: name: CorIdeMES25 namespace: "" attribute: false wrapped: false HEAHEA: required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false CUSOFFLON: required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false PERLODSUMDEC: required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false CUSOFFFENT730: required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false acknowledgement: required: - href - method type: object properties: method: type: string xml: name: method attribute: true wrapped: false href: type: string xml: name: href attribute: true wrapped: false xml: name: outcomeResponse namespace: "" attribute: false wrapped: false PERLODSUMDEC: title: PERLODSUMDEC required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false xml: name: PERLODSUMDEC namespace: "" attribute: false wrapped: false response: title: response required: - correlationId - link type: object properties: correlationId: type: string xml: name: correlationId namespace: "" attribute: false wrapped: false link: type: string xml: name: link namespace: "" attribute: false wrapped: false MRN: type: string xml: name: MRN namespace: "" attribute: false wrapped: false xml: name: response namespace: "" attribute: false wrapped: false response1: title: response required: - CC328A type: object properties: CC328A: required: - CUSOFFFENT730 - CUSOFFLON - CorIdeMES25 - DatOfPreMES9 - HEAHEA - MesIdeMES19 - MesRecMES6 - MesSenMES3 - MesTypMES20 - PERLODSUMDEC - TimOfPreMES10 type: object properties: MesSenMES3: type: string xml: name: MesSenMES3 namespace: "" attribute: false wrapped: false MesRecMES6: type: string xml: name: MesRecMES6 namespace: "" attribute: false wrapped: false DatOfPreMES9: type: string format: date xml: name: DatOfPreMES9 namespace: "" attribute: false wrapped: false TimOfPreMES10: type: string xml: name: TimOfPreMES10 namespace: "" attribute: false wrapped: false MesIdeMES19: type: string xml: name: MesIdeMES19 namespace: "" attribute: false wrapped: false MesTypMES20: type: string xml: name: MesTypMES20 namespace: "" attribute: false wrapped: false CorIdeMES25: type: string xml: name: CorIdeMES25 namespace: "" attribute: false wrapped: false HEAHEA: required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false CUSOFFLON: required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false PERLODSUMDEC: required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false CUSOFFFENT730: required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false xml: name: response namespace: "" attribute: false wrapped: false listOutcomesResponse: title: listOfOutcomes required: - entryDeclarationResponses type: object properties: entryDeclarationResponses: required: - response type: object properties: response: type: array description: "" xml: namespace: "" attribute: false wrapped: false items: title: response required: - correlationId - link type: object properties: correlationId: type: string xml: name: correlationId namespace: "" attribute: false wrapped: false link: type: string xml: name: link namespace: "" attribute: false wrapped: false MRN: type: string xml: name: MRN namespace: "" attribute: false wrapped: false xml: name: response namespace: "" attribute: false wrapped: false retrieveOutcomeResponse: title: retrieveOutcome required: - outcomeResponse type: object properties: outcomeResponse: required: - acknowledgement - response type: object properties: response: required: - CC328A type: object properties: CC328A: required: - CUSOFFFENT730 - CUSOFFLON - CorIdeMES25 - DatOfPreMES9 - HEAHEA - MesIdeMES19 - MesRecMES6 - MesSenMES3 - MesTypMES20 - PERLODSUMDEC - TimOfPreMES10 type: object properties: MesSenMES3: type: string xml: name: MesSenMES3 namespace: "" attribute: false wrapped: false MesRecMES6: type: string xml: name: MesRecMES6 namespace: "" attribute: false wrapped: false DatOfPreMES9: type: string format: date xml: name: DatOfPreMES9 namespace: "" attribute: false wrapped: false TimOfPreMES10: type: string xml: name: TimOfPreMES10 namespace: "" attribute: false wrapped: false MesIdeMES19: type: string xml: name: MesIdeMES19 namespace: "" attribute: false wrapped: false MesTypMES20: type: string xml: name: MesTypMES20 namespace: "" attribute: false wrapped: false CorIdeMES25: type: string xml: name: CorIdeMES25 namespace: "" attribute: false wrapped: false HEAHEA: required: - DecRegDatTimHEA115 - DocNumHEA5 - RefNumHEA4 type: object properties: RefNumHEA4: type: string xml: name: RefNumHEA4 namespace: "" attribute: false wrapped: false DocNumHEA5: type: string xml: name: DocNumHEA5 namespace: "" attribute: false wrapped: false DecRegDatTimHEA115: type: string format: date-time xml: name: DecRegDatTimHEA115 namespace: "" attribute: false wrapped: false CUSOFFLON: required: - RefNumCOL1 type: object properties: RefNumCOL1: type: string xml: name: RefNumCOL1 namespace: "" attribute: false wrapped: false PERLODSUMDEC: required: - TINPLD1 type: object properties: TINPLD1: type: string xml: name: TINPLD1 namespace: "" attribute: false wrapped: false CUSOFFFENT730: required: - RefNumCUSOFFFENT731 type: object properties: RefNumCUSOFFFENT731: type: string xml: name: RefNumCUSOFFFENT731 namespace: "" attribute: false wrapped: false acknowledgement: required: - href - method type: object properties: method: type: string xml: name: method attribute: true wrapped: false href: type: string xml: name: href attribute: true wrapped: false notFoundResponse: title: notFound required: - error type: object properties: error: required: - code - message type: object properties: code: type: string description: The error code message: type: string description: The error message parameters: acceptHeader: name: Accept in: header description: | Specifies the response format and the [version](/api-documentation/docs/reference-guide#versioning) of the API to be used. For example: application/vnd.hmrc.1.0+xml required: true style: simple explode: false schema: type: string enum: - application/vnd.hmrc.1.0+xml authorizationHeader: name: Authorization in: header description: | An [OAuth 2.0 Bearer Token](/api-documentation/docs/authorisation/user-restricted-endpoints) with the write:import-control-system scope. For example: Bearer bb7fed3fe10dd235a2ccda3d50fb required: true style: simple explode: false schema: type: string enum: - Bearer bb7fed3fe10dd235a2ccda3d50fb correlationId: name: correlationId in: path description: The Correlation ID corresponding to an ENS declaration. required: true style: simple explode: false schema: type: string securitySchemes: User-Restricted: type: oauth2 description: HMRC supports OAuth 2.0 for authenticating User-restricted API requests flows: authorizationCode: authorizationUrl: https://api.service.hmrc.gov.uk/oauth/authorize tokenUrl: https://api.service.hmrc.gov.uk/oauth/token refreshUrl: https://api.service.hmrc.gov.uk/oauth/refresh scopes: write:import-control-system: Access Import Control System