<commit_before># -*- coding: utf-8 -*-
from geeklist.api import BaseGeeklistApi, GeekListOauthApi, GeekListUserApi

from access import consumer_info#, access_token

BaseGeeklistApi.BASE_URL ='http://sandbox-api.geekli.st'
geeklist_oauth_api = oauth_api = GeekListOauthApi(consumer_info=consumer_info)
request_token = geeklist_oauth_api.request_token()
import webbrowser
webbrowser.open('http://sandbox.geekli.st/oauth/authorize?%s' % request_token['oauth_token'])

#read verifier
verifier = raw_input(prompt='Please enter verifier code')
new_access_token = geeklist_oauth_api.access_token(request_token=request_token, verifier=verifier)
BaseGeeklistApi.BASE_URL = 'http://sandbox-api.geekli.st/v1'
user_api = GeekListUserApi(consumer_info, new_access_token)
print user_api.user_info()
user_api.create_card(headline='First card created with the python wrapper API')
<commit_msg>Fix the example;<commit_after># -*- coding: utf-8 -*-
from geeklist.api import BaseGeeklistApi, GeekListOauthApi, GeekListUserApi

from access import consumer_info #consumer_info is { 'key': YOUR_KEY, 'secret': secret}

BaseGeeklistApi.BASE_URL ='http://sandbox-api.geekli.st/v1'
oauth_api = GeekListOauthApi(consumer_info=consumer_info)
request_token = oauth_api.request_token(type='oob')
import webbrowser
webbrowser.open('http://sandbox.geekli.st/oauth/authorize?oauth_token=%s' % request_token['oauth_token'])

#read verifier
verifier = raw_input('Please enter verifier code>')
oauth_access_token = oauth_api.access_token(request_token=request_token, verifier=verifier)
access_token = {
    'key':oauth_access_token['oauth_token'],
    'secret':oauth_access_token['oauth_token_secret']
}
user_api = GeekListUserApi(consumer_info, access_token)
print user_api.user_info()
user_api.create_card(headline='First card created with the python wrapper API')

{'fraction_non_alphanumeric': 0.11244541484716157, 'fraction_numerical': 0.002183406113537118, 'mean_word_length': 8.257575757575758, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2444226', 'n_tokens_mistral': 655, 'n_tokens_neox': 638, 'n_words': 107}