I'm trying do set Auth. Providers and Named Credential for the salesforce marketing cloud in order to be able to make callout from apex without worrying to get and refresh the token.
Is there any guide specific for SFMC to follow?
I tried setting the auth provider in this way: Provider Type: Open ID Connect ClientId and ClientSecret form SFMC app (accessible from the user that I try to connect to)
Setting the endpoints for authentication/token like that:
******.auth.marketingcloudapis.com/v2/authorize
******.auth.marketingcloudapis.com/v2/token
then when I created the Named Credential I selected OAuth 2.0 and the provider created before. As url I tried both with auth base url and rest base url.
After saving when he tries to login after insert the credential the popup tells me: We can’t log you in because of an authentication error. For help, contact your Salesforce administrator.
note: I'm trying to do that from a sandbox org.
Is it something possible to do?