Skip to content

GR Data

This interface is applicable for data integration API, read Api Access Process first

Request address

  • API
EnvironmentURL
Testhttps://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/open_platform/data/sync/odm/gr
Prodhttps://api-cn.lenovo.com/v1.0/supply_chain/scc/open_platform/data/sync/odm/gr
  • FTP
EnvironmentPartner directoryLenovo directoryFile name
Test/Planning/SCC/{appName}/odm/gr//Planning/SCC/{appName}/odm/gr/feedback/gr_{crud}_{yyyyMMddHHmmss}_
Prod/Planning/SCC/{appName}/odm/gr//Planning/SCC/{appName}/odm/gr/feedback/gr_{crud}_{yyyyMMddHHmmss}_

Sample:/Planning/SCC/LCFC/odm/gr/gr_update_20220928123000_001

FrequencyTimeData amount
Daily or Real time00:00:00Daily version of data(Incremental)

Request data description

TIP

Note: field requirements are different on bu, please refer to the following table

ParamKeyTypeDefault requirdPCG-NBISGMDSC-TBPCG-DTPCG-DockingSmart DeviceLengthDescriptionExample
uidString32Unique id
grYStringYYYYYYY50
gr_lineYStringYYYYYYY50
buYStringYYYYYY50Business unitThinkNB
odmYStringY40ODM nameWINGTECH
odm_pnYStringYYYYYYY20ODM part numberBLXSB18C53808
odm_pn_descStringYYYY240ODM part number descriptionXXXX
lenovo_pnStringY for DS materialY for DS materialYYYY18Lenovo part numberSB18C53808
material_typeStringYY for DSY for DS10DB/DS/BSDS
mfg_pnStringYYYYYY200manufacturing part numberXXX
odm_poYStringYYYYYY20purchase orderHG21100014
odm_po_lineYStringYYYYY10purchase order line10
gr_qtyNumberYYYYYY13,3Goods receive quantity100
gr_dateYDateYYYYYYGoods receive time2022-08-01
movement_typeYStringYYYYYYY20RMA/Return/GR/CANCEL/Drop to VMI/Drop to ODM/HUB PullGR
odm_supplier_codeStringYYYYY20ODM supplier codeW121081473
odm_supplier_nameStringYYYY100ODM supplier nameGOLD WIN TRADING (HK) LIMITED
ship_to_nameStringY100ship to odm factory
versionStringYYYYYYY14version in format yyyyMMddHHmmss20220809070623
comment1String100
comment2String100
dnString50delivery note
dn_lineString50

Response data description

ParamTypeDescription
codeString0: success, others:failed
msgStringthe detail message, especially useful on failure

Request sample

json
{
  "batch_id": "90497",
  "batch_size": 1,
  "seq_id": "1",
  "seq_size": 1,
  "data": [
    {
      "gr": "G202211183201",
      "gr_line": "10",
      "bu": "MDSC-TB",
      "odm": "odm_1",
      "odm_pn": "Wingtech",
      "odm_pn_desc": "",
      "lenovo_pn": "HG21100014",
      "material_type": "",
      "mfg_pn": "10",
      "odm_po": "28080",
      "odm_po_line": "HG21100014",
      "gr_qty": "10",
      "gr_date": "2022-09-15",
      "movement_type": "GR",
      "odm_supplier_code": "W121081473",
      "odm_supplier_name": "GOLDWINTRADING(HK)LIMITED",
      "ship_to_name": "",
      "version": "20220809070600",
      "comment1": "",
      "comment2": "",
      "dn": "",
      "dn_line": ""
    }
  ]
}

Successful response sample

json
{
  "code": "0",
  "msg": "request success"
}

Failed response sample

json
{
    "code": "E00V00",
    "msg": "data verification failed!",
    "result": [{
        "row": {
            "odm": "LCFC",
            ...
        },
        "verify": [{
            "type": "value length exceed",
            "fields": "version"
        }]
    }]
}