cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Create User Access Token with Username and Password

I am working on a thick-client application that will upload photos to eBay using the UploadSiteHostedPictures API. Because of this, there is no redirect URL available. Is it possible to generate a user access token (not an application access token) by providing a username and password in an HTTP request?

Thanks!

Message 1 of 2
latest reply
1 REPLY 1

Create User Access Token with Username and Password

The user must log into eBay at least once to authorize your application, regardless of whether the app is web-based or standalone. That method for Auth-n-Auth is described here: 

https://developer.ebay.com/api-docs/static/get_auth_n_auth_tokens.html

 

The auth-n-auth user-token for the Trading API can be stored in a file for up to 18 months. If this application is for a single user, the token can be acquired once and then stored for later calls to UploadSiteHostedPictures on behalf of that user.  When it expires, or if revoked by the seller, it would have to again be acquired.

 

The OAuth method is similar, except that refresh tokens will come into play and must be refreshed after  two hours, but the underlying user-token is still valid for 18 months.

 

Or, the UploadSiteHostedPictures call could be made with an "admin" user token, since the images are not assigned to a specific seller and can be used by any seller. The "admin" user token would need to be hard-updated every 18  months as well. 

 

 

ShipScript has been an eBay Community volunteer since 2003, specializing in HTML, CSS, Scripts, Photos, Active Content, Technical Solutions, and online Seller Tools.
Message 2 of 2
latest reply