{"openapi":"3.0.3","info":{"version":"1.0.0","title":"Microsoft 365","description":"This document lists M365 APIs for data protection using Druva inSync."},"servers":[{"url":"https://apis.druva.com"}],"tags":[{"name":"App Management","description":"Lists the APIs to get information and perform operations on M365 Apps managed in Druva SaaS Apps."}],"paths":{"/insync/cappmaster/v1/apps/status":{"get":{"tags":["App Management"],"summary":"Get Microsoft 365 Apps Status","description":"Provides the App Connection Status for M365.","operationId":"getCloudAppStatus","security":[{"bearerAuth":[]}],"parameters":[{"$ref":"#/components/parameters/tenantType"}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAppStatus"},"examples":{"M365":{"$ref":"#/components/examples/CloudAppStatus"}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/sharepointmaster/v3/sites":{"get":{"tags":["Restore SharePoint Online data"],"summary":"List All SharePoint Site Collections","description":"Retrieve the list of SharePoint site collections.","operationId":"getSites","security":[{"bearerAuth":[]}],"parameters":[{"in":"query","name":"lastBackupStatus","required":false,"schema":{"type":"array","items":{"type":"string","enum":["Backup Failed","Backed Up With Errors","Backed Up Successfully","Never Backed Up","Backup Cancelled"]},"description":"Specify the backup status of the SharePoint site for filtering. Set this value to one of the following: `Backup Failed`, `Backed Up With Errors`, `Backed Up Successfully`, `Successful with errors`, `Never Backed Up`, or `Backup Cancelled`. Leave empty to return all sites."}},{"in":"query","name":"searchTerm","required":false,"schema":{"type":"string","description":"Specify the title or URL of the SharePoint site for filtering."}},{"in":"query","name":"sortOrder","required":false,"schema":{"type":"string","enum":["asc","desc"],"description":"Specify the sorting order for the results. Use `asc` for ascending or `desc` for descending."}},{"in":"query","name":"sortByColumn","required":false,"schema":{"type":"string","enum":["siteCollectionId","title","siteStatus","lastBackupStatus","statusDetails","siteType","bulkExportStatus","lastBulkExportStatus","lastCompletedBulkExport","lastSync","backupData","siteCollectionUrl","configurationStatus","appState"],"description":"Specify the column name to sort the results. Example: Choose `lastSync` to arrange the results based on the last synchronization time of the SharePoint site."}},{"in":"query","name":"pageSize","required":false,"schema":{"type":"integer","maximum":1000,"description":"Specify the number of records to retrieve per request.\nFor example, if you want to retrieve 100 records in each request, set the `pageSize` as `100`."}},{"in":"query","name":"nextPageToken","required":false,"schema":{"type":"string","description":"Specify the token to access the next page of results. Keep this field blank in the first request. Use the token value received in the previous response's parameter 'nextPageToken'."}},{"in":"query","name":"appState","required":false,"schema":{"type":"string","enum":["Enabled","Disabled"],"description":"Specify the status of the SharePoint site for filtering. Set this value to one of the following: `Enabled` or `Disabled`."}},{"in":"query","name":"configurationStatus","required":false,"schema":{"type":"string","enum":["Configured","Not Configured"],"description":"Specify the configuration status of the SharePoint site for filtering. Set this value to one of the following: `Configured` or `Not Configured`"}},{"in":"query","name":"siteType","required":false,"schema":{"type":"array","items":{"type":"string","enum":["MS Teams Site","M365 Groups Site","MS Teams Private Channel Site","Other Site"]},"description":"Specify the type of SharePoint site for filtering.\nSet this value to one of the following: `MS Teams Site`, `M365 Groups Site`, `MS Teams Private Channel Site` or `Other Site.`"}},{"in":"query","name":"bulkExportStatus","required":false,"schema":{"type":"array","items":{"type":"string","enum":["Enabled","Disabled"]},"description":"Specify the Bulk Export Status of the SharePoint site for filtering.\nSet this value to one of the following: `Enabled` or `Disabled`."}},{"in":"query","name":"lastBulkExportStatus","required":false,"schema":{"type":"array","items":{"type":"string","enum":["Completed Successfully","Failed","Completed With Errors","Never Exported"]},"description":"Specify the Last Bulk Export Status of the SharePoint site for filtering. Set this value to one of the following: `Completed Successfully`, `Failed`, `Completed With Errors` or `Never Exported.`"}},{"in":"query","name":"pageNumber","required":false,"schema":{"type":"integer","description":"Specify the `pageNumber` parameter to indicate the page of results to retrieve in paginated API requests.\n\n For example, when initially calling the API with a `pageSize` of `100`, the first request returns records 1 to 100. Subsequent pages can be fetched using either the `nextPageToken` or `pageNumber` parameter.\n\n This parameter allows you to directly retrieve records from a specific page (e.g., records `401` to `500`) by providing the desired page number (e.g., `5`)."}},{"in":"query","name":"errors","required":false,"schema":{"type":"array","items":{"type":"string","enum":["MS-01","MS-247","MS-11","MS-17","MS-10","MS-22","MS-70","MS-135","MS-75","SPO-01","SPO-02","SPO-03","SPO-04","SPO-05","SPO-06","SPO-07","SPO-09","SPO-11","SPO-12","SPO-13","SPO-15","SPO-16","SPO-17","SPO-18","SPO-19","SPO-20","SPO-21","SPO-22","SPO-23","SPO-24","SPO-25","SPO-26","SPO-27","SPO-28","SPO-29","SPO-31","SPO-32","SPO-35"]},"example":["MS-01","SPO-22"],"description":"Specify a comma-separated list of specific error codes to filter the results.\nExample: use codes like `SPO-01`, `SPO-02`, and so on."}}],"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_list_sites"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/sharepointmaster/v2/siteCollections/{site_collection_id}/restorePoints":{"get":{"tags":["Restore SharePoint Online data"],"summary":"List All SharePoint Site Restore Points","description":"Retrieve the list of restore points for SharePoint sites protected by Druva.","security":[{"bearerAuth":[]}],"parameters":[{"name":"site_collection_id","in":"path","description":"Specify the unique identifier associated with a specific SharePoint site collection for filtering. Get the ID of a site using the `List all SharePoint Site Collections` API.","required":true,"schema":{"type":"integer"}},{"name":"include_virtual","in":"query","description":"Specify the flag indicating whether to include a curated snapshot in the result. Use `true` to include or `false` to exclude the curated snapshot.","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_list_spo_restore_points"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/sharepointmaster/v2/restores":{"post":{"tags":["Restore SharePoint Online data"],"summary":"Restore a SharePoint Site","description":"Performs a restore of a SharePoint site to a new or existing site.","operationId":"restorePoints","security":[{"bearerAuth":[]}],"requestBody":{"content":{"application/json":{"schema":{"properties":{"site_collection_id":{"type":"integer","example":123,"required":["site_collection_id"],"description":"Specify the unique identifier associated with a specific SharePoint site collection for filtering. \n\nGet the ID of a site using the `List all SharePoint Site Collections` API."},"path":{"type":"string","example":"[{\"minor_type\": 1, \"handle\": \"/Thu Mar 7 13:18:43 2024/shan_dl_restore\", \"parent\": \"root\"}]","required":["path"],"description":"Specify the list of paths to be restored, including the minor type, handle, and root for each path. \n\n The format for each path is as follows: \n `{\"minor_type\": 1,\n\"handle\": \"/Thu Mar 7 13:18:43 2024/shan_dl_restore\",\n\"parent\": \"root\"}` \n\n - **Minor Type**: The minor type represents the type of item being restored. The possible values are:`0-Folder`, `1-File`, `2-Document List`, `9-Settings File`, `10-List`, `11-Subsite`\n\n - **Handle**: The handle is the path to the specific item being restored relative to the snapshot. It follows this format: ``\n\n - **Parent/Root**: The root specifies the parent directory or root context for the item being restored. Multiple paths can be provided as a comma-separated list. It follows this format: ``"},"in_place":{"type":"boolean","example":"true/false","description":"Specify the flag indicating if the restore operation is an in-place restore. \n\n - If param `restore_to` is set to `new` then `` should be `false`. \n\n - If param `restore_to` is set to `existing`, then `in_place` should be `true`.","required":["in_place"]},"sid":{"type":"integer","example":1,"required":["sid"],"description":"Specify the ID of the storage assigned to the site collection. \nGet the ID of storage using the `List all storages API`. This API returns the list of all storage that the customer is using. \n\nThe list will provide the ID - Storage name mapping for each region that the customer is using. To know a SharePoint site's storage name, customers can see a SharePoint site's summary."},"restore_to":{"type":"string","example":"new","description":"Specify the flag indicating if the data should be restored to a new or an existing site. \nUse `new` to restore data to a new site collection or `existing` to restore data to an existing site collection.\n\nⓘ Note: If param `restore_to` is set to `new`, then `in_place` should be `false`. If param `restore_to` is set to `existing` then `in_place` should be `true`."},"destination_site_url":{"type":"string","example":"/sites/example","description":"Specify the URL of the destination site to be used in case of restoring data to an existing site."},"destination_site_title":{"type":"string","example":"Hello","description":"Specify the title of the destination site to be used in case of restoring data to an existing site."},"use_source_site_params":{"type":"boolean","example":false,"description":"Specify the flag indicating if the parameters from the source site should be used when restoring data to a new or existing site. \n\n - When set to `true`, the restore operation will apply the site configuration parameters (e.g., site templates, language settings, regional settings, etc.) from the original source site to the destination site. \n\n - If set to `false`, the operation will use the default site configuration parameters for the destination site, ignoring the source site's settings."},"new_site_params":{"type":"string","description":"Specify the site title and description containing the details for the new site to be created during a restore operation to a new site.\n\n `{\"new_site_title\": Title of the new site,\"new_site_description\": Description of the new site}` \n\nⓘNote: If param `restore_to` is set to an `existing`, the `new_site_params` is not required.","example":"{\"new_site_title\":\"RestoreNewprasadtestsite824\",\"new_site_description\":\"Whole site restore to a new site with site settings\"}"},"spo_settings_restore_option":{"type":"integer","example":1,"description":"Specify whether the SharePoint Online settings need to be restored or not during the restore operation. \n\n - Set it to `1` to include SharePoint Online settings in the restore process. These settings may include site configurations, regional settings, language settings, and other SharePoint Online-specific settings. \n\n - Set it to `0` to skip restoring SharePoint Online settings and only restore the content and data."},"teams_restore_params":{"type":"string","example":"","description":"Specify the parameters required for restoring a team. \n\n `{\"destination_site_collection_url\": \"/sites/example\", \"restore_to\": \"new\", \"restore_paths\": \"[{\"minor_type\": 1, \"handle\": \"/Thu Mar 7 13:18:43 2024/shan_dl_restore\", \"parent\": \"root\"}]\", \"is_wiki_restore\": \"false\"}`\n\n ⓘ Note: This is required only if `is_team_triggered` parameter is set to `true`"}}}}}},"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_trigger_spo_restore_resp"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/usermanagement/v1/users":{"get":{"tags":["Restore OneDrive/Exchange Online data"],"summary":"List users based on query filters","description":"Retrieve a filtered list of users based on query filters.","operationId":"getUserList","security":[{"bearerAuth":[]}],"parameters":[{"in":"query","name":"profileID","schema":{"type":"integer"},"required":false,"description":"Specify the unique ID of a profile to retrieve the list of users associated with that profile. Obtain the profile ID using the `List all profiles` API."},{"in":"query","name":"status","schema":{"type":"string","enum":["active","preserved"]},"required":false,"description":"Specify the flag indicating the desired user account status to filter the list of users based on the current status of their accounts. \n Set it to `active` to list active users or `Preserved` to list the preserved users."},{"in":"query","name":"storageID","schema":{"type":"integer","minimum":1},"required":false,"description":"Specify the ID of the storage assigned to the site collection. Get the ID of storage using the `List all storages API`. This API returns the list of all storage that the customer is using. \n\nThe list will provide the ID - Storage name mapping for each region that the customer is using. To know a SharePoint site's storage name, customers can see a SharePoint site's summary"},{"in":"query","name":"minAddedOn","schema":{"type":"string","pattern":"([12]\\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01]))T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]Z"},"required":false,"description":"Specify the date/time to filter the list of users to include only those who were added to Druva inSync after the specified date and time. Provide the UTC date and time using the `YYYY-MM-DDTHH:MM:SSZ` format."},{"in":"query","name":"maxAddedOn","schema":{"type":"string","pattern":"([12]\\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01]))T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]Z"},"required":false,"description":"Specify the date/time to filter the list of users to include only those who were added to Druva inSync before the specified date and time. Provide the UTC date and time using the `YYYY-MM-DDTHH:MM:SSZ` format."},{"in":"query","name":"emailID","schema":{"type":"string","pattern":"^(([^<>()\\[\\]\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$"},"required":false,"description":"Specify the email address of a user to retrieve their details."},{"in":"query","name":"cacheID","schema":{"type":"integer"},"required":false,"description":"Specify the ID of a CloudCache Server to retrieve the list of users associated with that server. \n\nObtain theCloudCache Server ID using the `List all CloudCache Servers` API."},{"in":"query","name":"userIDs","schema":{"type":"array","items":{"type":"integer"}},"required":false,"description":"Specify an array of unique user IDs to retrieve the details of specific users. Separate multiple user IDs with commas. /n/n - When this parameter is provided, the API will return information for only the users whose IDs are included in the array. /n - If it is not provided, the API returns the details of all the users."},{"in":"query","name":"searchPrefixUserName","schema":{"type":"string"},"required":false,"description":"Specify a prefix string to search and list users whose usernames begin with that prefix. The search is case-insensitive. \n\nExample: To search for users with usernames that start with `Ern` (such as `Ernie` or `Ernest`), set `searchPrefixUserName=Ern`."},{"in":"query","name":"searchPrefixEmailID","schema":{"type":"string"},"required":false,"description":"Specify a prefix string to search and list users whose email addresses begin with that prefix. The search is case-insensitive. \n\n Example: To search for users with email addresses that start with `ernie.carter` (such as `ernie.carter@example.com`), set `searchPrefixEmailID=ernie.carter`."},{"in":"query","name":"ldapGUID","schema":{"type":"string"},"required":false,"description":"Specify the Active Directory (AD) or Lightweight Directory Access Protocol (LDAP) object globally unique identifier (GUID) to retrieve a list of users associated with it. \n\nPass the parameter value as a hexadecimal string. For example: 'B1C47201C67910458867BA19982E353E'."},{"in":"query","name":"privacySettingsEnabled","schema":{"type":"boolean"},"required":false,"description":"Specify the privacy flag to filter the list of users based on the status of their privacy settings. \n\n - Set it to true to list users who have their privacy settings enabled or \n\n - Set it to false to list users who have their privacy settings disabled."},{"in":"query","name":"orderBy","schema":{"type":"string","enum":["userName","emailID","deviceCount","customUniqueID","totalDeviceUsage","m365Usage","googleUsage","cloudappCount","userID"]},"required":false,"description":"Specify the column name that Druva should use for sorting the data. Druva will sort the results using the data in the column and the sorting order that you specify in the next field. \n\nFor example, to sort the data using the `emailID` column, set `orderBy=emailID.`"},{"in":"query","name":"order","schema":{"type":"string","enum":["asc","desc"]},"required":false,"description":"Specify the sorting order for the data. \n\n - Set it to asc to sort the data in ascending order or \n\n - Set it as desc to sort the data in descending order."}],"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_list_users"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/cadevice/v1/devices":{"get":{"tags":["Restore OneDrive/Exchange Online data"],"summary":"List All Protected Cloud Apps","description":"Retrieve the list of all protected SaaS apps.","operationId":"getDeviceList","security":[{"bearerAuth":[]}],"parameters":[{"name":"appName","in":"query","description":"Specify the name of the application for which you want to retrieve a list of associated devices. \n\nExample: Exchange Online","required":false,"schema":{"type":"string"}},{"name":"sortByColumn","in":"query","description":"Specify the column name to use for sorting the list of devices that the API returns. \n\nxample: To sort the device list by the application name, set `sortByColumn`=appName.","required":false,"schema":{"type":"string"}},{"name":"sortOrder","in":"query","description":"Specify the order in which to sort the results based on the column specified in the `sortByColumn` parameter. \n\n - Set it to `asc` to sort the data in ascending order or \n\n - Set it to desc to sort the data in descending order.","required":false,"schema":{"type":"string"}},{"name":"searchTerm","in":"query","description":"Specify a search term to filter the list of devices returned. The results will include devices whose `appName` partially matches the provided search term (case-insensitive). \n\nExample: To search for devices with application names containing `Test`, set `searchTerm`=Test. This would match applications like \"TestApp\", \"MyTestApplication\", and \"ProductionTestSuite\".","required":false,"schema":{"type":"string"}},{"name":"userID","in":"query","description":"Specify the user IDs for which to retrieve device lists. \n\n - If provided, the API will return the list of devices associated with the specified user(s). \n\n - If not provided, the API will return the list of devices for all users. \n\nExample: To retrieve the device list for the user with ID 123, set `userID`=[123]. To retrieve device lists for multiple users, such as 123 and 456, set `userID`=[123, 456].","required":false,"schema":{"type":"array","items":{"type":"number"}}},{"name":"profileID","in":"query","description":"Specify an array of profile IDs for which to retrieve device lists. \n\n - If provided, the API will return the list of devices associated with the specified profile(s). \n\n - If not provided, the API will return the list of devices for all profiles. \n\n Example: To retrieve the device list for the profile with ID 123, set `profileID`=[123]. To retrieve device lists for multiple profiles, such as 123 and 456, set `profileID`=[123, 456].","required":false,"schema":{"type":"array","items":{"type":"number"}}},{"name":"pageSize","in":"query","description":"Specify the number of devices to include in each page of the paginated response. This value must be an integer between 1 and 1000. \n\n If not provided, the default page size is 1000.\n\nExample: To retrieve the device list in pages of 25 devices at a time, set `pageSize=25`.","required":false,"schema":{"type":"string"}},{"name":"nextPageToken","in":"query","description":"Specify the token to access the next page of results. Keep this field blank in the first request. Use the token value received in the previous response's parameter `nextPageToken`","required":false,"schema":{"type":"string"}},{"name":"workload","in":"query","description":"Specify the workload for which to retrieve the list of devices. Each workload identifier corresponds to the `cplatform` value stored in the device table.","required":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"lastBackupStatus","in":"query","description":"Specify the backup status flag to filter the list of devices based on their last backup status.The provided value must match the backup status exactly (case-sensitive), and partial matches are not accepted.","required":false,"schema":{"type":"string"}},{"name":"lastBackupTime","in":"query","description":"Specify the `lastBackupTime` flag as an date (epochtime) to filter out the devices based on their last successful backup time.","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_DeviceList"},"examples":{"example":{"value":{"totalResults":1,"nextPageToken":"","devices":[{"id":1,"appName":"OneDrive","userID":1,"userUrl":"https://insync.druva.com/admin/app/#/user/users/1","workload":"Office 365 OneDrive","createdOn":"2021-10-25T00:00:00.000Z","lastCompacted":1640076452,"profileID":1,"customerID":1,"lastBackupStatus":"Backed Up Successfully","lastBackupJob":1640076452,"lastSuccessfulBackup":1640076452,"deviceDisabled":false}]}}}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/cloudapp/v1/restorePoints":{"get":{"tags":["Restore OneDrive/Exchange Online data"],"summary":"List All OneDrive/Exchange Online Restore points","description":"Retrieve the list of OneDrive/Exchange Online restore points.","operationId":"getRestorePoints","security":[{"bearerAuth":[]}],"parameters":[{"name":"deviceId","description":"Specify the device ID associated with the OneDrive or Exchange account for which restore points are required.","schema":{"type":"integer","example":10001},"required":true,"in":"query"},{"name":"userId","description":"Specify the user ID associated with the OneDrive or Exchange account for which restore points are required.","schema":{"type":"integer","example":10001},"required":true,"in":"query"},{"name":"storageId","description":"Specify the ID of the storage assigned to the account. Get the ID of storage using the `List all storages API`. \n\nThis API returns the list of all storage that the customer is using. The list will provide the ID - Storage name mapping for each region that the customer is using.","required":false,"schema":{"type":"integer","example":10003},"in":"query"},{"name":"detailedRpStats","description":"Specify the flag indicating whether detailed snapshot statistics are required in the list of all OneDrive/Exchange Online restore points. \n\n - Set it to `true` to include detailed statistics about the snapshot in the response or \n\n - `false` to exclude detailed statistics about the snapshot in the response.","required":false,"schema":{"type":"boolean","example":false},"in":"query"},{"name":"anomalousInfoRequired","description":"Specify the flag indicating whether information about anomalous snapshots is required in the list of all OneDrive/Exchange Online restore points. \n\n - Set it to `true` to include anomalous snapshot information or \n\n - Set it to `false` to exclude anomalous snapshot information.","required":false,"schema":{"type":"boolean","example":false},"in":"query"},{"name":"includVirtual","description":"Specify the flag indicating whether information about curated snapshots is required in all OneDrive/Exchange Online restore points lists. \n\n - Set it to `true` to include curated snapshot information or \n\n - set it to `false` to exclude curated snapshot information.","required":false,"schema":{"type":"boolean","example":false},"in":"query"},{"name":"startTime","description":"Specify the start time to filter the list of restore points. The value must be a Unix timestamp in seconds. Use with the endTime parameter to retrieve restore points within a specific time range.","required":false,"schema":{"type":"integer","example":1710424684},"in":"query"},{"name":"endTime","description":"Specify the end time to filter the list of restore points. The value must be a Unix timestamp in seconds. Use with the startTime parameter to retrieve restore points within a specific time range.","required":false,"schema":{"type":"integer","example":1710424684},"in":"query"}],"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_list_restore_points"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}},"/insync/cloudapp/v1/restores":{"post":{"tags":["Restore OneDrive/Exchange Online data"],"summary":"Restore a OneDrive Account or Exchange Online Mailbox","description":"Performs a restore of a OneDrive account or an Exchange Online mailbox to a new or existing account.","operationId":"restore","security":[{"bearerAuth":[]}],"requestBody":{"content":{"application/json":{"schema":{"properties":{"retainShareSettings":{"type":"boolean","example":false,"description":"Specify the flag indicating whether the sharing settings of the restored items should be retained during the restore operation. \n\n - Set it to `true` to apply the original sharing settings or \n\n - `false` to apply the default sharing settings to the restored items."},"inplaceRestoreDeletedOnly":{"type":"boolean","example":false,"description":"Specify the flag indicating whether the in-place restore operation should restore deleted items. \n\n - Set it to `true` to restore deleted items or \n\n - `false` to exclude deleted items."},"sources":{"type":"array","description":"Specify the paths of files or folders that you want to restore. \n\n ⓘ Note: The length of the sources array should match the length of the source_types array. The format for each path or file is as follows:`/backup_date/folder_or_library_name/file_or_folder_name`","items":{"type":"string","example":"/Wed Mar 6 11:54:00 2024/Documents/1st Aug"}},"destination":{"type":"string","description":"Specify the destination where you want to restore the data.\n\n ⓘ Note: This field is required for Exchange Online device restore operations.","example":"inSync Restore Thu Mar 7 07-50-01 2024"},"storage":{"type":"integer","example":0,"description":"Specify the storage flag to identify if the provided storageId refers to a primary or secondary storage. \n\nSet the storage flag to 0 for primary storage and 1 for secondary storage."},"sourceTypes":{"type":"array","description":"Specify the types of sources (files or folders) to be restored. Set it to `32768` for files or `16384` for folders. \n\n ⓘ Note: The length of the sourceTypes array should match the length of the sources array.","items":{"type":"integer","example":16384},"example":[16384,32768]},"storageId":{"type":"integer","description":"Specify the ID of the storage assigned. Get the ID of storage using the `List all storages API`. Refer This API returns the list of all storage that the customer is using. The list will provide the ID - Storage name mapping for each region that the customer is using.","example":1001,"required":["storageId"]},"restoreOption":{"description":"Specify the type of restore operation. \n\n - Set it to `inplacerestore` to restore data to the original location from which the backup was taken or \n\n - Set it to `restorecopy` to restore to a new or different location.","type":"string","example":"restorecopy","required":["true"]},"isCloudapp":{"type":"boolean","example":true,"description":"Specify the flag indicating whether the restore operation is for a cloud application. \n\n - Set it to `true` for cloud applications or \n\n - `false` for non-cloud applications such as on-premises systems, local servers, or other non-cloud environments."},"includeExchangeInplaceArchive":{"type":"boolean","example":false,"description":"Specify the flag indicating whether the restore operation should include the Exchange In-Place Archive. \n\n - Set it to `true` to restore operation and include the Exchange In-Place Archive data. Any archived emails or data stored in the user's In-Place Archive will be restored along with the primary mailbox data. \n\n - Set it to `false` for the restore operation to exclude the Exchange In-Place Archive data and only restore the data from the primary mailbox."},"selectiveRestore":{"type":"boolean","example":false,"description":"Specify the flag indicating whether the restore operation should be a selective restore or a full restore. \n\n - Set to `true` for a selective restore or \n\n - `false` to indicate that the restore operation will be a full restore, where the entire backup set or data source will be restored."},"fromDeviceId":{"type":"integer","description":"Specify the source device ID from which the data needs to be restored.","example":1000001,"required":["fromDeviceId"]},"deviceId":{"type":"integer","description":"Specify the destination device ID to which the data should be restored.","example":1000001,"required":["deviceId"]},"appType":{"type":"string","description":"Specify the application for which the restore operation is being performed. \n\n - Set to `O365 OneDrive` to Indicate that the restore operation is for Microsoft Office 365 OneDrive or \n\n - Set to `O365 Exchange Online` if the restore operation is for Microsoft Office 365 Exchange Online.","required":["appType"],"example":"O365 OneDrive"},"version":{"type":"integer","description":"Specify the version number or identifier for the Exchange Online device restore operation.\n\n ⓘ Note: This field is required only for Exchange Online device restore operations."},"pathDetails":{"type":"array","example":["inSync-Mails-root"],"description":"Specify the path or locations of the data to be restored in an Exchange Online device restore operation. \n\nExample: the pathDetails array contains three strings: `inSync-Mails-root` Represents the path or location of the mailbox or mail data to be restored.\n\nⓘ Note: This field is required only for Exchange Online device restore operations.","items":{"type":"string","example":"inSync-Mails-root"}}}}}}},"responses":{"200":{"description":"success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/200_trigger_restore_resp"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"BadRequest":{"$ref":"#/components/examples/BadRequest"}}}}},"401":{"description":"The request did not include an authentication token or an expired authentication token was supplied.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Unauthorized":{"$ref":"#/components/examples/Unauthorized"}}}}},"403":{"description":"Access denied: Insufficient permissions. User requires specific access rights and minimum permissions. Details: https://help.druva.com/en/articles/15069296","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"Forbidden":{"$ref":"#/components/examples/Forbidden"},"GARError":{"$ref":"#/components/examples/GARError"}}}}},"404":{"description":"The requested resource was not found.","content":{"application/json":{"schema":{},"examples":{"NotFound":{"$ref":"#/components/examples/NotFound"}}}}},"500":{"description":"The request was not processed due to an internal error on server.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"InternalServerError":{"$ref":"#/components/examples/InternalServerError"}}}}},"501":{"description":"Requested HTTP method is not implemented.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"NotImplemented":{"$ref":"#/components/examples/NotImplemented"}}}}}}}}},"components":{"schemas":{"CloudAppStatus":{"type":"object","properties":{"status":{"type":"integer","example":0,"description":"Status response code for API. It is 0 (zero) for a success response."},"M365":{"type":"array","items":{"type":"object","properties":{"appId":{"type":"integer","example":1,"description":"The ID of the App."},"appName":{"type":"string","example":"Microsoft 365 Advanced","description":"The name of the App configured for backup. Example - Microsoft 365 Advanced"},"status":{"type":"integer","example":3,"description":"The status of the application.\n\n- 0 - Not configured\n\n- 1 - Configured\n\n- 2 - Not connected\n\n- 3 - Connected\n\n- 4 - Not licensed"},"lastConfigured":{"type":"string","example":"2020-09-18T11:50:41+00:00Z","description":"The date and time when the app was last configured. Example format - YYYY-MM-DDTHH:MM:SSZ"},"clientid":{"type":"string","example":"r5949668-853d-485t-vlo5-28df7cd0d7c8","description":"The Application or Client ID of the App. Example - r5942009-853d-485t-vlo5-28df7cd0d7c8"}}},"description":"Array of dictionary containing app information for specific tenant type"}}},"200_list_spo_restore_points":{"type":"array","items":{"type":"object","properties":{"isAnomalous":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is anomalous."},"ls_name":{"type":"string","example":"Wed Mar 6 11:54:00 2024","description":"Snapshot name."},"filesMissed":{"type":"integer","example":0,"description":"Number of files missed in the snapshot."},"ls_rpxattrs":{"type":"object","example":{},"description":"Dict containing the restore point extra attributes."},"display_name":{"type":"string","example":"Wed Mar 6 11:54:00 2024","description":"Snapshot display name"},"ls_virtual":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is virtual snapshot on storage"},"filesSynced":{"type":"integer","example":221,"description":"Number files backed up in snapshot"},"ls_stat":{"type":"object","example":{"st_blocksz":0,"st_flags":0,"st_mtime":1710236576,"st_links":1,"st_mdattrs":null,"st_ver":18,"st_method":-1,"st_deleted":false,"st_mode":16384,"st_acl_handle":0,"st_size":40041770,"st_ino":5,"st_valid":true,"st_readsz":0,"st_cver":17},"description":"Object containg the storage stats of the snapshot."},"is_virtual":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is virtual snapshot"},"sysState":{"type":"integer","example":0,"description":"System state of the snapshot"},"sid":{"type":"integer","example":1000002,"description":"Storage id of snapshot"},"ls_softdel":{"type":"object","properties":{"deleted":{"type":"boolean","example":false,"description":"Flahg indicating if the snashot is deleted"},"softdeleted":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is soft deleted"}},"example":{"deleted":false,"softdeleted":false},"description":"Object containing the info if the snapshot is deleted or soft deleted."},"latestUnquarantined":{"type":"boolean","example":true,"description":"Flag indicating if the snapshot is latest unquarantined snapshot"},"isQuarantined":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is quarantined snapshot"},"ls_locked":{"type":"boolean","example":false,"description":"Flag indicating of the snapshot is locked"},"ignFilesMissed":{"type":"integer","example":0,"description":"Number of ignored files missed."},"bmr":{"type":"boolean","example":false,"description":"Flag indicating if the meeting recordings are backed up in snapshot"},"ectime":{"type":"integer","example":1709726041,"description":"Snapshot exact creation datetime"},"ls_ino":{"type":"integer","example":5,"description":"Snapshot number"},"ls_type":{"type":"integer","example":5,"description":"Snapshot type. Default 5"},"ls_rplckowns":{"type":"array","items":{"type":"string"},"example":[],"description":"List of rplc knowns"},"ls_dver":{"type":"integer","example":2147483632,"description":"Snapshot data version"},"ctime":{"type":"integer","example":1709726040,"description":"Snapshot creation detetime"},"totalSize":{"type":"integer","example":23903222,"description":"Total size of snapshot in bytes"},"ls_cver":{"type":"integer","example":17,"description":"Snapshot version number"},"ls_cseq":{"type":"integer","example":5,"description":"Snapshot sequence number"}}}},"200_list_sites":{"type":"object","properties":{"status":{"type":"integer","example":0,"description":"SharePoint site status eg. 0-Disabled, 1-Enabled"},"nextPageToken":{"type":"string","example":"Mg==","description":"Token to be used in next request to fetch next page data."},"totalResult":{"type":"integer","example":3500,"description":"Total no of SharePoint sites available with provided filter criteria."},"pageSize":{"type":"integer","example":1000,"description":"Current page size i.e no of records to fetched per page"},"siteCollections":{"type":"array","items":{"type":"object","properties":{"lastSync":{"type":"integer","example":1712909603,"description":"Datetime on which the last backup of SharePoint Site was done. 0 in case of Never Backed Up."},"siteType":{"type":"string","example":"M365 Groups Site","description":"Type of SharePoint site. eg. MS Teams Site, M365 Groups Site, MS Teams Private Channel Site, Other Site"},"siteCollectionId":{"type":"integer","example":123,"description":"SharePoint site collection id"},"siteCollectionUrl":{"type":"string","example":"https://druvaglobalind.sharepoint.com/sites/SC_V","description":"SharePoint site collection URL"},"backupData":{"type":"integer","example":19745050,"description":"Backed up data in bytes."},"storageid":{"type":"integer","example":0,"description":"Id of storage attached to SharePoint site collection."},"backupDataStr":{"type":"string","example":"18.83 MB","description":"Backed up data in human readable text format."},"guid":{"type":"string","example":"a0de3f5a-e0b8-41ce-9bc2-446932c5420f","description":"Unique id of SharePoint site collection provided by Microsoft."},"useDefaultSettings":{"type":"boolean","example":true,"description":"Boolean flag indicating whether the SharePoint site collection is using default backup settings or not."},"errors":{"type":"array","items":{"type":"string"},"example":["MS-01","SPO-22"],"description":"List of new error codes occurred in recent backup activity of SharePoint sites"},"titleUrl":{"type":"string","example":"https://insync-prasadp.drtst.in/admin/app/#/cloudapps/office365/sharepoint/1/summary","description":"Url of the summary page of the SharePoint site collection"},"lastBackupJob":{"type":"integer","example":1712909603,"description":"Datetime when the last backup job was run for SharePoint site"},"title":{"type":"string","example":"SC_V","description":"Title of SharePoint site collection"},"bulkExportStatus":{"type":"string","example":"Disabled","description":"Staus indicating if the Bulk Export is Enabled or Disabled for SharePoint site collection."},"totalErrorsCount":{"type":"integer","example":0,"description":"Total count of errors occured during the backup of SharePoint site collection."},"lastActivityId":{"type":"integer","example":0,"description":"Id of the last backup activity for SharePoint site collection."},"parentId":{"type":"integer","example":0,"description":"Id of the parent MS Team or MS Group if SharePoint site belongs to any MS Team or MS Group. Default is 0."},"filescurrent":{"type":"integer","example":471,"description":"Total no of files backed up currenly."},"lastSyncTime":{"type":"integer","example":1712909603,"description":"Datetime on which the last backup of SharePoint Site was done. 0 in case of Never Backed Up."},"cloudappBackupStatus":{"type":"integer","example":0,"description":"Error code indicating the last error occured in last failed back up. 0 if none of the backups are failed."},"enabled":{"type":"integer","example":1,"description":"No indicating if SharePoint site collection is enabled or disabled for backup. 0-Disabled, 1-Enable."},"lastBackupStatus":{"type":"string","example":"Backed Up Successfully","description":"Status of last backup of SharePoint site collection. Eg. Backed Up Successfully, Backed Up With Errors, Never Backed Up, Backup Cancelled, Backup Failed"},"parentType":{"type":"integer","example":0,"description":"Value indicating the type of parent of site if the SharePoint site belongs to any MS Team or Ms Group. Eg. 5-MS Team, 10-MS Group"},"configured":{"type":"boolean","example":true,"description":"Flag indicating if the site is configured for backup or not."},"missedFiles":{"type":"integer","example":0,"description":"Number of files missed during the last backup."},"currentBackupData":{"type":"integer","example":19745050,"description":"Current backed up data in bytes."},"totalFiles":{"type":"integer","example":0,"description":"Total number of files in SharePoint site collection."},"geoLocation":{"type":"string","example":"IND","description":"Geo location code to which the SharePoint site belongs."},"workload":{"type":"string","example":"SharePoint","description":"Workload of SharePoint site collection. Default SharePoint."},"createdOn":{"type":"integer","example":1710165704,"description":"Datetime of SharePoint site collection creation"},"lastSyncFailed":{"type":"boolean","example":false,"description":"Flag indicating if the last backup failed. True if last backup failed else False"},"useDefaultExportSettings":{"type":"boolean","example":true,"description":"Flag indicating whether to use default bulk export settings."},"lastSuccessfullBackup":{"type":"integer","example":0,"description":"Datetime of last successful backup of SharePoint site collection"},"siteStatusStr":{"type":"string","example":"Not Configured","description":"SharePoint site collection configuration status string Eg. Configured, Not Configured."},"customerId":{"type":"integer","example":2,"description":"Druva Customer Id of SharePoint site collection"},"internalTitle":{"type":"string","example":"SC_V_Main","description":"System-defined title of the SharePoint site collection, primarily used for backend processes such as restore."}}},"description":"List of SharePoint Site Collections"}}},"200_trigger_spo_restore_resp":{"type":"object","properties":{"message":{"type":"string","example":"Restore triggered successfully.","description":"Message indicating the restore trigger status if restore is triggered successfully or restore trigger failed."},"restore_status":{"type":"integer","example":0,"description":"Restore status code. Eg. 0-Success, 1-Failure"},"restore_task":{"type":"boolean","example":true,"description":"flag indicating if restore task was created successfuly. Eg. True-Success, False-Failure"},"task_id":{"type":"integer","example":"3458","description":"A unique identifier for the restore task."}}},"200_list_users":{"type":"object","properties":{"totalSize":{"type":"integer","description":"The total number of users fetched based on applied filters."},"nextPageToken":{"type":"string","description":"The token to access the next page of results. This parameter will be empty for the last page of results."},"users":{"type":"array","items":{"type":"object","properties":{"userName":{"type":"string","description":"The username of the user in inSync. Example - Ernie Carter"},"emailID":{"type":"string","description":"The email address of the user. Example - ernie.carter@druva.com"},"userID":{"type":"integer","description":"The unique id of the user in inSync. Example - 1"},"status":{"type":"string","description":"The status of the user account. Example - active/preserved"},"profileID":{"type":"integer","description":"The profile ID of the profile associated with the user. Example - 1"},"storageID":{"type":"integer","description":"The storage ID of the storage associated with the user. Example - 1"},"quota":{"type":"integer","description":"The storage quota assigned to the user in inSync. Example - 10 GB"},"quotaInBytes":{"type":"integer","description":"The storage quota assigned to the user (in bytes) in inSync. Example - 10737418240"},"cacheID":{"type":"integer","description":"The CloudCache Server ID associated with the user. Example - 1"},"addedOn":{"type":"string","description":"The date on which the user was added in inSync. Example - 2019-10-25T00:00:00Z"},"ldapGUID":{"type":"string","description":"The AD or LDAP object GUID of the user in a hex string format. Example: B1C47201C67910458867BA19982E353E. The ldapGUID displays objectGUID if the user is imported from AD and displays entryUUID if imported from LDAP."},"privacySettingsEnabled":{"type":"boolean","description":"Displays the status of the privacy setting of the user. If the value returned is True, privacy setting is enabled by the user. If the value returned is False, privacy settings is not set or user has allowed admin access to their data."},"additionalProperties":{"type":"object","description":"Contains the two keys of userIdentifierCustomAttribute and userIdentifierCustomAttributeValue if the User-Identifier Custom Attribute feature is enabled for the account and the administrator has opted to display it on the inSync UI. This field remains empty if the administrator has opted to hide the User-Identifier Custom Attribute."}}}}}},"200_DeviceList":{"required":["devices","nextPageToken","totalResults"],"type":"object","properties":{"totalResults":{"type":"number","description":"The total number of devices listed in the result pages."},"nextPageToken":{"type":"string","description":"The token to access next page of results. This parameter will be empty for the last page of results."},"devices":{"minItems":1,"uniqueItems":true,"type":"array","items":{"required":["id","appName","userID","userUrl","workload","createdOn","lastCompacted","profileID","customerID","lastBackupStatus","lastBackupJob","lastSuccessfulBackup"],"type":"object","properties":{"id":{"type":"number","description":"The unique id of the device in inSync. Example - 12345"},"appName":{"minLength":1,"type":"string","description":"The device app name in inSync. Example - OneDrive"},"userId":{"type":"number","description":"A unique id of the user in inSync. Example - 1234"},"workload":{"minLength":1,"type":"string","description":"Name of cloud platform. Example - Office 365 OneDrive, Office 365 Exchange Online, G Suite Gmail, G Suite Google Drive."},"createdOn":{"minLength":1,"type":"string","description":"The date and time on which the device was added to inSync. Example - 2019-10-25T00:00:00Z"},"profileID":{"type":"number","description":"A unique id of the profile in inSync."},"customerID":{"type":"number","description":"A unique id of the administrator in inSync."},"lastBackupStatus":{"type":"number","description":"Shows last backup status. Example - Backed Up Successfully"},"lastBackupJob":{"type":"string","description":"Date string indicating latest time of the backup job run."},"lastSuccessfulBackup":{"type":"string","description":"Date string indicating latest time of the backup job run that was successful."}}}}},"x-examples":{"example-1":{"totalResults":1,"nextPageToken":"","devices":{"id":1,"appName":"OneDrive","userID":1,"userUrl":"https://insync.druva.com/admin/app/#/user/users/1","workload":"Office 365 OneDrive","createdOn":"2021-10-25T00:00:00.000Z","lastCompacted":1640076452,"profileID":1,"customerID":1,"lastBackupStatus":"Backed Up Successfully","lastBackupJob":1640076452,"lastSuccessfulBackup":1640076452}}}},"200_list_restore_points":{"type":"array","items":{"type":"object","properties":{"anomalous":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is anomalous."},"created":{"type":"string","example":"20/02/2024 11:58","description":"Datetime of snapshot creation in human readable format"},"timestamp":{"type":"integer","example":1710424684,"description":"Datetime of snapshot creation"},"filesMissed":{"type":"integer","example":0,"description":"Number of files missed in snapshot backup"},"displayName":{"type":"string","example":"Wed Mar 6 11:54:00 2024","description":"Snapshot display name"},"filesSynced":{"type":"integer","example":0,"description":"Number files backed up in snapshot"},"storageId":{"type":"integer","example":1000002,"description":"Storage id of snapshot"},"latestUnquarantined":{"type":"boolean","example":true,"description":"Flag indicating if the snapshot is latest unquarantined snapshot"},"isQuarantined":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is quarantined snapshot"},"anomalousStats":{"type":"object","example":{},"description":"Object containing detailed stats of anomalous snapshot."},"ignFilesMissed":{"type":"integer","description":"Number of ignored files missed.","example":0},"bmr":{"type":"boolean","example":false,"description":"Flag indicating if the meeting recordings are backed up in snapshot"},"lsCver":{"type":"integer","example":17,"description":"Snapshot version number"},"size":{"type":"integer","example":23903222,"description":"Total size of snapshot in bytes"},"name":{"type":"string","example":"Thu Mar 14 13:58:04 2024","description":"Snapshot name"},"activityLogsDownloadable":{"type":"boolean","example":false,"description":"Flag indicating if the activity logs of snapshot are downloadable"},"isLockedByVirtual":{"type":"boolean","example":false,"description":"Flag indicating of the snapshot is locked by virtual snapshot"},"anomalousUda":{"type":"boolean","example":false,"description":"Flag indicating if snapshot is anomalous"},"isVirtual":{"type":"boolean","example":false,"description":"Flag indicating if the snapshot is virtual snapshot on storage"},"isLocked":{"type":"boolean","example":false,"description":"Flag indicating of the snapshot is locked"},"totalFiles":{"type":"integer","example":639,"description":"Total number of files in the snapshot. Applicable for M365 OneDrive"},"sizeInBytes":{"type":"integer","example":1024000,"description":"Total size of the snapshot in bytes"}}}},"200_trigger_restore_resp":{"type":"object","properties":{"status":{"type":"string","example":"OK"}}},"Error":{"type":"object","properties":{"message":{"type":"string","example":"Invalid API syntax."},"code":{"type":"string","example":"InsyncCappmaster-1001"},"data":{"type":"object","example":null},"retryable":{"type":"boolean","enum":[true,false],"example":false}}}},"parameters":{"tenantType":{"name":"tenantType","in":"query","description":"The name of the App for which the status is required.","required":true,"schema":{"type":"string","enum":["M365"],"example":"M365"}}},"examples":{"CloudAppStatus":{"summary":"M365 Response","description":"Example of success response from get CloudApp Status API for M365 tenant type in request.","value":{"status":0,"M365":[{"appId":1,"appName":"Microsoft 365 Advanced","status":3,"lastConfigured":"2020-09-18T11:50:41+00:00Z","clientid":"r5949668-853d-485t-vlo5-28df7cd0d7c8"},{"appId":13,"appName":"OneDrive and SharePoint","status":4,"lastConfigured":"2020-09-18T11:50:41+00:00Z","clientid":"r5949668-853d-485t-vlo5-28df7cd0d7c8"}]}},"BadRequest":{"summary":"Bad Request","description":"This response means that the server could not understand the request due to invalid syntax.","value":{"code":"InsyncCappmaster-1001","message":"Invalid API syntax.","retryable":false,"data":null}},"Unauthorized":{"summary":"Unauthorized","description":"Authentication is needed to get the requested response.","value":{"code":"InsyncCappmaster-1002","message":"Invalid API credentials.","retryable":false,"data":null}},"Forbidden":{"summary":"Forbidden","description":"The request was a legal request, but the server is refusing to respond to it due to insufficient access rights to the content.","value":{"code":"InsyncCappmaster-1009","message":"Auth session expired","retryable":false,"data":null}},"GARError":{"summary":"Authorization Error","description":"Client does not have access rights or permissions to the requested content.","value":{"code":"InsyncCappmaster-1221","message":"You do not have permission to access this workload.","retryable":false,"data":null}},"NotFound":{"summary":"Resource Not Found","description":"The requested resource could not be found on server.","value":null},"InternalServerError":{"summary":"Internal Server Error","description":"The request was not processed due to an internal error on server.","value":{"code":"InsyncCappmaster-1006","message":"Internal server error.","retryable":false,"data":{"status":1,"message":"Failed to get Customer License"}}},"NotImplemented":{"summary":"Method Not Implemented","description":"Requested HTTP method is not implemented.","value":{"code":"InsyncCappmaster-1007","message":"Method Not implemented.","retryable":false,"data":null}}},"securitySchemes":{"bearerAuth":{"type":"apiKey","name":"Authorization","in":"header"}}}}