{"id":26000,"date":"2018-08-10T12:41:36","date_gmt":"2018-08-10T17:41:36","guid":{"rendered":"http:\/\/www.multitech.net\/developer\/?page_id=26000"},"modified":"2020-09-24T10:56:08","modified_gmt":"2020-09-24T15:56:08","slug":"using-curl-for-commissioning","status":"publish","type":"page","link":"https:\/\/www.multitech.net\/developer\/software\/mtr-software\/mtr-api-reference\/rcell_api_appendix\/using-curl-for-commissioning\/","title":{"rendered":"Using curl for Commissioning"},"content":{"rendered":"<p>Execute this command to check that the device is in the commissioning mode.<\/p>\n<pre class=\"brush:xml\">curl -k \"https:\/\/192.168.2.1\/api\/commissioning\"\r\n{\r\n\"code\" : 200,\r\n\"status\" : \"success\"\r\n}<\/pre>\n<p>Execute this command to set the username. In this example, the username is <strong>admin. NOTE:\u00a0<\/strong>Copy or write down the\u00a0<strong>aasID<\/strong>\u00a0value (a 30-character alphanumeric string provided after you request a commissioning session or password change, which is not the same as the token used to log in)\u00a0as you must use it in the further commands.<\/p>\n<pre class=\"brush:xml\">curl -k -X POST -H \"Content-Type: application\/json\" -d '{\"username\":\"admin\", \"aasID\": \"\", \"aasAnswer\":\"\"}' https:\/\/192.168.2.1:443\/api\/commissioning\r\n{\r\n\"code\" : 200,\r\n\"result\" : {\r\n\"aasDone\" : false,\r\n\"aasID\" : \"5EC7E7C8FE2A6E3584D2A124A10E9\",\r\n\"aasMsg\" : \"New password: \",\r\n\"aasType\" : \"question; input hide\"\r\n},\r\n\"status\" : \"success\"\r\n}<\/pre>\n<p>Execute this command to set the password. Use the <strong>aasID<\/strong> value that is received in the previous response.\u00a0 Use\u00a0<strong>aasAnswer <\/strong>value to provide the new password.<\/p>\n<pre class=\"brush:xml\">curl -k -X POST -H \"Content-Type: application\/json\" -d '{\"username\":\"admin\", \"aasID\": \"5EC7E7C8FE2A6E3584D2A124A10E9\", \"aasAnswer\":\"Admin123\"}' https:\/\/192.168.2.1:443\/api\/commissioning\r\n{\r\n\"code\" : 200,\r\n\"result\" : {\r\n\"aasDone\" : false,\r\n\"aasID\" : \"5EC7E7C8FE2A6E3584D2A124A10E9\",\r\n\"aasMsg\" : \"Retype new password: \",\r\n\"aasType\" : \"question; input hide\"\r\n},\r\n\"status\" : \"success\"\r\n}<\/pre>\n<p>Execute this command to confirm the password. If you get a response to the command &#8220;Change password success!&#8221;, it means that the commissioning mode has been completed successfully.<\/p>\n<pre class=\"brush:xml\">curl -k -X POST -H \"Content-Type: application\/json\" -d '{\"username\":\"admin\", \"aasID\": \"5EC7E7C8FE2A6E3584D2A124A10E9\", \"aasAnswer\":\"Admin123\"}' https:\/\/192.168.2.1:443\/api\/commissioning\r\n{\r\n\"code\" : 200,\r\n\"result\" : {\r\n\"aasDone\" : true,\r\n\"aasID\" : \"5EC7E7C8FE2A6E3584D2A124A10E9\",\r\n\"aasMsg\" : \"Change password success!\",\r\n\"aasType\" : \"info\"\r\n},\r\n\"status\" : \"success\"\r\n}<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Execute this command to check that the device is in the commissioning mode. curl -k &#8220;https:\/\/192.168.2.1\/api\/commissioning&#8221; { &#8220;code&#8221; : 200, &#8220;status&#8221; : &#8220;success&#8221; } Execute this command to set the username. In this example, the username is admin. NOTE:\u00a0Copy or write down the\u00a0aasID\u00a0value (a 30-character alphanumeric string provided after you request a commissioning session or [&hellip;]<\/p>\n","protected":false},"author":1478,"featured_media":0,"parent":13423,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"footnotes":""},"class_list":["post-26000","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/26000","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/users\/1478"}],"replies":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/comments?post=26000"}],"version-history":[{"count":10,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/26000\/revisions"}],"predecessor-version":[{"id":26297,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/26000\/revisions\/26297"}],"up":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/13423"}],"wp:attachment":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/media?parent=26000"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}