Data Schema

This page details the request and response data schemas for the ClearPort API.

We have made a NuGet package available for C# projects UKCustoms.Api.Models, which contains request and response schema classes.

For endpoints that require a request body, the data should be in JSON format.

CreateExportDataSchema

Property

Data type

Required

Format

Description

templateId

integer

linkedDeclarationId

integer

correlationId

string

an..255

Your internal unique identifier

externalSystemLink

string

an..1000

category

string

Yes

an..7

declarationType

string

a3

specificCircumstanceIndicator

string

an3

previousDocuments

array

ducr

string

an..35

rrs01

boolean

rrs01Description

string

an..70

referenceNumber

string

an..35

lrn

boolean

an..22

warehouseType

string

a1

warehouseId

string

an..35

exporter

NameAndAddressSchema

exporterContactId

integer

exporterAddressId

integer

exporterIdentificationNumber

string

an..17

The EORI of the exporter

consignee

NameAndAddressSchema

consigneeContactId

integer

consigneeAddressId

integer

consigneeIdentificationNumber

string

an..17

The EORI of the consignee

declarant

NameAndAddressSchema

declarantContactId

integer

declarantAddressId

integer

declarantIdentificationNumber

string

an..17

The EORI of the declarant

representative

NameAndAddressSchema

representativeContactId

integer

representativeAddressId

integer

representativeIdentificationNumber

string

an..17

The EORI of the representative

carrier

NameAndAddressSchema

carrierContactId

integer

carrierAddressId

integer

carrierIdentificationNumber

string

an..17

The EORI of the carrier

holdersOfAuthorisation

array of HolderOfAuthorisationIdentificationNumberSchema

fr1

boolean

fr1VATNumber

string

transportChargesMethodOfPayment

string

a1

totalInvoice

decimal

n..16,2

totalInvoiceCrrencyCode

string

a3

exchangeRate

decimal

n..12,5

countryOfDestination

string

a2

customsOfficeOfExit

string

an8

countryOfDispatch

string

an8

countryOfRoutingCodes

array

locationOfGoods

string

an..35

customsOfficeOfPresentation

string

an8

supervisingCustomsOffice

string

an8

totalGrossMass

decimal

n..11,3

totalNetMass

decimal

n..11,3

totalPackages

integer

containerised

boolean

modeOfTransportAtBorder

integer

inlandModeOfTransport

integer

typeOfTransportAtDeparture

integer

identityOfTransportAtDeparture

string

an..27

containers

array

typeOfActiveMeansOfTransportAtBorder

integer

identityOfActiveMeansOfTransportAtBorder

string

an..35

nationalityOfActiveMeansOfTransportAtBorder

string

a2

seals

array

guarantees

array

natureOfTransaction

string

n..2

items

array of ExportItemSchema

relatedNCTSDeparture

object

CreateExportResponseSchema

Property

Data type

Required

Description

success

boolean

Yes

location

string

correlationId

string

GetExportDataSchema

Property

Data type

Required

Description

correlationId

string

yes

status

boolean

yes

mrn

boolean

lrn

boolean

ducr

boolean

HolderOfAuthorisationIdentificationNumberSchema

Property

Data type

Required

Format

Description

authorisationTypeCode

string

an..4

identifier

string

an..17

ExportItemSchema

Property

Data type

Required

Description

correlationId

string

an..255

An internal value for your use to identify goods items

procedure

string

an4

additionalProcedures

string

an3

previousDocuments

array of PreviousDocumentSchema

additionalInformation

array of AdditionalInformationSchema

documentsProduced

array of DocumentProducedSchema

referenceNumber

string

an..35

consignee

NameAndAddressSchema

consigneeIdentificationNumber

string

an..17

The EORI of the consignee

consigneeContactId

integer

consigneeAddressId

integer

additionalFiscalReferenceIdentificationNumbers

array of AdditionalFiscalReferenceIdentificationNumberSchema

