How to programmatically access Mailchimp API via oauth2?

8 views
Skip to first unread message

Mike Schleif

unread,
Jan 30, 2020, 11:09:40 AM1/30/20
to OAuth PHP
Who here has programmatically accessed the Mailchimp API?

We need to programmatically get specific data from our Mailchimp campaigns.

Mailchimp suggests their API.

Oauth2 is the way to authenticate to the Mailchimp API.

From a browser, we do this:

This brings up a Mailchimp form. Username is filled in, but Password field is empty.

Three days after requesting Mailchimp support, they responded:
"... the password is intended to be entered in the login step, and passing it via the URL will not input the password automatically."

Who here has programmatically accessed the Mailchimp API?

Please, advise. Thank you.

~ Mike

Marc Worrell

unread,
Jan 31, 2020, 3:38:38 AM1/31/20
to oaut...@googlegroups.com
Hi Mike,

Your question is more a generic OAuth question than related to this library.

Looks like you are trying to do the OAuth ‘dance’ to get the authorization token.

This should not be needed, as the ‘dance’ is only used to fetch authorization tokens for users of your site.
For example for the “Log in with <somesite>” buttons.

Normally, if you access an API with OAuth2 then the other party has some dashboard where you can copy the token.
With OAuth2 you then configure this token in your application and just pass it along with your API requests.

Cheers,

Marc



--
You received this message because you are subscribed to the Google Groups "OAuth PHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to oauth-php+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/oauth-php/111ae24f-b334-4f41-a561-ea24ea4e3154%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages