Microsoft Graph – How to create / register app in Microsoft Entra
Hi All,
Greetings.
Continue to explore my favorite topic – Microsoft Graph.
Today in this article we will discuss how to create App in Microsoft Entra using Microsoft GRAPH API from Graph Explorer
Take away from this article
- Prerequisites required to create / register app using Microsoft Graph APIs
- Permissions required to create / register app
- How to create / register app from Graph Explorer tool
- Reference for creating / registering app through Microsoft Entra admin center
We could create / register the app from Microsoft Entra admin center. We have detailed article for the same. Microsoft Entra – registering new application and assigning permissions to access Microsoft Graph APIs – https://knowledge-junction.in/2024/01/18/microsoft-entra-registering-new-application-and-assigning-permissions-to-access-microsoft-graph-apis/
We have an also option to create / register app using Microsoft Graph API. Today we will use Microsoft Graph Explorer to create / register App.
Prerequisites required to create / register app using Microsoft Graph APIs
- Microsoft Entra tenant
- Permissions required to create / register app
Permissions required to create / register app in Microsoft Entra
Details
- Login to Graph Explorer – https://developer.microsoft.com/en-us/graph/graph-explorer
- I am logged in with my development account and in local tenant as
- Before creating lets see all available applications in Microsoft Entra
- If we notice from above figure, currently we have total 7 app registrations
- Lets create / register new app registration using Graph Explorer
- We have “applications” Microsoft Graph resource for managing applications / apps in Microsoft Entra
- We have detailed article on “Microsoft Graph API metadata” which enlist all the available resources – Small Tips and Tricks – Microsoft Graph API metadata – https://knowledge-junction.in/2024/03/08/small-tips-and-tricks-microsoft-graph-api-metadata/
- For creating / registering new app we need to use “POST” method and in request, we need to pass the “displayName” property. This is the minimal property required as
{
"displayName": "Life Is Beautiful app"
}
- Query required for creating / registering application / app is
https://graph.microsoft.com/v1.0/applications
- As we “Run query” app will be created successfully as we could see details in “Response“
{
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#applications/$entity",
"id": "f1af7a26-874c-4eb2-ae0b-9e8e65028567",
"deletedDateTime": null,
"appId": "26e9ef69-eafe-4689-b35e-c397653c9b91",
"applicationTemplateId": null,
"disabledByMicrosoftStatus": null,
"createdDateTime": "2024-05-06T01:39:10.5667112Z",
"displayName": "Life Is Beautiful app",
"description": null,
"groupMembershipClaims": null,
"identifierUris": [],
"isDeviceOnlyAuthSupported": null,
"isFallbackPublicClient": null,
"notes": null,
"publisherDomain": "knowledgejunction1.onmicrosoft.com",
"serviceManagementReference": null,
"signInAudience": "AzureADMyOrg",
"tags": [],
"tokenEncryptionKeyId": null,
"uniqueName": null,
"samlMetadataUrl": null,
"defaultRedirectUri": null,
"certification": null,
"optionalClaims": null,
"servicePrincipalLockConfiguration": null,
"requestSignatureVerification": null,
"addIns": [],
"api": {
"acceptMappedClaims": null,
"knownClientApplications": [],
"requestedAccessTokenVersion": null,
"oauth2PermissionScopes": [],
"preAuthorizedApplications": []
},
"appRoles": [],
"info": {
"logoUrl": null,
"marketingUrl": null,
"privacyStatementUrl": null,
"supportUrl": null,
"termsOfServiceUrl": null
},
"keyCredentials": [],
"parentalControlSettings": {
"countriesBlockedForMinors": [],
"legalAgeGroupRule": "Allow"
},
"passwordCredentials": [],
"publicClient": {
"redirectUris": []
},
"requiredResourceAccess": [],
"verifiedPublisher": {
"displayName": null,
"verifiedPublisherId": null,
"addedDateTime": null
},
"web": {
"homePageUrl": null,
"logoutUrl": null,
"redirectUris": [],
"implicitGrantSettings": {
"enableAccessTokenIssuance": false,
"enableIdTokenIssuance": false
},
"redirectUriSettings": []
},
"spa": {
"redirectUris": []
}
}
- Now if we again navigate to listing of “app registration” page we will see our new app
In this way we could create / register new app using Microsoft Graph from Microsoft Graph Explorer.
Upcoming articles : We will see how to set different properties like description, logo url, redirect url etc. We will also discuss how to assign role to app. I’ll also share – how to create / register app in Microsoft Entra using Microsoft Graph PowerShell
REFERENCES
- Microsoft Entra – registering new application and assigning permissions to access Microsoft Graph APIs – https://knowledge-junction.in/2024/01/18/microsoft-entra-registering-new-application-and-assigning-permissions-to-access-microsoft-graph-apis/
- Small Tips and Tricks – Microsoft Graph API metadata – https://knowledge-junction.in/2024/03/08/small-tips-and-tricks-microsoft-graph-api-metadata/
Thanks for reading !
HAPPY LEARNING AHEAD 🙂 LIFE IS BEAUTIFUL 🙂
You must be logged in to post a comment.