Skip to content

PRC CDA

The following interfaces apply to API Data Integration

Create CDA

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/create
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/create
  • Request data description
ParamkeyTypeRequiredLengthFormatDescriptionExample
cdaNoYStringY50custom declaration application number20211016 粤 B12345-A
编码规则为日期+车牌号+(-)+批次(a/b/c/d…..)
cdaTypeStringY50custom declaration applicationNORMAL REBALANCE FOC
字符串需为大写
portOfLadingStringY50lading port991201
详情见码表附件
portOfEntryStringY50entry port110001
详情见码表附件
importModeOfTransportStringY50transport mode2
详情见码表附件
manifestTypeString50manifest type入境
详情见码表附件
manifestNoString50manifest numberCODE0000001
tmsTrafNOString50TMS运单号
hawbString50入境提运单号CODE0000001
voyageNoString50voyage noCODE0000001
golden2systemString50gold2systemCODE0000001
vehicleTypeStringY50vehicle type吨车
详情见码表附件
containerTypeString50container typeCODE0000001
containerNoString50container noCODE0000001
truckLicenseString50truck license粤 B12345
driverString50driver name王师傅
telOfDriverString50driver phone1850000000
请符合手机号规则, 不支持座机
weightOfVehicleNumber50vehicle(KG)5000
vehicleFrameIdString50vehicle frame idCODE0000001
weightOfVehicleFrameNumber50vehicle frame weight(KGS)2000
weightOfContainerNumber50container weight(KGS)2000
cdaLineListArrayY0collectionCDA LINE collection[]
cdaLineYNumberY50CDA line1
deliveryNoteStringY16delivery noteDN00001
packageTypeStringY50packge type22
详情见码表附件
totalGrossWeightOfGoodsNumberY50total gross weight(kg)5000
totalQtyOfCartonNumberY50total carton quantity800
cdaPoListArrayY0collectionPO collection[]
deliveryNoteStringY16delivery noteDN00001
此字段在 cdaLineList,cdaPoList 中都要存在
vendorCodeStringY150vendor codeCODE0000001
vendorNameStringY150vendor namevendor A
lenovoPnStringY50lenovo part noPN000001
declarationQtyNumberY50declaration quantity98
cooStringY50country of originAD
详情见码表附件
brandStringY50brand品牌 A
无品牌请填写"无品牌"
priceNumber50price178.9
FOC 类型填写
currencyString50currencyCNY
FOC 类型填写
shipToPlantString50lenovo plant codeCODE0000001
FOC 类型填写
storageLocationString50storage locationCODE0000001
FOC 类型填写
invoiceString16invoiceCODE0000001
poNoStringY50lenovo PO/SA/FOCCODE0000001
poLineStringY50lenovo PO/SA/FOC line00010
uomString50unit of measureEA
FOC 类型填写
tier2VendorNameString100tier2 vendor name
netWeightString100天津厂净重需必填
  • Response data description
ParamTypeRequiredLengthDescriptionExample
codeStringY10response code"0"
msgStringY10response message"ok"/"error"
resultObjectNresponse payloadrefer to response sample
  • Request sample
JSON
{
  "cdaNo": "20220801粤A78978-A",
  "cdaType": "REBALANCE",
  "portOfLading": "HKG000",
  "importModeOfTransport": "4",
  "manifestType": "入境",
  "portOfEntry": "471401",
  "vehicleType": "柜车",
  "driver": "王师傅",
  "telOfDriver": "18300000000",
  "truckLicense": "粤A78978",
  "vehicleFrameId": "38543T",
  "weightOfVehicle": 7800,
  "weightOfVehicleFrame": 5950,
  "containerType": "40HQ",
  "containerNo": "NYKU4545836",
  "weightOfContainer": 4860,
  "manifestNo": "1100390819778",
  "tmsTrafNO": "TMS2023021000001",
  "cdaLineList": [
    {
      "cdaLine": "10",
      "deliveryNote": "62608566",
      "totalQtyOfCarton": 566,
      "packageType": "99",
      "totalGrossWeightOfGoods": 5656,
      "cdaPoList": [
        {
          "poNo": "6900000304",
          "poLine": "00010",
          "lenovoPn": "SP50H29573",
          "coo": "CN",
          "brand": "SAMSUNG",
          "declarationQty": 100,
          "invoice": "BCD",
          "tier2VendorName": "AAA"
        },
        {
          "poNo": "6900000304",
          "poLine": "00020",
          "lenovoPn": "SP50H29573",
          "coo": "CN",
          "brand": "SAMSUNG",
          "declarationQty": 100,
          "invoice": "BCD",
          "tier2VendorName": "BBB"
        }
      ]
    }
  ]
}
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok"
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20220801粤A78978-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20220801粤A78978-A",
              "error": "当前cdaNo已创建, 请修改后重试"
            }
          ]
        },
        {
          "field": "poLine",
          "message": [
            {
              "value": "00010",
              "error": "数据组合 6900000304:00010:62608566 已存在, 无法执行此操作"
            },
            {
              "value": "00020",
              "error": "数据组合 6900000304:00020:62608566 已存在, 无法执行此操作"
            }
          ]
        }
      ]
    }
  ]
}
  • Business error code
