{"id":32403,"date":"2022-02-03T17:02:26","date_gmt":"2022-02-03T23:02:26","guid":{"rendered":"http:\/\/www.multitech.net\/developer\/?page_id=32403"},"modified":"2022-02-04T10:11:06","modified_gmt":"2022-02-04T16:11:06","slug":"create-an-install-app-task-on-a-device-specifying-app-version-and-configuration","status":"publish","type":"page","link":"https:\/\/www.multitech.net\/developer\/software\/devicehq\/account-api-extensions-for-task-management\/detailed-request-examples\/create-an-install-app-task-on-a-device-specifying-app-version-and-configuration\/","title":{"rendered":"Create an Install App Task on a Device, Specifying App Version and Configuration"},"content":{"rendered":"<p>This example creates an install app task on a device, specifys the app version, and the app configurations to apply after the install. App configurations are specified by ID in the config_ids array.<\/p>\n<pre class=\"brush:xml\">\r\nPOST \/api\/v2\/devices\/997270969\/tasks\r\n{\r\n  \"data\": {\r\n    \"type\": \"tasks\",\r\n    \"attributes\": {\r\n      \"type\": \"INSTALL_APP\",\r\n      \"app_id\": \"60d0e0d631eddd4f5a2f5d85\",\r\n      \"version\": \"4.3.3\",\r\n      \"config_ids\": [\r\n        \"60d0e0d631eddd4f5a2f5d8c\"\r\n      ]\r\n    }\r\n  }\r\n}<\/pre>\n<p>RESPONSE<\/p>\n<pre class=\"brush:xml\">\r\n{\r\n  \"data\": {\r\n    \"id\": \"60d0e0d631eddd4f5a2f5d90\",\r\n    \"type\": \"tasks\",\r\n    \"attributes\": {\r\n      \"function\": \"INSTALL_APP\",\r\n      \"created_at\": \"2021-06-21T18:56:22.638Z\",\r\n      \"state\": \"queued\",\r\n      \"app_id\": \"60d0e0d631eddd4f5a2f5d85\",\r\n      \"config_ids\": \"60d0e0d631eddd4f5a2f5d8c\",\r\n      \"app\": {\r\n        \"name\": \"app_56448630\",\r\n        \"version\": \"4.3.3\",\r\n        \"config_ids\": \"60d0e0d631eddd4f5a2f5d8c\",\r\n        \"id\": \"60d0e0d631eddd4f5a2f5d85\"\r\n      },\r\n      \"version\": \"4.3.3\"\r\n    }\r\n  }\r\n}\r\n\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>This example creates an install app task on a device, specifys the app version, and the app configurations to apply after the install. App configurations are specified by ID in the config_ids array. POST \/api\/v2\/devices\/997270969\/tasks { &#8220;data&#8221;: { &#8220;type&#8221;: &#8220;tasks&#8221;, &#8220;attributes&#8221;: { &#8220;type&#8221;: &#8220;INSTALL_APP&#8221;, &#8220;app_id&#8221;: &#8220;60d0e0d631eddd4f5a2f5d85&#8221;, &#8220;version&#8221;: &#8220;4.3.3&#8221;, &#8220;config_ids&#8221;: [ &#8220;60d0e0d631eddd4f5a2f5d8c&#8221; ] } } } [&hellip;]<\/p>\n","protected":false},"author":537,"featured_media":0,"parent":32378,"menu_order":4,"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-32403","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/32403","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\/537"}],"replies":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/comments?post=32403"}],"version-history":[{"count":4,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/32403\/revisions"}],"predecessor-version":[{"id":32498,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/32403\/revisions\/32498"}],"up":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/32378"}],"wp:attachment":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/media?parent=32403"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}