2

I'm trying to integrate with the https://auth.exacttargetapis.com/v1/requestToken endpoint to receive an AuthToken to communicate with the Salesforce REST API, like here.

I created a Connected App and received my Consumer Key and Consumer Secret (clientId & clientSecret) but I keep receiving the following error when I try to post my credentials to the endpoint:

{
  "message": "Unauthorized",
  "errorcode": 1,
  "documentation": ""
}

That is the crux of my issue which could be a number of different things, but here is some other pertinent information:

  • The User I created the Connected App with, my own user, is a "System Administrator" with "API Enabled" checked
  • I am on a free version, I have not paid for any license
  • I have selecetd all possible scopes for the Connected App under "Selected OAuth Scopes"
  • I allowed "all users to self-authorize" as via this answer
  • I an unable to find the "API Integration Component" as described here under the Package Manager / Installed Packages fields, which seems to be a point of importance in all the docs that I have seen.
  • I posted an answer for getting the token. It is an old one. Thought it could help you in any way also just to be clear you need to create package in the marketing cloud, after creating package you will receive client id and client secret, This is not salesforce ORG connected app. Hope you know. – Mr.Frodo Jun 6 '18 at 17:16
  • Hi Mr.Frodo, thanks for the input. That method you explained is the one I have been using but I still receive the error. It may be that I created this Connected app in the Lightning interface (lightning.force.com). When I access the Marketing Cloud login (at auth.s1.exacttarget.com/hub-cas/login?......) I don't see a way to create an account, or even a trial version. Is that the interface I need? – Ron Jun 6 '18 at 17:30
5

I think the issue here is you created connected app in salesforce ORG and not in marketing cloud. Marketing cloud does not provide a free/trial account(I suppose there is a way to get demo account for partners).

The link which you have shared itself says that you need to create a package in Marketing cloud. After creating this package you will get client id and client secret.

From Doc:

Create an installed package in your Marketing Cloud account to create API integrations, install custom apps, or add custom Journey Builder components.

The Rest APIs which you want to access are Marketing cloud APIs not the Salesforce Rest APIs, So you need to create a package in Marketing cloud account.

  • Thank you, Mr.Frodo. I got in contact with an admin and got the proper credentials to the Marketing Cloud account instead of the other Salesforce integration – Ron Jun 6 '18 at 21:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.