Error codeError descriptionResolution
-1result coderevise field value according to result message
500server errorplease contact IT with detail error message

supplement、modify CDA attachment

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/uploadAttachment
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/uploadAttachment
  • Request data description
ParamTypeRequiredLengthFormatDescriptionExample
cdaNoStringY50custom20220801 粤 A78978-A
fileFileY50MFilecompressed attachmentfile should compressed by zip or 7z
  • Response data description
ParamTypeRequiredLengthDescriptionExample
codeStringY10response code"0"
msgStringY10response message"ok"/"error"
resultObjectNresponse payloadrefer to response sample
  • Request sample
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok"
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20220801粤A78978-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20220801粤A78978-A",
              "error": "cdaNo不存在, 请修改后重试"
            }
          ]
        },
        {
          "field": "file",
          "message": [
            {
              "value": "file",
              "error": "文件后缀名必须是zip或者7z"
            }
          ]
        }
      ]
    }
  ]
}
  • Business error code
Error codeError descriptionResolution
-1result coderevise field value according to result message
500server errorplease contact IT with detail error message

Update CDA

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/update
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/update
  • Request data description
ParamTypeRequiredLengthFormatDescriptionExample
cdaNoStringY50custom declaration application number20211016 粤 B12345-A
Pattern=Date+vehicleLicense+(-)+batch(a/b/c/d…..)
cdaTypeStringY50custom declaration application typeNORMAL REBALANCE FOC
in upper case
portOfLadingStringY50lading port991201
详情见码表附件
portOfEntryStringY50entry port110001
详情见码表附件
importModeOfTransportStringY50transport mode2
详情见码表附件
manifestTypeString50manifest typeEntry
详情见码表附件
manifestNoString50manifest noCODE0000001
hawbString50hawb (入境提运单号)CODE0000001
voyageNoString50voyage noCODE0000001
golden2systemString50golden2sytemCODE0000001
vehicleTypeStringY50vehicle typexx
详情见码表附件
containerTypeString50container typeCODE0000001
containerNoString50container noCODE0000001
truckLicenseString50truck license粤 B12345
driverString50driver name
telOfDriverString50driver phone1850000000
mobile phone
weightOfVehicleNumber50vehicle weight(KG)5000
vehicleFrameIdString50vehicle frame idCODE0000001
weightOfVehicleFrameNumber50vehicle frame weigxingyinght(KGS)2000
weightOfContainerNumber50container weight(KGS)2000
cdaLineListArrayY0CollectionCollection of CDA line[]
cdaLineNumberY50CDA line1
deliveryNoteStringY16delivery noteDN00001
packageTypeStringY50pakcage type22
详情见码表附件
totalGrossWeightOfGoodsNumberY50total gross weight(kg)5000
totalQtyOfCartonNumberY50total carton quantity800
cdaPoListArrayY0CollectionPO collection[]
deliveryNoteStringY16delivery noteDN00001
此字段在 cdaLineList,cdaPoList 中都要存在
vendorCodeStringY150vendor codeCODE0000001
vendorNameStringY150vendor namevendor A
lenovoPnStringY50lenovo part numberPN000001
tier2VendorNameString100tier2 vendor name
declarationQtyNumberY50declaration quantity98
cooStringY50country of originAD
详情见码表附件
brandStringY50brandbrand A
no brand fill with "none"
priceNumber?50price178.9
FOC type
currencyString?50currencyCNY
FOC type
shipToPlantString?50lenovo plant codeCODE0000001
FOC type
storageLocationString?50lenovo storage locationCODE0000001
FOC type
invoiceString16invoiceCODE0000001
poNoStringY50lenovo PO/SA/FOCCODE0000001
poLineStringY50lenovo PO/SA/FOC line00010
uomString?50unit of measureEA
FOC type
netWeightString?50Tianjin plant weight is required
  • 响应参数
