Item

Endpoints

Create new item

/companies/{companycode}/items

Description

Returns created item.

Parameters

Type Name Description Schema Business Rules

Path

companyCode
required

Current context company code

string

2 characters max

Body

body
required

Responses

HTTP Code Description Schema

201

Successfully created

400

Functionnal error

No Content

500

Internal server error

No Content

Consumes

  • application/json

Produces

  • application/json

Get entity list

/companies/{companycode}/items

Description

Returns entities.

Parameters

Type Name Description Schema Business Rules

Path

companyCode
required

Current context company code

string

2 characters max

Query

page
optional

Page index

integer (int32)

Query

size
optional

Entity count per page

integer (int32)

Responses

HTTP Code Description Schema

200

Successfull

< Item > array

400

Functionnal error

No Content

500

Internal server error

No Content

Produces

  • application/json

Import entity list

/companies/{companycode}/items/import

Parameters

Type Name Description Schema Business Rules

Path

companyCode
required

Current context company code

string

2 characters max

Body

body
required

Responses

HTTP Code Description Schema

202

Accepted

No Content

400

Functionnal error

No Content

500

Internal server error

No Content

Consumes

  • application/json

Produces

  • application/json

Get one item

/companies/{companycode}/items/{code}

operation.deprecated

Description

Returns retrieved item.

Parameters

Type Name Description Schema Business Rules

Path

code
required

Entity code to retrieve

string

20 characters max

Responses

HTTP Code Description Schema

200

Successful

404

Entity not found

No Content

500

Internal server error

No Content

Produces

  • application/json

Delete item

/companies/{companycode}/items/{code}

Description

In fact disable this entity.

Parameters

Type Name Description Schema Business Rules

Path

code
required

Entity public uuid code to delete

string

20 characters max

Responses

HTTP Code Description Schema

204

Succefully deleted

No Content

400

Functionnal error

No Content

500

Internal server error

No Content

Produces

  • application/json

Data structure

Item

Item data structure.

Name Description Value Business Rules

allExpeditionSites
optional

All expedition sites

boolean

code
required

Item code

string

20 characters max
All characters in uppercase accepted except characters \ ; | " < > µ and spaces at the beginning and at the end

companyCode
required

Current company code

string

2 characters max

consumerPriceUnitCode
optional

Consumer price unit code

string

5 characters max

downgradedItems
optional

list

ean
optional

GTIN

string

14 characters max

establishments
optional

All establishments code

expeditionSites
optional

list

firstUnitCode
required

First unit code

string

5 characters max

hierarchies
optional

GroupLink list

imageCode
optional

string

label
required

Item label

string

50 characters max

labels
optional

outer
optional

Outer

integer

planningInfos
optional

Planning informations

priceUnitCode
optional

Price unit code

string

5 characters max

publicUuid
optional
read-only

Item public uuid

string

qualityInfos
optional

secondUnitCode
optional

Second unit code

string

5 characters max

shortLabel
optional

Short label

string

12 characters max

stockInfos
optional

Stock informations

stockManaged
optional

boolean

substituteItems
optional

list

unitConversions
optional

useBatch
optional

boolean

validityEndDate
required

Validity end date

datetime (ISO-8601)

YYYY-MM-DDTHH:MM:SSZ

Establishment

Name Value Business Rules

code
optional

string

2 characters max

label
optional

string

50 characters max

ItemPlanningInfos

Name Value

internalPurchaseReplenishmentInfos
optional

manufacturingReplenishmentInfos
optional

purchaseReplenishmentInfos
optional

stockInfos
optional

ItemPlanningInternalPurchaseInfos

Name Value Business Rules

startEstablishmentCode
required

string

2 characters max

startDepositCode
optional

string

10 characters max

arrivalEstablishmentCode
required

string

2 characters max

arrivalDepositCode
optional

string

10 characters max

parameterCode
required

string

IN(MINIMUM_REPLENISHMENT, MULTIPLE_REPLENISHMENT, REPLENISHMENT_DELAY)

parameterUnit
required

string

if MINIMUM_REPLENISHMENT or MULTIPLE_REPLENISHMENT, it is a unit code
if REPLENISHMENT_DELAY, parameterUnit = "WEEK" or it is null if a transfer time code is used

parameterValue
required

decimal

if REPLENISHMENT_DELAY, it is null

