AddItemProperty

Extends \Recombee\RecommApi\Requests\Request

Adding an item property is somehow equivalent to adding a column to the table of items. The items may be characterized by various properties of different types.

package

Default

Methods

Construct the request

__construct(string $property_name, string $type) 

Arguments

$property_name

string

Name of the item property to be created. Currently, the following names are reserved:id, itemid, case insensitively. Also, the length of the property name must not exceed 63 characters.

$type

string

Value type of the item property to be created. One of: int, double, string, boolean, timestamp, set, image or imageList.

  • int- Signed integer number.
  • double - Floating point number. It uses 64-bit base-2 format (IEEE 754 standard).
  • string - UTF-8 string.
  • boolean - true / false
  • timestamp - Value representing date and time.
  • set - Set of strings.
  • image - URL of an image (jpeg, png or gif).
  • imageList - List of URLs that refer to images.

Get body parameters

getBodyParameters() : array
inherited abstract

Response

array

Values of body parameters (name of parameter => value of the parameter)

Returns true if HTTPS must be chosen over HTTP for this request

getEnsureHttps() : boolean
inherited

Response

boolean

true if HTTPS must be chosen

Get used HTTP method

getMethod() : static
inherited abstract

Response

static

Used HTTP method

Get URI to the endpoint

getPath() : string
inherited abstract

Response

string

URI to the endpoint

Get query parameters

getQueryParameters() : array
inherited abstract

Response

array

Values of query parameters (name of parameter => value of the parameter)

Get request timeout

getTimeout() : integer
inherited

Response

integer

Request timeout in milliseconds

Sets if HTTPS must be chosen over HTTP for this request

setEnsureHttps( $ensure_https) 
inherited

Arguments

$ensure_https

Sets request timeout

setTimeout( $timeout) 
inherited

Arguments

$timeout

Properties

Name of the item property to be created. Currently, the following names are reserved:`id`, `itemid`, case insensitively. Also, the length of the property name must not exceed 63 characters.

property_name : string
var

Name of the item property to be created. Currently, the following names are reserved:id, itemid, case insensitively. Also, the length of the property name must not exceed 63 characters.

Type(s)

string

Value type of the item property to be created. One of: `int`, `double`, `string`, `boolean`, `timestamp`, `set`, `image` or `imageList`. * `int`- Signed integer number. * `double` - Floating point number. It uses 64-bit base-2 format (IEEE 754 standard). * `string` - UTF-8 string. * `boolean` - *true* / *false* * `timestamp` - Value representing date and time. * `set` - Set of strings. * `image` - URL of an image (`jpeg`, `png` or `gif`). * `imageList` - List of URLs that refer to images.

type : string
var

Value type of the item property to be created. One of: int, double, string, boolean, timestamp, set, image or imageList.

  • int- Signed integer number.
  • double - Floating point number. It uses 64-bit base-2 format (IEEE 754 standard).
  • string - UTF-8 string.
  • boolean - true / false
  • timestamp - Value representing date and time.
  • set - Set of strings.
  • image - URL of an image (jpeg, png or gif).
  • imageList - List of URLs that refer to images.

Type(s)

string

Timeout of the request in milliseconds

timeout : integer
inherited
var

Timeout of the request in milliseconds

Type(s)

integer

Sets if the HTTPS must be chosen over HTTP for this request

ensure_https : boolean
inherited
var

Sets if the HTTPS must be chosen over HTTP for this request

Type(s)

boolean