lib/SiftClient.php
public function label($userId, $properties, $opts = array()) {
        $this->mergeArguments($opts, array(
            'timeout' => $this->timeout,
            'version' => $this->version
        ));

        $this->validateArgument($userId, 'user id', 'string');
        $this->validateArgument($properties, 'properties', 'array');

        return $this->track('$label', $properties, array(
            'timeout' => $opts['timeout'],
            'version' => $opts['version'],
            'path' => $this->userLabelApiUrl($userId, $opts['version'])
        ));
    }
public function label($userId, $properties, $opts = array()) {
        $this->mergeArguments($opts, array(
            'timeout' => $this->timeout,
            'version' => $this->version
        ));

        $this->validateArgument($userId, 'user id', 'string');
        $this->validateArgument($properties, 'properties', 'array');

        return $this->track('$label', $properties, array(
            'timeout' => $opts['timeout'],
            'version' => $opts['version'],
            'path' => $this->userLabelApiUrl($userId, $opts['version'])
        ));
    }
public function label ( $ userId , $ properties , $ opts = array ( ) ) { $ this -> mergeArguments ( $ opts , array ( 'timeout' => $ this -> timeout , 'version' => $ this -> version ) ) ; $ this -> validateArgument ( $ userId , 'user id' , 'string' ) ; $ this -> validateArgument ( $ properties , 'properties' , 'array' ) ; return $ this -> track ( '$label' , $ properties , array ( 'timeout' => $ opts [ 'timeout' ] , 'version' => $ opts [ 'version' ] , 'path' => $ this -> userLabelApiUrl ( $ userId , $ opts [ 'version' ] ) ) ) ; }
Labels a user as either good or bad through the Sift Science API.

See https://siftscience.com/resources/references/labels_api.html for valid $properties
fields.

@param string $userId  The ID of a user.  This parameter is required.

@param array $properties An array of name-value pairs that specify the label attributes.
This parameter is required.

@param array $opts  Array of optional parameters for this request:
- int 'timeout': By default, this client's timeout is used.
- string 'version': By default, this client's version is used.

@return null|SiftResponse
Labels a user as either good or bad through the Sift Science API .