transferTimeCode
required if REPLENISHMENT_DELAY

string

ItemPlanningManufacturingInfos

Name Value Business Rules

establishmentCode
required

string

2 characters max

activityCode
optional

string

use only activityCode or activitySuiteCode

activitySuiteCode
optional

string

use only activityCode or activitySuiteCode

parameterCode
required

string

IN(MINIMUM_REPLENISHMENT, MULTIPLE_REPLENISHMENT, MAXIMUM_REPLENISHMENT, REPLENISHMENT_PERIOD, REPLENISHMENT_DELAY, REPLENISHMENT_DAYS)

parameterUnit
required and do not use if REPLENISHMENT_DAYS

string

if REPLENISHMENT_PERIOD, parameterUnit IN(DAY, WEEK)
if REPLENISHMENT_DELAY, parameterUnit IN(DAY, WEEK, WORKING_DAY)

parameterValue
required and do not use if REPLENISHMENT_DAYS

decimal

replenishmentDays
required if REPLENISHMENT_DAYS else do not use

list

IN(MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY)

ItemPlanningPurchaseInfos

Name Value Business Rules

establishmentCode
required

string

2 characters max

depositCode
optional

string

2 characters max

parameterCode
required

string

IN(MINIMUM_REPLENISHMENT, MULTIPLE_REPLENISHMENT, MAXIMUM_REPLENISHMENT, REPLENISHMENT_PERIOD, REPLENISHMENT_DELAY)

parameterUnit
optional

string

if REPLENISHMENT_PERIOD, parameterUnit IN(DAY, WEEK)
if REPLENISHMENT_DELAY, parameterUnit IN(DAY, WEEK, WORKING_DAY)

parameterValue
required

decimal

ItemPlanningStockInfos

Name Value Business Rules

establishmentCode
required

string

2 characters max

depositCode
optional

string

2 characters max

parameterCode
required

string

IN(MINIMUM_SALES_HEDGE, MAXIMUM_INVENTORY_HEDGE, MINIMUM_INVENTORY_HEDGE, MINIMUM_STOCK_HEDGE, MAXIMUM_STOCK)

parameterUnit
required

string

if MINIMUM_SALES_HEDGE, parameterUnit IN(DAY, SALES_DAY, WEEK)
if MAXIMUM_INVENTORY_HEDGE, parameterUnit IN(DAY, WEEK)
if MINIMUM_INVENTORY_HEDGE, parameterUnit IN(DAY, WEEK, WORKING_DAY)
if MINIMUM_STOCK_HEDGE or MAXIMUM_STOCK, parameterUnit = MAXIMUM_STOCK

parameterValue
required

decimal

ItemQualityInfos

Name Value Business Rules

establishmentCode
optional

string

2 characters max

lockingDuration
optional

double

preservationDuration
optional

double

preservationDurationUnit
optional

string

DAYS or MONTHS

useDuration
optional

double

optimalPreservationDuration
optional

integer

shippingGuaranteedDuration
optional

integer

ItemStockInfos

Name Value Business Rules

firstUnitCode
optional

string

5 characters max

multiItemBatch
optional

boolean

referenceItemBatchCode
optional

string

secondUnitCode
optional

string

5 characters max

thirdUnitCode
optional

string

5 characters max

UnitConversion

Name Value Business Rules

constantQuantity
optional

boolean

quantity
optional

double

referenceQuantity
optional

double

referenceUnitCode
optional

string

5 characters max

unitCode
optional

string

5 characters max

TranslationLabel

Name Value Business Rules

language
required

string

2 characters max (FR, EN, ES or PT)

label
required

string

50 characters max

ImportItemList

Name Value

callback
optional

string

data
optional

Item list

Example of JSON that can be send:

