TypeError: string indices must be integer <p>I tried to get data from <code>JSON</code>. But instead data i get <code>TypeError</code>:</p> <pre><code>'TypeError: string indices must be integers' </code></pre> <p>Here ist my code:</p> <pre><code>api.authenticate(LOGIN, CONN) profil = api.get_profile("abc") data = json.dumps(profil, indent=4) print(data["login"]) </code></pre> <p>JSON file:</p> <pre><code>{ "public_email": "", "violation_url": null, "is_blocked": false, "links_published": 0, "login": "abc", "links_added": 1, "gg": "", "signup_date": "2014-10-26 21:15:41", } </code></pre> <p>I've looking for solution (google, SO) but I cannot find or not working for me.</p>