From a8e324247bbcf9ce820339eba93397a0803c84ed Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 27 May 2024 17:49:48 +0200 Subject: [PATCH 01/79] Update rest-api.md --- docs/REST API/rest-api.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index dbb2f72381ab..f984ab35d0b8 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -5788,6 +5788,7 @@ This endpoint returns the list of custom MDM commands that have been executed. - [Get Apple Push Notification service (APNs)](#get-apple-push-notification-service-apns) - [Get Apple Business Manager (ABM)](#get-apple-business-manager-abm) +- [Get Volume Purchasing Program (VPP)](#get-volume-purchasing-program-vpp) ### Get Apple Push Notification service (APNs) @@ -5842,6 +5843,27 @@ None. } ``` +Get Volume Purchasing Program (VPP) + +_Available in Fleet Premium_ + +`GET /api/v1/fleet/vpp` + +#### Example + +`GET /api/v1/fleet/vpp` + +##### Default response + +`Status: 200` + +```json +{ + "org_name": "Fleet Device Management", + "renew_date": "2023-11-29T00:00:00Z", +} +``` + --- ## Policies From 622b78af97649a6f3ff6a4a2602d9f6f833b3131 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 27 May 2024 18:15:11 +0200 Subject: [PATCH 02/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 36 +++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 08a501809530..a14bcb97e794 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -536,6 +536,7 @@ The MDM endpoints exist to support the related command-line interface sub-comman - [Preassign profiles to devices](#preassign-profiles-to-devices) - [Match preassigned profiles](#match-preassigned-profiles) - [Get FileVault statistics](#get-filevault-statistics) +- [Upload VPP content token](#upload-vpp-content-token) ### Generate Apple DEP Key Pair @@ -773,6 +774,41 @@ This endpoint uses the profiles stored by the [Preassign profiles to devices](#p `Status: 204` +### Upload VPP content token + +`POST /api/v1/fleet/mdm/apple/vpp_token` + +#### Parameters + +| Name | Type | In | Description | +| ---- | ---- | -- | ----------- | +| token | file | form | *Required* The file containing the content token (.vpptoken) from Apple Business Manager | + +#### Example + +`POST /api/v1/fleet/mdm/apple/vpp_token` + +##### Request header + +```http +Content-Length: 850 +Content-Type: multipart/form-data; boundary=------------------------f02md47480und42y +``` + +##### Request body + +```http +--------------------------f02md47480und42y +Content-Disposition: form-data; name="token"; filename="sToken_for_Acme.vpptoken" +Content-Type: application/octet-stream + +--------------------------f02md47480und42y +``` + +##### Default response + +`Status: 200` + ## Get or apply configuration files These API routes are used by the `fleetctl` CLI tool. Users can manage Fleet with `fleetctl` and [configuration files in YAML syntax](https://fleetdm.com/docs/using-fleet/configuration-files/). From 7feee4ba425544239dce2adfe9ba03961b06e067 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 27 May 2024 18:22:39 +0200 Subject: [PATCH 03/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index a14bcb97e794..6df3e696d8cb 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -809,6 +809,20 @@ Content-Type: application/octet-stream `Status: 200` + +### Disable VPP + +`DELETE /api/v1/fleet/mdm/apple/vpp_token` + +#### Example + +`DELETE /api/v1/fleet/mdm/apple/vpp_token` + +##### Default response + +`Status: 204` + + ## Get or apply configuration files These API routes are used by the `fleetctl` CLI tool. Users can manage Fleet with `fleetctl` and [configuration files in YAML syntax](https://fleetdm.com/docs/using-fleet/configuration-files/). From 2c81ef98680ff3ff45970eba45c94ccb6fa7603c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 27 May 2024 18:51:38 +0200 Subject: [PATCH 04/79] Update rest-api.md --- docs/REST API/rest-api.md | 58 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 57 insertions(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index f984ab35d0b8..4d4f92caab1e 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8025,6 +8025,8 @@ Deletes the session specified by ID. When the user associated with the session n - [List software versions](#list-software-versions) - [Get software](#get-software) - [Get software version](#get-software-version) +- [Get VPP software](#get-vpp-software) +- [Add VPP software](#add-vpp-software) ### Add software @@ -8481,8 +8483,62 @@ Returns information about the specified software version. } ``` -## Vulnerabilities +### Get VPP software + +Returns the list of software purchased in Apple Business Manager. + +`GET /api/v1/fleet/software/vpp` + +#### Example + +`GET /api/v1/fleet/software/versions/12` + +##### Default response + +`Status: 200` + +```json +{ + "vpp_software": { + { + "id": 1, + "name": "Xcode", + "latest_version": "15.4", + }, + { + "id": 2, + "name": "Xcode", + "latest_version": "15.4", + }, +} +} +``` + +### Add VPP software + +_Available in Fleet Premium._ + +Add a VPP software form App Store to the Fleet software title. +`POST /api/v1/fleet/software/vpp/:id` + +#### Parameters + +| Name | Type | In | Description | +| ---- | ---- | -- | ----------- | +| id | integer | path | **Required.** The VPP software's ID. | +| team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | + +#### Example + +`POST /api/v1/fleet/software/vpp/2?team_id=3` + +##### Default response + +`Status: 200` + + +## Vulnerabilities - [List vulnerabilities](#list-vulnerabilities) - [Get vulnerability](#get-vulnerability) From dfb4b26fddf5540783bf22fc4fa54785ee4510e8 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 27 May 2024 19:09:48 +0200 Subject: [PATCH 05/79] Update rest-api.md --- docs/REST API/rest-api.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 4d4f92caab1e..c546b86754c2 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8192,7 +8192,8 @@ Get a list of all software. | query | string | query | Search query keywords. Searchable fields include `title` and `cve`. | | team_id | integer | query | _Available in Fleet Premium_. Filters the software to only include the software installed on the hosts that are assigned to the specified team. | | vulnerable | bool | query | If true or 1, only list software that has detected vulnerabilities. Default is `false`. | -| available_for_insall | bool | query | If `true` or `1`, only list software that is available for install (added by the user). Default is `false`. | +| available_for_install | bool | query | If `true` or `1`, only list software that is available for install (added by the user). Default is `false`. | +| vpp | bool | query | If `true` or `1`, only list VPP software (added from Apple Business Manager). Default is `false`. | #### Example @@ -8388,6 +8389,7 @@ Returns information about the specified software. By default, `versions` are sor "software_title": { "id": 12, "name": "Firefox.app", + "bundle_identifier": "org.mozilla.firefox", "software_package": { "name": "FalconSensor-6.44.pkg", "version": "6.44", From 3a276d5144ba9f8e4c65ee40597751b8da0d9b05 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 28 May 2024 08:46:30 +0200 Subject: [PATCH 06/79] Update rest-api.md --- docs/REST API/rest-api.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index c546b86754c2..244806d5575d 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8426,6 +8426,35 @@ Returns information about the specified software. By default, `versions` are sor "hosts_count": 4 } ] + }, + { + "id": 15, + "name": "Logic Pro.app", + "bundle_identifier": "org.apple.logic10", + "software_package": { + "name": "Logic Pro", + "version": "2.0.11", + "uploaded_at": "2024-04-01T14:22:58Z", + "install_script": "", + "pre_install_query": "", + "post_install_script": "", + "status": { + "installed": 3, + "pending": 1, + "failed": 2, + } + }, + "source": "vpp", + "browser": "", + "hosts_count": 23, + "versions": [ + { + "id": 123, + "version": "2.0.11", + "vulnerabilities": [], + "hosts_count": 23 + } + ] } } ``` From bc25b979f2bee6dd5f82043d9dac359f89fe0634 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Fri, 31 May 2024 10:31:41 +0200 Subject: [PATCH 07/79] Update rest-api.md --- docs/REST API/rest-api.md | 34 ++++------------------------------ 1 file changed, 4 insertions(+), 30 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 244806d5575d..084feacd6100 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8390,7 +8390,9 @@ Returns information about the specified software. By default, `versions` are sor "id": 12, "name": "Firefox.app", "bundle_identifier": "org.mozilla.firefox", + "store_id": "", "software_package": { + "type": "installer", "name": "FalconSensor-6.44.pkg", "version": "6.44", "uploaded_at": "2024-04-01T14:22:58Z", @@ -8401,7 +8403,8 @@ Returns information about the specified software. By default, `versions` are sor "installed": 3, "pending": 1, "failed": 2, - } + }, + "licenses": null }, "source": "apps", "browser": "", @@ -8426,35 +8429,6 @@ Returns information about the specified software. By default, `versions` are sor "hosts_count": 4 } ] - }, - { - "id": 15, - "name": "Logic Pro.app", - "bundle_identifier": "org.apple.logic10", - "software_package": { - "name": "Logic Pro", - "version": "2.0.11", - "uploaded_at": "2024-04-01T14:22:58Z", - "install_script": "", - "pre_install_query": "", - "post_install_script": "", - "status": { - "installed": 3, - "pending": 1, - "failed": 2, - } - }, - "source": "vpp", - "browser": "", - "hosts_count": 23, - "versions": [ - { - "id": 123, - "version": "2.0.11", - "vulnerabilities": [], - "hosts_count": 23 - } - ] } } ``` From 452406d5b2598b47974caf78ea694227ebac7b14 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 5 Jun 2024 14:24:32 +0200 Subject: [PATCH 08/79] Update rest-api.md --- docs/REST API/rest-api.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 084feacd6100..b5cff68359a2 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8492,11 +8492,17 @@ Returns information about the specified software version. Returns the list of software purchased in Apple Business Manager. -`GET /api/v1/fleet/software/vpp` +`GET /api/v1/fleet/software/vpp/:team_id` + +#### Parameters + +| Name | Type | In | Description | +| ------- | ---- | -- | ----------- | +| team_id | integer | query | **Required**. The team ID. Lists available VPP software for specified team. | #### Example -`GET /api/v1/fleet/software/versions/12` +`GET /api/v1/fleet/software/vpp/3` ##### Default response From c4aeaf0aa6ab332b224c1757983ed0019fd4655b Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 5 Jun 2024 14:40:20 +0200 Subject: [PATCH 09/79] Update rest-api.md --- docs/REST API/rest-api.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index b5cff68359a2..0be346f1d7bf 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8515,11 +8515,13 @@ Returns the list of software purchased in Apple Business Manager. "id": 1, "name": "Xcode", "latest_version": "15.4", + "store_id": 497799835 }, { "id": 2, - "name": "Xcode", - "latest_version": "15.4", + "name": "Logic Pro", + "latest_version": "2.04", + "store_id": 634148309 }, } } From 6d3a3520b1bb93590cf3eb744e43e6a972d63b82 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 6 Jun 2024 14:37:49 +0200 Subject: [PATCH 10/79] Update rest-api.md --- docs/REST API/rest-api.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 0be346f1d7bf..0b7940f3de5f 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8550,6 +8550,28 @@ Add a VPP software form App Store to the Fleet software title. `Status: 200` +### Delete VPP software + +_Available in Fleet Premium._ + +Delete a VPP app from software title. + +`DELETE /api/v1/fleet/software/titles/:software_title_id/vpp` + +#### Parameters + +| Name | Type | In | Description | +| ---- | ------- | ---- | -------------------------------------------- | +| software_title_id | integer | path | **Required**. The ID of the software title for the VPP app to delete. | +| team_id | integer | query | **Required**. The team ID. Deletes a software package added to the specified team. | + +#### Example + +`DELETE /api/v1/fleet/software/titles/24/vpp?team_id=2` + +##### Default response + +`Status: 204` ## Vulnerabilities From deaae54b1801964c43dba8708a5fe24921d63742 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 6 Jun 2024 14:41:24 +0200 Subject: [PATCH 11/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 6df3e696d8cb..9e7b96f18aad 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -537,6 +537,8 @@ The MDM endpoints exist to support the related command-line interface sub-comman - [Match preassigned profiles](#match-preassigned-profiles) - [Get FileVault statistics](#get-filevault-statistics) - [Upload VPP content token](#upload-vpp-content-token) +- [Disable VPP](#disable-vpp) + ### Generate Apple DEP Key Pair From 81f260a3b2dddaa6129b30f6410c8727a71ef150 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Fri, 7 Jun 2024 19:23:42 +0200 Subject: [PATCH 12/79] Update rest-api.md --- docs/REST API/rest-api.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 0b7940f3de5f..cd66bda9dc8f 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -5859,8 +5859,9 @@ _Available in Fleet Premium_ ```json { - "org_name": "Fleet Device Management", + "org_name": "Acme Inc.", "renew_date": "2023-11-29T00:00:00Z", + "location": "Acme Inc. Main Address" } ``` From 575a96c22a312f4a17eb30225ba72c8f500c5402 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Fri, 7 Jun 2024 19:25:23 +0200 Subject: [PATCH 13/79] Update rest-api.md --- docs/REST API/rest-api.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index cd66bda9dc8f..ae3b7230d5dc 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8194,8 +8194,6 @@ Get a list of all software. | team_id | integer | query | _Available in Fleet Premium_. Filters the software to only include the software installed on the hosts that are assigned to the specified team. | | vulnerable | bool | query | If true or 1, only list software that has detected vulnerabilities. Default is `false`. | | available_for_install | bool | query | If `true` or `1`, only list software that is available for install (added by the user). Default is `false`. | -| vpp | bool | query | If `true` or `1`, only list VPP software (added from Apple Business Manager). Default is `false`. | - #### Example `GET /api/v1/fleet/software/titles` From 6fa5cfb6eb5e7f09b8b6604ab23324f6bfca00bc Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 11 Jun 2024 17:08:32 +0200 Subject: [PATCH 14/79] Update rest-api.md --- docs/REST API/rest-api.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index ae3b7230d5dc..9c281632cc23 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8389,7 +8389,6 @@ Returns information about the specified software. By default, `versions` are sor "id": 12, "name": "Firefox.app", "bundle_identifier": "org.mozilla.firefox", - "store_id": "", "software_package": { "type": "installer", "name": "FalconSensor-6.44.pkg", @@ -8402,8 +8401,7 @@ Returns information about the specified software. By default, `versions` are sor "installed": 3, "pending": 1, "failed": 2, - }, - "licenses": null + } }, "source": "apps", "browser": "", From ea2400bf23bcac72b3cacc4cdf6a4cc1e99f607b Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 11 Jun 2024 17:10:07 +0200 Subject: [PATCH 15/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 9c281632cc23..632b4669ea52 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8390,7 +8390,6 @@ Returns information about the specified software. By default, `versions` are sor "name": "Firefox.app", "bundle_identifier": "org.mozilla.firefox", "software_package": { - "type": "installer", "name": "FalconSensor-6.44.pkg", "version": "6.44", "uploaded_at": "2024-04-01T14:22:58Z", From 93556156537185c3562738b639e773b3bfd3f384 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:52:37 +0200 Subject: [PATCH 16/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 632b4669ea52..7c18106a253c 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8508,7 +8508,6 @@ Returns the list of software purchased in Apple Business Manager. { "vpp_software": { { - "id": 1, "name": "Xcode", "latest_version": "15.4", "store_id": 497799835 From be9c5cc5503b951db85431fb89e3117ba8c8519c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:53:21 +0200 Subject: [PATCH 17/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 7c18106a253c..7229878f8b06 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8513,7 +8513,6 @@ Returns the list of software purchased in Apple Business Manager. "store_id": 497799835 }, { - "id": 2, "name": "Logic Pro", "latest_version": "2.04", "store_id": 634148309 From b41d7a4fd5542a4a70854a4ec055fb4a90ccc9eb Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:53:25 +0200 Subject: [PATCH 18/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 7229878f8b06..93b19be173c5 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8510,7 +8510,7 @@ Returns the list of software purchased in Apple Business Manager. { "name": "Xcode", "latest_version": "15.4", - "store_id": 497799835 + "app_store_id": 497799835 }, { "name": "Logic Pro", From 4e489b539d3af1198db1383d22493c48c2507ecf Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:53:30 +0200 Subject: [PATCH 19/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 93b19be173c5..c8c1d8494ed9 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8515,7 +8515,7 @@ Returns the list of software purchased in Apple Business Manager. { "name": "Logic Pro", "latest_version": "2.04", - "store_id": 634148309 + "app_store_id": 634148309 }, } } From 7f6b686b7fcf1564838f6b635006599bf5dcdb58 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:55:39 +0200 Subject: [PATCH 20/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index c8c1d8494ed9..a1812662e0f1 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8533,7 +8533,7 @@ Add a VPP software form App Store to the Fleet software title. | Name | Type | In | Description | | ---- | ---- | -- | ----------- | -| id | integer | path | **Required.** The VPP software's ID. | +| app_store_id | integer | path | **Required.** The ID of Apple App Store app. | | team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | #### Example From 1daa44776714dfecb28e85bd0ed0b7c1502ad8c2 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 16:55:49 +0200 Subject: [PATCH 21/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index a1812662e0f1..e2b6defae445 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8527,7 +8527,7 @@ _Available in Fleet Premium._ Add a VPP software form App Store to the Fleet software title. -`POST /api/v1/fleet/software/vpp/:id` +`POST /api/v1/fleet/software/vpp/:app_store_id` #### Parameters From d0b980a0235301345ee55f316ea2607033c49b16 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 17:03:38 +0200 Subject: [PATCH 22/79] Update rest-api.md --- docs/REST API/rest-api.md | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index e2b6defae445..1f86c0ea718a 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8026,8 +8026,8 @@ Deletes the session specified by ID. When the user associated with the session n - [List software versions](#list-software-versions) - [Get software](#get-software) - [Get software version](#get-software-version) -- [Get VPP software](#get-vpp-software) -- [Add VPP software](#add-vpp-software) +- [Get available App Store apps](#get-available-app-store-apps) +- [Add App Store app](#add-app-store-app) ### Add software @@ -8484,11 +8484,11 @@ Returns information about the specified software version. } ``` -### Get VPP software +### Get available App Store apps -Returns the list of software purchased in Apple Business Manager. +Returns the list of App Store (VPP) apps purchased in Apple Business Manager. -`GET /api/v1/fleet/software/vpp/:team_id` +`GET /api/v1/fleet/software/app_store/:team_id` #### Parameters @@ -8498,7 +8498,7 @@ Returns the list of software purchased in Apple Business Manager. #### Example -`GET /api/v1/fleet/software/vpp/3` +`GET /api/v1/fleet/software/app_store/3` ##### Default response @@ -8506,7 +8506,7 @@ Returns the list of software purchased in Apple Business Manager. ```json { - "vpp_software": { + "app_store_apps": { { "name": "Xcode", "latest_version": "15.4", @@ -8521,47 +8521,45 @@ Returns the list of software purchased in Apple Business Manager. } ``` -### Add VPP software +### Add App Store app _Available in Fleet Premium._ -Add a VPP software form App Store to the Fleet software title. +Add App Store (VPP) app purchased in Apple Business Manager. -`POST /api/v1/fleet/software/vpp/:app_store_id` +`POST /api/v1/fleet/software/app_store/:app_store_id` #### Parameters | Name | Type | In | Description | | ---- | ---- | -- | ----------- | -| app_store_id | integer | path | **Required.** The ID of Apple App Store app. | +| app_store_id | integer | path | **Required.** The ID of App Store app. | | team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | #### Example -`POST /api/v1/fleet/software/vpp/2?team_id=3` +`POST /api/v1/fleet/software/app_store/2?team_id=3` ##### Default response `Status: 200` -### Delete VPP software +### Delete App Store app _Available in Fleet Premium._ -Delete a VPP app from software title. - -`DELETE /api/v1/fleet/software/titles/:software_title_id/vpp` +`DELETE /api/v1/fleet/software/titles/:software_title_id/app_store` #### Parameters | Name | Type | In | Description | | ---- | ------- | ---- | -------------------------------------------- | -| software_title_id | integer | path | **Required**. The ID of the software title for the VPP app to delete. | +| software_title_id | integer | path | **Required**. The ID of the software title to delete App Store app. | | team_id | integer | query | **Required**. The team ID. Deletes a software package added to the specified team. | #### Example -`DELETE /api/v1/fleet/software/titles/24/vpp?team_id=2` +`DELETE /api/v1/fleet/software/titles/24/app_store?team_id=2` ##### Default response From 21727effe0b07ff943b6a74d27624aca554de547 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 17:42:19 +0200 Subject: [PATCH 23/79] Update rest-api.md --- docs/REST API/rest-api.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 2307a5d8a8c5..6cbedd025cf2 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8624,6 +8624,7 @@ Add App Store (VPP) app purchased in Apple Business Manager. | ---- | ---- | -- | ----------- | | app_store_id | integer | path | **Required.** The ID of App Store app. | | team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | +| self_service | boolean | form | Self-service software is optional and can be installed by the end user. | #### Example From 4ca25078346af034b3ce0be835569ab9cf77be2b Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 20:33:19 +0200 Subject: [PATCH 24/79] Update rest-api.md --- docs/REST API/rest-api.md | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 2307a5d8a8c5..e5acf694fbec 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8107,9 +8107,9 @@ Deletes the session specified by ID. When the user associated with the session n ## Software -- [Add software](#add-software) -- [Download software](#download-software) -- [Delete software](#delete-software) +- [Add software package](#add-software) +- [Download software package](#download-software) +- [Delete software available for install](#delete-software) - [Get installation result](#get-installation-result) - [List software](#list-software) - [List software versions](#list-software-versions) @@ -8118,7 +8118,7 @@ Deletes the session specified by ID. When the user associated with the session n - [Get available App Store apps](#get-available-app-store-apps) - [Add App Store app](#add-app-store-app) -### Add software +### Add software package _Available in Fleet Premium._ @@ -8175,13 +8175,11 @@ Content-Type: application/octet-stream `Status: 200` -### Download software +### Download software available for install _Available in Fleet Premium._ -Download a software package. - -`GET /api/v1/fleet/software/titles/:software_title_id/package/?alt=media` +`GET /api/v1/fleet/software/titles/:software_title_id?alt=media` #### Parameters @@ -8193,7 +8191,7 @@ Download a software package. #### Example -`GET /api/v1/fleet/software/titles/123/package?alt=media?team_id=2` +`GET /api/v1/fleet/software/titles/123?alt=media?team_id=2` ##### Default response @@ -8207,24 +8205,24 @@ Content-Length: Body: ``` -### Delete software +### Delete software available for install _Available in Fleet Premium._ -Delete a software package. +Deletes software that's available for install (package or App Store app). -`DELETE /api/v1/fleet/software/titles/:software_title_id/package` +`DELETE /api/v1/fleet/software/titles/:software_title_id` #### Parameters | Name | Type | In | Description | | ---- | ------- | ---- | -------------------------------------------- | -| software_title_id | integer | path | **Required**. The ID of the software title for the software package to delete. | +| software_title_id | integer | path | **Required**. The ID of the software title to delete software available for install. | | team_id | integer | query | **Required**. The team ID. Deletes a software package added to the specified team. | #### Example -`DELETE /api/v1/fleet/software/titles/24/package?team_id=2` +`DELETE /api/v1/fleet/software/titles/24?team_id=2` ##### Default response From 86f127933fc30b17cb73b32c6ed96e0f08dfad71 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 20:34:56 +0200 Subject: [PATCH 25/79] Update rest-api.md --- docs/REST API/rest-api.md | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index e5acf694fbec..1b4e28c5bb76 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8631,27 +8631,6 @@ Add App Store (VPP) app purchased in Apple Business Manager. `Status: 200` -### Delete App Store app - -_Available in Fleet Premium._ - -`DELETE /api/v1/fleet/software/titles/:software_title_id/app_store` - -#### Parameters - -| Name | Type | In | Description | -| ---- | ------- | ---- | -------------------------------------------- | -| software_title_id | integer | path | **Required**. The ID of the software title to delete App Store app. | -| team_id | integer | query | **Required**. The team ID. Deletes a software package added to the specified team. | - -#### Example - -`DELETE /api/v1/fleet/software/titles/24/app_store?team_id=2` - -##### Default response - -`Status: 204` - ## Vulnerabilities - [List vulnerabilities](#list-vulnerabilities) From aa90a825da5cecf5f841ea59c38325310a6295c8 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 20:39:39 +0200 Subject: [PATCH 26/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 1b4e28c5bb76..a3e626359876 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8179,7 +8179,7 @@ Content-Type: application/octet-stream _Available in Fleet Premium._ -`GET /api/v1/fleet/software/titles/:software_title_id?alt=media` +`GET /api/v1/fleet/software/titles/:software_title_id/package?alt=media` #### Parameters From a83349d502b3f047f0c8089f8930a8bdda568354 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 20:40:00 +0200 Subject: [PATCH 27/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index a3e626359876..1e78a15ddaf6 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8191,7 +8191,7 @@ _Available in Fleet Premium._ #### Example -`GET /api/v1/fleet/software/titles/123?alt=media?team_id=2` +`GET /api/v1/fleet/software/titles/123/package?alt=media?team_id=2` ##### Default response From 79c71caf01c827f850678bbf6a5d8290a0f61a88 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 21:09:25 +0200 Subject: [PATCH 28/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 25 +++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 9e7b96f18aad..93ff2bba97e4 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -1338,7 +1338,9 @@ If the `name` is not already associated with an existing team, this API route cr | mdm.windows_settings | object | body | The Windows-specific MDM settings. | | mdm.windows_settings.custom_settings | list | body | The list of objects consists of a `path` to XML files and `labels` list of label names. | | scripts | list | body | A list of script files to add to this team so they can be executed at a later time. | -| software | list | body | An array of software objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | +| software | object | body | The team's software that will be available for install | +| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | +| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | | mdm.macos_settings.enable_disk_encryption | bool | body | Whether disk encryption should be enabled for hosts that belong to this team. | | force | bool | query | Force apply the spec even if there are (ignorable) validation errors. Those are unknown keys and agent options-related validations. | | dry_run | bool | query | Validate the provided JSON for unknown keys and invalid value types and return any validation errors, but do not apply the changes. | @@ -1415,13 +1417,20 @@ If the `name` is not already associated with an existing team, this API route cr } }, "scripts": ["path/to/script.sh"], - "software": [ - { - "url": "https://cdn.zoom.us/prod/5.16.10.26186/x64/ZoomInstallerFull.msi", - "pre_install_query": "SELECT 1 FROM macos_profiles WHERE uuid='c9f4f0d5-8426-4eb8-b61b-27c543c9d3db';", - "post_install_script": "sudo /Applications/Falcon.app/Contents/Resources/falconctl license 0123456789ABCDEFGHIJKLMNOPQRSTUV-WX", - } - ] + "software": { + "packages": [ + { + "url": "https://cdn.zoom.us/prod/5.16.10.26186/x64/ZoomInstallerFull.msi", + "pre_install_query": "SELECT 1 FROM macos_profiles WHERE uuid='c9f4f0d5-8426-4eb8-b61b-27c543c9d3db';", + "post_install_script": "sudo /Applications/Falcon.app/Contents/Resources/falconctl license 0123456789ABCDEFGHIJKLMNOPQRSTUV-WX", + } + ], + "app_store_apps": [ + { + "app_store_id": 12464567 + } + ] + } } ] } From 615269c74b4b0da1ab109a0ff9cf20a6c633f483 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 12 Jun 2024 21:13:33 +0200 Subject: [PATCH 29/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 93ff2bba97e4..ec18d5abcdc9 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -1338,7 +1338,7 @@ If the `name` is not already associated with an existing team, this API route cr | mdm.windows_settings | object | body | The Windows-specific MDM settings. | | mdm.windows_settings.custom_settings | list | body | The list of objects consists of a `path` to XML files and `labels` list of label names. | | scripts | list | body | A list of script files to add to this team so they can be executed at a later time. | -| software | object | body | The team's software that will be available for install | +| software | object | body | The team's software that will be available for install. | | software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | | software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | | mdm.macos_settings.enable_disk_encryption | bool | body | Whether disk encryption should be enabled for hosts that belong to this team. | @@ -2922,7 +2922,9 @@ _Available in Fleet Premium._ | team_id | number | query | The ID of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request, omit this parameter if using `team_name`. | | team_name | string | query | The name of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request, omit this parameter if using `team_id`. | | dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | -| software | list | body | An array of software objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | +| software | object | body | The team's software that will be available for install. | +| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | +| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | If both `team_id` and `team_name` parameters are included, this endpoint will respond with an error. If no `team_name` or `team_id` is provided, the scripts will be applied for **all hosts**. From 505d9375cd973764d52eaa2117f33ff267857197 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 19 Jun 2024 16:34:02 +0200 Subject: [PATCH 30/79] Update docs/REST API/rest-api.md Co-authored-by: George Karr --- docs/REST API/rest-api.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 1e78a15ddaf6..438c8f2c60f0 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8597,12 +8597,14 @@ Returns the list of App Store (VPP) apps purchased in Apple Business Manager. { "name": "Xcode", "latest_version": "15.4", - "app_store_id": 497799835 + "app_store_id": 497799835, + "added": true }, { "name": "Logic Pro", "latest_version": "2.04", - "app_store_id": 634148309 + "app_store_id": 634148309, + "added": false }, } } From af962c2487bef9c3a586b3c31bdddc37d8056a27 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 25 Jun 2024 17:43:44 +0200 Subject: [PATCH 31/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 438c8f2c60f0..5c61647d5f7d 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8211,7 +8211,7 @@ _Available in Fleet Premium._ Deletes software that's available for install (package or App Store app). -`DELETE /api/v1/fleet/software/titles/:software_title_id` +`DELETE /api/v1/fleet/software/titles/:software_title_id/available_for_install` #### Parameters From 0b6a308610defdf230382d2ff182cea80bed7a5e Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:30:41 +0200 Subject: [PATCH 32/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 601ed86bd29e..7f0ae8e5355c 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8691,7 +8691,7 @@ Deletes software that's available for install (package or App Store app). #### Example -`DELETE /api/v1/fleet/software/titles/24?team_id=2` +`DELETE /api/v1/fleet/software/titles/24/available_for_install?team_id=2` ##### Default response From 2603c7db8ff137a0eb290c20e8b2cfd2c3553e81 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:38:21 +0200 Subject: [PATCH 33/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 7f0ae8e5355c..8560a0619688 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9054,7 +9054,7 @@ Returns information about the specified software version. Returns the list of App Store (VPP) apps purchased in Apple Business Manager. -`GET /api/v1/fleet/software/app_store/:team_id` +`GET /api/v1/fleet/software/app_store_apps/:team_id` #### Parameters From 80f939314ac134fdf667bb484306b2e71da7b97f Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:38:41 +0200 Subject: [PATCH 34/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 8560a0619688..97dd01a10fd5 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9064,7 +9064,7 @@ Returns the list of App Store (VPP) apps purchased in Apple Business Manager. #### Example -`GET /api/v1/fleet/software/app_store/3` +`GET /api/v1/fleet/software/app_store_apps/3` ##### Default response From 0935d767c67f53d566e2c817f418ce34acd3d99c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:39:14 +0200 Subject: [PATCH 35/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 97dd01a10fd5..9994b20bf447 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9106,7 +9106,7 @@ Add App Store (VPP) app purchased in Apple Business Manager. #### Example -`POST /api/v1/fleet/software/app_store/2?team_id=3` +`POST /api/v1/fleet/software/app_store_apps/2?team_id=3` ##### Default response From 38b16f63049d7cfdd419d4ddcf9054fde5d77681 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:39:50 +0200 Subject: [PATCH 36/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 9994b20bf447..e651525e8a23 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9095,7 +9095,7 @@ _Available in Fleet Premium._ Add App Store (VPP) app purchased in Apple Business Manager. -`POST /api/v1/fleet/software/app_store/:app_store_id` +`POST /api/v1/fleet/software/app_store_apps/:app_store_id` #### Parameters From 749f2ffcc5d748c7bca836a210056718a00334ce Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:44:24 +0200 Subject: [PATCH 37/79] Update rest-api.md --- docs/REST API/rest-api.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index e651525e8a23..2e1ff51a6bb7 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8966,6 +8966,7 @@ Returns information about the specified software. By default, `versions` are sor "failed": 2, } }, + "app_store_app": null, "source": "apps", "browser": "", "hosts_count": 48, From be4d18e3b3e43bfed483de61da670ac96669fcfd Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:51:00 +0200 Subject: [PATCH 38/79] Update rest-api.md --- docs/REST API/rest-api.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 2e1ff51a6bb7..22a18ccf0ff1 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8768,7 +8768,7 @@ Get a list of all software. { "id": 12, "name": "Firefox.app", - "software_package": "FirefoxInstall.pkg", + "available_for_install": true, "self_service": true, "versions_count": 3, "source": "apps", @@ -8795,7 +8795,8 @@ Get a list of all software. { "id": 22, "name": "Google Chrome.app", - "software_package": null, + "available_for_install": false, + "app_store_app": null, "self_service": false, "versions_count": 5, "source": "apps", @@ -8827,7 +8828,7 @@ Get a list of all software. { "id": 32, "name": "1Password – Password Manager", - "software_package": null, + "available_for_install": false, "self_service": false, "versions_count": 1, "source": "chrome_extensions", From e7fa7a7ccea0754be81b4bff0c491759078540c9 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:51:38 +0200 Subject: [PATCH 39/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 22a18ccf0ff1..3bcc84201884 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8796,7 +8796,6 @@ Get a list of all software. "id": 22, "name": "Google Chrome.app", "available_for_install": false, - "app_store_app": null, "self_service": false, "versions_count": 5, "source": "apps", From 4ff4003a1a941f7432f3e95a33a2e5991947162e Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 14:50:12 +0200 Subject: [PATCH 40/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index bf572aabe195..36deab40d505 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -1435,7 +1435,7 @@ If the `name` is not already associated with an existing team, this API route cr | scripts | list | body | A list of script files to add to this team so they can be executed at a later time. | | software | object | body | The team's software that will be available for install. | | software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `self_service` boolean. | -| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app and `self_service` boolean. | +| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | | mdm.macos_settings.enable_disk_encryption | bool | body | Whether disk encryption should be enabled for hosts that belong to this team. | | force | bool | query | Force apply the spec even if there are (ignorable) validation errors. Those are unknown keys and agent options-related validations. | | dry_run | bool | query | Validate the provided JSON for unknown keys and invalid value types and return any validation errors, but do not apply the changes. | From 1cb66f37db625776a0bd0016546cf66e7baf7ade Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 16:06:58 +0200 Subject: [PATCH 41/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 3bcc84201884..3c6ec3bc4e15 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9076,6 +9076,7 @@ Returns the list of App Store (VPP) apps purchased in Apple Business Manager. "app_store_apps": { { "name": "Xcode", + "icon_url": "https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/f1/65/1e/a4844ccd-486d-455f-bb31-67336fe46b14/AppIcon-1x_U007emarketing-0-7-0-85-220-0.png/512x512bb.jpg", "latest_version": "15.4", "app_store_id": 497799835, "added": true From 717d0f32815b651cdfc7ce9847a48decca7a316c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 10 Jul 2024 16:07:16 +0200 Subject: [PATCH 42/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 3c6ec3bc4e15..f321e6bc75b4 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9083,6 +9083,7 @@ Returns the list of App Store (VPP) apps purchased in Apple Business Manager. }, { "name": "Logic Pro", + "icon_url": "https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/f1/65/1e/a4844ccd-486d-455f-bb31-67336fe46b14/AppIcon-1x_U007emarketing-0-7-0-85-220-0.png/512x512bb.jpg", "latest_version": "2.04", "app_store_id": 634148309, "added": false From 0d3ea2574a31e1794dfa2c94e145f9270d2ecb8c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 11 Jul 2024 11:08:10 +0200 Subject: [PATCH 43/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index f321e6bc75b4..26d0654910c5 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9055,7 +9055,7 @@ Returns information about the specified software version. Returns the list of App Store (VPP) apps purchased in Apple Business Manager. -`GET /api/v1/fleet/software/app_store_apps/:team_id` +`GET /api/v1/fleet/software/app_store_apps` #### Parameters From f5c71a98ded49eeb08b5a83dd802b5a279aa443f Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 11 Jul 2024 11:08:52 +0200 Subject: [PATCH 44/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 26d0654910c5..e7192b9afddb 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9065,7 +9065,7 @@ Returns the list of App Store (VPP) apps purchased in Apple Business Manager. #### Example -`GET /api/v1/fleet/software/app_store_apps/3` +`GET /api/v1/fleet/software/app_store_apps/?team_id=3` ##### Default response From e677dff4b0b3f5a2547acb63795fb71227e6e67a Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 11 Jul 2024 11:14:50 +0200 Subject: [PATCH 45/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index e7192b9afddb..d76cdfb8ecdc 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9053,7 +9053,7 @@ Returns information about the specified software version. ### Get available App Store apps -Returns the list of App Store (VPP) apps purchased in Apple Business Manager. +Returns the list of App Store (VPP) apps purchased in Apple Business Manager. Apps that are already added to a team won't be returned. `GET /api/v1/fleet/software/app_store_apps` From 5f02f0aa2f89d6baa8345dffc2314cfcc2c4c028 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:00:31 +0200 Subject: [PATCH 46/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 36deab40d505..ff9d22acbacf 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,6 +2597,10 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", + "available_for_install": { + "name": "GoogleChrome.pkg" + "version": "126.0.6478.127" + }, "source": "apps", "status": "failed", "last_install": { From ded40549101a4a17791fc72531fc0be85842d294 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:09:54 +0200 Subject: [PATCH 47/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index d5e8878127d5..90174d0365b7 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9107,7 +9107,7 @@ Add App Store (VPP) app purchased in Apple Business Manager. | ---- | ---- | -- | ----------- | | app_store_id | integer | path | **Required.** The ID of App Store app. | | team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | -| self_service | boolean | form | Self-service software is optional and can be installed by the end user. | +| self_service | boolean | body | Self-service software is optional and can be installed by the end user. | #### Example From bc4c776f4a4151f110ee351a4500bc484ec14615 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:17:48 +0200 Subject: [PATCH 48/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 7e8cf79e1908..b85af7c2f574 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9110,7 +9110,14 @@ Add App Store (VPP) app purchased in Apple Business Manager. #### Example -`POST /api/v1/fleet/software/app_store_apps/2?team_id=3` +`POST /api/v1/fleet/software/app_store_apps?team_id=3` + +##### Request body + +```json +{ + "app_store_id": 2 +} ##### Default response From 74ec2469561312c381bc2b54e1d7ea252d9bade1 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:18:26 +0200 Subject: [PATCH 49/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index b85af7c2f574..d7e5068195b1 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9118,7 +9118,6 @@ Add App Store (VPP) app purchased in Apple Business Manager. { "app_store_id": 2 } - ##### Default response `Status: 200` From 025da7e9a18fb1623b02cb316c0564237698dc61 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:18:44 +0200 Subject: [PATCH 50/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index d7e5068195b1..849837d05bff 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9105,7 +9105,7 @@ Add App Store (VPP) app purchased in Apple Business Manager. | Name | Type | In | Description | | ---- | ---- | -- | ----------- | -| app_store_id | integer | path | **Required.** The ID of App Store app. | +| app_store_id | integer | body | **Required.** The ID of App Store app. | | team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | #### Example From d717596952fe6896b1e82e8d82c3965485180e2d Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:19:59 +0200 Subject: [PATCH 51/79] Update rest-api.md --- docs/REST API/rest-api.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 849837d05bff..85de9c5299b0 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9099,14 +9099,14 @@ _Available in Fleet Premium._ Add App Store (VPP) app purchased in Apple Business Manager. -`POST /api/v1/fleet/software/app_store_apps/:app_store_id` +`POST /api/v1/fleet/software/app_store_apps` #### Parameters | Name | Type | In | Description | | ---- | ---- | -- | ----------- | | app_store_id | integer | body | **Required.** The ID of App Store app. | -| team_id | integer | query | **Required**. The team ID. Adds VPP software to the specified team. | +| team_id | integer | body | **Required**. The team ID. Adds VPP software to the specified team. | #### Example @@ -9116,8 +9116,11 @@ Add App Store (VPP) app purchased in Apple Business Manager. ```json { - "app_store_id": 2 + "app_store_id": 2, + "team_id": 2 } +``` + ##### Default response `Status: 200` From 19003af3f3e50c9fd3cea91214fe27cd36643a04 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 15 Jul 2024 20:01:19 +0200 Subject: [PATCH 52/79] Update rest-api.md --- docs/REST API/rest-api.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 85de9c5299b0..d5ba354b47aa 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8770,6 +8770,7 @@ Get a list of all software. "id": 12, "name": "Firefox.app", "available_for_install": true, + "icon_url": null, "self_service": true, "versions_count": 3, "source": "apps", @@ -8797,6 +8798,7 @@ Get a list of all software. "id": 22, "name": "Google Chrome.app", "available_for_install": false, + "icon_url": null, "self_service": false, "versions_count": 5, "source": "apps", @@ -8829,6 +8831,7 @@ Get a list of all software. "id": 32, "name": "1Password – Password Manager", "available_for_install": false, + "icon_url": null, "self_service": false, "versions_count": 1, "source": "chrome_extensions", From 007a9d036ff019fd963ecccd7122d4090ad9cb71 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 18:26:30 +0200 Subject: [PATCH 53/79] Update rest-api.md --- docs/REST API/rest-api.md | 41 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index d5ba354b47aa..c8cfa2b5f711 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8998,6 +8998,47 @@ Returns information about the specified software. By default, `versions` are sor } ``` +#### Example (App Store app) + +`GET /api/v1/fleet/software/titles/15` + +##### Default response + +`Status: 200` + +```json +{ + "software_title": { + "id": 15, + "name": "Logic Pro", + "bundle_identifier": "com.apple.logic10", + "software_package": null, + "app_store_app": { + "name": "Logic Pro", + "app_store_id": 1091189122, + "latest_version": "2.04", + "icon_url": "https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/f1/65/1e/a4844ccd-486d-455f-bb31-67336fe46b14/AppIcon-1x_U007emarketing-0-7-0-85-220-0.png/512x512bb.jpg", + "status": { + "installed": 3, + "pending": 1, + "failed": 2, + } + }, + "source": "apps", + "browser": "", + "hosts_count": 48, + "versions": [ + { + "id": 123, + "version": "2.04", + "vulnerabilities": [], + "hosts_count": 24 + } + ] + } +} +``` + ### Get software version Returns information about the specified software version. From f71649808edbc2ef42f50eb39222f153f20c8993 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 18:42:59 +0200 Subject: [PATCH 54/79] Update rest-api.md --- docs/REST API/rest-api.md | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index c8cfa2b5f711..9d84420c61dd 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -4301,7 +4301,11 @@ OS vulnerability data is currently available for Windows and macOS. For other pl { "id": 121, "name": "Google Chrome.app", - "package_available_for_install": "GoogleChrome.pkg", + "available_for_install": true, + "software_package": { + "name": "GoogleChrome.pkg" + }, + "app_store_app": null "self_service": true, "source": "apps", "status": "failed", @@ -4321,7 +4325,11 @@ OS vulnerability data is currently available for Windows and macOS. For other pl { "id": 134, "name": "Falcon.app", - "package_available_for_install": "FalconSensor-6.44.pkg", + "available_for_install": true, + "software_package": { + "name": "FalconSensor-6.44.pkg" + }, + "app_store_app": null "self_service": false, "source": "", "status": null, @@ -4330,9 +4338,14 @@ OS vulnerability data is currently available for Windows and macOS. For other pl }, { "id": 147, - "name": "Firefox.app", + "name": "Logic Pro", + "available_for_install": true, + "software_package": null + "app_store_app": { + "app_store_id": "1091189122" + }, + "self_service": false, "source": "apps", - "bundle_identifier": "org.mozilla.firefox", "status": null, "last_install": null, "installed_versions": [ From 473f63f424f266372c7c6ea16af7f8e8516c9450 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 19:06:14 +0200 Subject: [PATCH 55/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index ff9d22acbacf..76b897d8382a 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,12 +2597,15 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", - "available_for_install": { - "name": "GoogleChrome.pkg" - "version": "126.0.6478.127" + "available_for_install" true, + "software_package": { + "name": "GoogleChrome.pkg" + "version": "125.12.2" }, + "app_store_app": null, + "self_service": true, "source": "apps", - "status": "failed", + "status": null, "last_install": { "install_uuid": "8bbb8ac2-b254-4387-8cba-4d8a0407368b", "installed_at": "2024-05-15T15:23:57Z" @@ -2639,6 +2642,8 @@ Lists the software installed on the current device. } ``` + + #### Install self-service software Install self-service software on macOS, Windows, or Linux (Ubuntu) host. The software must have a `self_service` flag `true` to be installed. From 4c7069f676daea4bb272129f94481f49e14446e8 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:14:50 +0200 Subject: [PATCH 56/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 9d84420c61dd..0d84f6c89c59 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -4303,7 +4303,8 @@ OS vulnerability data is currently available for Windows and macOS. For other pl "name": "Google Chrome.app", "available_for_install": true, "software_package": { - "name": "GoogleChrome.pkg" + "name": "GoogleChrome.pkg", + "version": "125.12.0.3" }, "app_store_app": null "self_service": true, From 489a38b156a682f7e832c79d86b4dd437dbd2728 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:32:52 +0200 Subject: [PATCH 57/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 36deab40d505..70f9714909f3 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,6 +2597,13 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", + "available_for_install" true, + "software_package": { + "name": "GoogleChrome.pkg" + "version": "125.12.2" + }, + "app_store_app": null, + "self_service": true, "source": "apps", "status": "failed", "last_install": { @@ -2614,16 +2621,23 @@ Lists the software installed on the current device. }, { "id": 143, - "name": "Firefox.app", + "name": "Logic Pro", + "available_for_install" true, + "software_package": null, + "app_store_app": { + "app_store_id": "1091189122" + "version": "2.04" + }, + "self_service": false, "source": "apps", "status": null, "last_install": null, "installed_versions": [ { - "version": "125.6", + "version": "2.04", "last_opened_at": "2024-04-01T23:03:07Z", - "vulnerabilities": ["CVE-2023-1234","CVE-2023-4321","CVE-2023-7654"], - "installed_paths": ["/Applications/Firefox.app"] + "vulnerabilities": [], + "installed_paths": ["/Applications/Logic Pro.app"] } ] } From b6b9120be85b19c46a39cd3f936b6f689e41870b Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:38:39 +0200 Subject: [PATCH 58/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 70f9714909f3..82592c8a289c 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2621,23 +2621,19 @@ Lists the software installed on the current device. }, { "id": 143, - "name": "Logic Pro", - "available_for_install" true, + "name": "Firefox.app", + "available_for_install" false, "software_package": null, - "app_store_app": { - "app_store_id": "1091189122" - "version": "2.04" - }, "self_service": false, "source": "apps", "status": null, "last_install": null, "installed_versions": [ { - "version": "2.04", + "version": "25.04", "last_opened_at": "2024-04-01T23:03:07Z", "vulnerabilities": [], - "installed_paths": ["/Applications/Logic Pro.app"] + "installed_paths": ["/Applications/Firefox.app"] } ] } From 5359a76f06776e1180277675adcdb69dace8c1ad Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:42:02 +0200 Subject: [PATCH 59/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 82592c8a289c..30f740b57c19 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2624,6 +2624,7 @@ Lists the software installed on the current device. "name": "Firefox.app", "available_for_install" false, "software_package": null, + "app_store_app": null, "self_service": false, "source": "apps", "status": null, From 5527efd952c3a07cc03a2fe72d4250c955330dff Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:42:22 +0200 Subject: [PATCH 60/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 30f740b57c19..2b3ee5bdea8d 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2624,7 +2624,7 @@ Lists the software installed on the current device. "name": "Firefox.app", "available_for_install" false, "software_package": null, - "app_store_app": null, + "app_store_app": null, "self_service": false, "source": "apps", "status": null, From d8f72219f8bb9adc62ffca75101f0bebd6549f18 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:43:43 +0200 Subject: [PATCH 61/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 2b3ee5bdea8d..c0d9c093d1a6 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2631,7 +2631,7 @@ Lists the software installed on the current device. "last_install": null, "installed_versions": [ { - "version": "25.04", + "version": "125.6", "last_opened_at": "2024-04-01T23:03:07Z", "vulnerabilities": [], "installed_paths": ["/Applications/Firefox.app"] From 3df87b967197c7b7d0b431479ef0e6c3904216ab Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:44:16 +0200 Subject: [PATCH 62/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index c0d9c093d1a6..8e6ac6983748 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2633,7 +2633,7 @@ Lists the software installed on the current device. { "version": "125.6", "last_opened_at": "2024-04-01T23:03:07Z", - "vulnerabilities": [], + "vulnerabilities": ["CVE-2023-1234","CVE-2023-4321","CVE-2023-7654"], "installed_paths": ["/Applications/Firefox.app"] } ] From e4b46d1bc191ed7c793a5f4d0adcbdee7e5861a4 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:47:07 +0200 Subject: [PATCH 63/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 8e6ac6983748..95c4e5ea40a8 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,7 +2597,7 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", - "available_for_install" true, + "available_for_install": true, "software_package": { "name": "GoogleChrome.pkg" "version": "125.12.2" From 6cb3884d51dca62501760eb2145b037f1a31c49c Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:51:11 +0200 Subject: [PATCH 64/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index f685f974b153..ff9c5f272c3f 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,7 +2597,7 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", - "available_for_install" true, + "available_for_install": true, "software_package": { "name": "GoogleChrome.pkg" "version": "125.12.2" From b01cc87340771eda65f38596df113515cc9c6be9 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 16 Jul 2024 20:51:41 +0200 Subject: [PATCH 65/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index ff9c5f272c3f..ad2466319472 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2605,7 +2605,7 @@ Lists the software installed on the current device. "app_store_app": null, "self_service": true, "source": "apps", - "status": null, + "status": "failed", "last_install": { "install_uuid": "8bbb8ac2-b254-4387-8cba-4d8a0407368b", "installed_at": "2024-05-15T15:23:57Z" From f10d9fb0772ace2f4f4d6f81cf483e6b4c4cd46a Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 16:30:01 +0200 Subject: [PATCH 66/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 0d84f6c89c59..b2e6a13421fc 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9174,7 +9174,7 @@ Add App Store (VPP) app purchased in Apple Business Manager. ```json { - "app_store_id": 2, + "app_store_id": 497799835, "team_id": 2 } ``` From 7b3dd7d7162db5c8014f1cc97223a77fe15ab48f Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 16:45:10 +0200 Subject: [PATCH 67/79] Update rest-api.md --- docs/REST API/rest-api.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 208d2f27fcbf..c288d9959ad0 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -9032,6 +9032,7 @@ Returns information about the specified software. By default, `versions` are sor "app_store_id": 1091189122, "latest_version": "2.04", "icon_url": "https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/f1/65/1e/a4844ccd-486d-455f-bb31-67336fe46b14/AppIcon-1x_U007emarketing-0-7-0-85-220-0.png/512x512bb.jpg", + "self_service": true, "status": { "installed": 3, "pending": 1, From 7472eceef8e1eb981abe04f27a861059f20bbb02 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 17:55:38 +0200 Subject: [PATCH 68/79] Update rest-api.md --- docs/REST API/rest-api.md | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index b2e6a13421fc..c354d106377a 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -4301,13 +4301,12 @@ OS vulnerability data is currently available for Windows and macOS. For other pl { "id": 121, "name": "Google Chrome.app", - "available_for_install": true, "software_package": { "name": "GoogleChrome.pkg", - "version": "125.12.0.3" + "version": "125.12.0.3", + "self_service": true }, "app_store_app": null - "self_service": true, "source": "apps", "status": "failed", "last_install": { @@ -4326,12 +4325,11 @@ OS vulnerability data is currently available for Windows and macOS. For other pl { "id": 134, "name": "Falcon.app", - "available_for_install": true, "software_package": { "name": "FalconSensor-6.44.pkg" + "self_service": false, }, - "app_store_app": null - "self_service": false, + "app_store_app": null "source": "", "status": null, "last_install": null, @@ -4340,12 +4338,10 @@ OS vulnerability data is currently available for Windows and macOS. For other pl { "id": 147, "name": "Logic Pro", - "available_for_install": true, "software_package": null "app_store_app": { "app_store_id": "1091189122" }, - "self_service": false, "source": "apps", "status": null, "last_install": null, From cca0f87b0ee4a7cc4419817c5084eecbbfeae0ec Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 18:45:03 +0200 Subject: [PATCH 69/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 95c4e5ea40a8..c262d36dcb01 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -2597,13 +2597,12 @@ Lists the software installed on the current device. { "id": 121, "name": "Google Chrome.app", - "available_for_install": true, "software_package": { "name": "GoogleChrome.pkg" "version": "125.12.2" + "self_service": true, }, "app_store_app": null, - "self_service": true, "source": "apps", "status": "failed", "last_install": { @@ -2622,10 +2621,8 @@ Lists the software installed on the current device. { "id": 143, "name": "Firefox.app", - "available_for_install" false, "software_package": null, "app_store_app": null, - "self_service": false, "source": "apps", "status": null, "last_install": null, From 7a20c2f1c2e0d992360576f4f11e250fcfaa4ca1 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 18:51:03 +0200 Subject: [PATCH 70/79] Update rest-api.md --- docs/REST API/rest-api.md | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index c354d106377a..2ca28831b17c 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8779,9 +8779,13 @@ Get a list of all software. { "id": 12, "name": "Firefox.app", - "available_for_install": true, - "icon_url": null, - "self_service": true, + "software_package": { + "name": "FirefoxInsall.pkg", + "version": "125.6", + "icon_url": null, + "self_service": true + }, + "app_store_app": null, "versions_count": 3, "source": "apps", "browser": "", @@ -8807,9 +8811,8 @@ Get a list of all software. { "id": 22, "name": "Google Chrome.app", - "available_for_install": false, - "icon_url": null, - "self_service": false, + "software_package": null, + "app_store_app": null, "versions_count": 5, "source": "apps", "browser": "", @@ -8840,9 +8843,8 @@ Get a list of all software. { "id": 32, "name": "1Password – Password Manager", - "available_for_install": false, - "icon_url": null, - "self_service": false, + "software_package": null, + "app_store_app": null, "versions_count": 1, "source": "chrome_extensions", "browser": "chrome", From f26f6e90ce5a55e47d3d869f8d9c61f87d7cef8d Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Wed, 17 Jul 2024 19:15:16 +0200 Subject: [PATCH 71/79] Update API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index ea546f71834c..a6526536b915 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -1435,7 +1435,7 @@ If the `name` is not already associated with an existing team, this API route cr | scripts | list | body | A list of script files to add to this team so they can be executed at a later time. | | software | object | body | The team's software that will be available for install. | | software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `self_service` boolean. | -| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | +| software.app_store_apps | list | body | An array of objects. Each object consists of `app_store_id` - ID of the App Store app and `self_service` boolean. | | mdm.macos_settings.enable_disk_encryption | bool | body | Whether disk encryption should be enabled for hosts that belong to this team. | | force | bool | query | Force apply the spec even if there are (ignorable) validation errors. Those are unknown keys and agent options-related validations. | | dry_run | bool | query | Validate the provided JSON for unknown keys and invalid value types and return any validation errors, but do not apply the changes. | @@ -1524,6 +1524,7 @@ If the `name` is not already associated with an existing team, this API route cr "app_store_apps": [ { "app_store_id": 12464567, + "self_service": true } ] } @@ -2643,8 +2644,6 @@ Lists the software installed on the current device. } ``` - - #### Install self-service software Install self-service software on macOS, Windows, or Linux (Ubuntu) host. The software must have a `self_service` flag `true` to be installed. @@ -3049,7 +3048,7 @@ _Available in Fleet Premium._ | dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | | software | object | body | The team's software that will be available for install. | | software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, and `post_install_script` - script that runs after software install. | -| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | +| software.app_store_apps | list | body | An array of objects. Each object consists of `app_store_id` - ID of the App Store app and `self_service` boolean. | If both `team_id` and `team_name` parameters are included, this endpoint will respond with an error. If no `team_name` or `team_id` is provided, the scripts will be applied for **all hosts**. From a294dee41255803847eaf6eb640e0a169c9d5a86 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:15:04 +0200 Subject: [PATCH 72/79] Update yaml-files.md --- docs/Configuration/yaml-files.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/Configuration/yaml-files.md b/docs/Configuration/yaml-files.md index 937408ec2c52..5dca677d71d3 100644 --- a/docs/Configuration/yaml-files.md +++ b/docs/Configuration/yaml-files.md @@ -338,7 +338,9 @@ software: - `app_store_id` is the ID of the Apple App Store app. You can find this at the end of the app's App Store URL. For example, "Bear - Markdown Notes" URL is "https://apps.apple.com/us/app/bear-markdown-notes/id1016366447" and the `app_store_id` is `1016366447`. -> Make sure to include only the ID itself, and not the `id` prefix shown in the URL. The ID must be wrapped in quotes as shown in the example so that it is processed as a string. +> Make sure to include only the ID itself, and not the `id` prefix shown in the URL. The ID must be wrapped in quotes as shown in the example so that it is processed as a string. + +For App Store apps that are supported on iOS and/or iPadOS, self-service is set to false. For example, if the app is supported on macOS, iOS, and iPadOS, and self_service is set to true, it will only be applied for macOS. ### org_settings and team_settings From d901dcd1b086cad103426007482de7c68709d172 Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Tue, 17 Sep 2024 13:31:25 +0200 Subject: [PATCH 73/79] Update docs/REST API/rest-api.md --- docs/REST API/rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 1ced3a0c1637..816f860ec5b8 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -4282,7 +4282,7 @@ Resends a configuration profile for the specified host. "software_package": null "app_store_app": { "app_store_id": "1091189122", - "https://is1-ssl.mzstatic.com/image/thumb/Purple221/v4/f4/25/1f/f4251f60-e27a-6f05-daa7-9f3a63aac929/AppIcon-0-0-85-220-0-0-4-0-0-2x-0-0-0-0-0.png/512x512bb.png" + "icon_url": "https://is1-ssl.mzstatic.com/image/thumb/Purple221/v4/f4/25/1f/f4251f60-e27a-6f05-daa7-9f3a63aac929/AppIcon-0-0-85-220-0-0-4-0-0-2x-0-0-0-0-0.png/512x512bb.png" "version": "2.04", "self_service": false, "last_install": { From 4490c0c4a74da6352adfdca2fed6c23595de2a5b Mon Sep 17 00:00:00 2001 From: Marko Lisica <83164494+marko-lisica@users.noreply.github.com> Date: Thu, 19 Sep 2024 20:06:15 +0200 Subject: [PATCH 74/79] Update docs/Configuration/yaml-files.md Co-authored-by: Rachael Shaw --- docs/Configuration/yaml-files.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Configuration/yaml-files.md b/docs/Configuration/yaml-files.md index 5dca677d71d3..d55ad822cdce 100644 --- a/docs/Configuration/yaml-files.md +++ b/docs/Configuration/yaml-files.md @@ -340,7 +340,7 @@ software: > Make sure to include only the ID itself, and not the `id` prefix shown in the URL. The ID must be wrapped in quotes as shown in the example so that it is processed as a string. -For App Store apps that are supported on iOS and/or iPadOS, self-service is set to false. For example, if the app is supported on macOS, iOS, and iPadOS, and self_service is set to true, it will only be applied for macOS. +`self_service` only applies to macOS, and is ignored for other platforms. For example, if the app is supported on macOS, iOS, and iPadOS, and `self_service` is set to `true`, it will be self-service on macOS workstations but not iPhones or iPads. ### org_settings and team_settings From d32470d29592e58214e9b8d1003b96e477b9eb67 Mon Sep 17 00:00:00 2001 From: Noah Talerman Date: Tue, 24 Sep 2024 09:30:52 -0400 Subject: [PATCH 75/79] Move endpoints --- docs/Contributing/API-for-contributors.md | 114 +++++++++++++++++++++ docs/REST API/rest-api.md | 116 ---------------------- 2 files changed, 114 insertions(+), 116 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 1c2c323d2a8f..03064eee993d 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -541,6 +541,10 @@ The MDM endpoints exist to support the related command-line interface sub-comman - [Renew VPP token](#renew-vpp-token) - [Delete VPP token](#delete-vpp-token) - [Batch-apply MDM custom settings](#batch-apply-mdm-custom-settings) +- [Batch-apply packages](#batch-apply-packages) +- [Batch-apply App Store apps](#batch-apply-app-store-apps) +- [Get token to download package](#get-token-to-download-package) +- [Download package using a token](#download-package-using-a-token) - [Initiate SSO during DEP enrollment](#initiate-sso-during-dep-enrollment) - [Complete SSO during DEP enrollment](#complete-sso-during-dep-enrollment) - [Over the air enrollment](#over-the-air-enrollment) @@ -975,6 +979,116 @@ If no team (id or name) is provided, the profiles are applied for all hosts (for `204` +### Batch-apply packages + +_Available in Fleet Premium._ + +`POST /api/v1/fleet/software/batch` + +#### Parameters + +| Name | Type | In | Description | +| --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| team_id | number | query | The ID of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_name`. Omitting these parameters will add software to "No Team". | +| team_name | string | query | The name of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_id`. Omitting these parameters will add software to "No Team". | +| dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | +| software | object | body | The team's software that will be available for install. | +| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `uninstall_script` - command that Fleet runs to uninstall software. | +| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | + +If both `team_id` and `team_name` parameters are included, this endpoint will respond with an error. If no `team_name` or `team_id` is provided, the scripts will be applied for **all hosts**. + +#### Example + +`POST /api/v1/fleet/software/batch` + +##### Default response + +`Status: 204` + +### Batch-apply app store apps + +_Available in Fleet Premium._ + +`POST /api/v1/fleet/software/app_store_apps/batch` + +#### Parameters + +| Name | Type | In | Description | +|-----------------|---------|-------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| team_name | integer | query | **Required**. The name of the team to add the app to. | +| dry_run | bool | query | If `true`, will validate the provided apps and return any validation errors, but will not apply the changes. | +| apps_store_apps | list | body | The list of objects containing `app_store_id`: a string representation of the app's App ID, `self_service`: a bool indicating if the app's installation can be initiated by end users. | + +> Note that this endpoint replaces all apps associated with a team. + +#### Example + +`POST /api/v1/fleet/software/app_store_apps/batch` + +#### Default response + +`Status: 204` + +### Get token to download package + +_Available in Fleet Premium._ + +`POST /api/v1/fleet/software/titles/:software_title_id/package/token?alt=media` + +The returned token is a one-time use token that expires after 10 minutes. + +#### Parameters + +| Name | Type | In | Description | +|-------------------|---------|-------|------------------------------------------------------------------| +| software_title_id | integer | path | **Required**. The ID of the software title for software package. | +| team_id | integer | query | **Required**. The team ID containing the software package. | +| alt | integer | query | **Required**. Must be specified and set to "media". | + +#### Example + +`POST /api/v1/fleet/software/titles/123/package/token?alt=media&team_id=2` + +##### Default response + +`Status: 200` + +```json +{ + "token": "e905e33e-07fe-4f82-889c-4848ed7eecb7" +} +``` + +### Download package using a token + +_Available in Fleet Premium._ + +`GET /api/v1/fleet/software/titles/:software_title_id/package/token/:token?alt=media` + +#### Parameters + +| Name | Type | In | Description | +|-------------------|---------|------|--------------------------------------------------------------------------| +| software_title_id | integer | path | **Required**. The ID of the software title to download software package. | +| token | string | path | **Required**. The token to download the software package. | + +#### Example + +`GET /api/v1/fleet/software/titles/123/package/token/e905e33e-07fe-4f82-889c-4848ed7eecb7` + +##### Default response + +`Status: 200` + +```http +Status: 200 +Content-Type: application/octet-stream +Content-Disposition: attachment +Content-Length: +Body: +``` + ### Initiate SSO during DEP enrollment This endpoint initiates the SSO flow, the response contains an URL that the client can use to redirect the user to initiate the SSO flow in the configured IdP. diff --git a/docs/REST API/rest-api.md b/docs/REST API/rest-api.md index 30331ee1cf6c..3b5037437c0b 100644 --- a/docs/REST API/rest-api.md +++ b/docs/REST API/rest-api.md @@ -8654,11 +8654,6 @@ Deletes the session specified by ID. When the user associated with the session n - [Get package install result](#get-package-install-result) - [Download package](#download-package) - [Delete package or App Store app](#delete-package-or-app-store-app) -- [Batch-apply software](#batch-apply-software) -- [Batch-apply app store apps](#batch-apply-app-store-apps) -- [Get token to download package](#get-token-to-download-package) -- [Download package using a token](#download-package-using-a-token) - ### List software @@ -9547,117 +9542,6 @@ Deletes software that's available for install (package or App Store app). `Status: 204` -### Batch-apply software - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/batch` - -#### Parameters - -| Name | Type | In | Description | -| --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| team_id | number | query | The ID of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_name`. Omitting these parameters will add software to "No Team". | -| team_name | string | query | The name of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_id`. Omitting these parameters will add software to "No Team". | -| dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | -| software | object | body | The team's software that will be available for install. | -| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `uninstall_script` - command that Fleet runs to uninstall software. | -| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | - -If both `team_id` and `team_name` parameters are included, this endpoint will respond with an error. If no `team_name` or `team_id` is provided, the scripts will be applied for **all hosts**. - -#### Example - -`POST /api/v1/fleet/software/batch` - -##### Default response - -`Status: 204` - -### Batch-apply app store apps - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/app_store_apps/batch` - -#### Parameters - -| Name | Type | In | Description | -|-----------------|---------|-------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| team_name | integer | query | **Required**. The name of the team to add the app to. | -| dry_run | bool | query | If `true`, will validate the provided apps and return any validation errors, but will not apply the changes. | -| apps_store_apps | list | body | The list of objects containing `app_store_id`: a string representation of the app's App ID, `self_service`: a bool indicating if the app's installation can be initiated by end users. | - -> Note that this endpoint replaces all apps associated with a team. - -#### Example - -`POST /api/v1/fleet/software/app_store_apps/batch` - -#### Default response - -`Status: 204` - -### Get token to download package - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/titles/:software_title_id/package/token?alt=media` - -The returned token is a one-time use token that expires after 10 minutes. - -#### Parameters - -| Name | Type | In | Description | -|-------------------|---------|-------|------------------------------------------------------------------| -| software_title_id | integer | path | **Required**. The ID of the software title for software package. | -| team_id | integer | query | **Required**. The team ID containing the software package. | -| alt | integer | query | **Required**. Must be specified and set to "media". | - -#### Example - -`POST /api/v1/fleet/software/titles/123/package/token?alt=media&team_id=2` - -##### Default response - -`Status: 200` - -```json -{ - "token": "e905e33e-07fe-4f82-889c-4848ed7eecb7" -} -``` - -### Download package using a token - -_Available in Fleet Premium._ - -`GET /api/v1/fleet/software/titles/:software_title_id/package/token/:token?alt=media` - -#### Parameters - -| Name | Type | In | Description | -|-------------------|---------|------|--------------------------------------------------------------------------| -| software_title_id | integer | path | **Required**. The ID of the software title to download software package. | -| token | string | path | **Required**. The token to download the software package. | - -#### Example - -`GET /api/v1/fleet/software/titles/123/package/token/e905e33e-07fe-4f82-889c-4848ed7eecb7` - -##### Default response - -`Status: 200` - -```http -Status: 200 -Content-Type: application/octet-stream -Content-Disposition: attachment -Content-Length: -Body: -``` - - ## Vulnerabilities - [List vulnerabilities](#list-vulnerabilities) From deb9565c46fe8f86c39236a8cb130d7452dfcb6f Mon Sep 17 00:00:00 2001 From: Noah Talerman Date: Tue, 24 Sep 2024 09:43:53 -0400 Subject: [PATCH 76/79] Update docs --- docs/Contributing/API-for-contributors.md | 294 ++++++++++++++-------- 1 file changed, 184 insertions(+), 110 deletions(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 03064eee993d..c18589f21bd8 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -979,116 +979,6 @@ If no team (id or name) is provided, the profiles are applied for all hosts (for `204` -### Batch-apply packages - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/batch` - -#### Parameters - -| Name | Type | In | Description | -| --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| team_id | number | query | The ID of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_name`. Omitting these parameters will add software to "No Team". | -| team_name | string | query | The name of the team to add the software package to. Only one team identifier (`team_id` or `team_name`) can be included in the request; omit this parameter if using `team_id`. Omitting these parameters will add software to "No Team". | -| dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | -| software | object | body | The team's software that will be available for install. | -| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `uninstall_script` - command that Fleet runs to uninstall software. | -| software.app_store_apps | list | body | An array objects. Each object consists of `app_store_id` - ID of the App Store app. | - -If both `team_id` and `team_name` parameters are included, this endpoint will respond with an error. If no `team_name` or `team_id` is provided, the scripts will be applied for **all hosts**. - -#### Example - -`POST /api/v1/fleet/software/batch` - -##### Default response - -`Status: 204` - -### Batch-apply app store apps - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/app_store_apps/batch` - -#### Parameters - -| Name | Type | In | Description | -|-----------------|---------|-------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| team_name | integer | query | **Required**. The name of the team to add the app to. | -| dry_run | bool | query | If `true`, will validate the provided apps and return any validation errors, but will not apply the changes. | -| apps_store_apps | list | body | The list of objects containing `app_store_id`: a string representation of the app's App ID, `self_service`: a bool indicating if the app's installation can be initiated by end users. | - -> Note that this endpoint replaces all apps associated with a team. - -#### Example - -`POST /api/v1/fleet/software/app_store_apps/batch` - -#### Default response - -`Status: 204` - -### Get token to download package - -_Available in Fleet Premium._ - -`POST /api/v1/fleet/software/titles/:software_title_id/package/token?alt=media` - -The returned token is a one-time use token that expires after 10 minutes. - -#### Parameters - -| Name | Type | In | Description | -|-------------------|---------|-------|------------------------------------------------------------------| -| software_title_id | integer | path | **Required**. The ID of the software title for software package. | -| team_id | integer | query | **Required**. The team ID containing the software package. | -| alt | integer | query | **Required**. Must be specified and set to "media". | - -#### Example - -`POST /api/v1/fleet/software/titles/123/package/token?alt=media&team_id=2` - -##### Default response - -`Status: 200` - -```json -{ - "token": "e905e33e-07fe-4f82-889c-4848ed7eecb7" -} -``` - -### Download package using a token - -_Available in Fleet Premium._ - -`GET /api/v1/fleet/software/titles/:software_title_id/package/token/:token?alt=media` - -#### Parameters - -| Name | Type | In | Description | -|-------------------|---------|------|--------------------------------------------------------------------------| -| software_title_id | integer | path | **Required**. The ID of the software title to download software package. | -| token | string | path | **Required**. The token to download the software package. | - -#### Example - -`GET /api/v1/fleet/software/titles/123/package/token/e905e33e-07fe-4f82-889c-4848ed7eecb7` - -##### Default response - -`Status: 200` - -```http -Status: 200 -Content-Type: application/octet-stream -Content-Disposition: attachment -Content-Length: -Body: -``` - ### Initiate SSO during DEP enrollment This endpoint initiates the SSO flow, the response contains an URL that the client can use to redirect the user to initiate the SSO flow in the configured IdP. @@ -3479,3 +3369,187 @@ Run a live script and get results back (5 minute timeout). Live scripts only run "exit_code": 0 } ``` +## Software + +### Batch-apply software + +_Available in Fleet Premium._ + +`POST /api/v1/fleet/software/batch` + +This endpoint is asynchronous, meaning it will start a background process to download and apply the software and return a `request_uuid` in the JSON response that can be used to query the status of the batch-apply (using the `GET /api/v1/fleet/software/batch/{request_uuid}` endpoint defined below). + +#### Parameters + +| Name | Type | In | Description | +| --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| team_name | string | query | The name of the team to add the software package to. Ommitting these parameters will add software to 'No Team'. | +| dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | +| software | object | body | The team's software that will be available for install. | +| software.packages | list | body | An array of objects. Each object consists of:`url`- URL to the software package (PKG, MSI, EXE or DEB),`install_script` - command that Fleet runs to install software, `pre_install_query` - condition query that determines if the install will proceed, `post_install_script` - script that runs after software install, and `uninstall_script` - command that Fleet runs to uninstall software. | + +#### Example + +`POST /api/v1/fleet/software/batch` + +##### Default response + +`Status: 200` +```json +{ + "request_uuid": "ec23c7b6-c336-4109-b89d-6afd859659b4", +} +``` + +### Get status of software batch-apply request + +_Available in Fleet Premium._ + +`GET /api/v1/fleet/software/batch/{request_uuid}` + +This endpoint allows querying the status of a batch-apply software request (`POST /api/v1/fleet/software/batch`). +Returns `"status"` field that can be one of `"processing"`, `"complete"` or `"failed"`. +If `"status"` is `"completed"` then the `"packages"` field contains the applied packages. +If `"status"` is `"processing"` then the operation is ongoing and the request should be retried. +If `"status"` is `"failed"` then the `"message"` field contains the error message. + +#### Parameters + +| Name | Type | In | Description | +| ------------ | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| request_uuid | string | query | The request_uuid returned by the `POST /api/v1/fleet/software/batch` endpoint. | +| team_name | string | query | The name of the team to add the software package to. Ommitting these parameters will add software to 'No Team'. | +| dry_run | bool | query | If `true`, will validate the provided software packages and return any validation errors, but will not apply the changes. | + +##### Default responses + +`Status: 200` +```json +{ + "status": "processing", + "message": "", + "packages": null +} +``` + +`Status: 200` +```json +{ + "status": "completed", + "message": "", + "packages": [ + { + "team_id": 1, + "title_id": 2751, + "url": "https://ftp.mozilla.org/pub/firefox/releases/129.0.2/win64/en-US/Firefox%20Setup%20129.0.2.msi" + } + ] +} +``` + +`Status: 200` +```json +{ + "status": "failed", + "message": "validation failed: software.url Couldn't edit software. URL (\"https://foobar.does.not.exist.com\") returned \"Not Found\". Please make sure that URLs are reachable from your Fleet server.", + "packages": null +} +``` + +### Batch-apply App Store apps + +_Available in Fleet Premium._ + +`POST /api/latest/fleet/software/app_store_apps/batch` + +#### Parameters + +| Name | Type | In | Description | +| --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| team_name | string | query | The name of the team to add the software package to. Ommitting this parameter will add software to 'No Team'. | +| dry_run | bool | query | If `true`, will validate the provided VPP apps and return any validation errors, but will not apply the changes. | +| app_store_apps | list | body | An array of objects. Each object contains `app_store_id` and `self_service`. | +| app_store_apps.app_store_id | string | body | ID of the App Store app. | +| app_store_apps.self_service | boolean | body | Whether the VPP app is "Self-service" or not. | + +#### Example + +`POST /api/latest/fleet/software/app_store_apps/batch` +```json +{ + "team_name": "Foobar", + "app_store_apps": { + { + "app_store_id": "597799333", + "self_service": false, + }, + { + "app_store_id": "497799835", + "self_service": true, + } + } +} +``` + +##### Default response + +`Status: 204` + +### Get token to download package + +_Available in Fleet Premium._ + +`POST /api/v1/fleet/software/titles/:software_title_id/package/token?alt=media` + +The returned token is a one-time use token that expires after 10 minutes. + +#### Parameters + +| Name | Type | In | Description | +|-------------------|---------|-------|------------------------------------------------------------------| +| software_title_id | integer | path | **Required**. The ID of the software title for software package. | +| team_id | integer | query | **Required**. The team ID containing the software package. | +| alt | integer | query | **Required**. Must be specified and set to "media". | + +#### Example + +`POST /api/v1/fleet/software/titles/123/package/token?alt=media&team_id=2` + +##### Default response + +`Status: 200` + +```json +{ + "token": "e905e33e-07fe-4f82-889c-4848ed7eecb7" +} +``` + +### Download package using a token + +_Available in Fleet Premium._ + +`GET /api/v1/fleet/software/titles/:software_title_id/package/token/:token?alt=media` + +#### Parameters + +| Name | Type | In | Description | +|-------------------|---------|------|--------------------------------------------------------------------------| +| software_title_id | integer | path | **Required**. The ID of the software title to download software package. | +| token | string | path | **Required**. The token to download the software package. | + +#### Example + +`GET /api/v1/fleet/software/titles/123/package/token/e905e33e-07fe-4f82-889c-4848ed7eecb7` + +##### Default response + +`Status: 200` + +```http +Status: 200 +Content-Type: application/octet-stream +Content-Disposition: attachment +Content-Length: +Body: +``` From d7be5d8ca039f2a578b3e8a020f05463faeb2f5c Mon Sep 17 00:00:00 2001 From: Rachael Shaw Date: Fri, 27 Sep 2024 16:20:48 -0500 Subject: [PATCH 77/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index c18589f21bd8..070890a91a9e 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -3405,7 +3405,7 @@ This endpoint is asynchronous, meaning it will start a background process to dow _Available in Fleet Premium._ -`GET /api/v1/fleet/software/batch/{request_uuid}` +`GET /api/v1/fleet/software/batch/:request_uuid` This endpoint allows querying the status of a batch-apply software request (`POST /api/v1/fleet/software/batch`). Returns `"status"` field that can be one of `"processing"`, `"complete"` or `"failed"`. From cf5052f427cb480c39b06886b15dfcadf8813b8e Mon Sep 17 00:00:00 2001 From: Rachael Shaw Date: Fri, 27 Sep 2024 16:20:55 -0500 Subject: [PATCH 78/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index 070890a91a9e..de8ddf47108d 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -3377,7 +3377,7 @@ _Available in Fleet Premium._ `POST /api/v1/fleet/software/batch` -This endpoint is asynchronous, meaning it will start a background process to download and apply the software and return a `request_uuid` in the JSON response that can be used to query the status of the batch-apply (using the `GET /api/v1/fleet/software/batch/{request_uuid}` endpoint defined below). +This endpoint is asynchronous, meaning it will start a background process to download and apply the software and return a `request_uuid` in the JSON response that can be used to query the status of the batch-apply (using the `GET /api/v1/fleet/software/batch/:request_uuid` endpoint defined below). #### Parameters From ea0bc2ebd3bafb525487da54c8092bc9385da14f Mon Sep 17 00:00:00 2001 From: Rachael Shaw Date: Fri, 27 Sep 2024 16:22:07 -0500 Subject: [PATCH 79/79] Update docs/Contributing/API-for-contributors.md --- docs/Contributing/API-for-contributors.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Contributing/API-for-contributors.md b/docs/Contributing/API-for-contributors.md index de8ddf47108d..67aa9766330b 100644 --- a/docs/Contributing/API-for-contributors.md +++ b/docs/Contributing/API-for-contributors.md @@ -3466,7 +3466,7 @@ _Available in Fleet Premium._ | Name | Type | In | Description | | --------- | ------ | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| team_name | string | query | The name of the team to add the software package to. Ommitting this parameter will add software to 'No Team'. | +| team_name | string | query | The name of the team to add the software package to. Ommitting this parameter will add software to "No team". | | dry_run | bool | query | If `true`, will validate the provided VPP apps and return any validation errors, but will not apply the changes. | | app_store_apps | list | body | An array of objects. Each object contains `app_store_id` and `self_service`. | | app_store_apps.app_store_id | string | body | ID of the App Store app. |