{"action":"created","issue":{"url":"https://api.github.com/repos/hybridauth/hybridauth/issues/617","repository_url":"https://api.github.com/repos/hybridauth/hybridauth","labels_url":"https://api.github.com/repos/hybridauth/hybridauth/issues/617/labels{/name}","comments_url":"https://api.github.com/repos/hybridauth/hybridauth/issues/617/comments","events_url":"https://api.github.com/repos/hybridauth/hybridauth/issues/617/events","html_url":"https://github.com/hybridauth/hybridauth/issues/617","id":132762804,"number":617,"title":"How to add instagram provider ?","user":{"login":"githubitsme","id":13369831,"avatar_url":"https://avatars.githubusercontent.com/u/13369831?v=3","gravatar_id":"","url":"https://api.github.com/users/githubitsme","html_url":"https://github.com/githubitsme","followers_url":"https://api.github.com/users/githubitsme/followers","following_url":"https://api.github.com/users/githubitsme/following{/other_user}","gists_url":"https://api.github.com/users/githubitsme/gists{/gist_id}","starred_url":"https://api.github.com/users/githubitsme/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/githubitsme/subscriptions","organizations_url":"https://api.github.com/users/githubitsme/orgs","repos_url":"https://api.github.com/users/githubitsme/repos","events_url":"https://api.github.com/users/githubitsme/events{/privacy}","received_events_url":"https://api.github.com/users/githubitsme/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2016-02-10T17:15:39Z","updated_at":"2016-02-14T16:03:06Z","closed_at":null,"body":"When I am trying to add the Instagram OAuth With proper key credentials.\r\nIt shows me a error like this. And yes I moved that instagram.php From third party provider to Providers\r\n\r\n```\r\n( ! ) Notice: Undefined index: id in C:\\wamp\\www\\edit\\hybridauth-2.6.0\\hybridauth\\Hybrid\\Provider_Model_OAuth2.php on line 68\r\nCall Stack\r\n#\tTime\tMemory\tFunction\tLocation\r\n1\t0.0010\t257688\t{main}( )\t..\\login-with.php:0\r\n2\t0.0090\t748648\tHybrid_Auth::authenticate( )\t..\\login-with.php:13\r\n3\t0.0090\t748856\tHybrid_Auth::setup( )\t..\\Auth.php:229\r\n4\t0.0090\t750288\tHybrid_Provider_Adapter->factory( )\t..\\Auth.php:277\r\n5\t0.0100\t783760\tHybrid_Provider_Model->__construct( )\t..\\Provider_Adapter.php:101\r\n6\t0.0100\t785296\tHybrid_Providers_Instagram->initialize( )\t..\\Provider_Model.php:96\r\n7\t0.0100\t785832\tHybrid_Provider_Model_OAuth2->initialize( )\t..\\Instagram.php:21\r\nMissing provider application credentials.\r\n\r\nOriginal error message: Your application id and secret are required in order to connect to Instagram\r\n```\r\n\r\n\r\nLogin-with.php\r\n\r\n\r\n```\r\n<?php\r\n        session_start();\r\n        include('config.php');\r\n        include('hybridauth-2.6.0/hybridauth/Hybrid/Auth.php');\r\n        if(isset($_GET['provider']))\r\n        {\r\n        \t$provider = $_GET['provider'];\r\n        \t\r\n        \ttry{\r\n        \t\r\n        \t$hybridauth = new Hybrid_Auth( $config );\r\n        \t\r\n        \t$authProvider = $hybridauth->authenticate($provider);\r\n\r\n\t        $user_profile = $authProvider->getUserProfile();\r\n\t        \r\n\t\t\tif($user_profile && isset($user_profile->identifier))\r\n\t        {\r\n\t        \techo \"<b>Name</b> :\".$user_profile->displayName.\"<br>\";\r\n\t        \techo \"<b>Profile URL</b> :\".$user_profile->profileURL.\"<br>\";\r\n\t        \techo \"<b>Image</b> :\".$user_profile->photoURL.\"<br> \";\r\n\t        \techo \"<img src='\".$user_profile->photoURL.\"'/><br>\";\r\n\t        \techo \"<b>Email</b> :\".$user_profile->email.\"<br>\";\r\n                        echo \"<b>Email</b> :\".$user_profile->identifier.\"<br>\";\t        \t\t        \t\t        \t\r\n\t        \techo \"<br> <a href='logout.php'>Logout</a>\";\r\n\t        }\t        \r\n\r\n\t\t\t}\r\n\t\t\tcatch( Exception $e )\r\n\t\t\t{ \r\n\t\t\t\r\n\t\t\t\t switch( $e->getCode() )\r\n\t\t\t\t {\r\n                        case 0 : echo \"Unspecified error.\"; break;\r\n                        case 1 : echo \"Hybridauth configuration error.\"; break;\r\n                        case 2 : echo \"Provider not properly configured.\"; break;\r\n                        case 3 : echo \"Unknown or disabled provider.\"; break;\r\n                        case 4 : echo \"Missing provider application credentials.\"; break;\r\n                        case 5 : echo \"Authentication failed. \"\r\n                                         . \"The user has canceled the authentication or the provider refused the connection.\";\r\n                                 break;\r\n                        case 6 : echo \"User profile request failed. Most likely the user is not connected \"\r\n                                         . \"to the provider and he should to authenticate again.\";\r\n                                 $twitter->logout();\r\n                                 break;\r\n                        case 7 : echo \"User not connected to the provider.\";\r\n                                 $twitter->logout();\r\n                                 break;\r\n                        case 8 : echo \"Provider does not support this feature.\"; break;\r\n                }\r\n\r\n                // well, basically your should not display this to the end user, just give him a hint and move on..\r\n                echo \"<br /><br /><b>Original error message:</b> \" . $e->getMessage();\r\n\r\n                echo \"<hr /><h3>Trace</h3> <pre>\" . $e->getTraceAsString() . \"</pre>\";\r\n\r\n\t\t\t}\r\n        \r\n        }\r\n       \r\n      \r\n        \r\n?>\r\n```\r\n\r\nconfig.php\r\n\r\n``` <?php\r\n\r\n$config =array(\r\n\t\t\"base_url\" => \"http://localhost/edit/hybridauth-2.6.0/hybridauth\", \r\n\t\t\"providers\" => array ( \r\n\r\n\t\t\t\"Google\" => array ( \r\n\t\t\t\t\"enabled\" => true,\r\n\t\t\t\t\"keys\"    => array ( \"id\" => \"\", \"secret\" => \"\" ), \r\n\t\t\t),\r\n\r\n\t\t\t\"Facebook\" => array ( \r\n\t\t\t\t\"enabled\" => true,\r\n\t\t\t\t\"keys\"    => array ( \"id\" => \"\", \"secret\" => \"\" ), \r\n\t\t\t),\r\n\r\n\t\t\t\"Twitter\" => array ( \r\n\t\t\t\t\"enabled\" => true,\r\n\t\t\t\t\"keys\"    => array ( \"key\" => \"XXXXXXXX\", \"secret\" => \"XXXXXXXX\" ),\r\n\t\t\t),\r\n\t\t\t\"Instagram\" => array (\r\n                \"enabled\" => true,\r\n\t\t\t\t\"keys\"    => array ( \"key\" => \"my_instagram keys\", \"secret\" => \"my_instgram secret\" ),\r\n                    \r\n\t\t\t\t) \r\n\t\t),\r\n\t\t// if you want to enable logging, set 'debug_mode' to true  then provide a writable file by the web server on \"debug_file\"\r\n\t\t\"debug_mode\" => false,\r\n\t\t\"debug_file\" => \"\",\r\n\t);\r\n```"},"comment":{"url":"https://api.github.com/repos/hybridauth/hybridauth/issues/comments/183908190","html_url":"https://github.com/hybridauth/hybridauth/issues/617#issuecomment-183908190","issue_url":"https://api.github.com/repos/hybridauth/hybridauth/issues/617","id":183908190,"user":{"login":"githubitsme","id":13369831,"avatar_url":"https://avatars.githubusercontent.com/u/13369831?v=3","gravatar_id":"","url":"https://api.github.com/users/githubitsme","html_url":"https://github.com/githubitsme","followers_url":"https://api.github.com/users/githubitsme/followers","following_url":"https://api.github.com/users/githubitsme/following{/other_user}","gists_url":"https://api.github.com/users/githubitsme/gists{/gist_id}","starred_url":"https://api.github.com/users/githubitsme/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/githubitsme/subscriptions","organizations_url":"https://api.github.com/users/githubitsme/orgs","repos_url":"https://api.github.com/users/githubitsme/repos","events_url":"https://api.github.com/users/githubitsme/events{/privacy}","received_events_url":"https://api.github.com/users/githubitsme/received_events","type":"User","site_admin":false},"created_at":"2016-02-14T16:03:06Z","updated_at":"2016-02-14T16:03:06Z","body":"@VladyslavKurmaz Actually the problem occurs when We Join the all the logins"}}