Lesson 5. How to enable Sandbox
In this lesson you will learn to access Yandex Direct via the API without the risk to launch a real advertising campaign with a real budget.
What is Sandbox?
Sandbox is a test environment used to debug apps accessing Yandex Direct API. In Sandbox, you can make requests, get responses, and monitor status of campaigns and ads. However, in Sandbox you are working with the test data only, and your actions will not affect your real advertising campaigns. Test ads are never served, the test budget does not affect your real account in Yandex Direct, while the statistical report contains some pseudorandom data.
Your app's requests to the Sandbox must be in the same format as your real data requests. Sandbox uses real OAuth tokens. The only difference between the Sandbox requests and real data requests are the URLs they use.
Sandbox has no web interface, hence you can not see test clients and test ad campaigns in the interface. You can only work with the Sandbox by calling API methods.
How to enable
To enable Sandbox for your account, do the following:
-
In the Yandex Direct web interface, open the API section and go to the Sandbox tab.
-
Click the Launch sandbox link.
-
Choose a role: "Client" (direct advertiser) or "Agency" (advertising agency with its clients). Specify the currency for the test account. Select the Create test campaigns checkbox.
-
Click the Continue button.
Depending on the role you have selected, three test campaigns or three test clients are created immediately in Sandbox. Virtual money will be credited to one of the campaigns.
Working with Sandbox
- The Sandbox is active while you are using it. If no requests have been sent to the Sandbox over a month, your test accounts and all their settings are deleted. You will have to set up the test data again.
- If you want to disable the Sandbox, click the Stop using Sandbox link.
- If you switch the role, the test data is deleted and the Sandbox is created from scratch.
Task
Enable Sandbox with the "Client" role, creating the client account in rubles with preset test campaigns.
What's next
So you have completed all the preparation steps and are ready to start working with Yandex Direct API. In the next lesson, you will make your first request to the API.
Useful links
- Sandbox tab in the Yandex Direct interface