I'm trying to write a console script to process some videos and automatically upload them. Using my vimeo developer account, I created an application. Each time I upload, it will be with this user's account. I requested and received permission to upload via this account.
I assume I need to connect to the api via xAuth since I won't be able to get the oauth verifier string from the callback url.
I have this python code trying to log in, but I keep getting 400 Bad Request - Missing required parameter - A required parameter was missing.
import oauth2 as oauth
consumer = oauth.Consumer(client_id, client_secret)
client = oauth.Client(consumer)
client.add_credentials('email', 'password')
client.authorizations
creds = {'Authorization': 'Basic', 'x_auth_username': 'email', 'xauth_password': 'password'}
params = {}
params['x_auth_mode'] = 'client_auth'
params['x_auth_permission'] = 'write'
params['x_auth_username'] = 'email'
params['x_auth_password'] = 'password'
client.set_signature_method = oauth.SignatureMethod_HMAC_SHA1()
resp, token = client.request('https://vimeo.com/oauth/access_token',
method='POST', body=urllib.urlencode(params),headers=urllib.urlencode(creds))