{"id":4859,"date":"2024-07-17T08:44:09","date_gmt":"2024-07-17T08:44:09","guid":{"rendered":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/?page_id=4859"},"modified":"2024-07-17T08:57:19","modified_gmt":"2024-07-17T08:57:19","slug":"join-ad-domain","status":"publish","type":"page","link":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/actions\/join-ad-domain\/","title":{"rendered":"Join AD Domain"},"content":{"rendered":"<div class=\"method-copy\">\n<div class=\"method-copy-padding\">\n<h2> Join AD Domain <\/h2>\n<div class=\"table-responsive\">\n<table id=\"table_61516733\" width=\"100%\" class=\"table table-bordered\">\n<thead>\n<tr>\n<th width=\"15%\"> <strong>Argument<\/strong> <\/th>\n<th width=\"12%\"> <strong>Type<\/strong> <\/th>\n<th width=\"30%\"> <strong>Description<\/strong> <\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>domain<\/td>\n<td> String <\/td>\n<td>Required. Name of the domain to be linked.<\/td>\n<\/tr>\n<tr>\n<td>server<\/td>\n<td> String <\/td>\n<td>Required. Specify the full name of the domain controller that hosts the domain. <\/td>\n<\/tr>\n<tr>\n<td>username<\/td>\n<td> String <\/td>\n<td>Required. Enter the username of the corresponding user\u2019s AD login credentials.<\/td>\n<\/tr>\n<tr>\n<td>password<\/td>\n<td> String <\/td>\n<td>Optional. Enter the password of the corresponding user\u2019s AD login credentials.<\/td>\n<\/tr>\n<tr>\n<td>restart<\/td>\n<td> Boolean <\/td>\n<td>If true == Restarts the device,<br \/>\nIf false == Doesn\u2019t restart the device. <\/td>\n<\/tr>\n<tr>\n<td>users<\/td>\n<td> Array <\/td>\n<td>Optional. IDs of the users.<\/td>\n<\/tr>\n<tr>\n<td>usergroups<\/td>\n<td> Array <\/td>\n<td>Optional. IDs of the user groups.<\/td>\n<\/tr>\n<tr>\n<td>devices<\/td>\n<td> Array <\/td>\n<td>Optional. IDs of the devices.<\/td>\n<\/tr>\n<tr>\n<td>devicegroups<\/td>\n<td> Array <\/td>\n<td>Optional. IDs of the device groups.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"method-example\">\n<div class=\"curl-text\">curl<\/div>\n<div class=\"code-curl code-div active-code\">\n<div class=\"method-example-part\">\nHTTP Request:<\/p>\n<pre class=\"lang:default decode:true\">POST https:\/\/<portal>.hexnodemdm.com\/api\/v1\/actions\/ad_domain_join\/ \r\nheaders:- \r\nAuthorization: <api key> \r\nContent-Type: application\/json \r\nSample Post Data:- \r\n[{ \r\n\"users\":[0], \r\n\"usergroups\":[4], \r\n\"devices\":[5,6], \r\n\"devicegroups\":[12], \r\n\"domain\": \"<domain name>\",\r\n\"server\": \"<server address>\",\r\n\"username\": \"<username>\",\r\n\"password\": \"<password>\",\r\n\"restart\": true,\r\n}] \r\n\r\n<\/pre>\n<p>Shell Command:<\/p>\n<pre class=\"lang:default decode:true\">curl  -H \"Authorization: <your API key>\" -H \"Content-Type: application\/json\" -d '{\"users\":[0],\"usergroups\":[4],\"devices\":[5,6],\"devicegroups\":[12],\"domain\": \"<domain name>\",\"server\":\"<server address>\",\"username\":\"<username>\",\"password\":\"<password>\",\"restart\":true}' https:\/\/<portal>.hexnodemdm.com\/api\/v1\/actions\/ad_domain_join\/ \r\n<\/pre>\n<\/div>\n<\/div>\n<div class=\"code-curl code-div active-code\">\n<div class=\"method-example-part\">\nHTTP Response:<\/p>\n<pre class=\"lang:default decode:true\">HTTP\/1.1 200 ok\r\n<\/pre>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Join AD Domain Argument Type Description domain String Required. Name of the domain to be linked. server String Required. Specify the full name of the domain controller that hosts the domain. username String Required. Enter the username of the corresponding user\u2019s AD login credentials. password String Optional. Enter the password of the corresponding user\u2019s AD [&hellip;]<\/p>\n","protected":false},"author":11,"featured_media":0,"parent":3698,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"class_list":["post-4859","page","type-page","status-publish","hentry"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/pages\/4859","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/users\/11"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/comments?post=4859"}],"version-history":[{"count":5,"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/pages\/4859\/revisions"}],"predecessor-version":[{"id":4872,"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/pages\/4859\/revisions\/4872"}],"up":[{"embeddable":true,"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/pages\/3698"}],"wp:attachment":[{"href":"https:\/\/www.hexnode.com\/mobile-device-management\/developers\/wp-json\/wp\/v2\/media?parent=4859"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}