Coder Social home page Coder Social logo

mailchimp / oauth2-sample-apps Goto Github PK

View Code? Open in Web Editor NEW
38.0 38.0 21.0 41 KB

Archived: Sample apps to work with MailChimp's Oauth2 service.

Home Page: https://developer.mailchimp.com/documentation/mailchimp/guides/how-to-use-oauth2/

CoffeeScript 0.67% Ruby 28.50% JavaScript 0.67% PHP 65.62% CSS 1.02% HTML 3.51%

oauth2-sample-apps's People

Contributors

fholgado avatar jessedp avatar mc-hannah-morrison avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

oauth2-sample-apps's Issues

Python example

A python example should be implemented alongside the php and ruby examples.

CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set

I get the error CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set when complete.php receives a response from MailChimp (the error occurs in OAuth2Client.php on line 504.)

By setting CURLOPT_FOLLOWLOCATION => FALSE, on line 246 I was able to work around this error. I'm wondering if FOLLOWLOCATION is required for the code to work properly?

Oauth

Hello Friends I am trying connect my local app using oauth authentication. But When I click it is neither redicting to mailchimp authentication site nor showing any errors or exceptions.

I have followed below steps:

  1. I have created a sample app for it. mentioned
  2. public function __construct() {
    //basically, your redirect_url
    $base =  '192.168.3.57';   //your host
    $path = '/Oauth/complete.php'; //the path on your host

    $client_id = '376179255358';   //client_id from creating app in MC (see README)
    $client_secret = '5d2afe4af54d32bb0bd4229ece4db86b'; //client_secret from creating app in MC  (see README)

    $config = array('client_id'=>$client_id, 'client_secret'=>$client_secret,
                    'authorize_uri'=>'https://login.mailchimp.com/oauth2/authorize',
                    'access_token_uri'=>'https://login.mailchimp.com/oauth2/token',
                    'redirect_uri'=>'http://'.$base.$path,
                    'cookie_support'=>false, 'file_upload'=>false,
                    'token_as_header'=>true,
                    'base_uri'=>'https://login.mailchimp.com/oauth2/'
                    );

    parent::__construct($config);
}

but not working
Step 1: Your application begins the authorization process by redirecting the user to the authorize_uri

    - this is a GET request
    - response_type=code, your client_id, and the *urlencoded* redirect_uri are included

authorize_uri = https://login.mailchimp.com/oauth2/authorize?response_type=code&client_id=635959587059&redirect_uri=http%3A%2F%2F192.168.1.8%2Foauth%2Fcomplete.php

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.