Introduction
API

SFTP
On this page

In order to test your integration, you’ll need:
How do I place a test order?
How do I perform the E2E testing?

Testing Integration#

Click below to jump to the topics:

In order to test your integration, you’ll need:#

  1. Have a test user

    You must share with your Account Manager an email address you have access to, but that does not already exist in PedidosYa. This email will be used to create a test user so you can view your test store from the PedidosYa mobile app.

  2. Have a test store

    Your Account Manager must provide you with the ID, name, and address of your test store.

  3. Have access to the test store in Partner Portal

    Your Account Manager must ensure that you have access to the test store in Partner Portal and Pelican. In Partner Portal, you must configure the webhook and obtain the token.

  4. Validate your integration

    You can test the different functionalities you develop in your test store.

How do I place a test order?#

By logging into the PedidosYa mobile app with your test user, you must search for the test store at the address shared by your Account Manager. Once you find the store, you can place orders from the app as if you were a real user.

After placing the order in the app, you will receive it in Pelican (if you have already logged into the Pelican app with your user), where you must manage it. Once you mark the order as READY FOR PICKUP in Pelican, you will receive the payload in the webhook you configured.

How do I perform the E2E testing?#

In order to ensure your integration is up and running, it’s important that you go through the end-to-end test cases. You’ll see all use cases listed below:

  1. Place order on the platform app, fulfil the order completely on Pelican

    1. Webhook should receive READY_FOR_PICKUP event

    2. Check for items level status as IN_CART

  2. Place an order in the platform with at least 3 products (request at least 2 units of one of them). In Pelican, partially fulfill the order: decrease the picked quantity for the product requested in more than 1 unit, mark one product as NOT_FOUND without replacing it, and modify the price of the third product.

    1. The webhook must receive the READY_FOR_PICKUP event.

    2. Verify the item-level status as IN_CART & NOT_FOUND (and check the final picked quantity and final price of the IN_CART items).

  3. Replace the out-of-stock (OOS) items with a suggested item and fulfill the order in Pelican.

    1. The webhook must receive the READY_FOR_PICKUP event.

    2. Verify the item-level status as IN_CART & REPLACED.

    3. Both the OOS item and the suggested replacement item are sent to the webhook with the statuses REPLACED & IN_CART.

  4. Place an order in the platform that includes: one weighted product (if your stores sell this type of item), one product with a final price promotion, and another product with an NxM promotion. Modify the price of one of the promotional products and adjust the weight of the weighted product.

    1. The webhook must receive the READY_FOR_PICKUP event.

    2. Verify the item-level status as IN_CART and validate the promotions information received. Note: the promotions array displayed is static and corresponds to the products added to the cart (it does not reflect modifications made in Pelican). Validate the quantity field for the weighted product.

  5. Cancellation: A few minutes after the orders are placed, you will receive the cancellation payload in the webhook. Order cancellation by the customer, logistics & vendor.

Customer cancellation after order placement:

  1. Order is placed on app

  2. Picker received the order

  3. Customer cancelled the order

  4. Your webhook should receive CANCELLED status

Customer cancellation after order fulfilment:

  1. Order is placed on app

  2. Picker received the order and fulfilled the order

  3. Your webhook should receive READY_FOR_PICKUP status

  4. Customer cancelled the order

  5. Your webhook should receive the CANCELLED status

  6. In cancellation order payload you will receive an additional field post_pickup_flag: true which means cancellation happened after rider pickup. (check this FAQ)

Logistic cancellation after order fulfilment:

  1. Order is placed on app

  2. Picker received the order and fulfilled the order

  3. Your webhook should receive READY_FOR_PICKUP status

  4. Riders cancelled the order due some issues

  5. Your webhook should receive the CANCELLED status

  6. In cancellation order payload you will receive an additional field post_pickup_flag: true which means cancellation happened after rider pickup. (check this FAQ)

Vendor cancellation after order fulfilment:

  1. Order is placed on app

  2. Picker received the order

  3. Vendor can CANCELLED the order due item unavailability or store being busy

  4. Your webhook should receive the CANCELLED status

  5. During fulfilment if customer cancels the order, the CANCELLED event is sent to webhook

  6. Check order payload on webhook for CANCELLED event

  7. Check for item level status NOT_PROCESSED or NOT_FOUND

Endpoints test:

  1. GET /vendor_id/orders: Set the time frame and get list of orders at store level, they will have final order statuses like CANCELLED or PICKED_UP

  2. GET /order_id: Retrieves order on specific id, it will have final order statuses like CANCELLED or PICKED_UP

If all updates are correctly processed without errors, the integration is ready to go live. You can schedule a meeting here with our Integrations Support team to certify your integration.


APIUse Cases - Endpoints ExplainedAPITroubleshooting