def obtain_access_token(self):
if self.oauth_version != <NUM_LIT:2>:<EOL><INDENT>raise TwythonError('<STR_LIT>')<EOL><DEDENT>data = {'<STR_LIT>': '<STR_LIT>'}<EOL>basic_auth = HTTPBasicAuth(self.app_key, self.app_secret)<EOL>try:<EOL><INDENT>response = self.client.post(self.request_token_url,<EOL>data=data, auth=basic_auth)<EOL>content = response.content.decode('<STR_LIT:utf-8>')<EOL>try:<EOL><INDENT>content = content.json()<EOL><DEDENT>except AttributeError:<EOL><INDENT>content = json.loads(content)<EOL>access_token = content['<STR_LIT>']<EOL><DEDENT><DEDENT>except (KeyError, ValueError, requests.exceptions.RequestException):<EOL><INDENT>raise TwythonAuthError('<STR_LIT>')<EOL><DEDENT>else:<EOL><INDENT>return access_token<EOL><DEDENT>
Returns an OAuth 2 access token to make OAuth 2 authenticated
        read-only calls.

        :rtype: string