-
Register the application in Entgra IoT server by using following CURL command. For the Authorization header encode
username:password
to Base64 format and use the encoded value as'Authorization: Basic {encodedValue}'
. Provide any name for theapplicationName
and provide the application owner’s username for theusername
. Copy the values ofclient_id
andclient_secret
.curl --location --request POST 'https://${mgtURL}/api-application-registration/register' \ --header 'Accept: application/json' \ --header 'Authorization: Basic YWRtaW46YWRtaW4=' \ --header 'Content-Type: application/json' \ --data-raw '{"applicationName":"sp_sdk_s1","tags":["android","device_management"],"username":"admin", "allowedToAllDomains":false,"mappingAnExistingOAuthApp":false}'
Response:
{"client_secret":"gBb6LATYVyxplGhvB6tcckBOvo8a","client_id":"O6lYcMOwg1wl9OfhCrUDB_QTkKwa"}
-
Login to Entgra IoT management console from
https://{mgtURL}/carbon
and navigate to the Service Providers tab listed under the Main section. You will see the service provider you created above. -
Expand the OAuth/OpenID Connect Configuration section inside Inbound Authentication Configuration section and check if the
OAuth Client Key
is same as theclient_id
you got from the above response. -
Click on Edit button, and you will be redirected to Application Settings page.
Make sure Code option in Allowed Grant Types and Default in Token Issuer are ticked. Provide a valid URL format ending with
/sdk/secure
for Callback Url section. -
To set up the WSO2 Identity Server as an External Identity Provider (IDP) with Entgra MDM using OpenID Connect (OIDC), follow the detailed instructions provided here. Remember to adjust the endpoint URLs as needed to match your specific configuration.