Datatypes

The REST Datatypes transfers all data physically as UTF-8 strings, either as JSON or XML representation. The following list gives an overview on the data types which are used throughout the whole REST Service API.

STRING

Definition

Unicode Characters

Pattern

Example

"Hello World!", "Heute ist ein schöner Tag", "世界您好!"

Corresponding Java Datatype

java.lang.String

INTEGER

Definition

Integer Numbers (-9,223,372,036,854,775,808 to 9,223,372,036,854,775,807)

Pattern

[+/-] 0-9*

Example

4711

Corresponding Java Datatype

java.lang.Long

DECIMAL

Definition

Signed decimal number. Please see the properties of the parameter/field for details on the
precision and the allowed number of fraction digits.

The string representation consists of an optional sign,'+' or '-', followed by a sequence of
zero or more decimal digits ("the integer"), optionally followed by a fraction

The fraction consists of a decimal point followed by zero or more decimal digits.
The string must contain at least one digit in either the integer or the fraction.

Pattern

[+/-] 0-9*[.0-9*]

Example

100.90

Corresponding Java Datatype

java.math.BigDecimal

DATE

Definition

Calendar Date (12/30/1899 to 12/31/9999)

Pattern

yyyy-MM-dd

Example

2012-05-01
(first of May in 2012)

Corresponding Java Datatype

java.sql.Date

TIME

Definition

Time (00:00:00 to 24:00:00)

Pattern

HH:mmZ

Example

12:05
(five minutes after 12 o'clock noon)

Corresponding Java Datatype

java.sql.Time

DATETIME

Definition

Date and Time in one value

Pattern

Input

Output

yyyy-MM-dd'T'HH:mm:ss

yyyy-MM-dd'T'HH:mm:ss:SSSZ

yyyy-MM-dd'T'HH:mm:ssZ

yyyy-MM-dd'T'HH:mm:ss:SSS

yyyy-MM-dd'T'HH:mm:ss:SSSZ

Example

2012-05-01T12:00:00

2012-05-01T12:00:00-0700

2012-05-01T12:00:00:000

2012-05-01T12:00:00:000-0700

Corresponding Java Datatype

java.sql.Timestamp

BOOLEAN

Definition

Boolean value - either true or false. Note: Fields which are not mandatory might also have an empty string which means no value
which should not be interpreted as "false" or "true". It's just, "not defined".

Pattern

true / false

Example

true, false

Corresponding Java Datatype

java.lang.Boolean

ENTITY_ITEM

Definition

A Product Manager object which is described in the Meta API. In case entity item's are part of a result object from a service call, they will be serialized as separate object structure. In case you need to provide an entity item as a parameter, a simpler string representation is mostly enough.

As part of a result object an entity item is rendered like this:

"object": {
"id": "86@1064",
"label": "A1"
}

If you do not need the human readable label of the entity items, you can disable the label generation by specifying includeLabels with false. See also the REST List API Read for Root Entities page.

Pattern

Entity Item ID Syntax:

Entity Item without a container item:

'<external_identifier>'|<internal_id>

Entity Item with a container item:

'<external_identifier>'|<internal_id>@'<container_external_identifier>'|<container_internal_id>

Please note that you need to escape single quotes in case they are part of the external identifier or container external identifier with a backslash

Example

'SomeItem'@'SupplierCat1'

12345@5

'SomeSupplier'

42

'SomeItem\'WithASingleQuote'@'MASTER'

Corresponding Java Datatype

com.heiler.pim.webservice.client.EntityItemReference

MIME_VALUE

Definition

A reference to a mime file. In case mime values are part of a result object from a service call, they will be serialized as separate object structure.
A mime value has a label. The label is shown in the UI in case a preview picture is not used there. The relative file path defines the location of the file inside of the zip archive when you download or upload the mime values

The label and mime type are optional in case you want to write a mime value. They will be extracted from the relativeFilePath if omitted.
Please note that the relative file path of a mime value will change once it's uploaded and saved as Product 360 makes sure that every mime value is unique in the system. If you retrieve the mime value again after the upload, the
relativeFilePath will be different. It should always be treated as a black box.

Pattern

No Simple string representation, it's always rendered as JSON/XML structure

Example

{
"label": "examplePicture.jpg",
"mimeType": "image/jpg",
"relativeFilePath": "dir1\\dir2\\dir3\\examplePicture.[sequenceToMakeFileNameUnique].jpg"
}

Corresponding Java Datatype

com.heiler.pim.webservice.client.MIMEValueReference

ANY

Definition

ANY can be one specific datatype like STRING,DATETIME, DECIMAL, ENTITY_ITEM or BOOLEAN. A field with ANY as datatype must have a specific implementation to figure out which of the specific datatypes mentioned before is actually taking effect.

Pattern

see at the specific datatype

Example

see at the specific datatype

Corresponding Java Datatype

java.lang.Object