This article covers the features that are unique to the REST API Importer. For features common to all importers, please see this article.
TABLE OF CONTENTS
- Introduction
- Cross Project Connecting to ManagementStudio
- Common Settings
- Examples
- Further Support
Introduction
The REST API importer can be used to connect to compatible 3rd party data sources that don't have an official ManagementStudio connector but does have a standard REST API.
Cross Project Connecting to ManagementStudio
The REST API Importer allows you to connect to the same or other instances of ManagementStudio. Where cross-project sharing has been enabled, this can be used to copy data between a Primary Project and Sub-Projects that isn't shared by default.
When connecting back to ManagementStudio, refer to the [Endpoint Reports (for PowerBI) ] article for guidance on forming REST queries.
Tip: Use the keyword [importer-auth-token]
as the value for the Auth-Token
header when connecting to the same instance of ManagementStudio but targeting a different project or module.
Common Settings
- Rest Api Endpoint Url -
- The ManagementStudio Url
- X = ProjectId of the Primary Project
- https://ServerAddress/X/p/report/Datamining/0/InternalName/json
- Import Multiple Matched Rows
- Tick this option to continue importing mutiple rows after the first match is found.
- This is required for import lists such as Blueprints, Contacts & Dependencies
Examples
Example - Sync Custom Fields from Primary Project to Sub-Project
Headers
Header | Value | Note |
---|---|---|
Auth-Token | [importer-auth-token] | Auto-gen a token to connect back to MS |
Datamining-Tier1-Module | Applications | Get an Applications list |
Datamining-Tier1-Fields | AppId | Add the AppId field |
Datamining-Tier1-CustomFieldIds | 1000, 1001, 1002 | List of Custom Fields from the Primary Project |
DataSource-All | True | Include all Apps |
Field Mapping
MCH | Src. Field | MS Field | Notes |
---|---|---|---|
Yes | AppId | AppId | Use the App Id from the Primary Project to find a match in the Sub-Project |
CustomField_1000 | APPDSC\MyTab\Intune Devices | Copy data from Primary to Sub-Project | |
CustomField_1001 | APPDSC\MyTab\SCCM Collections | Copy data from Primary to Sub-Project | |
CustomField_1002 | APPDSC\MyTab\AD Groups |
Example - Sync App Blueprints from Primary Project to Sub-Project
Headers
Header | Value | Notes |
---|---|---|
Auth-Token | [importer-auth-token] | Auto-gen a token to connect back to MS |
Datamining-Tier1-Module | Applications | Get an Applications list |
Datamining-Tier1-Fields | AppId | Get the AppId field |
Blueprint-1-Module | Applications | Get Application Blueprints |
Blueprint-1-ColumnName | Blueprints | Name the column the BPs will be returned in |
Blueprint-1-AllOnOneLine | False | If an App has more than 1 BP, split them across multiple rows |
Blueprint-1-FolderIds | 86, 303 | The Folder Ids to only include Blueprints from (e.g. Departments, Location) |
DataSource-All | True | Include all Apps |
DataSource-FilterExpression | Blueprint_Blueprints <> '' | Filter results to only Apps that have a Blueprint |
Field Mapping
MCH | Src. Field | MS Field | Notes |
---|---|---|---|
Yes | AppId | AppId | Use the AppId from the Primary Project to find a match in the Sub-Project |
Blueprints | BlueprintPath | Use the Blueprints column to import as a BlueprintPath keyword. This will Add Apps to this Blueprint (and create it if not found) |
Example - Sync App Contacts from Primary Project to Sub-Project
In this example, we are targeting the Contacts module and linking them to AppIds
Contacts must be shared from the Primary Project to the sub-project for linking to work
Headers
Header | Value | Note |
---|---|---|
Auth-Token | [importer-auth-token] | Auto-gen a token to connect back to MS |
Datamining-Tier1-Module | Applications | Get an Applications list |
Datamining-Tier1-Fields | AppId | Add the AppId field |
Datamining-Tier2-Module | Contacts | Add a Contacts Tier |
Datamining-Tier2-Fields | ContactId | Add the Contact Id Field |
Datamining-Tier2-Options | Contacts_ContactType | Add the Contact Type Field |
DataSource-All | True | Include all Apps |
DataSource-FilterExpression | Contacts_ContactId >= 0 | Filter results to only Apps that have a Contact |
Field Mapping
MCH | Src. Field | MS Field | Notes |
---|---|---|---|
Yes | ContactId | ContactId | Use the Contact Id from the Primary Project to find a match in the Sub-Project |
AppId | ContactAppId | Use the AppId column to import into the linking field ContactAppId | |
ContactId | ContactLinkId | Use the ContactId column to import into the linking field ContactLinkId | |
ContactType | ContactLinkType | Use the ContactId column to import into the linking field ContactLinkType |
Example - Sync App Dependencies from Primary Project to Sub-Project
Headers
Header | Value | Note |
---|---|---|
Auth-Token | [importer-auth-token] | Auto-gen a token to connect back to MS |
Datamining-Tier1-Module | Applications | Get an Applications list |
Datamining-Tier1-Fields | AppId | Add the AppId field |
Datamining-Tier2-Module | Dependencies | Add a Dependencies Tier |
Datamining-Tier2-Fields | Module,InstanceId,IsTopLevel | Add the Module, InstanceId, IsTopLevel Fields |
DataSource-All | True | Include all Apps |
DataSource-FilterExpression | Dependencies_IsTopLevel = True | Filter results to Apps with a dependency and only the top-level dependencies |
Field Mapping
MCH | Src. Field | MS Field | Notes |
---|---|---|---|
Yes | AppId | AppId | Use the App Id from the Primary Project to find a match in the Sub-Project |
InstanceId | DependencyChildId | Use the InstanceId of the Dependency to import as the DependencyChildId | |
Module | DependencyChildModule | Which Module does the Dependency belong to |
Further Support
If you require further support, please visit ManagementStudio's Service Desk to search the knowledge base or create a new support ticket.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article