transportChargesMethodOfPayment

string

a1

countryOfDestination

string

a2

countryOfOrigin

string

a2

netMass

decimal

n..11,5

grossMass

decimal

n..11,5

supplementaryUnits

decimal

n..16,6

descriptionOfGoods

string

an..280

packages

array of PackageSchema

unDangerousGoodsCode

string

an..4

cusCodeForChemicals

string

an8

commodityCode

string

an..10

taricAdditionalCodes

string

an4

nationalAdditionalCodes

string

an..4

containerIdentificationNumbers

array of string

statisticalValue

decimal

statisticalValueCurrencyCode

string

a3

PreviousDocumentSchema

Property

Data type

Required

Format

Description

category

string

a1

type

string

an..3

documentReference

string

an..35

goodsItemIdentifier

integer

n..3

AdditionalInformationSchema

Property

Data type

Required

Format

Description

code

string

an5

description

string

an..70

DocumentProducedSchema

Property

Data type

Required

Format

Description

documentType

string

an4

documentIdentifierAndPart

string

an..30 + an..5

documentStatus

string

a2

reason

string

an..35

issuingAuthorityName

string

an..70

dateOfValidity

date

yyyymmdd

measurementUnitAndQualifier

string

an..4

quantity

decimal

n..16,6

NameAndAddressSchema

Property

Data type

Required

Format

Description

name

string

an..35

streetAndNumber

string

an..35

cityName

string

an..35

postcode

string

an..9

countryCode

string

a2

AdditionalFiscalReferenceIdentificationNumberSchema

Property

Data type

Required

Format

Description

roleCode

string

an3

vatIdentificationNumber

string

an..17

PackageSchema

Property

Data type

Required

Format

Description

type

string

an..2

number

string

n..5

shippingMarks

string

an..42

CreateImportDataSchema

Property

Data type

Required

Format

Description

templateId

integer

linkedDeclarationId

integer

correlationId

string

an..255

externalSystemLink

string

an..1000

category

string

Yes

badge

string

an3

csp

string

declarationType

string

a3

referenceNumber

string

an..35

ducr

string

an..35

lrn

boolean

an..22

representativeStatusCode

integer

exporter

NameAndAddressSchema

exporterContactId

integer

exporterAddressId

integer

exporterIdentificationNumber

string

an..17

The EORI of the exporter

importer

NameAndAddressSchema

importerContactId

integer

importerAddressId

integer

importerIdentificationNumber

string

an..17

The EORI of the importer

declarant

NameAndAddressSchema

declarantContactId

integer

declarantAddressId

integer

declarantIdentificationNumber

string

an..17

The EORI of the declarant

representative

NameAndAddressSchema

representativeContactId

integer

representativeAddressId

integer

representativeIdentificationNumber

string

an..17

The EORI of the representative

seller

NameAndAddressSchema

sellerContactId

integer

sellerAddressId

integer

sellerIdentificationNumber

string

an..17

The EORI of the seller

buyer

NameAndAddressSchema

buyerContactId

integer

buyerAddressId

integer

buyerIdentificationNumber

string

an..17

The EORI of the buyer

dan1

string

an..35

dan2

string

an..35

pva

boolean

pvaVATNumber

string

an..512

cashAccountNumber

string

an..17

guarantees

array

holdersOfAuthorisation

array of HolderOfAuthorisationIdentificationNumberSchema

rrs01

boolean

rrs01Description

string

an..17

countryOfDestination

string

a2

countryOfDispatch

string

a2

airportOfLoading

string

a3

containerised

boolean

modeOfTransportAtBorder

integer

nationalityOfActiveMeansOfTransportAtBorder

string

a2

inlandModeOfTransport

integer

identityOfTransportOnArrival

string

an..35

typeOfTransportOnArrival

string

n2

containers

array

awb

string

an..35

mcr

string

an..35