ParamTypeRequiredLengthDescriptionExample
codeStringY10"0"
msgStringY10"ok"/"error"
resultObjectYrefer to response sample
  • Request sample
JSON
{
  "cdaNo": "20220801粤A78978-A",
  "cdaType": "REBALANCE",
  "portOfLading": "HKG000",
  "importModeOfTransport": "4",
  "manifestType": "入境",
  "portOfEntry": "471401",
  "vehicleType": "柜车",
  "driver": "王师傅",
  "telOfDriver": "18300000000",
  "truckLicense": "粤A78978",
  "vehicleFrameId": "38543T",
  "weightOfVehicle": 7800,
  "weightOfVehicleFrame": 5950,
  "containerType": "40HQ",
  "containerNo": "NYKU4545836",
  "weightOfContainer": 4860,
  "manifestNo": "1100390819778",
  "cdaLineList": [
    {
      "cdaLine": "10",
      "deliveryNote": "62608566",
      "totalQtyOfCarton": 566,
      "packageType": "99",
      "totalGrossWeightOfGoods": 5656,
      "cdaPoList": [
        {
          "deliveryNote": "62608566",
          "poNo": "6900000304",
          "poLine": "00010",
          "lenovoPn": "SP50H29573",
          "tier2VendorName": "str",
          "coo": "CN",
          "brand": "SAMSUNG",
          "declarationQty": 100,
          "invoice": "BCD"
        },
        {
          "deliveryNote": "62608566",
          "poNo": "6900000304",
          "poLine": "00020",
          "lenovoPn": "SP50H29573",
          "tier2VendorName": "str",
          "coo": "CN",
          "brand": "SAMSUNG",
          "declarationQty": 100,
          "invoice": "BCD"
        }
      ]
    }
  ]
}
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok"
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20220801粤A78978-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20220801粤A78978-A",
              "error": "当前cdaNo已创建, 请修改后重试"
            }
          ]
        },
        {
          "field": "poLine",
          "message": [
            {
              "value": "00010",
              "error": "数据组合 6900000304:00010:62608566 已存在, 无法执行此操作"
            },
            {
              "value": "00020",
              "error": "数据组合 6900000304:00020:62608566 已存在, 无法执行此操作"
            }
          ]
        }
      ]
    }
  ]
}

Query CDA

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/query
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/query
  • Request data description
ParamTypeRequiredDescriptionExample
cdaNoArrayYcustom declaration application no20220801 粤 A78978-A
  • Response data description
ParamTypeRequiredLengthDescriptionExample
codeStringY10"0"
msgStringY10"ok"/"error"
resultObjectNrefer to response sample
statusStringYcustom declaration status
vehInfoStatusStringYvehicle info declaration status
  • Request sample
JSON
{
  "cdaNoList": [
    "20211016粤B12345-A"
  ]
}
  • Successfule response sample
JSON
{
  "code": "0",
  "msg": "ok",
  "result": [
    {
      "cdaNo": "20220801粤A78978-A",
      "cdaType": "REBALANCE",
      "status": "Draft",
      "vehInfoStatus": "Draft",
      "portOfLading": "HKG000",
      "importModeOfTransport": "4",
      "manifestType": "入境",
      "portOfEntry": "471401",
      "vehicleType": "柜车",
      "driver": "王师傅",
      "telOfDriver": "18300000000",
      "truckLicense": "粤A78978",
      "vehicleFrameId": "38543T",
      "weightOfVehicle": 7800,
      "weightOfVehicleFrame": 5950,
      "containerType": "40HQ",
      "containerNo": "NYKU4545836",
      "weightOfContainer": 4860,
      "manifestNo": "1100390819778",
      "cdaLineList": [
        {
          "cdaLine": "10",
          "deliveryNote": "62608566",
          "totalQtyOfCarton": 566,
          "packageType": "99",
          "totalGrossWeightOfGoods": 5656,
          "cdaPoList": [
            {
              "deliveryNote": "62608566",
              "poNo": "6900000304",
              "poLine": "00010",
              "lenovoPn": "SP50H29573",
              "coo": "CN",
              "brand": "SAMSUNG",
              "declarationQty": 100,
              "invoice": "BCD"
            },
            {
              "deliveryNote": "62608566",
              "poNo": "6900000304",
              "poLine": "00020",
              "lenovoPn": "SP50H29573",
              "coo": "CN",
              "brand": "SAMSUNG",
              "declarationQty": 100,
              "invoice": "BCD"
            }
          ]
        }
      ]
    }
  ]
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20220801粤A78978-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20220801粤A78978-A",
              "error": "当前cdaNo不存在"
            }
          ]
        }
      ]
    }
  ]
}

