var examplesData = [{"section":"\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435","name":"\u0412\u0432\u0435\u0434\u0435\u043d\u0438\u0435","description":"

\u0412\u0441\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441 API \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043f\u0443\u0442\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u0441 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0443\u044e\u0449\u0438\u043c\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c\u0438 \u043f\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0443:https:\/\/{server}<\/b>:{port}<\/b>\/api\/0\/{operation}<\/b>?{parametr1}<\/b>={value1}<\/b>&{parametrN}<\/b>={valueN}<\/b><\/span>\u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u043e\u043b\u044c\u0448\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0437\u0430\u043a\u0430\u0437) \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0447\u0435\u0440\u0435\u0437 POST.<\/br><\/br>\u0414\u043b\u044f POST-\u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c Content-Type: application\/json.<\/span><\/br><\/br> \u0411\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u044b\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0432\u044b \u043d\u0430\u0439\u0434\u0435\u0442\u0435 \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u043a API Iiko delivery.<\/p>

\u0412 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f 3 \u043d\u0435\u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0438, \u0437\u0430\u043d\u0438\u043c\u0430\u044e\u0449\u0438\u0435\u0441\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u043e\u0439 \u0432\u0441\u0435\u0433\u043e:<\/p>

curl_get()<\/b>

\n\/**\n* http:\/\/www.php.net\/manual\/ru\/function.curl-exec.php\n*\/\n\/**\n* Send a GET request using cURL\n* @param string $url to request\n* @param array $get values to send\n* @param array $options for cURL\n* @return string\n*\/\n\nfunction curl_get($url, array $get = NULL, array $options = array()) {\n    $defaults = array(\n        CURLOPT_URL => $url . (strpos($url, \"?\") === FALSE ? \"?\" : \"\") . http_build_query($get) ,\n        CURLOPT_HEADER => 0,\n        CURLOPT_RETURNTRANSFER => TRUE,\n        CURLOPT_DNS_USE_GLOBAL_CACHE => false,\n        CURLOPT_SSL_VERIFYHOST => 0, \/\/unsafe, but the fastest solution for the error \" SSL certificate problem, verify that the CA cert is OK\"\n        CURLOPT_SSL_VERIFYPEER => 0, \/\/unsafe, but the fastest solution for the error \" SSL certificate problem, verify that the CA cert is OK\"\n    );\n    $ch = curl_init();\n    curl_setopt_array($ch, ($options + $defaults));\n    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n\n\n    if (!$result = curl_exec($ch)) {\n        trigger_error(curl_error($ch));\n    }\n\n    curl_close($ch);\n    return $result;\n}\n<\/pre>\n<\/p>

curl_post()<\/b>

\n\/**\n* http:\/\/www.php.net\/manual\/ru\/function.curl-exec.php\n*\/\n\/**\n* Send a POST request using cURL\n* @param string $url to request\n* @param array|string $post values to send\n* @param array $options for cURL\n* @internal param array $get\n* @return string\n*\/\nfunction curl_post($url, $post = null, array $options = array()) {\n    $defaults = array(\n                        CURLOPT_POST => 1,\n                        CURLOPT_HEADER => 0,\n                        CURLOPT_URL => $url,\n                        CURLOPT_FRESH_CONNECT => 1,\n                        CURLOPT_RETURNTRANSFER => 1,\n                        CURLOPT_FORBID_REUSE => 1,\n                        CURLOPT_SSL_VERIFYHOST =>0,\/\/unsafe, but the fastest solution for the error \" SSL certificate problem, verify that the CA cert is OK\"\n                        CURLOPT_SSL_VERIFYPEER=>0, \/\/unsafe, but the fastest solution for the error \" SSL certificate problem, verify that the CA cert is OK\"\n                        CURLOPT_POSTFIELDS => $post\n                    );\n    $ch = curl_init();\n    curl_setopt_array($ch, ($options + $defaults));\n    if( ! $result = curl_exec($ch)){\n        trigger_error(curl_error($ch));\n    }\n    curl_close($ch);\n    return $result;\n}\n<\/pre><\/p>

getGUID()<\/b>

\nfunction getGUID(){\n    if (function_exists(\"com_create_guid\")){\n        return com_create_guid();\n    }else{\n        mt_srand((double)microtime()*10000);\/\/optional for php 4.2.0 and up.\n        $charId = md5(uniqid(rand(), true));\n        $hyphen = chr(45);\/\/ \"-\"\n        $uuid =substr($charId, 0, 8).$hyphen\n        .substr($charId, 8, 4).$hyphen\n        .substr($charId,12, 4).$hyphen\n        .substr($charId,16, 4).$hyphen\n        .substr($charId,20,12);\n        return $uuid;\n    }\n}\n<\/pre><\/p>

\u041f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0432 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u0441\u043e\u043a\u0440\u0430\u0449\u0435\u043d\u043d\u043e\u043c \u0434\u043b\u044f \u0447\u0438\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0435, \u043f\u0440\u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0443 \u0441\u0435\u0431\u044f, \u043d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u0439\u0442\u0435 \u0432\u0430\u043b\u0438\u0434\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0432\u0435\u0434\u0435\u043d\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0438.\u0442.\u043f.<\/p>","steps":[],"exampleName":"main"},{"section":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","name":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430 \u0434\u043e\u0441\u0442\u0430\u0432\u043a\u0438","description":"","steps":[{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430","use_method":"get_access_token"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0439","use_method":"get_organization_list"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044e","use_method":"get_organization_nomenclature"},{"name":"\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u043e\u0432\u0430\u0440\u043e\u0432 \u0432 \u0437\u0430\u043a\u0430\u0437","description":"

\u041d\u0430 \u044d\u0442\u043e\u043c \u0448\u0430\u0433\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0437\u0430\u043a\u0430\u0437, \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u044d\u0442\u043e \u0437\u0430 \u043d\u0435\u0433\u043e \u0438 \u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0431\u043b\u044e\u0434 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445<\/p>","use_method":false,"customProcess":"addRandomItemsToOrder"},{"name":"\u041e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","use_method":"add_order","customProcess":"addOrder","final":"\u0413\u043e\u0442\u043e\u0432\u043e! \u0417\u0430\u043a\u0430\u0437 \u0441\u043e\u0437\u0434\u0430\u043d! \u041d\u043e\u043c\u0435\u0440 \u0437\u0430\u043a\u0430\u0437\u0430: {{number}}"}],"exampleName":"base_create_order"},{"section":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","name":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430 \u0434\u043e\u0441\u0442\u0430\u0432\u043a\u0438 (\u0441 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u0430\u043c\u0438)","description":"","steps":[{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430","use_method":"get_access_token"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0439","use_method":"get_organization_list"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044e","use_method":"get_organization_nomenclature"},{"name":"\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u043e\u0432\u0430\u0440\u043e\u0432 \u0441 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u0430\u043c\u0438 \u0432 \u0437\u0430\u043a\u0430\u0437","description":"

\u041d\u0430 \u044d\u0442\u043e\u043c \u0448\u0430\u0433\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0437\u0430\u043a\u0430\u0437 \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b \u043a \u0431\u043b\u044e\u0434\u0430\u043c \u0438\u0437 \u043c\u0435\u043d\u044e, \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u044d\u0442\u043e \u0437\u0430 \u043d\u0435\u0433\u043e \u0438 \u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0431\u043b\u044e\u0434 \u0441\u043e \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u043c\u0438 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u0430\u043c\u0438 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445<\/p>","use_method":false,"customProcess":"addRandomItemsWithModToOrder"},{"name":"\u041e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","use_method":"add_order","customProcess":"addOrder","final":"\u0413\u043e\u0442\u043e\u0432\u043e! \u0417\u0430\u043a\u0430\u0437 \u0441\u043e\u0437\u0434\u0430\u043d! \u041d\u043e\u043c\u0435\u0440 \u0437\u0430\u043a\u0430\u0437\u0430: {{number}}"}],"exampleName":"create_order_with_modif"},{"section":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","name":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430 \u0434\u043e\u0441\u0442\u0430\u0432\u043a\u0438 \u0441 \u043e\u043f\u043b\u0430\u0442\u0430\u043c\u0438","description":"","steps":[{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430","use_method":"get_access_token"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0439","use_method":"get_organization_list"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u0438\u043f\u043e\u0432 \u043e\u043f\u043b\u0430\u0442","use_method":"get_payment_types"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044e","use_method":"get_organization_nomenclature"},{"name":"\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u043e\u0432\u0430\u0440\u043e\u0432 \u0432 \u0437\u0430\u043a\u0430\u0437","description":"

\u041d\u0430 \u044d\u0442\u043e\u043c \u0448\u0430\u0433\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0437\u0430\u043a\u0430\u0437, \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u044d\u0442\u043e \u0437\u0430 \u043d\u0435\u0433\u043e \u0438 \u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0431\u043b\u044e\u0434 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445<\/p>","use_method":false,"customProcess":"addRandomItemsToOrder"},{"name":"\u041e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","use_method":"add_order_with_payment","customProcess":"addOrderWithPayment","final":"\u0413\u043e\u0442\u043e\u0432\u043e! \u0417\u0430\u043a\u0430\u0437 \u0441\u043e\u0437\u0434\u0430\u043d! \u041d\u043e\u043c\u0435\u0440 \u0437\u0430\u043a\u0430\u0437\u0430: {{number}}"}],"exampleName":"create_order_with_payments"},{"section":"\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0437\u0430\u043a\u0430\u0437\u0430","name":"\u0420\u0430\u0441\u0441\u0447\u0438\u0442\u0430\u0442\u044c \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0443 \u043b\u043e\u044f\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0434\u043b\u044f \u0437\u0430\u043a\u0430\u0437\u0430","description":"","steps":[{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430","use_method":"get_access_token"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0439","use_method":"get_organization_list"},{"name":"\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u043d\u044e","use_method":"get_organization_nomenclature"},{"name":"\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u043e\u0432\u0430\u0440\u043e\u0432 \u0432 \u0437\u0430\u043a\u0430\u0437","description":"

\u041d\u0430 \u044d\u0442\u043e\u043c \u0448\u0430\u0433\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0437\u0430\u043a\u0430\u0437, \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u044d\u0442\u043e \u0437\u0430 \u043d\u0435\u0433\u043e \u0438 \u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0445 \u0431\u043b\u044e\u0434 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0445<\/p>","use_method":false,"customProcess":"addRandomItemsToOrder"},{"name":"\u041e\u0442\u043f\u0440\u0430\u0432\u043a\u0430 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043d\u0430 \u0440\u0430\u0441\u0441\u0447\u0451\u0442 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u043b\u043e\u044f\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0434\u043b\u044f \u0437\u0430\u043a\u0430\u0437\u0430","use_method":"add_order","customProcess":"calculateCheckinResult","final":"\u0413\u043e\u0442\u043e\u0432\u043e! \u0420\u0430\u0441\u0441\u0447\u0451\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0451\u043d \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d!"}],"exampleName":"calculate_checkin_result"}];