hawb

string

an..35

bol

string

an..35

previousDocuments

array

warehouseType

string

a1

warehouseId

string

an..35

customsOfficeOfPresentation

string

an8

supervisingCustomsOffice

string

an8

natureOfTransaction

string

n..2

deliveryTerms

string

a3

deliveryTermsLocation

string

an..35

totalGrossMass

decimal

n..16,6

totalNetMass

decimal

n..16,6

totalPackages

integer

n..8

totalInvoice

decimal

n..16,2

totalInvoiceCrrencyCode

string

a3

exchangeRate

decimal

n..12,5

items

array of ImportItemSchema

additionsAndDeductions

array of AdditionsAndDeductionsSchema

freightCharge

array

freightChargeCurrency

array

airTransportCharge

array

airTransportChargeCurrency

array

insuranceCharge

array

insuranceChargeCurrency

array

vatAdjustmentCharge

array

vatAdjustmentCurrency

array

apportionByValue

boolean

CreateImportResponseSchema

Property

Data type

Required

Description

success

boolean

Yes

location

string

correlationId

string

GetImportDataSchema

Property

Data type

Required

Description

correlationId

string

yes

status

boolean

yes

mrn

boolean

lrn

boolean

ducr

boolean

GetImportTaxDataSchema

Property

Data type

Required

Description

mrn

string

yes

hasTaxes

boolean

yes

totalDuty

decimal

totalVAT

decimal

payableDuty

decimal

payableVAT

decimal

taxBreakdown

array of TaxBreakdownSchema

TaxBreakdownSchema

Property

Data type

Required

Description

type

string

totalAmount

decimal

payableAmount

decimal

dan

string

cdsCashAccount

string

pvavatnumber

string

ImportItemSchema

Property

Data type

Required

Description

correlationId

string

an..255

An internal value for your use to identify goods items

commodityCode

string

n..10

taricAdditionalCodes

string

an4

nationalAdditionalCodes

string

an..4

procedure

string

an4

additionalProcedures

string

an3

countryOfOrigin

string

a2

countryOfPreferentialOrigin

string

a2

preference

string

n3

quotaNumber

string

an6

descriptionOfGoods

string

an..512

cusCodeForChemicals

string

an8

valuationMethod

integer

itemPrice

decimal

n..16,2

itemPriceCurrencyCode

string

a3

value

decimal

n..16,2

valueCurrencyCode

string

a3

statisticalValue

decimal

n..16,2

statisticalValueCurrencyCode

string

a3

valuationIndicator_PartyRelationship

boolean

valuationIndicator_BuyerRestrictions

boolean

valuationIndicator_SaleOrPriceConditions

boolean

valuationIndicator_SaleProceeds

boolean

transportCostsToFinalDestination

decimal

n..16,2

transportCostsToFinalDestinationCurrencyCode

string

a3

netMass

decimal

n..16,6

supplementaryUnits

decimal

n..16,6

grossMass

decimal

n..16,6

previousDocuments

array of PreviousDocumentSchema

additionalInformation

array of AdditionalInformationSchema

documentsProduced

array of DocumentProducedSchema

packages

array of PackageSchema

containerIdentificationNumbers

array of string

taxLines

array of TaxLineSchema

A00_PaymentMethod

string

a1

B00_PaymentMethod

string

a1

jobReference

string

an..35

exporterNameAndAddress

string

an..70

exporterIdentificationNumber

string

an..17

The EORI of the exporter

sellerNameAndAddress

string

an..70

sellerIdentificationNumber

string

an..17

The EORI of the seller

buyerNameAndAddress

string

an..70

buyerIdentificationNumber

string

an..17

The EORI of the buyer

additionalSupplyChainActors

array of AdditionalSupplyChainActorSchema

additionalFiscalReferenceIdentificationNumbers

array of AdditionalFiscalReferenceIdentificationNumberSchema

additionsAndDeductions