Query CDA Status

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/query/status
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/query/status
  • Request data description
ParamTypeRequiredLength描述Example
cdaNoListArrayYCollection of custom declaration application numbers20220801 A78978-A
  • Response data description
ParamTypeRequiredLengthDescriptionExample
codeStringY10"0"
msgStringY10"ok"/"error"
resultObjectYrefer to response sample
statusStringY10Draft:can edit
Deleted:deleted
Published: published to lenovo
Returned: rejected by lenovo
Rejected: Customs declaration amendment
Confirmed: he application has been reviewed by Lenovo Customs and is awaiting customs declaration.
Inspection
Declared
Failed
Success
vehInfoStatusStringY10Draft:Vehicle info not sent
Published:Vehicle info is sent to the customs system
Confirmed: Vehicle information confirmed
Error: Vehicle information returned
messageStringN500Vehicle information customs declaration status
  • Request sample
JSON
{
  "cdaNoList": [
    "20220801 A78978-A"
  ]
}
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok",
  "result": [
    {
      "cdaNo": "20220801粤A78978-A",
      "status": "Draft",
      "vehInfoStatus": "Draft",
      "message": "关务备注"
    }
  ]
}
  • Failed response sample
JSON

Publish CDA

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/publish
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/publish
  • Request sample
ParamTypeRequiredLengthFormatDescriptionExample
cdaNoStringYcustom declaration application number20220801 A78978-A
  • Response data description
ParamTypeRequiredLengthFormatDescriptionExample
codeStringY10code"0"
msgStringY10message"ok"/"error"
resultObjectNrefer to response sample
statusStringYcda status
vehInfoStatusStringYvehicle info status
  • Request sample
JSON
{
  "cdaNo": "20211016粤B12345-A"
}
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok"
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20211016粤B12345-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20211016 B12345-A",
              "error": "cdaNo not exists"
            }
          ]
        }
      ]
    }
  ]
}

Publish CDA vehicle info

  • Request address
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/cda/publishVeh
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/cda/publishVeh
  • Request data description
ParamTypeRequiredLengthFormatDescriptionExample
cdaNoStringYcustom declaration application number20220801 A78978-A
  • Response data description
ParamTypeRequiredLengthdescriptionExample
codeStringY10"0"
msgStringY10"ok"/"error"
resultObjectNrefer to response sample
statusStringYcda status
vehInfoStatusStringYvehicle info declaration status
  • Request sample
JSON
{
  "cdaNo": "20211016粤B12345-A"
}
  • Successful response sample
JSON
{
  "code": "0",
  "msg": "ok"
}
  • Failed response sample
JSON
{
  "code": "-1",
  "msg": "error",
  "result": [
    {
      "key": "20211016粤B12345-A",
      "errors": [
        {
          "field": "cdaNo",
          "message":[
            {
              "value": "20211016粤B12345-A",
              "error": "当前cdaNo不存在"
            }
          ]
        }
      ]
    }
  ]
}

status list

FieldValueEditableComment
statusDraftYcan edit
statusDeletedYdeleted
statusPublishedNThe application has been released to Lenovo Customs Team
statusReturnedYThe application was rejected by Lenovo Customs (the reasons can be found in the Customs Notes)
statusRejectedYCustoms declaration change (if there is a problem found by the customs when making a report or passing through the door)
statusConfirmedNThe application has been reviewed by Lenovo Customs and is awaiting customs declaration.
statusInspectionNCustoms declaration and inspection in progress
statusDeclaredNThe customs declaration application has been declared
statusRejectedNDeletion of customs declaration (if there is a problem found by the customs when making a report or passing through the door)
statusSuccessNThe application has been successfully declared
vehInfoStatusDraftYVehicle information not declared to customs
vehInfoStatusPublishedNVehicle information is sent to the customs system
vehInfoStatusConfirmedNVehicle information is being confirmed
vehInfoStatusErrorYVehicle information return
vehInfoStatusSuccessNVehicle information customs declaration successful