Managing Availability
The Rappi API enables you to configure the availability of your menu items and your stores, by using the items
resource.
The following sections guide you through the process of configuring these options for your integration.
Item Availability
Configure the availability of your menu items and disable them when they are out of stock, to prevent incoming orders that contain unavailable products.
The Rappi API enables you to configure availability by:
- Item SKU: This is the SKU you provided for the item to the Rappi when uploading to the menu.
- Item ID: This is the identifier that Rappi provided you when uploading to the menu.
Consulting the Availability by SKU
Use the POST availability/items/status
endpoint to query the availability of your items by item SKU.
To check the availability of your items by Item SKU:
Make a POST
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/items/status
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
{ "store_id": "900144512", "item_ids": ["7713", "2668", "3395", "5685"] }
Note
The values from this JSON
object are not real data. Ensure to replace them with your own data when making API requests.
This is an example JSON
of the response:
[ { "item_id": 2136411305, "item_type": "PRODUCT", "stock_out_state": "AVAILABLE" }, { "item_id": 2136411307, "item_type": "PRODUCT", "stock_out_state": "AVAILABLE" }, { "item_id": 2136411304, "item_type": "PRODUCT", "stock_out_state": "AVAILABLE" }, { "item_id": 2136411306, "item_type": "PRODUCT", "stock_out_state": "AVAILABLE" } ]
Consulting the Availability by Rappi ID
Use the POST availability/items/rappi/status
endpoint to query the availability of your items by item SKU.
To check the availability of your items by Item SKU:
Make a POST
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/items/rappi/status
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
{ "store_id": "900144512", "item_ids": ["2136411304"] }
Note
The values from this JSON
object are not real data. Ensure to replace them with your own data when making API requests.
This is an example JSON
of the response:
[ { "item_id": 2136411304, "item_type": "PRODUCT", "stock_out_state": "AVAILABLE" } ]
Setting Availability by SKU
Use the PUT availability/stores/items
endpoint to configure the availability of your items by Item SKU.
To configure the availability of your items by Item SKU:
Make a PUT
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/token
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
[ { "store_integration_id": "999", "items": { "turn_on": ["1111", "2222", "3333"], "turn_off": ["5555"] } } ]
Note
The values from this JSON
object are not real data. Ensure to replace them with your own data when making API requests.
You can add more items to the turn_on
and turn_off
JSON
objects separated by a comma. If you only want to turn on or turn off items in your request, remove the other object from your JSON
accordingly.
The system retrieves a JSON
response with the confirmation message Items successfully updated.
Setting Availability by Rappi ID
Use the PUT availability/stores/items/rappi
endpoint to configure the availability of your items by Item ID.
To configure the availability of your items by Item ID:
Make a PUT
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
[ { "store_integration_id": "999", "items": { "turn_on": [1111, 2222, 3333], "turn_off": [5555] } } ]
Note
The values from this JSON
are not real data. Ensure to replace them with your data when making API requests.
You can add more items to the turn_on
and turn_off
JSON
objects separated by a comma. If you only want to turn on or turn off items in your request, remove the other object from your JSON
accordingly.
The system returns a JSON
response with the confirmation status message "Items successfully updated".
Store status
Use the POST availability/stores
endpoint to check the availability of your stores.
To check the availability of your stores:
Make a POST
request to the following URL and add a JSON
to the request body with the following structure.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
[900105433]
Note
- The values in this
JSON
are not actual data. Be sure to replace them with your data when making API requests. - You can add more stores in the
JSON
separated by a comma. - You can query up to 100 stores in your
JSON
.
This is an example of the JSON
response:
{ "900105433": false }
Store Availability (asynchronous)
Use the PUT availability/stores
endpoint to configure the availability of your stores.
Important
This is an asynchronous method so the operation's result will not come in the response. Using this approach you can receive the updated store status through the STORE_CONNECTIVITY webhook. See Store Connectivity
If an instant response is needed the synchronous endpoint should be use. See Store Availability (synchronous)
To configure the availability of your stores:
Make a PUT
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
{ "turn_on": ["2222"], "turn_off": ["333", "444"] }
Note
- The values from this
JSON
are not real data. Ensure to replace them with your data when making API requests. - You can add more items to the
turn_on
andturn_off
JSON
objects separated by a comma. - If you only want to turn on or turn off items in your request, remove the other object from your
JSON
accordingly.
The system retrieves a JSON
response with the confirmation message "Stores successfully updated".
Store Availability massive (asynchronous)
Use the PUT availability/stores/enable/massive
endpoint to configure the availability of your stores.
Important
This is an asynchronous method so the operation's result will not come in the response. Using this approach you can receive the updated store status through the STORE_CONNECTIVITY webhook. See Store Connectivity
It is possible that a store cannot be turn on/off because it is suspended or not published in the Rappi app
To configure the availability of your stores:
Make a PUT
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores/enable/massive
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
{ "stores": [ { "store_id": "12312", "is_enabled": true }, { "store_id": "12312", "is_enabled": false } ] }
Store Availability (synchronous)
Use the PUT availability/stores/enable
endpoint to configure the availability of your stores.
Important
This is a synchronous method so the operation's result will come in the response.
Keep in mind that the max amount of stores is 300. If you need to send more stores use the async method. See Store Availability (asynchronous)
It is possible that a store cannot be turn on/off because it is suspended or not published in the Rappi app
To configure the availability of your stores:
Make a PUT
request to the following URL, and add a JSON
to the body of the request with the following objects.
URL: https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores/enable
{COUNTRY_DOMAIN}
: This is your Rappi Country Domain. See the list of Country Domains.
This is an example of the JSON
in the body of the request:
{ "stores": [ { "store_id": "12312", "is_enabled": true }, { "store_id": "12312", "is_enabled": false } ] }
This is an example of the response:
{ "results": [ { "store_id": 90774, "is_enabled": false, "operation_result": false, "operation_result_type": "suspended", "suspended_reason": "suspended due cancelled orders", "suspended_at": "2022-04-11T20:23:00.00Z", "suspended_time": 60 } ] }