Sandbox
General
Sandbox is the test environment, used for testing an API connection. It provides all the functionalities of the live OTTO Market Interface. All actions and orders there are simulated for testing purposes.
The login session and the API key in the sandbox environment are completely separated from the production environment.
REST API: https://sandbox.api.otto.market
Getting started
Follow these steps to start testing on our sandbox environment:
-
Make yourself familiar with sandbox functionalities.
-
Request a sandbox API user: As a partner (seller) you first have to make sure that your user have the role "API-Zugriff". You can then navigate to the API-Zugriff. There you can create a Sandbox App for yourself. As a service partner please register in our OTTO Market Service Partner Program. Follow all necessary steps and request the "Sandbox Apps" Permission to get access to create Sandbox Apps.
-
Authenticate to our sandbox environment. As Partner have a look at the Developer's Guide and as service partner have a look at the specific information in Service Partner Program.
-
Make yourself familiar with our Best-Practice test cases and download the testcase file
-
Use our Order Generator to create fictional orders. See Order Generator below to know which orders are created.
-
Test the API functionality of your application.
Technical Advice
Please note the following information:
Authorization
For the endpoint like all the other endpoints a valid authorization token has to be sent. If you need further information, please consult the Developer's Guide.
Sandbox Reset
To prevent data overload, our sandbox and its orders are reset monthly at first Sunday from 6 p.m. to 10 p.m.
Any dynamic data (shipments, returns) is deleted. Old shipments will not be available anymore.
Therefore, you have to create new orders every month.
Customer-Interactions in Sandbox
Since there are no real costumers, all interfaces which work with customer data will either mock customer data or reduce the functionalities i.e. returns cannot be announced. Hence, the GET endpoint of returns is retrieving an empty string.
Product validation
Submitted product data is validated in two steps, which will be explained further on:
Attention: Since the sandbox is missing a direct shop integration the second validation is simulated. For more details on how to test these functionalities, please have a look into our Best-Practise test cases, where you can find specific EANs for testing purposes.
1. Technical validation
The first technical validation (syntax and required attributes) takes place after you´ve sent product data using a POST request. Read more about uploading products here. If your http request was successful (http response state 202), you´ll be provided with four different links (pending, succeeded, failed, unchanged). Following the links you´ll be able to check which products have been successfully listed, failed, unchanged or are still being processed.
Status | Explanation |
---|---|
Pending | The product listing is still being processed |
Succeeded | The shown products listing was successful |
Failed | Listing of all shown products has failed |
Unchanged | The request for the listed products is unchanged to the last request |
2. Shop validation
The second step is the shop validation. Results of the shop validation are retrievable using the marketplace-status endpoint. Please read the following documentation on how to use the marketplace status endpoint. Submitted product data always has one of the following four marketplace statuses:
Status | Explanation |
---|---|
Pending | Submitted product data is currently proceeded. |
Online | The SKU is displayed at otto.de. You can find the SKU using the shop link. In some cases, additional information will be shown on how to improve the visibility on otto.de. |
Restricted | The SKU is not displayed at otto.de because of an error shown within the error’s container. |
Inactive | The SKU was set inactive via the active-status endpoint and could be reactivated via the active-status endpoint. |
Attention: Since the sandbox is missing a direct shop integration the second validation is simulated. For more details on how to test these functionalities, please have a look into our Best-Practise test cases, where you can find specific EANs for testing purposes.
Order Generator
To test your API implementation you can generate test orders only on the sandbox environment by sending an empty POST request to the following generation endpoint:
https://sandbox.api.otto.market/v4/orders/testorders
This will run 8 predefined scenarios on our sandbox. After the POST request, you will receive 6 orders in "PROCESSABLE" status with different combinations of positions and items (e.g. standard and freight delivery). You will also receive 1 prepayment order in "ANNOUNCED" and 1 order in "CANCELLED_BY_MARKETPLACE" status.
The generated orders will contain one or more position items with the following products:
Product Title | EAN | SKU |
---|---|---|
Smartphone »CallMe 1000« | 1245780164732 | SmartCM1000-schwarz-1 |
Fancy Shirt »Flower« | 4851278936452 | FancyFlower-m-pi |
Rasenmaeher »Turbo V1« | 9821393948573 | 0440-Rasen-T-V1 |
Spedition Wohnlandschaft 3.tlg. | 8263748321943 | Sped-Wohn-3-98735 |
Spedition Kühlschrank »COOL EXTREM« | 7263000981290 | Sped-Kühl084-kombi |
Scenarios:
Scenarios | Status | Comment |
---|---|---|
1, 2, 3, 4, 7, 8 | PROCESSABLE | Scenario 4 inclusive discount |
5 | ANNOUNCED | Order with payment method PREPAYMENT awaiting customer's payment Order includes weeePickup on position item level |
6 | CANCELLED_BY_MARKETPLACE | Order with payment method PREPAYMENT which has been cancelled since the customer didn't pay |
Please use the generated orders to test the interaction with Orders, Shipments and Returns.
If you want to create a single scenario you can do that by sending an empty POST to:
https://sandbox.api.otto.market/v4/orders/testorders/scenario{scenarionumber}
e.g. https://sandbox.api.otto.market/v4/orders/testorders/scenario1
Best-Practice test cases
We´ve come up with mulitple test cases to help you test the basic functionalities needed for each endpoint when offering your service to an OTTO Market Seller. The test cases should be tested within the sandbox environment. If you´re interested in feedback from our service partner management you can send screenshots of the test results here.
The Best-Practice testcases should help you as a developer to understand the behavior and the interdependencies between different APIs. With the test cases you can get hints for testing the interfaces and to reproduce the Use-Cases within the sandbox-environment.
We´re referring to the test orders created using the test order generator within the sandbox environment. Please read the section Order Generator on how to create test orders.
You can download a file where you can find the Best-Practice test cases here.