array of AdditionsAndDeductionsSchema

countryOfDestinationCode

string

a2

countryOfDispatchCode

string

a2

natureOfTransaction

string

n..2

TaxLineSchema

Property

Data type

Required

Description

taxType

string

taxBase

TaxBaseSchema

payableAmount

decimal

payableAmountCurrencyCode

string

totalTaxes

decimal

totalTaxesCurrencyCode

string

methodOfPayment

string

AdditionalSupplyChainActorSchema

Property

Data type

Required

Description

roleCode

string

identifier

decimal

AdditionsAndDeductionsSchema

Property

Data type

Required

Description

code

string

amount

decimal

amountCurrency

string

TaxBaseSchema

Property

Data type

Required

Description

measurementUnit

string

quantity

decimal

GetAirConsignmentsDataSchema

Property

Data type

Required

Description

awb

string

hawb

string

split

string

mrn

string

customsEntryDate

datetime

jobReferenceNumber

string

numberOfPiecesReceived

integer

customsStatus

string

CreateENSDataSchema

Property

Data type

Required

Description

correlationId

string

Yes

Use this field to relate the submission to an identifier in your system

templateId

integer

Optionally specify a template

submitIfValid

boolean

Automatically submit the declaration if it passes validation checks

externalSystemLink

string

messageSenderEORI

string

messageSenderBranch

string

lrn

string

placeOfDeclaration

string

placeOfLoading

string

placeOfUnloading

string

commercialReferenceNumber

string

modeOfTransportAtBorder

string

identityOfMeansOfTransportAtBorder

string

nationalityOfMeansOfTransportAtBorder

string

conveyenceReferenceNumber

string

consignor

ENSPartySchema

consignee

ENSPartySchema

personLodgingDeclaration

ENSPartySchema

carrier

ENSPartySchema

notifyParty

ENSPartySchema

representative

ENSPartySchema

customsOfficeOfArrival

string

dateAndTimeOfArrival

datetime

customsOfficesOfSubsequentEntry

array of string

transportChargesMethodOfPayment

string

specialMentions

string

routingCountries

array of string

seals

array of string

goodsItems

array of ENSGoodsItemSchema

ENSPartySchema

Property

Data type

Required

Description

name

string

streetAndNumber

string

city

string

postcode

string

countryCode

string

eori

string

ENSGoodsItemSchema

Property

Data type

Required

Description

commodityCode

string

goodsDescription

string

commercialReferenceNumber

string

grossMass

string

unDangerousGoodsCode

string

identityOfMeansOfTransportAtBorder

string

nationalityOfMeansOfTransportAtBorder

string

placeOfLoading

string

placeOfUnloading

string

transportChargesMethodOfPayment

string

packages

array of ENSPackageSchema

producedDocuments

array of ENSProdcedDocumentSchema

ENSPackageSchema

Property

Data type

Required

Description

kind

string

numberOfPackages

integer

numberOfPieces

integer

marksAndNumbers

string

ENSProdcedDocumentSchema

Property

Data type

Required

Description

type

string

reference

string

CreateENSResponseSchema

Property

Data type

Required

Description

success

boolean

Yes

location

string

correlationId

string

GetENSDataSchema

Property

Data type

Description

status

boolean

mrn

string

lrn

string

CreateGVMSDataSchema

Property

Data type

Description

correlationId

string

submitIfValid

boolean

Automatically submit the declaration if it passes validation checks

direction

string

haulierType

string

isUnaccompanied

boolean

vehicleRegNumber

string

trailerRegistrationNumbers

array of string

containerRegistrationNumbers

array of string

routeId

string

see GVMS Routes

localDateTimeOfDeparture

string

sAndSMasterRefNum

string

customsDeclarations

array of GVMSCustomsDeclarationDataSchema

transitDeclarations

array of GVMSTransitDeclarationDataSchema

tirDeclarationDTO

