Hi there,
I realize this question has been asked already in some other forms but I have some clarifications needed.
So, what we have is a Dynamic CRM online account with leads, contacts, etc. and we would like to perform CRUD operations on the CRM from a Drupal installation, we want to post some data to the CRM when a certain interaction happens on the site.
What seems to be clear from resources on the web is that the correct and more secure way is to access is via AZURE AD by requesting a token, we manage to get the token
but then we get a 401 error when we use the token to retrieve data ( using POSTMAN )
Is it the best way to use AZURE AD?
Can we use custom code ( with curl for example ) to login and access the data or do we have to use ADAL? we want to connect from a Drupal backend is it possible? is there a library for that?
stupid question: we don't have to use implicit login right? that's only if we want the user to be prompted to login right?
I use this URL login.microsoftonline.com/{{tenant}}/oauth2/v2.0/token to get the token {{tenant}} is the tenant ID ofcourse.
the request is made here https://<tenant-name>.api.crm4.dynamics.com/api/data/v9.1/leads with the authorization header : Bearer <token>
thanx in advance
*This post is locked for comments