This topic was automatically generated from Slack. You can find the original thread here.
Hello team, I am relatively new to Pipedream and trying to set up an integration with ADP. We just purchased the Advanced plan but the ADP integration says it requires Premium which is not in the available plans. Am I missing something? Thanks!
Another question then, when setting up my ADP Auth (it’s weird, it requires a cert and private key), I went through ADP’s docs and got the cert and private key created. Verified it worked through curl as the TLS handshake was successful, but when I use the exact same cert and key in the ADP setup from Pipedream, it fails to connect.
I believe the ADP integration is fairly new, so this may turn into a bug report, unless I’m doing something wrong (which is entirely possible).
I can’t see anything in the network or console in the dev tools to show why it might be failing. Any help here would be great as well
Might have an update here. I think I have confirmed my cert and key are valid. However I did reproduce the exact same error when my client_id and client_secret for ADP were not correct.
There isn’t a place in the ADP OAuth config to put those values. Do you think that could be an issue? Or do you think my cert and key are invalid?
This returned a successful response, which should mean my cert and key are valid and ADP’s API accepts them.
Then I tried:
curl -X POST -v --cert <cert_file> --key <private_key_file> https://accounts.adp.com/auth/oauth/v2/token -H "Content-Type: application/x-www-form-urlencoded" -d "grant_type=client_credentials&client_id=CLIENT_ID&client_secret=SECRET"
CLIENT_ID and SECRET were actually in the curl request! i.e. incorrect client_id and client_secret
And got the exact same response you did earlier:
{ "error":"invalid_client", "error_description":"The given client credentials were not valid" }
curl -X POST https://accounts.adp.com/auth/oauth/v2/token -H "Content-Type: application/x-www-form-urlencoded" -d "grant_type=client_credentials&client_id=CLIENT_ID&client_secret=SECRET"
{ "error":"invalid_client", "error_description":"The given client credentials were not valid" }
NOTE!! -- Without the cert and key files, but with the same incorrect client_id and client_secret and still got the error saw earlier.
I don’t fully understand what ADP wants as their docs are pretty horrendous, but it’s odd to me this gave me a response at all considering the cert and key were missing.
You can access your API credentials (Client ID/Client secret) in API Central tool (https://api-central.adp.com) but you must have a project setup. I do not see that you have a project setup and here are steps on how to create your project:
• Login to https://api-central.adp.com and on the left hand menu click on "Projects"
• To the right you will click on "Create a Project"
• Provide a name and description for your project and select a template that matches your scenario. Note: you can add additional APIs to your project at a later time if needed.
Once your project is created, you can access the details where you will find the Client ID and Client Secret. These are your credentials for connecting your application to the API.
Please see this resource on How to create a Project:
https://developers.adp.com/getting-started/getting-started-as-a-client/guides/api-guides/api-central-quick-start-guide/chapter/3
You are also able to setup a certificate for your connection. Please see this resource on How to create and manage certificates:
https://developers.adp.com/getting-started/getting-started-as-a-client/guides/api-guides/api-central-quick-start-guide/chapter/4
In summary, in order to get the client id and client secret, one needs to go the ADP API central and create a project (which have 10 prescribed use-cases, which may define scopes under the hood) that you can choose from then they give you a client id and client secret. They also give you a nice way of creating the .pem
But also keep in mind that each request will need the .pem and .key private key file, so maybe giving us a nice way of puling those out of the auth config (if it’s not there already) would be nice so we can use them in our requests.
And no worries haha it took me like 3 or 4 full days to understand how to get data from ADP