array of GVMSTIRDeclarationDataSchema

ataDeclarations

array of GVMSATADeclarationDataSchema

eidrDeclarations

array of GVMSEIDRDeclarationDataSchema

indirectExportDeclarations

array of GVMSIndirectExportDeclarationDataSchema

emptyVehicle

boolean

ownVehicle

boolean

dbcGoods

string

exemptedGoods

string

GetGVMSDataSchema

Property

Data type

Description

correlationId

string

gmrId

string

status

string

direction

string

haulierType

string

isUnaccompanied

boolean

vehicleRegNumber

string

trailerRegistrationNumbers

array of string

containerRegistrationNumbers

array of string

routeId

string

see GVMS Routes

localDateTimeOfDeparture

string

sAndSMasterRefNum

string

customsDeclarations

array of GVMSCustomsDeclarationDataSchema

transitDeclarations

array of GVMSTransitDeclarationDataSchema

tirDeclarationDTO

array of GVMSTIRDeclarationDataSchema

ataDeclarations

array of GVMSATADeclarationDataSchema

eidrDeclarations

array of GVMSEIDRDeclarationDataSchema

indirectExportDeclarations

array of GVMSIndirectExportDeclarationDataSchema

emptyVehicle

boolean

ownVehicle

boolean

dbcGoods

string

exemptedGoods

string

UpdateGVMSDataSchema

Property

Data type

Description

direction

string

haulierType

string

isUnaccompanied

boolean

vehicleRegNumber

string

trailerRegistrationNumbers

array of string

containerRegistrationNumbers

array of string

routeId

string

see GVMS Routes

localDateTimeOfDeparture

string

sAndSMasterRefNum

string

customsDeclarations

array of GVMSCustomsDeclarationDataSchema

transitDeclarations

array of GVMSTransitDeclarationDataSchema

tirDeclarationDTO

array of GVMSTIRDeclarationDataSchema

ataDeclarations

array of GVMSATADeclarationDataSchema

eidrDeclarations

array of GVMSEIDRDeclarationDataSchema

indirectExportDeclarations

array of GVMSIndirectExportDeclarationDataSchema

emptyVehicle

boolean

ownVehicle

boolean

dbcGoods

string

exemptedGoods

string

GVMSCustomsDeclarationDataSchema

Property

Data type

Description

customsDeclarationId

string

customsDeclarationPartId

string

sAndSMasterRefNum

string

GVMSTransitDeclarationDataSchema

Property

Data type

Description

transitDeclarationId

string

isTSAD

bool

sAndSMasterRefNum

string

GVMSTIRDeclarationDataSchema

Property

Data type

Description

tirCarnetId

string

sAndSMasterRefNum

string

GVMSATADeclarationDataSchema

Property

Data type

Description

ataCarnetId

string

sAndSMasterRefNum

string

GVMSEIDRDeclarationDataSchema

Property

Data type

Description

traderEORI

string

sAndSMasterRefNum

string

GVMSIndirectExportDeclarationDataSchema

Property

Data type

Description

eadMasterRefNum

string

CreateELODataSchema

Property

Data type

Description

correlationId

string

referenceNumber

string

direction

string

Import or Export

vehicleStatus

string

Loaded or Empty

tirOrAta

boolean

sanitaryOrPhytosanitary

boolean

fishProducts

boolean

jeton

string

declarations

array of string

submitIfValid

boolean

GetELODataSchema

Property

Data type

Description

correlationId

string

referenceNumber

string

direction

string

Import or Export

vehicleStatus

string

Loaded or Empty

tirOrAta

boolean

sanitaryOrPhytosanitary

boolean

fishProducts

boolean

declarations

array of string

submittedDateTime

datetime

acceptedDateTime

datetime

rejectedDateTime

datetime

embarkedDateTime

datetime

disembarkedDateTime

datetime

closedDateTime

datetime

pairedDateTime

datetime