AddUserProperty extends Request
Adding an user property is somehow equivalent to adding a column to the table of users. The users may be characterized by various properties of different types.
Table of Contents
- $ensure_https : bool
- $property_name : string
- $timeout : int
- $type : string
- __construct() : mixed
- Construct the request
- getBodyParameters() : array<string|int, mixed>
- Get body parameters
- getEnsureHttps() : bool
- Returns true if HTTPS must be chosen over HTTP for this request
- getMethod() : static
- Get used HTTP method
- getPath() : string
- Get URI to the endpoint
- getQueryParameters() : array<string|int, mixed>
- Get query parameters
- getTimeout() : int
- Get request timeout
- setEnsureHttps() : mixed
- Sets if HTTPS must be chosen over HTTP for this request
- setTimeout() : mixed
- Sets request timeout
Properties
$ensure_https
protected
bool
$ensure_https
$property_name
protected
string
$property_name
$timeout
protected
int
$timeout
$type
protected
string
$type
Methods
__construct()
Construct the request
public
__construct(string $property_name, string $type) : mixed
Parameters
- $property_name : string
-
Name of the user property to be created. Currently, the following names are reserved:
id
,userid
, case insensitively. Also, the length of the property name must not exceed 63 characters. - $type : string
-
Value type of the user property to be created. One of:
int
,double
,string
,boolean
,timestamp
,set
.-
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.
-
Return values
mixed —getBodyParameters()
Get body parameters
public
getBodyParameters() : array<string|int, mixed>
Return values
array<string|int, mixed> —Values of body parameters (name of parameter => value of the parameter)
getEnsureHttps()
Returns true if HTTPS must be chosen over HTTP for this request
public
getEnsureHttps() : bool
Return values
bool —true if HTTPS must be chosen
getMethod()
Get used HTTP method
public
getMethod() : static
Return values
static —Used HTTP method
getPath()
Get URI to the endpoint
public
getPath() : string
Return values
string —URI to the endpoint
getQueryParameters()
Get query parameters
public
getQueryParameters() : array<string|int, mixed>
Return values
array<string|int, mixed> —Values of query parameters (name of parameter => value of the parameter)
getTimeout()
Get request timeout
public
getTimeout() : int
Return values
int —Request timeout in milliseconds
setEnsureHttps()
Sets if HTTPS must be chosen over HTTP for this request
public
setEnsureHttps(mixed $ensure_https) : mixed
Parameters
- $ensure_https : mixed
Return values
mixed —setTimeout()
Sets request timeout
public
setTimeout(mixed $timeout) : mixed
Parameters
- $timeout : mixed