Sandbox Mocking

5 different mocking scenarios are provided for having a better overview of different versions of response objects.

Please consider that input parameters are being merged through OR relations. Also, note that upon a successful run of each scenario, the corresponding entities (such as drop-off, pick-up, order, parcel, ...) will be moved to a final status which cannot be changed anymore by running another scenario.

Here is the list of samples for each of the available scenarios:

Happy Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/happy' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

Re-attempt Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/reattempt' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

Fail Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/fail' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

Bundled pick-ups Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/bundle-pick-up-shipments' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

In-transit Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/delivering-drop-off-shipments' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

Picked-up shipments Scenario

curl --location --request POST 'https://api-sandbox.flashbox.co/scheduled-service/api/v1/sandbox/scenarios/picked-pick-up-shipments' \
--header 'Content-Type: application/json' \
--header 'X-Requested-With: XMLHttpRequest' \
--header 'Authorization: Bearer <TOKEN>' \
--data-raw '{
    "drop_off_shipment_unique_ids": [],
    "drop_off_shipment_ids": [],
    "date": "2022-03-10"
}'

Did this page help you?