0

I'm using builkloader in Python, my command like below:

appcfg.py download_data --config_file=bulkloader.yaml --filename=all.csv --kind=all 
  --url=http://myapp.appspot.com/remote_api --namespace=mynamespace

it worked, and I can download it normally after input my email and password. I do not want to input email and password manually, and try --oauth2 option. But it's still prompt me to input email and password in console.

I tried to Google it but have no reason.

Thank in advanced !

Chung
  • 947
  • 1
  • 12
  • 22

1 Answers1

1

I think you are looking for this

appcfg.py --oauth2_refresh_token=token update myapp/

Link to docs

  • Thanks ! the --oauth2_refresh_token option help we use the same token for all the time. I wonder how to use --oauth2 option which load token from file – Chung Mar 12 '13 at 14:23
  • From the help link above - A page will appear in your web browser prompting you for authentication. (If you used the --noauth_local_webserver option, then appcfg.py will instead show you a URL to copy/paste into your browser.) Log in if necessary. The page will ask whether you wish to give appcfg access. Click OK. (If you used the --noauth_local_webserver option, then you will be given a token that you will need to supply to the prompt from appcfg.py.) –  Mar 12 '13 at 15:00
  • And further your question - From now on, when you run appcfg.py --oauth2, it uses the saved authentication token. –  Mar 12 '13 at 15:27
  • yeah ! I know that, I have authentication token file after first authentication. But it doesn't use the saved authen file to get authen. I also copied the refresh_token from that file too – Chung Mar 13 '13 at 01:53
  • weird I used it and it found the token without me doing anything extra? –  Mar 13 '13 at 05:08