RestService :: validateRobot: Bitrix method

      
<?php 
//  Bitrix\Bizproc\RestService :: validateRobot()
//  /dist/bitrix/modules/bizproc/lib/restservice.php:1426

    
private static function validateRobot($data$server)
    {
        if (!
is_array($data) || empty($data))
            throw new 
RestException('Empty data!'self::ERROR_ACTIVITY_VALIDATION_FAILURE);

        static::
validateActivityCode($data['CODE']);
        static::
validateActivityHandler($data['HANDLER'], $server);
        if (empty(
$data['NAME']))
            throw new 
RestException('Empty activity NAME!'self::ERROR_ACTIVITY_VALIDATION_FAILURE);

        if (isset(
$data['PROPERTIES']))
            static::
validateActivityProperties($data['PROPERTIES'], true);

        if (isset(
$data['RETURN_PROPERTIES']))
            static::
validateActivityProperties($data['RETURN_PROPERTIES']);
        if (isset(
$data['FILTER']) && !is_array($data['FILTER']))
            throw new 
RestException('Wrong activity FILTER!'self::ERROR_ACTIVITY_VALIDATION_FAILURE);
    }