Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
mahipalmahi116
New Member

Intune service account

Hi, 

 

We have created the dashboaed using intune odata link. 

 

Due to password change policy in organization, we have created a intune service account. Now I am unable to find the way to use this service account to fetch data from intune. Request your help and guidance to get data from intune using service account credentials. 

1 ACCEPTED SOLUTION
v-tangjie-msft
Community Support
Community Support

Hi @mahipalmahi116 ,

 

To use a service account with Intune, especially for fetching data, it's essential to ensure that the account has the necessary permissions and is correctly authenticated to access the Intune data.

1.Ensure Proper Permissions: The service account needs to have the appropriate permissions assigned to access the Intune data. Typically, this would involve having either Global Administrator or Intune Administrator roles assigned within your Azure Active Directory (Azure AD).

2.Authentication: For accessing Intune data programmatically, your service account must authenticate using OAuth 2.0 with Microsoft Entra ID. This involves registering an application in Azure AD, obtaining client credentials (client ID and secret), and using these credentials to request an access token from the Microsoft identity platform endpoint.

3.Use the Access Token: Once you have the access token, you can use it to authenticate requests to the Intune OData endpoint. Ensure that the HTTP request headers include the Authorization field with the bearer token.

4.Handling Password Rotation: Since your organization has a password change policy, consider using Azure AD's certificate-based authentication for your service account to avoid frequent password resets. This method involves using a certificate instead of a client secret, which can be more secure and less susceptible to password rotation policies.

 

 

For more details, please refer:

Create an Intune report from the OData feed with Power BI - Microsoft Intune | Microsoft Learn

Using the Microsoft Graph API to access data in Microsoft Intune - Microsoft Community Hub

Microsoft identity platform certificate credentials - Microsoft identity platform | Microsoft Learn

 

Best Regards,

Neeko Tang

If this post  helps, then please consider Accept it as the solution  to help the other members find it more quickly. 

View solution in original post

1 REPLY 1
v-tangjie-msft
Community Support
Community Support

Hi @mahipalmahi116 ,

 

To use a service account with Intune, especially for fetching data, it's essential to ensure that the account has the necessary permissions and is correctly authenticated to access the Intune data.

1.Ensure Proper Permissions: The service account needs to have the appropriate permissions assigned to access the Intune data. Typically, this would involve having either Global Administrator or Intune Administrator roles assigned within your Azure Active Directory (Azure AD).

2.Authentication: For accessing Intune data programmatically, your service account must authenticate using OAuth 2.0 with Microsoft Entra ID. This involves registering an application in Azure AD, obtaining client credentials (client ID and secret), and using these credentials to request an access token from the Microsoft identity platform endpoint.

3.Use the Access Token: Once you have the access token, you can use it to authenticate requests to the Intune OData endpoint. Ensure that the HTTP request headers include the Authorization field with the bearer token.

4.Handling Password Rotation: Since your organization has a password change policy, consider using Azure AD's certificate-based authentication for your service account to avoid frequent password resets. This method involves using a certificate instead of a client secret, which can be more secure and less susceptible to password rotation policies.

 

 

For more details, please refer:

Create an Intune report from the OData feed with Power BI - Microsoft Intune | Microsoft Learn

Using the Microsoft Graph API to access data in Microsoft Intune - Microsoft Community Hub

Microsoft identity platform certificate credentials - Microsoft identity platform | Microsoft Learn

 

Best Regards,

Neeko Tang

If this post  helps, then please consider Accept it as the solution  to help the other members find it more quickly. 

Helpful resources

Announcements
April Fabric Update Carousel

Fabric Monthly Update - April 2024

Check out the April 2024 Fabric update to learn about new features.

Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors