The eBay REST API is now available in the Sandbox (eBay's API testing environment). This is great news for everyone who wants to try out REST before paying the fee for application certification.
In a previous entry I gave an overview of the eBay REST API. And now, here are instructions for trying out the eBay REST API in the Sandbox:
- Register for the eBay Developers Program on http://developer.ebay.com/join. When you register you will get a set of developer keys that are required for making API calls in the Sandbox.
- Create a Sandbox test user using this tool: http://developer.ebay.com/DevZone/sandboxuser.asp
- Use the token tool at http://developer.ebay.com/tokentool to generate an authentication token and a REST token. On this page, select the Sandbox environment, select the option to generate a REST token, and enter the 3 developer keys you received when you registered for the Developers Program. On the next page, enter your Sandbox test username and password.
When you are redirected back to the token tool page you will get an authentication token (used to make XML API and SOAP API calls) and a REST token (used only for REST API calls). Save these tokens in a text file for later use.
Here is a sample query for the REST API in the Sandbox. To use it, simply replace "YourSandboxRESTToken" and "YourSandboxUsername" with your token and Sandbox username (right-click to get the full URL as it may appear truncated):
One thing to note about testing in the Sandbox is that many queries will not return any data, since only test items are listed in the Sandbox. The query shown above simply searches for "test", which will always return many items listed in the Sandbox, since Sandbox listings often contain that word in the title.