{
    "companyCode": "cCompany",
    "code": "01",
    "label": "Item 1",
    "shortLabel": null,
    "validityEndDate": "2099-12-31T00:00:00.000Z",
    "imageCode": null,
    "firstUnitCode": "KG",
    "secondUnitCode": "COL",
    "ean": null,
    "outer": null,
    "priceUnitCode": null,
    "consumerPriceUnitCode": null,
    "establishments": [],
    "hierarchies": [{
        "code": "H1",
        "value": "V1",
        "establishmentCode": "01"
    },
    {
        "code": "H2",
        "value": "V2",
        "establishmentCode": null
    }],
    "stockManaged": true,
    "useBatch": true,
    "qualityInfos": [{
        "establishmentCode": "01",
        "useDuration": null,
        "lockingDuration": null,
        "preservationDuration": 6,
        "preservationDurationUnit": "MONTHS"
    }],
    "stockInfos": {
        "firstUnitCode": "KG",
        "secondUnitCode": null,
        "thirdUnitCode": null,
        "multiItemBatch": false,
        "referenceItemBatchCode": null
    },
    "substituteItems": [],
    "downgradedItems": [],
    "allExpeditionSites": true,
    "expeditionSites": [],
    "planningInfos" : {
        "stockInfos": [{
            "establishmentCode": "01",
            "depositCode": "01",
            "parameterCode": "MINIMUM_INVENTORY_HEDGE",
            "parameterUnit": "DAY",
            "parameterValue": 2
        }],
        "purchaseReplenishmentInfos": [{
            "establishmentCode": "01",
            "depositCode": null,
            "parameterCode": "MINIMUM_REPLENISHMENT",
            "parameterUnit": "PAL",
            "parameterValue": 3.755
        },
        {
            "establishmentCode": "01",
            "depositCode": null,
            "parameterCode": "MULTIPLE_REPLENISHMENT",
            "parameterUnit": "PAL",
            "parameterValue": 3
        }],
        "manufacturingReplenishmentInfos": [{
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "MULTIPLE_REPLENISHMENT",
            "parameterUnit": "PAL",
            "parameterValue": 5.123,
            "replenishmentDays": []
        },
        {
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "MINIMUM_REPLENISHMENT",
            "parameterUnit": "PAL",
            "parameterValue": 6.123,
            "replenishmentDays": []
        },
        {
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "MAXIMUM_REPLENISHMENT",
            "parameterUnit": "COL",
            "parameterValue": 3,
            "replenishmentDays": []
        },
        {
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "REPLENISHMENT_PERIOD",
            "parameterUnit": "WEEK",
            "parameterValue": 4,
            "replenishmentDays": []
        },
        {
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "REPLENISHMENT_DAYS",
            "parameterUnit": null,
            "parameterValue": null,
            "replenishmentDays": [
              "MONDAY",
              "TUESDAY"
            ]
        },
        {
            "establishmentCode": "01",
            "activityCode": null,
            "activitySuiteCode": null,
            "parameterCode": "REPLENISHMENT_DELAY",
            "parameterUnit": "DAY",
            "parameterValue": 5,
            "replenishmentDays": []
        }],
        "internalPurchaseReplenishmentInfos": [{
            "startEstablishmentCode": "01",
            "startDepositCode": "01",
            "arrivalEstablishmentCode": "01",
            "arrivalDepositCode": "02",
            "parameterCode": "MINIMUM_REPLENISHMENT",
            "parameterUnit": "COL",
            "parameterValue": 25,
            "transferTimeCode": null
        },
        {
            "startEstablishmentCode": "01",
            "startDepositCode": "01",
            "arrivalEstablishmentCode": "01",
            "arrivalDepositCode": "02",
            "parameterCode": "REPLENISHMENT_DELAY",
            "parameterUnit": "WEEK",
            "parameterValue": 2,
            "transferTimeCode": null
        },
        {
            "startEstablishmentCode": "01",
            "startDepositCode": "01",
            "arrivalEstablishmentCode": "01",
            "arrivalDepositCode": "02",
            "parameterCode": "MULTIPLE_REPLENISHMENT",
            "parameterUnit": "COL",
            "parameterValue": 3,
            "transferTimeCode": null
        },
		{
            "startEstablishmentCode": "01",
            "startDepositCode": "02",
            "arrivalEstablishmentCode": "01",
            "arrivalDepositCode": "01",
            "parameterCode": "REPLENISHMENT_DELAY",
            "parameterUnit": null,
            "parameterValue": null,
            "transferTimeCode": "FD"
        }]
    },
    "unitConversions": [{
        "referenceUnitCode": "COL",
        "referenceQuantity": 1,
        "unitCode": "KG",
        "quantity": 3.6,
        "constantQuantity": true
    },
    {
        "referenceUnitCode": "COL",
        "referenceQuantity": 80,
        "unitCode": "PAL",
        "quantity": 1,
        "constantQuantity": false
    }]
}