I am working on a proof of concept where I need to request an AAD OAuth2 access token using Client Credentials flow so that I can securely send a message to an Azure Event Hub. The only way I have been able to get this use case to work is by:
Registering my App via App. Registration.
Assigning the Azure Event Hub Send role to the application
Upon making the OAuth2 request for an access token, I have to supply the Resource as a part of the request such that the access token contains the proper claims.
This all works fine, however, the problem that I am running into is that I am using does not have support to specify the Resource in the OAuth2 access token request. That means that the token I get receive from AAD does not have the proper claims and I end up getting the following response from Azure Event Hubs when I attempt to use the access token to send a message to the event hub.

I can reproduce the error in Postman by not supplying the Resource in the AAD OAuth2 request.
I am wondering if there is another way to create a proper access token that Azure Event Hubs will accept and does not require any other information other that the client_id and client_secret. Or perhaps another way that I can configure the registered app. such that a role assignment is not necessary or does not require the Resource to be supplied in the OAuth2 request.

