public static function add_rating_returns() {

        return new external_single_structure(
            array(
                'success' => new external_value(PARAM_BOOL, 'Whether the rate was successfully created'),
                'aggregate' => new external_value(PARAM_TEXT, 'New aggregate', VALUE_OPTIONAL),
                'count' => new external_value(PARAM_INT, 'Ratings count', VALUE_OPTIONAL),
                'itemid' => new external_value(PARAM_INT, 'Rating item id', VALUE_OPTIONAL),
                'warnings'  => new external_warnings(),
            )
        );
    }