Rappi API v1.24.5
Rappi API v1.24.5 includes all the resources, endpoints, and methods that enable you to integrate with the Rappi application.
The following table contains all the resources available to use with our API:
| API Resource | Endpoint | Endpoint Description |
|---|---|---|
| Menus | GET menu |
Returns the collection of menus created by the authenticating ally |
POST menu |
Creates or updates a menu in a store | |
GET menu/approved/{storeId} |
Returns the current approval status of a menu | |
GET menu/rappi/{storeId} |
Returns the last menu created for a store | |
| Orders | GET orders |
Returns a list of new orders created |
GET orders/status/sent |
Returns a list of new orders created in SENT |
|
PUT orders/{orderId}/take/{cookingTime} |
Takes an order to start preparing | |
PUT orders/{orderId}/reject |
Rejects an order | |
POST orders/{orderId}/ready-for-pickup |
Confirms that the order is ready for pickup | |
GET orders/{orderId}/events |
Returns the latest events from the orders | |
| Stores | GET stores-pa |
Returns the list of stores for the authenticated client |
PUT stores-pa/{storeId}/status |
Update a store to integrated or not integrated | |
| Availability | POST availability/items/status |
Returns the availability of items by Item SKU |
POST availability/items/rappi/status |
Returns the availability of items by Item ID | |
PUT availability/stores/items/rappi |
Manage item availability in the application by Item ID | |
PUT availability/stores/items/rappi |
Manage item availability in the application by Item ID | |
PUT availability/stores |
Manage store availability in the application | |
| Webhooks | GET webhook/{event} |
Returns the webhooks configured for all the stores of the authenticated client |
PUT webhook/{event}/add-stores |
Add stores to a specific webhook event | |
PUT webhook/{event}/change-url |
Change url from stores | |
POST webhook |
Creates a new webhook for a list of stores for the authenticated client | |
DELETE webhook/{event}/remove-stores |
Deletes stores from your webhook | |
PUT webhook/{event}/reset-secret |
Restarts the secret and generates a new one for the authenticated client | |
PUT webhook/{event}/change-status |
Enables or disables the webhooks for a list of stores |
Getting Started
To start using the Rappi API you must sing up as a Rappi ally.
After signing up as a Rappy ally, you receive your Rappi Credentials that consist of the following:
client_idclient_secretaudiencegrant_type
Use these Rappi Credentials to create your Access Token with the POST token. After generating your Access Token, you can start using the Rappi API.
Authentication
To authenticate when making API requests to the Rappi API, you require an Access Token.
The Rappi API uses a Bearer authentication scheme, as the HTTP authentication method for API requests.
To make API requests, send the token in a customer header to interact with protected resources.
Rappi uses the following scheme for the Bearer authentication:
| Key | Value |
|---|---|
x-authorization |
bearer [access_token] |
POST token
Use this endpoint to generate an Access Token. This token enables you to authenticate when making API requests.
Endpoint URL
Use the following URLs to make a request with this endpoint:
- Development URL:
https://rests-integrations-dev.auth0.com/oauth/token - Production URL:
https://rests-integrations.auth0.com/oauth/token
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Unauthorized
Sample Request
This is an example of an API request using this endpoint:
POST https://rests-integrations-dev.auth0.com/oauth/token
This is an example of the request:
{
"client_id":"7iCfjZCO4bTns3OjqLK4de2GV3sp6Ymd",
"client_secret":"40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW",
"audience":"https://int-public-api-v2/api",
"grant_type":"client_credentials"
}
URL url = new URL("https://rests-integrations-dev.auth0.com/oauth/token");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setDoOutput(true);
final String jsonInputString = "{\n" +
" \"client_id\":\"7iCfjZCO4bTns3OjqLK4de2GV3sp6Ymd\",\n" +
" \"client_secret\":\"40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW\",\n" +
" \"audience\":\"https://int-public-api-v2/api\",\n" +
" \"grant_type\":\"client_credentials\"\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
import requests
url = "https://rests-integrations-dev.auth0.com/oauth/token"
payload = "{ \"client_id\":\"7iCfjZCO4bTns3OjqLK4de2GV3sp6Ymd\"," \
"\"client_secret\":\"40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW\"," \
"\"audience\":\"https://int-public-api-v2/api\"," \
"\"grant_type\":\"client_credentials\"} "
headers = {
'Content-Type': 'application/json',
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'rests-integrations-dev.auth0.com',
'path': '/oauth/token?',
'headers': {
'Content-Type': 'application/json',
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"client_id":"7iCfjZCO4bTns3OjqLK4de2GV3sp6Ymd",
"client_secret":"40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW",
"audience":"https://int-public-api-v2/api",
"grant_type":"client_credentials"
});
req.write(postData);
req.end();
package main
import (
"fmt"
"io/ioutil"
"net/http"
"strings"
)
func main() {
url := "https://rests-integrations-dev.auth0.com/oauth/token"
method := "POST"
payload := strings.NewReader("{\n " +
"\"client_id\":\"7iCfjZCO4bTns3OjqLK4de2GV3sp6Ymd\",\n " +
"\"client_secret\":\"40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW40iFFYJV9A1LrVmJsaIeARW\",\n " +
"\"audience\":\"https://int-public-api-v2/api\",\n " +
"\"grant_type\":\"client_credentials\"\n}")
client := &http.Client{
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
client_idstring |
required |
Client Id of your Rappi Credentials. |
client_secretstring |
required |
Client Secret of your Rappi Credentials. |
audiencestring |
required |
Identifier of the Rappi API. |
grant_typestring |
required |
Permission to request. |
Sample Response
This is an example of the response:
{
"access_token":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpeyJhbGciOiJIUzI1NiIsInR5cCI6IkpeyJhbGciOiJIUzI1NiIsInR5cCI6Ikp",
"scope":"integration:health-check",
"expires_in":86400,
"token_type":"Bearer"
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
access_tokenstring |
Access token to access secure endpoints. |
scopestring |
Scope granted. |
expires_ininteger |
Token expiration time in seconds. |
token_typestring |
Token type. |
Menus
The Menus resource enables you to interact with the menus of your stores.
The following table describes the different contents of the Menus resource:
| Resource | Description |
|---|---|
GET menu |
Returns the collection of menus created by the authenticating ally |
POST menu |
Creates or updates a menu in a store |
GET menu/approved/{storeId} |
Returns the current approval status of a menu |
GET menu/rappi/{storeId} |
Returns the last menu created for a store |
GET menu
Use this endpoint to return the collection of menus created by the authenticating ally.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/menu
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/menu',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response "Success 200":
This is an example of the response:
[
{
"storeId": "900111978",
"items": [
{
"name": "Naked Cake con frutos",
"description": "Naked cake decorado con frutos. Cubierta de trufa derretida (ganache) y decorada con frutos del bosque.",
"sku": "8569874",
"type": "PRODUCT",
"price": 75.0,
"category": {
"id": "3",
"name": "Tortas",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image1.jpg",
"children": [
{
"name": "Chocolate",
"description": "",
"sku": "8569874-159",
"type": "TOPPING",
"price": 0.0,
"category": {
"id": "1",
"name": "Sabor",
"minQty": 0,
"maxQty": 1,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image10.jpg",
"children": [],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"340948822"
],
"sortingPosition": 1,
"maxLimit": 1
}
],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"2135527868"
],
"sortingPosition": 0,
"maxLimit": 1
},
{
"name": "Snowman",
"description": "Linda lata de Snowman con productos variadosIncluye:Galletas mantequilla 350 gr, 6 brookies y 4 trufas de brownie.",
"sku": "856887",
"type": "PRODUCT",
"price": 75.0,
"category": {
"id": "9",
"name": "Navidad",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image2.jpg",
"children": [],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"2135524472"
],
"sortingPosition": 0,
"maxLimit": 1
}
]
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
storeIdstring |
Identifier of the store in the Rappi application. |
itemsarray of objects |
Product list |
items.namestring |
Name of the product in the menu |
items.descriptionstring |
Description of the product in the menu |
items.skustring |
SKU that the ally assigned for the product in the menu |
items.typestring |
Item type. In this case can be only PRODUCT |
items.priceinteger |
Price of the product in the menu |
items.imageUrlstring |
Image url of the product in the menu |
items.availableFromstring |
Start date from the product is available to sell in the menu |
items.availableTostring |
End date from the product is available to sell in the menu |
items.rappiIdsarray of string |
List of the identifiers Rappi gives to this item |
items.sortingPositioninteger |
The position of the product in its category |
items.maxLimitinteger |
Maximum indicator of the item, it's required only if the type is topping |
items.categorystring |
Category of the product in the menu |
items.category.idstring |
The SKU (Stock-Keeping Unit) the ally gives to this category |
items.category.namestring |
Category name |
items.category.minQtyinteger |
The maximum number of items that can be ordered in this category |
items.category.maxQtyinteger |
The minimum quantity of elements that can be ordered in this category (In toppings, if it's 0 it means that it's not mandatory) |
items.category.sortingPositioninteger |
it's the position of the category in the menu |
items.childrenarray of objects |
List of product's toppings from the menu |
items.children.namestring |
Name of the topping in the menu |
items.children.descriptionstring |
Description of the topping in the menu |
items.children.skustring |
SKU that the ally assigned for the topping in the menu |
items.children.typestring |
Item type. In this case can be only TOPPING |
items.children.priceinteger |
Price of the topping in the menu |
items.children.imageUrlstring |
Image url of the topping in the menu |
items.children.availableFromstring |
Start date from the topping is available to sell in the menu |
items.children.availableTostring |
End date from the topping is available to sell in the menu |
items.children.rappiIdsarray of string |
List of the identifiers Rappi gives to this item |
items.children.sortingPositioninteger |
The position of the topping in its category |
items.children.maxLimitinteger |
Maximum indicator of the item, it's required only if the type is topping |
items.children.categorystring |
Category of the topping in the menu |
items.children.category.idstring |
The SKU (Stock-Keeping Unit) the ally gives to this category |
items.children.category.namestring |
Category name |
items.children.category.minQtyinteger |
The maximum number of items that can be ordered in this category |
items.children.category.maxQtyinteger |
The minimum quantity of elements that can be ordered in this category (In toppings, if it's 0 it means that it's not mandatory) |
items.children.category.sortingPositioninteger |
The position of the category within the product |
Sample Response "Invalid credentials 401":
{
"message": "Not a valid token"
}
This table describes the attributes from JSON response:
| Attributes | Description |
|---|---|
messagestring |
Not a valid token |
POST menu
Use this endpoint to create a new menu, or to add new items to an existing one, for the authenticated ally.
After creating a menu, or adding new items to an existing one, the Rappi team validates the items and the structure of the menu. You can consult the status of the approval process by using the GET menu/approved/{storeId} endpoint.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/menu
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Menu updated and ready to be validated
400
The menu structure is invalid
401
Invalid Credentials
404
Store not found
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu
This is an example of the request:
{
"storeId": "900103361",
"items": [
{
"category": {
"id": "2090019638",
"maxQty": 0,
"minQty": 0,
"name": "Burgers",
"sortingPosition": 0
},
"children": [
{
"category": {
"id": "211",
"maxQty": 1,
"minQty": 0,
"name": "Do you want to add?",
"sortingPosition": 0
},
"children": [],
"name": "French Fries",
"price": 5000,
"sku": "2135092195",
"sortingPosition": 1,
"type": "TOPPING",
"maxLimit": 1
},
{
"category": {
"id": "211",
"maxQty": 1,
"minQty": 0,
"name": "Do you want to add?",
"sortingPosition": 0
},
"children": [],
"name": "Potato Wedges",
"price": 7000,
"sku": "2135092196",
"sortingPosition": 1,
"type": "TOPPING",
"maxLimit": 1
}
],
"name": "Grilled Chicken Burger",
"price": 14000,
"sku": "2135092197",
"sortingPosition": 0,
"type": "PRODUCT"
},
{
"category": {
"id": "2090019639",
"maxQty": 0,
"minQty": 0,
"name": "Pizzas",
"sortingPosition": 1
},
"children": [],
"name": "Hawaiian Pizza",
"price": 17000,
"sku": "2135092198",
"sortingPosition": 1,
"type": "PRODUCT"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"storeId\": \"900103361\",\n" +
" \"items\": [\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"2090019638\",\n" +
" \"maxQty\": 0,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Burgers\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"211\",\n" +
" \"maxQty\": 1,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Do you want to add?\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"French Fries\",\n" +
" \"price\": 5000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"TOPPING\",\n" +
" \"maxLimit\": 1\n" +
" },\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"211\",\n" +
" \"maxQty\": 1,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Do you want to add?\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"Potato Wedges\",\n" +
" \"price\": 7000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"TOPPING\",\n" +
" \"maxLimit\": 1\n" +
" }\n" +
" ],\n" +
" \"name\": \"Grilled Chicken Burger\",\n" +
" \"price\": 14000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 0,\n" +
" \"type\": \"PRODUCT\"\n" +
" },\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"2090019639\",\n" +
" \"maxQty\": 0,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Pizzas\",\n" +
" \"sortingPosition\": 1\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"Hawaiian Pizza\",\n" +
" \"price\": 17000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"PRODUCT\"\n" +
" }\n" +
" ]\n" +
"}\n";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/menu',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify(
{
"storeId": "900103361",
"items": [
{
"category": {
"id": "2090019638",
"maxQty": 0,
"minQty": 0,
"name": "Burgers",
"sortingPosition": 0
},
"children": [
{
"category": {
"id": "211",
"maxQty": 1,
"minQty": 0,
"name": "Do you want to add?",
"sortingPosition": 0
},
"children": [],
"name": "French Fries",
"price": 5000,
"sku": "2135092145",
"sortingPosition": 1,
"type": "TOPPING",
"maxLimit": 1
},
{
"category": {
"id": "211",
"maxQty": 1,
"minQty": 0,
"name": "Do you want to add?",
"sortingPosition": 0
},
"children": [],
"name": "Potato Wedges",
"price": 7000,
"sku": "2135092145",
"sortingPosition": 1,
"type": "TOPPING",
"maxLimit": 1
}
],
"name": "Grilled Chicken Burger",
"price": 14000,
"sku": "2135092145",
"sortingPosition": 0,
"type": "PRODUCT"
},
{
"category": {
"id": "2090019639",
"maxQty": 0,
"minQty": 0,
"name": "Pizzas",
"sortingPosition": 1
},
"children": [],
"name": "Hawaiian Pizza",
"price": 17000,
"sku": "2135092145",
"sortingPosition": 1,
"type": "PRODUCT"
}
]
}
);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu"
payload = "{\n" \
" \"storeId\": \"900103361\",\n" \
" \"items\": [\n" \
" {\n" \
" \"category\": {\n" \
" \"id\": \"2090019638\",\n" \
" \"maxQty\": 0,\n" \
" \"minQty\": 0,\n" \
" \"name\": \"Burgers\",\n" \
" \"sortingPosition\": 0\n" \
" },\n" \
" \"children\": [\n" \
" {\n" \
" \"category\": {\n" \
" \"id\": \"211\",\n" \
" \"maxQty\": 1,\n" \
" \"minQty\": 0,\n" \
" \"name\": \"Do you want to add?\",\n" \
" \"sortingPosition\": 0\n" \
" },\n" \
" \"children\": [],\n" \
" \"name\": \"French Fries\",\n" \
" \"price\": 5000,\n" \
" \"sku\": \"2135092145\",\n" \
" \"sortingPosition\": 1,\n" \
" \"type\": \"TOPPING\",\n" \
" \"maxLimit\": 1\n" \
" },\n" \
" {\n" \
" \"category\": {\n" \
" \"id\": \"211\",\n" \
" \"maxQty\": 1,\n" \
" \"minQty\": 0,\n" \
" \"name\": \"Do you want to add?\",\n" \
" \"sortingPosition\": 0\n" \
" },\n" \
" \"children\": [],\n" \
" \"name\": \"Potato Wedges\",\n" \
" \"price\": 7000,\n" \
" \"sku\": \"2135092145\",\n" \
" \"sortingPosition\": 1,\n" \
" \"type\": \"TOPPING\",\n" \
" \"maxLimit\": 1\n" \
" }\n" \
" ],\n" \
" \"name\": \"Grilled Chicken Burger\",\n" \
" \"price\": 14000,\n" \
" \"sku\": \"2135092145\",\n" \
" \"sortingPosition\": 0,\n" \
" \"type\": \"PRODUCT\"\n" \
" },\n" \
" {\n" \
" \"category\": {\n" \
" \"id\": \"2090019639\",\n" \
" \"maxQty\": 0,\n" \
" \"minQty\": 0,\n" \
" \"name\": \"Pizzas\",\n" \
" \"sortingPosition\": 1\n" \
" },\n" \
" \"children\": [],\n" \
" \"name\": \"Hawaiian Pizza\",\n" \
" \"price\": 17000,\n" \
" \"sku\": \"2135092145\",\n" \
" \"sortingPosition\": 1,\n" \
" \"type\": \"PRODUCT\"\n" \
" }\n" \
" ]\n" \
"}\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu"
method := "POST"
payload := strings.NewReader("{\n" +
" \"storeId\": \"900103361\",\n" +
" \"items\": [\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"2090019638\",\n" +
" \"maxQty\": 0,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Burgers\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"211\",\n" +
" \"maxQty\": 1,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Do you want to add?\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"French Fries\",\n" +
" \"price\": 5000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"TOPPING\",\n" +
" \"maxLimit\": 1\n" +
" },\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"211\",\n" +
" \"maxQty\": 1,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Do you want to add?\",\n" +
" \"sortingPosition\": 0\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"Potato Wedges\",\n" +
" \"price\": 7000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"TOPPING\",\n" +
" \"maxLimit\": 1\n" +
" }\n" +
" ],\n" +
" \"name\": \"Grilled Chicken Burger\",\n" +
" \"price\": 14000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 0,\n" +
" \"type\": \"PRODUCT\"\n" +
" },\n" +
" {\n" +
" \"category\": {\n" +
" \"id\": \"2090019639\",\n" +
" \"maxQty\": 0,\n" +
" \"minQty\": 0,\n" +
" \"name\": \"Pizzas\",\n" +
" \"sortingPosition\": 1\n" +
" },\n" +
" \"children\": [],\n" +
" \"name\": \"Hawaiian Pizza\",\n" +
" \"price\": 17000,\n" +
" \"sku\": \"2135092145\",\n" +
" \"sortingPosition\": 1,\n" +
" \"type\": \"PRODUCT\"\n" +
" }\n" +
" ]\n" +
"}\n")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
storeIdstring |
required |
Identifier of the store in the Rappi application. |
itemsarray of objects |
required |
Product list |
items.namestring |
required |
Name of the product in the menu |
items.descriptionstring |
required |
Description of the product in the menu |
items.skustring |
required |
SKU that the ally assigned for the product in the menu |
items.typestring |
required |
Item type. In this case can be only PRODUCT |
items.priceinteger |
required |
Price of the product in the menu |
items.imageUrlstring |
optional |
Image url of the product in the menu |
items.availableFromstring |
optional |
Start date from the product is available to sell in the menu |
items.availableTostring |
optional |
End date from the product is available to sell in the menu |
items.rappiIdsarray of string |
optional |
List of the identifiers Rappi gives to this item |
items.sortingPositioninteger |
optional |
The position of the product in its category |
items.maxLimitinteger |
optional |
Maximum indicator of the item, it's required only if the type is topping |
items.categorystring |
required |
Category of the product in the menu |
items.category.idstring |
required |
The SKU (Stock-Keeping Unit) the ally gives to this category |
items.category.namestring |
required |
Category name |
items.category.minQtyinteger |
required |
The maximum number of items that can be ordered in this category |
items.category.maxQtyinteger |
required |
The minimum quantity of elements that can be ordered in this category (In toppings, if it's 0 it means that it's not mandatory) |
items.category.sortingPositioninteger |
required |
it's the position of the category in the menu |
items.childrenarray of objects |
optional |
List of product's toppings from the menu |
items.children.namestring |
required |
Name of the topping in the menu |
items.children.descriptionstring |
required |
Description of the topping in the menu |
items.children.skustring |
required |
SKU that the ally assigned for the topping in the menu |
items.children.typestring |
required |
Item type. In this case can be only TOPPING |
items.children.priceinteger |
required |
Price of the topping in the menu |
items.children.imageUrlstring |
optional |
Image url of the topping in the menu |
items.children.availableFromstring |
optional |
Start date from the topping is available to sell in the menu |
items.children.availableTostring |
optional |
End date from the topping is available to sell in the menu |
items.children.rappiIdsarray of string |
optional |
List of the identifiers Rappi gives to this item |
items.children.sortingPositioninteger |
optional |
The position of the topping in its category |
items.children.maxLimitinteger |
optional |
Maximum indicator of the item, it's required only if the type is topping |
items.children.categorystring |
required |
Category of the topping in the menu |
items.children.category.idstring |
required |
The SKU (Stock-Keeping Unit) the ally gives to this category |
items.children.category.namestring |
required |
Category name |
items.children.category.minQtyinteger |
required |
The maximum number of items that can be ordered in this category |
items.children.category.maxQtyinteger |
required |
The minimum quantity of elements that can be ordered in this category (In toppings, if it's 0 it means that it's not mandatory) |
items.children.category.sortingPositioninteger |
required |
The position of the category within the product |
Sample response "200 success"
This endpoint returns only one successful response code.
Sample response "400 The menu structure is invalid"
400 The menu structure is invalid:
{
"message": "The submitted menu has errors.",
"errors": [
{
"reason": "All items must have a valid name, category or product description.",
"relatedItems": [
{
"description": "",
"sku": "product1",
"type": "PRODUCT",
"price": 899.0,
"category": {
"id": "455",
"name": "producto category name 1",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "https://anydomain/anyimagen_1.png",
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"1965855"
],
"sortingPosition": 0,
"maxLimit": 1
}
]
},
{
"reason": "Invalid urls were found",
"relatedItems": [
{
"name": "producto name 1",
"description": "",
"sku": "product2",
"type": "PRODUCT",
"price": 899.0,
"category": {
"id": "455",
"name": "producto category name 1",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "httpaas://anydomain/anyimagen_2.png",
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"1965855"
],
"sortingPosition": 0,
"maxLimit": 1
}
]
}
]
}
This table describes the attributes from JSON response:
| Attributes | Description |
|---|---|
messagestring |
Generic error message to response "structure is invalid." message: "The submitted menu has errors." |
errorsarray of objects |
Error list found in menu. |
errors.reasonstring |
Description of the error. you can find more info in "Validations on the Received menu" |
errors.relatedItemsarray of objects |
Items with error. |
You can see the list of structure validations in the VALIDATIONS ON THE RECEIVED MENU.
Sample response "401 Invalid Credentials"
401 Invalid Credentials:
{
"message": "Not a valid token"
}
This table describes the attributes from JSON response:
| Attributes | Description |
|---|---|
messagestring |
Not a valid token |
Sample response "404 Store not found"
404 Store not found:
{
"message": "StoreId 9001035324: not found associated Stores"
}
This table describes the attributes from JSON response:
| Attributes | Description |
|---|---|
messagestring |
Store not found |
GET menu/approved/{storeId}
Use this endpoint to return the approval status of a menu.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/menu/approved/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
This table contains the possible response codes for this endpoint:
200
Success
401
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/approved/251
This is an example of the request:
final Integer storeId = 251;
URL url = new URL(
String.format("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/approved/%s", storeId));
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/menu/approved/251',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/approved/251"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/approved/251"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This endpoint returns a status response code only.
401 Invalid Credentials:
{
"message": "Not a valid token"
}
GET menu/rappi/{storeId}
Use this endpoint to return the last menu created for a specific store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/menu/rappi/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store integration.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
This table contains the possible response codes for this endpoint:
200
Success
401
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/rappi/251
This is an example of the request:
final Integer storeId = 251;
URL url = new URL(
String.format("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/rappi/%s", storeId));
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/menu/rappi/251',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/rappi/251"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/menu/rappi/251"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response "Success 200":
{
"storeId": "900111978",
"items": [
{
"name": "Naked Cake con frutos",
"description": "Naked cake decorado con frutos. Cubierta de trufa derretida (ganache) y decorada con frutos del bosque.",
"sku": "8569874",
"type": "PRODUCT",
"price": 75.0,
"category": {
"id": "3",
"name": "Tortas",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image1.jpg",
"children": [
{
"name": "Chocolate",
"description": "",
"sku": "8569874-159",
"type": "TOPPING",
"price": 0.0,
"category": {
"id": "1",
"name": "Sabor",
"minQty": 0,
"maxQty": 1,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image10.jpg",
"children": [],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"340948822"
],
"sortingPosition": 1,
"maxLimit": 1
}
],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"2135527868"
],
"sortingPosition": 0,
"maxLimit": 1
},
{
"name": "Snowman",
"description": "Linda lata de Snowman con productos variadosIncluye:Galletas mantequilla 350 gr, 6 brookies y 4 trufas de brownie.",
"sku": "856887",
"type": "PRODUCT",
"price": 75.0,
"category": {
"id": "9",
"name": "Navidad",
"minQty": 0,
"maxQty": 0,
"sortingPosition": 0
},
"imageUrl": "https://image.com/image2.jpg",
"children": [],
"availableFrom": null,
"availableTo": null,
"rappiIds": [
"2135524472"
],
"sortingPosition": 0,
"maxLimit": 1
}
]
}
This is an example of the response "Invalid credentials 401":
{
"message": "Not a valid token"
}
The context of the attribute response were mentionend before in Get Menu.
Orders
The Orders resource enables you to interact with the orders of your stores.
The following table describes the different contents of the Orders resource:
| Resource | Description |
|---|---|
GET orders |
Returns a list of new orders created. |
GET orders/status/sent |
Returns a list of new orders created in SENT. |
PUT orders/{orderId}/take/{cookingTime} |
Takes an order to commence preparation. |
PUT orders/{orderId}/reject |
Rejects an order. |
POST orders/{orderId}/ready-for-pickup |
Confirms that the order is ready for pickup. |
GET orders/{orderId}/events |
Returns the latest events from the orders. |
GET orders
Use this endpoint to return a collection of all the new orders for the stores of the authenticating ally.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint admits the following optional additional parameters:
| Parameter | Description |
|---|---|
{storeId} |
Returns only the orders from a specific store |
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
400
The store don't belong to the appClient of given id
401
Invalid credentials
404
Store not found
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders
this is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
[
{
"order_detail": {
"order_id": "392625",
"cooking_time": 10,
"min_cooking_time": 5,
"max_cooking_time": 20,
"created_at": "2019-04-10T11:12:57.000Z",
"delivery_method": "delivery",
"payment_method": "cc",
"delivery_information": {
"city": "Ciudad de México",
"complete_address": "Nombre de la calle 5050. Barrio. 12345. Ciudad De México",
"street_number": "5050",
"neighborhood": "Barrio",
"complement": "Portón verde",
"postal_code": "12345",
"street_name": "Nombre de la calle"
},
"billing_information": {
"address": "148 Davis Court",
"billing_type": "Bill",
"document_number": "32432342",
"document_type": "DNI",
"email": "client@gmail.com",
"name": "John Doe",
"phone": "43333222"
},
"totals": {
"total_products": 204000,
"total_discounts": 173685,
"total_order": 204180,
"total_discount_by_partner": 40180,
"total_to_pay": 0,
"discount_by_support": 0,
"charges": {
"shipping": 50,
"service_fee": 100
},
"other_totals": {
"tip": 30,
"total_rappi_pay": 0,
"total_rappi_credits": 0
}
},
"items": [
{
"sku": "1234",
"id": "2089918083",
"name": "Chicken and Apple Salad",
"type": "PRODUCT",
"comments": "No vinegar",
"price": 28900,
"quantity": 3,
"subitems": [
{
"sku": "11",
"id": "10005260",
"name": "Burrata Cheese",
"type": "TOPPING",
"price": 13500,
"quantity": 1
}
]
},
{
"id": "2089918082",
"name": "Seafood Salad",
"comments": "",
"price": 34900,
"quantity": 2,
"subitems": [
{
"id": "9928277",
"name": "With white vinaigrette",
"price": 0,
"quantity": 1
},
{
"id": "10005257",
"name": "Ricotta Cheese",
"price": 3500,
"quantity": 1
}
]
}
],
"delivery_discount": {
"total_percentage_discount": 100,
"total_value_discount": 50
},
"discounts": [
{
"value": 7600,
"description": "Envío gratis",
"title": "Envío gratis",
"product_id": null,
"sku": null,
"type": "shipping",
"raw_value": 100,
"value_type": "percentage",
"max_value": null,
"includes_toppings": false,
"percentage_by_rappi": 100,
"percentage_by_partners": 0,
"amount_by_rappi": 7600,
"amount_by_partner": 0,
"discount_product_units": 0,
"discount_product_unit_value": null
},
{
"value": 100,
"description": "Disfruta de 20% de descuento en productos seleccionados.",
"title": "Disfruta de 20% de descuento en productos seleccionados.",
"product_id": 2089918082,
"sku": 2089918082,
"type": "offer_by_product",
"raw_value": 20,
"value_type": "percentage",
"max_value": null,
"includes_toppings": false,
"percentage_by_rappi": 0,
"percentage_by_partners": 100,
"amount_by_rappi": 0,
"amount_by_partner": 100,
"discount_product_units": 1,
"discount_product_unit_value": 100
}
]
},
"customer": {
"first_name": "John",
"last_name": "Doe",
"phone_number": "3163535",
"document_number": "34545678",
"user_type": "USER_VIP"
},
"store": {
"internal_id": "30000011",
"external_id": "123445",
"name": "Store 1"
}
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
order_detailarray of objects |
Properties of the details of the order. |
order_detail.order_idstring |
Order identifier. |
order_detail.coooking_timeinteger |
Cooking time estimated for the preparation of the order. |
order_detail.min_cooking_timeinteger |
Minimum cooking time in minutes set for this order. |
order_detail.max_cooking_timeinteger |
Maximum cooking time in minutes set for this order. |
order_detail.created_atstring |
Creation date of the order. |
order_detail.delivery_methodstring, enumerable |
Delivery method set for this order. Options available: delivery,marketplace, pickup. |
order_detail.payment_methodstring, enumerable |
Payment method set for this order. Options available: rappi_pay, cc, cash, paypal, edenred, webpay, masterpass, dc, pos_terminal, elo, sodexo, vale_r, ticket_r, alelo, visa_checkout,google_pay, apple_pay, rappicorp, PSE, PIX, unknown. (You have to consider, Rappi frequently includes new payment methods, so this list may vary through time and isn't needs to be validated.) |
order_detail.delivery_informationobject |
Properties of the delivery information. |
order_detail.delivery_information.citystring |
City of the delivery address. |
order_detail.delivery_information.complete_addressstring |
Delivery address with all the fields |
order_detail.delivery_information.street_numberstring |
Number of the street. |
order_detail.delivery_information.neighborhoodstring |
Neighborhood of the address. |
order_detail.delivery_information.complementstring |
Additional information of the address. |
order_detail.delivery_information.postal_codestring |
Postal code of the address |
order_detail.delivery_information.street_namestring |
Street name of the address. |
order_detail.billing_informationarray of objects |
Properties of the billing information. |
order_detail.billing_information.addressstring |
Delivery address set for this order. |
order_detail.billing_information.billing_typestring |
Billing type set for this order. |
order_detail.billing_information.document_numberstring |
Document number of the customer. |
order_detail.billing_information.document_typestring |
Document type of the customer. |
order_detail.billing_information.emailstring |
Email set to receive billing information. |
order_detail.billing_information.namestring |
Name set for the billing information. |
order_detail.billing_information.phonestring |
Phone number set for the billing information. |
order_detail.totalsarray of objects |
Properties of the totals of the order. |
order_detail.totals.total_productsinteger |
Total products without discounts. |
order_detail.totals.total_discountsinteger |
Total products without discount in the order. |
order_detail.totals.total_orderinteger |
The total amount that the restaurant receives. When the delivery method is marketplace this field includes tip and delivery fee.For other delivery methods, this field contains only the total value of all products. In all cases, this field includes the discounts assumed by the restaurant. |
order_detail.totals.total_to_payinteger |
Total that the user pays in cash to the courier. Only applies when the delivery method is marketplace or pickup, and the payment method is cash. |
order_detail.totals.discount_by_supportinteger |
Discount applied to the customer by the Rappi support team. |
order_detail.totals.chargesarray of objects |
Properties of the order additional charges. |
order_detail.totals.charges.shippinginteger |
Shipping charges total. |
order_detail.totals.charges.service_feeinteger |
Rappi service fee charges |
order_detail.totals.other_totalsarray of objects |
Other charges included in this order. |
order_detail.totals.other_totals.tipinteger |
Tip for the courier. |
order_detail.totals.other_totals.total_rappi_payinteger |
Total paid using Rappi Pay. |
order_detail.totals.othet_totals.total_rappi_creditsinteger |
Total paid using Rappi Credits. |
order_detail.itemsarray of objects |
Properties of the items the order contains. |
order_detail.items.skustring |
SKU for the item in the order. The ally grants their own SKU to the item. |
order_detail.items.idstring |
Identifier of the item in the order. |
order_detail.items.namestring |
Name of the item in the order. |
order_detail.items.typestring, enumerable |
Type of the item. Options available: product, or topping. |
order_detail.items.commentsarray |
User comments for the items in the order. |
order_detail.items.priceinteger |
Unit price for the item without the discount. |
order_detail.items.percentage_discountinteger |
Discount percentage of the item in the order. |
order_detail.items.quantityinteger |
Quantity specified for this item in the order. |
order_detail.items.subitemsarray of objects |
Properties of subitems in the order. |
order_detail.items.subitems.skustring |
SKU for the subitem in the menu. The ally grants their own SKU to the item. |
order_detail.items.subitems.idstring |
The identifier that Rappi grants the item. |
order_detail.items.subitems.namestring |
Name of the subitem in the order. |
order_detail.items.subitems.typestring, enumerable |
Type of the subitem in the order. Options available: product, or topping. |
order_detail.items.subitems.priceinteger |
Unit price for the subitem without the discount. |
order_detail.items.subitems.pencentage_discountinteger |
Discount percentage of the subitem in the order. |
order_detail.items.subitems.quantityinteger |
Quantity specified for this subitem in the order. |
order_detail.delivery_discountinteger |
Properties of the discounts in the delivery of the order. |
order_detail.delivery_discount.total_percentage_discountinteger |
Discount percentage in the delivery of the order. |
order_detail.delivery_discount.total_value_discountinteger |
Total amount of the delivery discount. |
order_detail.customerarray of objects |
Properties of the Rappi user that places the order. Only sent when delivery method is marketplace or if you request Rappi to receive this data. |
order_detail.customer.first_namestring |
First name of the Rappi user that places the order. |
order_detail.customer.last_namestring |
Last name of the Rappi user that places the order. |
order_detail.customer.phone_numberstring |
Phone number of the Rappi user that places the order. |
order_detail.customer.document_numberstring |
Document number of the Rappi user that places the order. |
order_detail.customer.user_typestring |
If the user is VIP the value is USER_VIP. For other users this field is not sent. |
order_detail.storearray of objects |
Properties of the store that prepares the order. |
order_detail.store.internal_idstring |
Internal identifier that Rappi grants the store. |
order_detail.store.external_idstring |
Integration identifier of the store. |
order_detail.store.namestring |
Name of the store that prepares the order. |
order_detail.discounts.valueinteger |
Discount value in currency. |
order_detail.discounts.descriptionstring |
Descriptive message explaining the discount. |
order_detail.discounts.titlestring |
Discount name. |
order_detail.discounts.product_idinteger |
Product ID if the discount applies product. |
order_detail.discounts.skustring |
SKU of the product if the discount applies product. |
order_detail.discounts.typestring |
Indicates the discount type. |
order_detail.discounts.raw_valueinteger |
The discount value can represent a percentage or a currency value depending on the type_value. |
order_detail.discounts.value_typestring, enumerable |
The value type of the discount. Available options: value, percentage. |
order_detail.discounts.max_valueinteger |
Maximum value in currency to be discounted. |
order_detail.discounts.includes_toppingsboolean |
Indicates if the discount is subtracted from the product total with toppings or not. |
order_detail.discounts.percentage_by_rappiinteger |
The percentage of the discount assumed by Rappi. |
order_detail.discounts.percentage_by_partnersinteger |
The percentage of the discount assumed by the partner. |
order_detail.discounts.amount_by_rappiinteger |
Value of the discount in currency assumed by Rappi. |
order_detail.discounts.amount_by_partnerinteger |
Value of the discount in currency assumed by the partner. |
order_detail.discounts.discount_product_unitsinteger |
Number of products to which the discount was applied. |
order_detail.discounts.discount_product_unit_valueinteger |
Discount value per product unit. |
GET orders status SENT
Use this endpoint to return a collection of all the new orders status SENT for the stores of the authenticating ally.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders/status/sent
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint admits the following optional additional parameters:
| Parameter | Description |
|---|---|
{storeId} |
Returns only the orders from a specific store |
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
400
The store don't belong to the appClient of given id
401
Invalid credentials
404
Store not found
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/status/sent
this is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/status/sent");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders/status/sent',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/status/sent"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/status/sent"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
[
{
"order_detail": {
"order_id": "392625",
"cooking_time": 10,
"min_cooking_time": 5,
"max_cooking_time": 20,
"created_at": "2019-04-10T11:12:57.000Z",
"delivery_method": "delivery",
"payment_method": "cc",
"delivery_information": {
"city": "Ciudad de México",
"complete_address": "Nombre de la calle 5050. Barrio. 12345. Ciudad De México",
"street_number": "5050",
"neighborhood": "Barrio",
"complement": "Portón verde",
"postal_code": "12345",
"street_name": "Nombre de la calle"
},
"billing_information": {
"address": "148 Davis Court",
"billing_type": "Bill",
"document_number": "32432342",
"document_type": "DNI",
"email": "client@gmail.com",
"name": "John Doe",
"phone": "43333222"
},
"totals": {
"total_products": 204000,
"total_discounts": 173685,
"total_order": 204180,
"total_discount_by_partner": 40180,
"total_to_pay": 0,
"discount_by_support": 0,
"charges": {
"shipping": 50,
"service_fee": 100
},
"other_totals": {
"tip": 30,
"total_rappi_pay": 0,
"total_rappi_credits": 0
}
},
"items": [
{
"sku": "1234",
"id": "2089918083",
"name": "Chicken and Apple Salad",
"type": "PRODUCT",
"comments": "No vinegar",
"price": 28900,
"quantity": 3,
"subitems": [
{
"sku": "11",
"id": "10005260",
"name": "Burrata Cheese",
"type": "TOPPING",
"price": 13500,
"quantity": 1
}
]
},
{
"id": "2089918082",
"name": "Seafood Salad",
"comments": "",
"price": 34900,
"quantity": 2,
"subitems": [
{
"id": "9928277",
"name": "With white vinaigrette",
"price": 0,
"quantity": 1
},
{
"id": "10005257",
"name": "Ricotta Cheese",
"price": 3500,
"quantity": 1
}
]
}
],
"delivery_discount": {
"total_percentage_discount": 100,
"total_value_discount": 50
},
"discounts": [
{
"value": 7600,
"description": "Envío gratis",
"title": "Envío gratis",
"product_id": null,
"sku": null,
"type": "shipping",
"raw_value": 100,
"value_type": "percentage",
"max_value": null,
"includes_toppings": false,
"percentage_by_rappi": 100,
"percentage_by_partners": 0,
"amount_by_rappi": 7600,
"amount_by_partner": 0,
"discount_product_units": 0,
"discount_product_unit_value": null
},
{
"value": 100,
"description": "Disfruta de 20% de descuento en productos seleccionados.",
"title": "Disfruta de 20% de descuento en productos seleccionados.",
"product_id": 2089918082,
"sku": 2089918082,
"type": "offer_by_product",
"raw_value": 20,
"value_type": "percentage",
"max_value": null,
"includes_toppings": false,
"percentage_by_rappi": 0,
"percentage_by_partners": 100,
"amount_by_rappi": 0,
"amount_by_partner": 100,
"discount_product_units": 1,
"discount_product_unit_value": 100
}
]
},
"customer": {
"first_name": "John",
"last_name": "Doe",
"phone_number": "3163535",
"document_number": "34545678",
"user_type": "USER_VIP"
},
"store": {
"internal_id": "30000011",
"external_id": "123445",
"name": "Store 1"
}
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
order_detailarray of objects |
Properties of the details of the order. |
order_detail.order_idstring |
Order identifier. |
order_detail.coooking_timeinteger |
Cooking time estimated for the preparation of the order. |
order_detail.min_cooking_timeinteger |
Minimum cooking time in minutes set for this order. |
order_detail.max_cooking_timeinteger |
Maximum cooking time in minutes set for this order. |
order_detail.created_atstring |
Creation date of the order. |
order_detail.delivery_methodstring, enumerable |
Delivery method set for this order. Options available: delivery,marketplace, pickup. |
order_detail.payment_methodstring, enumerable |
Payment method set for this order. Options available: rappi_pay, cc, cash, paypal, edenred, webpay, masterpass, dc, pos_terminal, elo, sodexo, vale_r, ticket_r, alelo, visa_checkout,google_pay, apple_pay, rappicorp, PSE, PIX, unknown. |
order_detail.delivery_informationobject |
Properties of the delivery information. |
order_detail.delivery_information.citystring |
City of the delivery address. |
order_detail.delivery_information.complete_addressstring |
Delivery address with all the fields |
order_detail.delivery_information.street_numberstring |
Number of the street. |
order_detail.delivery_information.neighborhoodstring |
Neighborhood of the address. |
order_detail.delivery_information.complementstring |
Additional information of the address. |
order_detail.delivery_information.postal_codestring |
Postal code of the address |
order_detail.delivery_information.street_namestring |
Street name of the address. |
order_detail.billing_informationarray of objects |
Properties of the billing information. |
order_detail.billing_information.addressstring |
Delivery address set for this order. |
order_detail.billing_information.billing_typestring |
Billing type set for this order. |
order_detail.billing_information.document_numberstring |
Document number of the customer. |
order_detail.billing_information.document_typestring |
Document type of the customer. |
order_detail.billing_information.emailstring |
Email set to receive billing information. |
order_detail.billing_information.namestring |
Name set for the billing information. |
order_detail.billing_information.phonestring |
Phone number set for the billing information. |
order_detail.totalsarray of objects |
Properties of the totals of the order. |
order_detail.totals.total_productsinteger |
Total products without discounts. |
order_detail.totals.total_discountsinteger |
Total products without discount in the order. |
order_detail.totals.total_orderinteger |
The total amount that the restaurant receives. When the delivery method is marketplace this field includes tip and delivery fee.For other delivery methods, this field contains only the total value of all products. In all cases, this field includes the discounts assumed by the restaurant. |
order_detail.totals.total_discount_by_partnerinteger |
The total amount in currency of discounts assumed by the partner. |
order_detail.totals.total_to_payinteger |
Total that the user pays in cash to the courier. Only applies when the delivery method is marketplace or pickup, and the payment method is cash. |
order_detail.totals.discount_by_supportinteger |
Discount applied to the customer by the Rappi support team. |
order_detail.totals.chargesarray of objects |
Properties of the order additional charges. |
order_detail.totals.charges.shippinginteger |
Shipping charges total. |
order_detail.totals.charges.service_feeinteger |
Rappi service fee charges |
order_detail.totals.other_totalsarray of objects |
Other charges included in this order. |
order_detail.totals.other_totals.tipinteger |
Tip for the courier. |
order_detail.totals.other_totals.total_rappi_payinteger |
Total paid using Rappi Pay. |
order_detail.totals.othet_totals.total_rappi_creditsinteger |
Total paid using Rappi Credits. |
order_detail.itemsarray of objects |
Properties of the items the order contains. |
order_detail.items.skustring |
SKU for the item in the order. The ally grants their own SKU to the item. |
order_detail.items.idstring |
Identifier of the item in the order. |
order_detail.items.namestring |
Name of the item in the order. |
order_detail.items.typestring, enumerable |
Type of the item. Options available: product, or topping. |
order_detail.items.commentsarray |
User comments for the items in the order. |
order_detail.items.priceinteger |
Unit price for the item without the discount. |
order_detail.items.percentage_discountinteger |
Discount percentage of the item in the order. |
order_detail.items.quantityinteger |
Quantity specified for this item in the order. |
order_detail.items.subitemsarray of objects |
Properties of subitems in the order. |
order_detail.items.subitems.skustring |
SKU for the subitem in the menu. The ally grants their own SKU to the item. |
order_detail.items.subitems.idstring |
The identifier that Rappi grants the item. |
order_detail.items.subitems.namestring |
Name of the subitem in the order. |
order_detail.items.subitems.typestring, enumerable |
Type of the subitem in the order. Options available: product, or topping. |
order_detail.items.subitems.priceinteger |
Unit price for the subitem without the discount. |
order_detail.items.subitems.pencentage_discountinteger |
Discount percentage of the subitem in the order. |
order_detail.items.subitems.quantityinteger |
Quantity specified for this subitem in the order. |
order_detail.delivery_discountinteger |
Properties of the discounts in the delivery of the order. |
order_detail.delivery_discount.total_percentage_discountinteger |
Discount percentage in the delivery of the order. |
order_detail.delivery_discount.total_value_discountinteger |
Total amount of the delivery discount. |
order_detail.customerarray of objects |
Properties of the Rappi user that places the order. Only sent when delivery method is marketplace or if you request Rappi to receive this data. |
order_detail.customer.first_namestring |
First name of the Rappi user that places the order. |
order_detail.customer.last_namestring |
Last name of the Rappi user that places the order. |
order_detail.customer.phone_numberstring |
Phone number of the Rappi user that places the order. |
order_detail.customer.document_numberstring |
Document number of the Rappi user that places the order. |
order_detail.customer.user_typestring |
If the user is VIP the value is USER_VIP. For other users this field is not sent. |
order_detail.storearray of objects |
Properties of the store that prepares the order. |
order_detail.store.internal_idstring |
Internal identifier that Rappi grants the store. |
order_detail.store.external_idstring |
Integration identifier of the store. |
order_detail.store.namestring |
Name of the store that prepares the order. |
order_detail.discounts.valueinteger |
Discount value in currency. |
order_detail.discounts.descriptionstring |
Descriptive message explaining the discount. |
order_detail.discounts.titlestring |
Discount name. |
order_detail.discounts.product_idinteger |
Product ID if the discount applies product. |
order_detail.discounts.skustring |
SKU of the product if the discount applies product. |
order_detail.discounts.typestring |
Indicates the discount type. |
order_detail.discounts.raw_valueinteger |
The discount value can represent a percentage or a currency value depending on the type_value. |
order_detail.discounts.value_typestring, enumerable |
The value type of the discount. Available options: value, percentage. |
order_detail.discounts.max_valueinteger |
Maximum value in currency to be discounted. |
order_detail.discounts.includes_toppingsboolean |
Indicates if the discount is subtracted from the product total with toppings or not. |
order_detail.discounts.percentage_by_rappiinteger |
The percentage of the discount assumed by Rappi. |
order_detail.discounts.percentage_by_partnersinteger |
The percentage of the discount assumed by the partner. |
order_detail.discounts.amount_by_rappiinteger |
Value of the discount in currency assumed by Rappi. |
order_detail.discounts.amount_by_partnerinteger |
Value of the discount in currency assumed by the partner. |
order_detail.discounts.discount_product_unitsinteger |
Number of products to which the discount was applied. |
order_detail.discounts.discount_product_unit_valueinteger |
Discount value per product unit. |
PUT orders/{orderId}/take/{cookingTime}
Use this endpoint to take an order, so the store commences preparing it.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders/{orderId}/take/{cookingTime}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{orderId}: This is the identifier of the order.{cookingTime}: This is the new cooking time of the order. You can leave this field empty to keep the default cooking time of the order.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Order successfully taken
400
Invalid state transition
401
Invalid credentials
404
Order not found
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/take/20
this is an example of the request:
final Integer orderId = 392625;
final Integer cookingTime = 20;
URL url = new URL(
String.format("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/%s/take/%s", orderId, cookingTime)
);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders/392625/take/20',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/take/20"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/take/20"
method := "PUT"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This endpoint returns a status response code only.
PUT orders/{orderId}/reject
Use this endpoint to reject an order.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders/{orderId}/reject
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{orderId}: This is the identifier of the order.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
| Name | Requirement | Description |
|---|---|---|
orderIdstring |
required |
Rejects a specific order. |
items_idsarray of string |
optional |
List of offending items ids. Here you should use the rappi ids |
items_skusarray of string |
optional |
List of offending items skus. Here you should use your skus |
cancel_typestring enumerable |
optional |
Enum: "ITEM_WRONG_PRICE", "ITEM_NOT_FOUND", "ITEM_OUT_OF_STOCK", "ORDER_MISSING_INFORMATION", "ORDER_MISSING_ADDRESS_INFORMATION", "ORDER_TOTAL_INCORRECT" |
Status Codes
These are the possible status codes of the response for this endpoint:
200
Order successfully rejected
400
Invalid state transition
401
Invalid credentials
404
Order not found
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/reject
This is an example of the request:
{
"reason":"The order has invalid items"
}
This is an example of the request with offending items:
{
"reason":"The order has invalid items",
"cancel_type": "ITEM_NOT_FOUND",
"items_skus": ["sku1", "sku2"]
}
final Integer orderId = 3320025;
URL url = new URL(
String.format("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/%s/reject", orderId)
);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\"reason\":\"The order has invalid items\"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders/392625/reject',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({"reason":"The order has invalid items"});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/reject"
payload = "{\"reason\":\"The order has invalid items\"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/reject"
method := "PUT"
payload := strings.NewReader("{\"reason\":\"The order has invalid items\"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
reasonstring |
required |
Reason to reject the order |
Sample Response
This endpoint returns a status response code only.
POST orders/{orderId}/ready-for-pickup
Use this endpoint to notify the user in the Rappi application that the order is ready for pickup.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders/{orderId}/ready-for-pickup
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{orderId}: This is the identifier of your order.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Order successfully updated
400
Invalid state transition
401
Invalid credentials
404
Order not found
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/ready-for-pickup
This is an example of the request:
final Integer orderId = 392625;
URL url = new URL(
String.format(
"https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/%s/ready-for-pickup",
orderId));
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders/392625/ready-for-pickup',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/ready-for-pickup"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/ready-for-pickup"
method := "POST"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This endpoint returns a status response code only.
GET orders/{orderId}/events
Use this endpoint to retrieve the latest status updates from your orders.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/orders/{orderId}/events
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{orderId}: This is the identifier of your order.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/events
This is an example of the request:
final Integer orderId = 392625;
URL url = new URL(
String.format(
"https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/%s/events",
orderId));
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/orders/392625/events',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/events"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/orders/392625/events"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid credentials
404
Order not found
Sample Response
This is an example of the response:
[
{
"event":"canceled_with_charge",
"event_time":"2020-05-28T12:31:12.501Z",
"additional_information":{
}
},
{
"event":"taken_visible_order",
"event_time":"2020-05-28T12:30:12.501Z",
"additional_information":{
}
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Latest order event. |
event_timestring |
Time of the event. Format: yyyy-MM-dd'T'HH:mm:ss.SSS'Z'. |
additional_informationarray of objects |
Additional information for the order. The format can vary depending on the event. |
Stores
The Stores resource enables you to interact with your stores.
The following table describes the different contents of the Stores resource:
| API Resource | Endpoint | Endpoint Description |
|---|---|---|
GET stores-pa |
Returns the list of stores for the authenticated client | |
PUT stores-pa/{storeId}/status |
Update a store to integrated or not integrated |
GET stores-pa
Use this endpoint to retrieve the stores of an authenticating ally.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/stores-pa
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid credentials
404
App Client not found
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/stores-pa',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response "Success 200"
This is an example of the response "Success 200":
[
{
"integrationId":"111",
"rappiId":"890982",
"name":"Store 1"
},
{
"integrationId":"222",
"rappiId":"890983",
"name":"Store 2"
},
{
"integrationId":"333",
"rappiId":"890983",
"name":"Store 3"
}
]
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
integrationIdstring |
Identifier of the store in the Rappi application |
rappiIdstring |
Identifier that Rappi granted the ally |
namestring |
Name of the store in the Rappi application |
Sample Response "Invalid credentials 401"
This is an example of the response "Invalid credentials 401":
{
"message": "Not a valid token"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
Sample Response "App Client no encontrado 404"
This is an example of the response "App Client no encontrado 404":
{
"message": "Not found appClient of client id {clientId}"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
PUT store-pa integrated status
Use this endpoint to change a store to integrated or to not integrated
URL del Endpoint
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/stores-pa/{storeId}/status
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint has the following parameters:
| Parameter | Description |
|---|---|
{storeId} |
Path Param. Store Id from rappi |
{integrated} |
Query Param. To indicate whether the store is changed to "integrated" (true) o "not integrated" (false) |
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid credentials
404
App Client not found
400
Error while updating the store
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa/12345/status?integrated=true
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa/12345/status?integrated=true");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/stores-pa/12345/status?integrated=true',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa/12345/status?integrated=true"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/stores-pa/12345/status?integrated=true"
method := "PUT"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response "Success 200"
This is an example of the response "Success 200" when updating a store to "integrated"
{
"message":"The store {storeid} was changed to integrated {true} successfully."
}
This is an example of the response "Success 200" when updating a store to "not integrated"
{
"message":"The store {storeid} was changed to integrated {false} successfully. Please remember to login into the partners app and set the AUTO ACCEPT config"
}
This table describes the objects contained in the response example:
| Objeto | Descripción |
|---|---|
messagestring |
Mensaje con la información del cambio realizado |
Sample Response "Invalid credentials 401"
This is an example of the response "Invalid credentials 401":
{
"message": "Not a valid token"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
Sample Response "App Client no encontrado 404"
This is an example of the response "App Client no encontrado 404":
{
"message": "Not found appClient of client id {clientId}"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
Sample Response "Error while updating the store 400"
This is an example of the response "Error while updating the store 400":
{
"message": "There was an error trying to change the store {storeId} to integrated: {true|false}. Please contact support team"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
GET store current menu
Use this endpoint to retrieve the menu from the stores.
URL del Endpoint
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/store/{STORE_ID}/menu/current
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
{STORE_ID}: This is the store id from Rappi.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid credentials
404
App Client not found
400
Store not found in App Client
Sample Request
This is an example of an API request using this endpoint:
GET https://internal-microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/store/900111941/menu/current
This is an example of the request:
URL url = new URL("http://internal-microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/store/YOU_STORE/menu/current");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/store/YOU_STORE/menu/current',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/store/YOU_STORE/menu/current"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/store/YOU_STORE/menu/current"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response "Success 200"
This is an example of the response "Success 200":
[
{
"storeId":"900111941",
"products":[
{
"id":"2135501578",
"name":"2 por 19,90",
"price":52.9,
"partnerSku":null,
"active":null,
"toppings":[
{
"id":"340825698",
"name":"Batata Grande",
"price":6.9,
"partnerSku":null,
"active":null,
"category":{
"id":"1247164425",
"name":"Deseja Acompanhamento?"
}
},
{
"id":"340825699",
"name":"Pepsi 350ml",
"price":6.9,
"partnerSku":null,
"active":null,
"category":{
"id":"1247164426",
"name":"Deseja Bebida?"
}
}
]
},
{
"id":"2135501683",
"name":"4 Sanduíches por R$ 29,80!",
"price":43.6,
"partnerSku":null,
"active":null,
"toppings":[
{
"id":"340827238",
"name":"Rodeio",
"price":0,
"partnerSku":null,
"active":null,
"category":{
"id":"1247164714",
"name":"Escolha seu 1º sanduíche:"
}
}
]
}
]
}
]
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
storeIdstring |
Rappi Id from the Store |
productsarray of objects |
List of products |
products.idstring |
Rappi Id from toppings |
products.namestring |
Product name |
products.priceinteger |
Product price |
products.toppingsarray of objects |
List of toppings |
products.toppings.idstring |
Rappi Id from the topping |
products.toppings.namestring |
Topping name |
products.toppings.priceinteger |
Topping price |
products.toppings.categoryobjects |
Topping category |
products.toppings.category.idstring |
Rappi Id from Topping Category |
products.toppings.category.namestring |
Topping Category name |
Sample Response "Invalid credentials 401"
This is sample response "Invalid credentials 401":
{
"message": "Not a valid token"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Mensaje descriptivo del error |
Sample Response "App Client not found 404"
This is sample response "App Client no encontrado 404":
{
"message": "Not found appClient of client id {clientId}"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Mensaje descriptivo del error |
Sample Response "Store not found in App Client 400"
This is sample response "Store not found in App Client 400":
{
"message": "The stores {storeId} don't belong to the appClient of client id {clientId}"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Mensaje descriptivo del error |
Availability
The Availability resource enables you to interact with the availability options of your items and stores.
The following table describes the different contents of the Availability resource:
| Resource | Description |
|---|---|
POST availability/items/status |
Returns the availability of items by Item SKU. |
POST availability/items/rappi/status |
Returns the availability of items by Item ID. |
PUT availability/stores/items |
Manage item availability in the application by Item SKU. |
PUT availability/stores/items/rappi |
Manage item availability in the application by Item ID. |
PUT availability/stores |
Manage store availability asynchronously in the application. |
PUT availability/stores/enable/massive |
Manage store availability asynchronously in the application. |
PUT availability/stores/enable |
Manage store availability synchronously in the application. |
POST availability/items/status
Use this endpoint to check the availability options of your items by SKU in your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Error updating items
404
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/status
This is an example of the request:
{
"store_id":"900144512",
"item_ids":[
"7713",
"2668",
"3395",
"5685"
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/status");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"store_id\":\"900144512\",\n" +
" \"item_ids\":[\n" +
" \"7713\",\n" +
" \"2668\",\n" +
" \"3395\",\n" +
" \"5685\"\n" +
" ],\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/items/status',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify(
{
"store_id":"900144512",
"item_ids": [
"7713",
"2668",
"3395",
"5685"
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items"
payload ="{\n" \
" \"store_id\":\"900144512\",\n" \
" \"item_ids\":[\n" \
" \"7713\",\n" \
" \"2668\",\n" \
" \"3395\",\n" \
" \"5685\"\n" \
" ],\n" \
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/status"
method := "POST"
payload := strings.NewReader("{\n" +
" \"store_id\":\"900144512\",\n" +
" \"item_ids\":[\n" +
" \"7713\",\n" +
" \"2668\",\n" +
" \"3395\",\n" +
" \"5685\"\n" +
" ],\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
store_idstring |
required |
Identifier of the store. |
item_idsarray of strings |
required |
List of the SKUs of the articles to consult. |
Sample Response
This is an example 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"
}
]
This table describes the objects within the sample response::
| Object in response | Description |
|---|---|
item_idinteger |
Identifier of the item. |
item_typestring |
Type of product in the menu. |
stock_out_statestring |
Indicates product availability. |
These are the possible responses for the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
PUT availability/stores/items
Use this endpoint to configure the availability options of your items by SKU in your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/availability/stores/items
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Error updating items
404
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items
This is an example of the request:
[
{
"store_integration_id":"999",
"items":{
"turn_on":[
"1111",
"2222",
"3333"
],
"turn_off":[
"5555"
]
}
}
]
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "[\n" +
" {\n" +
" \"store_integration_id\":\"999\",\n" +
" \"items\":{\n" +
" \"turn_on\":[\n" +
" \"1111\",\n" +
" \"2222\",\n" +
" \"3333\"\n" +
" ],\n" +
" \"turn_off\":[\n" +
" \"5555\"\n" +
" ]\n" +
" }\n" +
" }\n" +
"]";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/stores/items',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify(
[
{
"store_integration_id":"999",
"items": {
"turn_on": [
"1111",
"2222",
"3333"
],
"turn_off": [
"5555"
]
}
}
]);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items"
payload = "[\n" \
" {\n" \
" \"store_integration_id\":\"999\",\n" \
" \"items\":{\n" \
" \"turn_on\":[ " \
" \"1111\", " \
" \"2222\", " \
" \"3333\" " \
" ],\n" \
" \"turn_off\":[ " \
" \"5555\" " \
" ]\n" \
" }\n" \
" }\n" \
"]"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items"
method := "PUT"
payload := strings.NewReader("[\n" +
" {\n" +
" \"store_integration_id\":\"999\",\n" +
" \"items\":{\n" +
" \"turn_on\":[\n" +
" \"1111\",\n" +
" \"2222\",\n" +
" \"3333\"\n" +
" ],\n" +
" \"turn_off\":[\n" +
" \"5555\"\n" +
" ]\n" +
" }\n" +
" }\n" +
"]")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
store_integration_idstring |
required |
Identifier of the store integration. |
itemsarray of objects |
required |
Properties of the items you configure. |
items.turn_onstring |
optional |
SKU of the item to turn on. |
items.turn_offstring |
optional |
SKU of the item to turn off. |
Sample Response
This is an example of the response with an error message:
[
{
"message":"Error updating items"
}
]
These are the possible responses for the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
POST availability/items/rappi/status
Use this endpoint to check the availability options of your items by ID in your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Error updating items
404
Invalid Credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/rappi/status
This is an example of the request:
{
"store_id":"900144512",
"item_ids":[
"2136411304"
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/rappi/status");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"store_id\":\"900144512\",\n" +
" \"item_ids\":[\n" +
" \"2136411304\"\n" +
" ],\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/items/rappi/status',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify(
{
"store_id":"900144512",
"item_ids": [
"2136411304"
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/rappi/status"
payload ="{\n" \
" \"store_id\":\"900144512\",\n" \
" \"item_ids\":[\n" \
" \"2136411304\"\n" \
" ],\n" \
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/items/rappi/status"
method := "POST"
payload := strings.NewReader("{\n" +
" \"store_id\":\"900144512\",\n" +
" \"item_ids\":[\n" +
" \"2136411304\"\n" +
" ],\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
store_idstring |
required |
Identifier of the store. |
item_idsarray of strings |
required |
List of the IDs of the articles to consult. |
Sample Response
This is an example of the response:
[
{
"item_id": 2136411304,
"item_type": "PRODUCT",
"stock_out_state": "AVAILABLE"
}
]
This table describes the objects within the sample response::
| Object in response | Description |
|---|---|
item_idinteger |
Identifier of the item. |
item_typestring |
Type of product in the menu. |
stock_out_statestring |
Indicates product availability. |
These are the possible responses for the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
PUT availability/stores/items/rappi
Use this endpoint to configure the availability options of your items by Rappi ID in your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Items successfully updated
401
Error updating items
404
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi
This is an example of the request:
[
{
"store_integration_id":"999",
"items":{
"turn_on":[
1111,
2222,
3333
],
"turn_off":[
5555
]
}
}
]
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "[\n" +
" {\n" +
" \"store_integration_id\":\"999\",\n" +
" \"items\":{\n" +
" \"turn_on\":[\n" +
" 1111,\n" +
" 2222,\n" +
" 3333\n" +
" ],\n" +
" \"turn_off\":[\n" +
" 5555\n" +
" ]\n" +
" }\n" +
" }\n" +
"]";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify(
[
{
"store_integration_id":"999",
"items": {
"turn_on": [
1111,
2222,
3333
],
"turn_off": [
5555
]
}
}
]);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi"
payload = "[\n" \
" {\n" \
" \"store_integration_id\":\"999\",\n" \
" \"items\":{\n" \
" \"turn_on\":[ " \
" 1111, " \
" 2222, " \
" 3333 " \
" ],\n" \
" \"turn_off\":[\n" \
" 5555\n" \
" ]\n" \
" }\n" \
" }\n" \
"]"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/items/rappi"
method := "PUT"
payload := strings.NewReader("[\n" +
" {\n" +
" \"store_integration_id\":\"999\",\n" +
" \"items\":{\n" +
" \"turn_on\":[\n" +
" 1111,\n" +
" 2222,\n" +
" 3333\n" +
" ],\n" +
" \"turn_off\":[\n" +
" 5555\n" +
" ]\n" +
" }\n" +
" }\n" +
"]")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
store_integration_idstring |
required |
Identifier of the store integration. |
itemsarray of objects |
required |
Properties of the items you configure. |
items.turn_oninteger |
optional |
Rappi ID of the item to turn on. |
items.turn_offinteger |
optional |
Rappi ID the item to turn off. |
Sample Response
This is an example of the response with an error message:
{
"message": "Error message"
}
These are the possible responses for the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
PUT availability/stores
Use this endpoint to configure the availability options of your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Stores successfully updated
401
Error updating stores
404
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores
This is an example of the request:
{
"turn_on":[
"2222"
],
"turn_off":[
"333",
"444"
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"turn_on\":[\n" +
" \"2222\"\n" +
" ],\n" +
" \"turn_off\":[\n" +
" \"333\",\n" +
" \"444\"\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/stores/items',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"turn_on":[
"2222"
],
"turn_off":[
"333",
"444"
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores"
payload = "{\n" \
" \"turn_on\":[\n" \
" \"2222\"\n" \
" ],\n" \
" \"turn_off\":[\n" \
" \"333\",\n" \
" \"444\"\n" \
" ]\n" \
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores"
method := "PUT"
payload := strings.NewReader("{\n" +
" \"turn_on\":[\n" +
" \"2222\"\n" +
" ],\n" +
" \"turn_off\":[\n" +
" \"333\",\n" +
" \"444\"\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
turn_oninteger |
optional |
List of store IDs to turn on. |
turn_offinteger |
optional |
List of store IDs to turn off. |
Sample Response
This is an example of the response with an error message:
{
"message":"Error message"
}
These are the possible responses to the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
PUT availability/stores/enable/massive
Use this endpoint to configure the availability options of your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Stores successfully updated
400
Error updating stores
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable/massive
This is an example of the request:
{
"stores": [
{
"store_id": "12312",
"is_enabled": true
},
{
"store_id": "12312",
"is_enabled": false
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable/massive");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = = "{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/stores//enable/massive',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({"stores": [
{
"store_id": "12312",
"is_enabled": true
},
{
"store_id": "12312",
"is_enabled": false
}]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable/massive"
payload = = "{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable/massive"
method := "PUT"
payload := strings.NewReader("{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
storesarray of objects |
required |
List of store's data |
stores.store_idstring |
required |
id of the store (rappi side) that will change the status |
stores.is_enabledboolean |
required |
true to turn on the store, otherwise false |
Sample Response
This is an example of the response with an error message:
{
"message":"Error message"
}
These are the possible responses to the request:
- If the request succeeds, the endpoint returns a Success response code.
- If the request fails, the endpoint returns an Error response code with an error message in a
JSON.
PUT availability/stores/enable
Use this endpoint to configure the availability options of your stores synchronously
Endpoint URL
Use this URL to make a request with this endpoint:
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.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response to this endpoint:
200
Stores updated successfully
400
Bad Request
403
You are not allowed to update those stores
422
Amount of stores exceeded
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable
This is an example of the request:
{
"stores": [
{
"store_id": "12312",
"is_enabled": true
},
{
"store_id": "12312",
"is_enabled": false
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = = "{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/availability/stores/enable',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({"stores": [
{
"store_id": "12312",
"is_enabled": true
},
{
"store_id": "12312",
"is_enabled": false
}]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable"
payload = = "{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/availability/stores/enable"
method := "PUT"
payload := strings.NewReader("{\n"
+ " \"stores\": [\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": true\n"
+ " },\n"
+ " {\n"
+ " \"store_id\": \"12312\",\n"
+ " \"is_enabled\": false\n"
+ " }\n"
+ " ]\n"
+ "}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
storesarray of objects |
required |
List of store's data |
stores.store_idstring |
required |
id of the store (your side) that will change the status |
stores.is_enabledboolean |
required |
true to turn on the store, otherwise false |
Sample Response
This is an example of a successful response:
{
"results":[
{
"store_id": 90774,
"is_enabled": true,
"operation_result": true,
"operation_result_type": "SUCCESS",
"operation_result_message": "success",
"suspended_reason": null,
"suspended_at": null,
"suspended_time": 0
},
{
"store_id": 90775,
"is_enabled": false,
"operation_result": false,
"operation_result_type": "SUSPENDED",
"operation_result_message": "suspended",
"suspended_reason": "suspended due to cancelled orders",
"suspended_at": "2022-04-11T20:23:00.00Z",
"suspended_time": 60
}
]
}
This is an example of an error response:
{
"message": "It has been sent more than 300 stores and cannot be processed, please use the asynchronous service"
}
This table describes the attributes that the JSON of the response contains:
| Response Object | Object Description |
|---|---|
resultsarray of objects |
Result list |
results.store_idint |
Store id. |
results.is_enabledboolean |
Current store status |
results.operation_resultboolean |
true if the operation has been finished successfully, otherwise false. |
results.operation_result_typestring |
Possible values: SUCCESS, SUSPENDED, FORBIDDEN, STORE_NOT_PUBLISHED, STORE_ALREADY_IN_STATUS, ERROR_EXTERNAL_SERVICE |
results.operation_result_messagestring |
Result type description |
results.suspended_reasonstring |
If the store has been suspended, the reason will be here |
results.suspended_atdate |
Date since the store has been suspended |
results.suspended_timeint |
Time in minutes that indicates for how long the store will be suspended |
Meaning of the different operation_result_type values
STORE_NOT_PUBLISHED: the store is not currently showing on the appSUSPENDED: the store has been suspended and it is not possible to turn it onERROR_EXTERNAL_SERVICE: there was an error trying to change the store statusSTORE_ALREADY_IN_STATUS: the store is already in the status you are trying to change toFORBIDDEN: the authenticated client_id is not allowed to change the status for the specified storeSUCCESS: the store was updated successfully
Webhooks
Use the webhooks resource to manage the webhooks configured in your stores.
The following table describes the different contents of the Webhooks resource:
| API Resource | Endpoint | Endpoint Description |
|---|---|---|
GET webhook/{event} |
Returns the webhooks configured for all the stores of the authenticated client | |
PUT webhook/{event}/add-stores |
Add stores to a specific webhook event | |
PUT webhook/{event}/change-url |
Change url from stores | |
POST webhook |
Creates a new webhook for a list of stores for the authenticated client | |
DELETE webhook/{event}/remove-stores |
Deletes stores from your webhook | |
PUT webhook/{event}/reset-secret |
Restarts the secret and generates a new one for the authenticated client | |
PUT webhook/{event}/change-status |
Enables or disables the webhooks for a list of stores |
GET webhook
Use this endpoint to retrieve the webhooks configured for your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{EVENT}
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
| Parameter | Requirement | Description |
|---|---|---|
eventstring |
optional |
Returns only the details from a specific event |
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
401
Invalid Credentials
406
Invalid event
Sample Response
This is an example of the response:
[
{
"event": "event_1",
"stores": [
{
"store_id": "1000",
"url": "http://testUrl/one",
"state": "ENABLE"
},
{
"store_id": "10001",
"url": "http://testUrl/one",
"state": "ENABLE"
}
]
},
{
"event": "event_2",
"stores": [
{
"store_id": "1000",
"url": "http://testUrl/one",
"state": "ENABLE"
}
]
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Stores |
List of the stores where the event triggers. |
store_idstring |
Store id where the event triggers |
urlstring |
URL to which the webhook communicates. |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
PUT webhook Add Stores
Use this endpoint to add stores to the webhook event specified.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{event}/add-stores
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
| Parameter | Requirement | Description |
|---|---|---|
eventstring |
required |
The event name to update |
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
404
The list of stores are invalid for the authenticated client
401
Invalid credentials
406
Invalid event
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/add-stores
This is an example of the request:
[
{
"url":"http://testDomain/webhook/data",
"stores":[
"1000",
"1001"
]
}
]
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/add-stores");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "[{\n" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
"}]";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/add-stores',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify([{
"url":"http://testDomain/webhook/data",
"stores":[
"1000",
"1001"
]
}]);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/add-stores"
payload = "[{\n" \
" \"url\":\"http://testDomain/webhook/data\",\n" \
" \"stores\":[\n" \
" \"1000\",\n" \
" \"1001\"\n" \
" ]\n" \
"}]"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/add-stores"
method := "PUT"
payload := strings.NewReader("[{\n" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
"}]")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
urlstring |
required |
URL to which the webhook communicates. |
storesarray of strings |
required |
List of the stores where the event triggers. |
Sample Response
This is an example of the response:
{
"event":"NEW_ORDER",
"stores":[{
"store_id": "1000",
"url":"http://testDomain/webhook/data",
"state": "ENABLE"
}]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Stores |
List of the stores where the event triggers. |
store_idstring |
Store id where the event triggers |
urlstring |
URL to which the webhook communicates. |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
PUT webhook Change Url
Use this endpoint to update the url of the webhook event specified.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{event}/change-url
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
| Parameter | Requirement | Description |
|---|---|---|
eventstring |
required |
The event name to update |
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
404
The list of stores are invalid for the authenticated client
401
Invalid credentials
406
Invalid event
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-url
This is an example of the request:
{
"url":"http://testDomain/webhook/data",
"stores":[
"1000",
"1001"
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-url");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-url',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"url":"http://testDomain/webhook/data",
"stores":[
"1000",
"1001"
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-url"
payload = "{\n" \
" \"url\":\"http://testDomain/webhook/data\",\n" \
" \"stores\":[\n" \
" \"1000\",\n" \
" \"1001\"\n" \
" ]\n" \
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-url"
method := "PUT"
payload := strings.NewReader("{\n" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
urlstring |
required |
URL to which the webhook communicates. |
storesarray of strings |
required |
List of the stores where the event triggers. |
Sample Response
This is an example of the response:
{
"event":"NEW_ORDER",
"stores":[{
"store_id": "1000",
"url":"http://testDomain/webhook/data",
"state": "ENABLE"
}]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Stores |
List of the stores where the event triggers. |
store_idstring |
Store id where the event triggers |
urlstring |
URL to which the webhook communicates. |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
POST webhook
Use this endpoint to create a webhook for your stores.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
404
The list of stores are invalid for the authenticated client
401
Invalid credentials
406
Invalid event
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook
This is an example of the request:
{
"event": "test_event",
"data": [
{
"url": "http://testDomain/webhook/data",
"stores": [
"1000",
"1001"
]
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"event\":\"test_event\",\n" +
" \"data\": [ {" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
" } ]" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"event":"test_event",
"data": [ {
"url":"http://testDomain/webhook/data",
"stores":[
"1000",
"1001"
]
}
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook"
payload = "{\n" +
" \"event\":\"test_event\",\n" +
" \"data\": [ {" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
" } ]" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook"
method := "POST"
payload := strings.NewReader("{\n" +
" \"event\":\"test_event\",\n" +
" \"data\": [ {" +
" \"url\":\"http://testDomain/webhook/data\",\n" +
" \"stores\":[\n" +
" \"1000\",\n" +
" \"1001\"\n" +
" ]\n" +
" } ]" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
eventstring |
required |
Event that triggers the webhook. |
urlstring |
required |
URL to which the webhook communicates. |
dataarray of Object |
required |
Contains the attributes to configure |
storesarray of strings |
optional |
List of the stores where the event triggers. If you don't send this attribute, the API takes all the stores of the authenticated user. |
Sample Response
This is an example of the response:
{
"event":"test_1",
"stores":[ {
"url":"https://localhost:8080/test",
"store_id": "1000",
"state": "ENABLE"
},
{
"url":"https://localhost:8080/test",
"store_id": "1001",
"state": "ENABLE"
}
],
"secret":"TEST_SECRET"
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Store |
List of the stores where the event triggers |
urlstring |
URL to which the webhook communicates. |
store_idstring |
Store id where the event triggers |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
secretstring |
Secret key to create the security signature for every webhook event post. |
DELETE webhook
Use this endpoint to delete a store from your webhook.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{EVENT}/remove-stores
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
| Parameter | Requirement | Description |
|---|---|---|
eventstring |
required |
The event name to update |
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
401
Invalid credentials
404
The list of stores are invalid for the authenticated client
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/remove-stores
This is an example of the request:
{
"stores":[
"1000"
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/remove-stores");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"stores\":[\n" +
" \"1000\"\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/remove-stores',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"stores":[
"1000"
]
});
req.setHeader('Content-Length', postData.length);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/remove-stores"
payload = "{\n" \
" \"stores\":[\n" \
" \"1000\"\n" \
" ]\n" \
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/remove-stores"
method := "DELETE"
payload := strings.NewReader("{\n" +
" \"stores\":[\n" +
" \"1000\"\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
storesarray of strings |
required |
List of the stores to delete the webhook from |
Sample Response
This is an example of the response:
{
"stores":[
"1000"
],
"message":"Store settings removed successfully."
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
storesarray of strings |
List of the stores where the event triggers. |
messagestring |
Output message of the request. |
PUT webhook reset secret
Use this endpoint to reset the secret, and create a new one for the authenticated ally.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{EVENT}/reset-secret
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
| Parameter | Requirement | Description |
|---|---|---|
eventstring |
required |
The webhook event name to update |
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
401
Invalid credentials
406
Invalid event
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/reset-secret
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/reset-secret");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/reset-secret',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/reset-secret"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"io/ioutil"
"net/http"
"strings"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/reset-secret"
method := "PUT"
client := &http.Client{
}
req, err := http.NewRequest(method, url)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"event": "NEW_ORDER",
"stores":[ {
"store_id": "1000",
"url": "http://localhost",
"state": "ENABLE"
}
],
"secret":"NEW_SECRET"
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Stores |
List of the stores where the event triggers. |
store_idstring |
Store id where the event triggers |
urlstring |
URL to which the webhook communicates. |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
secretstring |
New secret key to use when creating the security signature for a webhook event post. |
PUT webhook change status
Use this endpoint to change the availability state of a configured webhook.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/v2/restaurants-integrations-public-api/webhook/{EVENT}/change-status
{COUNTRY_DOMAIN}: This is your Rappi country domain. See the list of country domains.{EVENT}: This is the name of the event See the list of valid webhook events.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
401
Invalid credentials
404
The list of stores are invalid for the authenticated client
406
Invalid event
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-status
This is an example of the request:
{
"stores": {
"enable": [
"1001"
],
"disable": [
"1000"
]
}
}
URL url = new URL("https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-status");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\"stores\": {\"enable\": [\"1001\"],\"disable\": [\"1000\" ] } }";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-status',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"stores":{
"enable": [
"1001"
],
"disable": [
"1000"
]
}
});
req.setHeader('Content-Length', postData.length);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-status"
payload = "{\"stores\": {\"enable\": [\"1001\"],\"disable\": [\"1000\" ] } }"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/v2/restaurants-integrations-public-api/webhook/NEW_ORDER/change-status"
method := "PUT"
payload := strings.NewReader("{\"stores\": {\"enable\": [\"1001\"],\"disable\": [\"1000\" ] } }")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
storesObject |
required |
Object that contains the list of the stores to enable or disable |
enablearray of strings |
required |
List of the stores to enable |
disablearray of strings |
required |
List of the stores to disable |
Sample Response
This is an example of the response:
{
"event":"NEW_ORDER",
"stores":[ {
"store_id": "1001",
"url": "http://localhost",
"state": "ENABLE"
},
{
"store_id": "1000",
"url": "http://localhost",
"state": "ENABLE"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
eventstring |
Name of the event that triggers the webhook. |
storesarray of Stores |
List of the stores where the event triggers. |
store_idstring |
Store id where the event triggers |
urlstring |
URL to which the webhook communicates. |
statestring |
Status of the webhook. Options available: ENABLE or DISABLE |
Utils API v1.2.0
Utils API v1.2.0 includes all the resources, endpoints, and methods that assist you to manage your restaurant operation.
The following tables contains all the resources available to use with Utils API:
API Resource Corridor Schedules |
Endpoint Description |
|---|---|
GET corridor/store/{storeId} |
Returns the collection of corridors for the store |
GET corridor/schedule/{corridorId}/store/{storeId} |
Returns the corridor schedules configured for the store |
POST corridor/schedule/{corridorId}/store/{storeId} |
Create corridor schedules for the store |
PUT corridor/schedule/{corridorId}/store/{storeId} |
Update corridor schedules for the store |
DELETE corridor/schedule/{corridorId}/store/{storeId}/{corridorProductScheduleId} |
Delete corridor schedules for the store |
API Resource Corridor Schedules by Integration |
Endpoint Description |
|---|---|
GET corridor/integration/{integrationId} |
Returns the collection of corridors for the store |
GET corridor/schedule/{corridorId}/integration/{integrationId} |
Returns the corridor schedules configured for the store |
POST corridor/schedule/{corridorId}/integration/{integrationId} |
Create corridor schedules for the store |
PUT corridor/schedule/{corridorId}/integration/{integrationId} |
Update corridor schedules for the store |
DELETE corridor/schedule/{corridorId}/integration/{integrationId}/{corridorProductScheduleId} |
Delete corridor schedules for the store |
API Resource Product Schedules |
Endpoint Description |
|---|---|
GET product/corridor/{corridorId}/store/{storeId} |
Returns the collection of products for the corridor and store |
GET product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Returns the product schedules configured for the corridor and store |
POST product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Create product schedules for the corridor and store |
PUT product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Update product schedules for the corridor and store |
DELETE product/schedule/{productId}/corridor/{corridorId}/store/{storeId}/{corridorProductScheduleId} |
Delete product schedules for the corridor and store |
API Resource Product Schedules by SKU |
Endpoint Description |
|---|---|
GET sku/corridor/{corridorId}/integration/{integrationId} |
Returns the collection of products for the corridor and store |
GET sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Returns the product schedules configured for the corridor and store |
POST sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Create product schedules for the corridor and store |
PUT sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Update product schedules for the corridor and store |
DELETE sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}/{corridorProductScheduleId} |
Delete product schedules for the corridor and store |
Utils Getting Started
To start using the Utils API you must sign up as a Rappi ally. See details here Getting Started.
Once you receive your Rappi Credentials, you can create your Access Token with the POST token.
After generating your Access Token, you can start using the Utils API.
Utils Corridor Schedules By Store Id
Use the Utils resource to manage the Schedules configured in your stores.
The following table describes the different contents of the Schedules Utils resource:
| Resource | Description |
|---|---|
GET corridor/store/{storeId} |
Returns the collection of corridors for the store |
GET corridor/schedule/{corridorId}/store/{storeId} |
Returns the corridor schedules configured for the store |
POST corridor/schedule/{corridorId}/store/{storeId} |
Create corridor schedules for the store |
PUT corridor/schedule/{corridorId}/store/{storeId} |
Update corridor schedules for the store |
DELETE corridor/schedule/{corridorId}/store/{storeId}/{corridorProductScheduleId} |
Delete corridor schedules for the store |
GET corridor/store/{storeId}
Use this endpoint to retrieve the collections of corridors configured for your store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/store/{storeId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/store/999
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/store/999"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/store/999"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid Credentials
Sample Response
This is an example of the response:
[
{
"id": 123,
"name": "Bebidas Calientes",
"description": "Corredor Bebidas Calientes",
"storeId": 999
},
{
"id": 321,
"name": "Bebidas Frias",
"description": "Corredor Bebidas Frias",
"storeId": 999
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
idinteger |
Identifier of the corridor. |
namestring |
Name of the corridor. |
descriptionstring |
Description of the corridor . |
storeIdinteger |
Identifier of the store that contains the corridor. (The parent store identifier in case of child store request) |
GET corridor/schedule/{corridorId}/store/{storeId}
Use this endpoint to obtain corridor schedules configured for the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/schedule/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/store/999
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/321/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/store/999"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/store/999"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"corridor_id": 321,
"store_id": 999,
"schedule_details": [
{
"id": 1,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
POST corridor/schedule/{corridorId}/store/{storeId}
Use this endpoint to create schedules for your corridors in the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/schedule/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999
This is an example of the request:
{
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/123/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999"
method := "POST"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given corridor. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"id": 3,
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
PUT corridor/schedule/{corridorId}/store/{storeId}
Use this endpoint to update schedules for your corridors in the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/corridor/schedule/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999
This is an example of the request:
{
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/123/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999"
method := "PUT"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given corridor. |
schedule_details.idinteger |
required |
Identifier of the corridor schedule. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
DELETE corridor/schedule/{corridorId}/store/{storeId}/{corridorProductScheduleId}
Use this endpoint to delete schedules for your corridors in the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/corridor/schedule/{corridorId}/store/{storeId}/{corridorProductScheduleId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{corridorProductScheduleId}: This is the identifier of the corridor schedule.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999/2541
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999/2541");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/123/store/999/2541',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999/2541"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/store/999/2541"
method := "PUT"
client := &http.Client {
}
req, err := http.NewRequest(method, url)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of corridor schedules that are still available |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Utils Corridor Schedules By Integration Id
Use the Utils resource to manage the Schedules configured in your stores.
The following table describes the different contents of the Schedules Utils resource:
| Resource | Description |
|---|---|
GET corridor/integration/{integrationId} |
Returns the collection of corridors for the store |
GET corridor/schedule/{corridorId}/integration/{integrationId} |
Returns the corridor schedules configured for the store |
POST corridor/schedule/{corridorId}/integration/{integrationId} |
Create corridor schedules for the store |
PUT corridor/schedule/{corridorId}/integration/{integrationId} |
Update corridor schedules for the store |
GET corridor/integration/{integrationId}
Use this endpoint to retrieve the collections of corridors configured for your store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/integration/888
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/integration/888"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/integration/888"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid Credentials
Sample Response
This is an example of the response:
[
{
"id": 123,
"name": "Bebidas Calientes",
"description": "Corredor Bebidas Calientes",
"integrationId": "888"
},
{
"id": 321,
"name": "Bebidas Frias",
"description": "Corredor Bebidas Frias",
"integrationId": "888"
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
idinteger |
Identifier of the corridor. |
namestring |
Name of the corridor. |
descriptionstring |
Description of the corridor . |
integrationIdstring |
Identifier of the store that contains the corridor. (The parent store identifier in case of child store request) |
GET corridor/schedule/{corridorId}/integration/{integrationId}
Use this endpoint to obtain corridor schedules configured for the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/schedule/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/321/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"corridor_id": 321,
"integration_id": "888",
"schedule_details": [
{
"id": 1,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
integration_idstring |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
POST corridor/schedule/{corridorId}/integration/{integrationId}
Use this endpoint to create schedules for your corridors in the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/schedule/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888
This is an example of the request:
{
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888"
method := "POST"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given corridor. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"id": 3,
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
integration_idstring |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
PUT corridor/schedule/{corridorId}/store/{storeId}
Use this endpoint to update schedules for your corridors in the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/corridor/schedule/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888
This is an example of the request:
{
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/123/integration/888"
method := "PUT"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 2,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given corridor. |
schedule_details.idinteger |
required |
Identifier of the corridor schedule. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 2,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
integration_idinteger |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where corridor must be available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
DELETE corridor/schedule/{corridorId}/integration/{integrationId}/{corridorProductScheduleId}
Use this endpoint to delete corridor schedules configured for the store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/corridor/schedule/{corridorId}/integration/{integrationId}/{corridorProductScheduleId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{corridorProductScheduleId}: This is the identifier of the corridor schedule.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888/254
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888/254");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/schedule/321/integration/888/254',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888/254"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/corridor/schedule/321/integration/888/254"
method := "DELETE"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"corridor_id": 321,
"integration_id": "888",
"schedule_details": [
{
"id": 1,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
corridor_idinteger |
Identifier of the corridor. |
integration_idstring |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of corridor schedules that are still available. |
schedule_details.idinteger |
Identifier of the corridor schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the corridor begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the corridor becomes unavailable for users. 24 hour format HH:mm:ss |
Utils Product Schedules By Product Id
Use the Utils resource to manage the Schedules configured in your stores.
The following table describes the different contents of the Schedules Utils resource:
| Resource | Description |
|---|---|
GET product/corridor/{corridorId}/store/{storeId} |
Returns the collection of products for the corridor and store |
GET product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Returns the product schedules configured for the corridor and store |
POST product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Create product schedules for the corridor and store |
PUT product/schedule/{productId}/corridor/{corridorId}/store/{storeId} |
Update product schedules for the corridor and store |
GET product/corridor/{corridorId}/store/{storeId}
Use this endpoint to retrieve the collections of products configured for the given corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/product/corridor/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/product/corridor/123/store/999
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/product/corridor/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/corridor/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/product/corridor/123/store/999"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/product/corridor/123/store/999"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid Credentials
Sample Response
This is an example of the response:
[
{
"product_id": 789,
"name": "Americano Caliente 16 oz",
"description": "16 oz. Espresso con agua caliente.",
"corridor_id": 123,
"store_id": 999
},
{
"product_id": 987,
"name": "Americano Caliente 20 oz",
"description": "20 oz. Espresso con agua caliente.",
"corridor_id": 123,
"store_id": 999
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
product_idinteger |
Identifier of the product. |
namestring |
Name of the product. |
descriptionstring |
Description of the product . |
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store that contains the corridor. (The parent store identifier in case of child store request) |
GET product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
Use this endpoint to obtain product schedules configured for the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{productId}: This is the identifier of the product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/product/schedule/789/corridor/123/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"product_id": 789,
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 4,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "23:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
product_idinteger |
Identifier of the product. |
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
POST product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
Use this endpoint to create schedules for your products in the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{productId}: This is the identifier of the product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999
This is an example of the request:
{
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/product/schedule/789/corridor/123/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
method := "POST"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given product. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"product_id": 789,
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"id": 6,
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
product_idinteger |
Identifier of the product. |
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
PUT product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
Use this endpoint to update schedules for your products in the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999
This is an example of the request:
{
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/product/schedule/789/corridor/123/store/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999"
method := "PUT"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given product. |
schedule_details.idinteger |
required |
Identifier of the product schedule. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"product_id": 789,
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
product_idinteger |
Identifier of the product. |
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
DELETE product/schedule/{productId}/corridor/{corridorId}/store/{storeId}/{corridorProductScheduleId}
Use this endpoint to delete product schedules configured for the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}/{corridorProductScheduleId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{corridorProductScheduleId}: This is the identifier of the product schedule.{storeId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{productId}: This is the identifier of the product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/{productId}/corridor/{corridorId}/store/{storeId}/{corridorProductScheduleId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999/254");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/product/schedule/789/corridor/123/store/999/254',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999/254"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/product/schedule/789/corridor/123/store/999/254"
method := "DELETE"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"product_id": 789,
"corridor_id": 123,
"store_id": 999,
"schedule_details": [
{
"id": 4,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "23:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
product_idinteger |
Identifier of the product. |
corridor_idinteger |
Identifier of the corridor. |
store_idinteger |
Identifier of the store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules that are still available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Utils Product Schedules by SKU
Use the Utils resource to manage the Schedules configured in your stores.
The following table describes the different contents of the Schedules Utils resource:
| Resource | Description |
|---|---|
GET sku/corridor/{corridorId}/integration/{integrationId} |
Returns the collection of products for the corridor and store |
GET sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Returns the product schedules configured for the corridor and store |
POST sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Create product schedules for the corridor and store |
PUT sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId} |
Update product schedules for the corridor and store |
GET sku/corridor/{corridorId}/integration/{integrationId}
Use this endpoint to retrieve the collections of products configured for the given corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/sku/corridor/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/sku/corridor/123/integration/888
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/sku/corridor/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/sku/corridor/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/corridor/123/integration/888"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/corridor/123/integration/888"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid Credentials
Sample Response
This is an example of the response:
[
{
"sku": 789,
"name": "Americano Caliente 16 oz",
"description": "16 oz. Espresso con agua caliente.",
"corridor_id": 123,
"integration_id": "888"
},
{
"sku": 987,
"name": "Americano Caliente 20 oz",
"description": "20 oz. Espresso con agua caliente.",
"corridor_id": 123,
"integration_id": "888"
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
skuinteger |
Identifier of the product. |
namestring |
Name of the product. |
descriptionstring |
Description of the product . |
corridor_idinteger |
Identifier of the corridor. |
integration_idstring |
Identifier of the store that contains the corridor. (The parent store identifier in case of child store request) |
GET sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
Use this endpoint to obtain product schedules configured for the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{sku}: This is the identifier of your product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"sku": 987,
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 4,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "23:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
skuinteger |
Identifier of your product. |
corridor_idinteger |
Identifier of the corridor. |
integration_idinteger |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
POST sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
Use this endpoint to create schedules for your products in the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{sku}: This is the identifier of your product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888
This is an example of the request:
{
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
method := "POST"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" },\n" +
" {\n" +
" \"days\": \"hol\",\n" +
" \"starts_time\": \"13:00:00\",\n" +
" \"ends_time\": \"22:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given product. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"sku": 987,
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "08:00:00",
"ends_time": "20:00:00"
},
{
"id": 6,
"days": "hol",
"starts_time": "13:00:00",
"ends_time": "22:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
skuinteger |
Identifier of your product. |
corridor_idinteger |
Identifier of the corridor. |
integration_idinteger |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
PUT sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
Use this endpoint to update schedules for your products in the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{sku}: This is the identifier of your product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888
This is an example of the request:
{
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}";
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
payload = "{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888"
method := "PUT"
payload := strings.NewReader(""{\n" +
" \"schedule_details\": [\n" +
" {\n" +
" \"id\": 5,\n" +
" \"days\": \"mon,tue,wed,thu,fri,sat,sun\",\n" +
" \"starts_time\": \"10:00:00\",\n" +
" \"ends_time\": \"16:00:00\"\n" +
" }\n" +
" ]\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
schedule_detailsarray of objects |
required |
List of the schedules for the given product. |
schedule_details.idinteger |
required |
Identifier of the product schedule. |
schedule_details.daysstring |
required |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestrings |
required |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestrings |
required |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Sample Response
This is an example of the response:
{
"sku": 987,
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 5,
"days": "mon,tue,wed,thu,fri,sat,sun",
"starts_time": "10:00:00",
"ends_time": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
skuinteger |
Identifier of your product. |
corridor_idinteger |
Identifier of the corridor. |
integration_idinteger |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules where product must be available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
DELETE sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}/{corridorProductScheduleId}
Use this endpoint to delete product schedules configured for the corridor and store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}/{corridorProductScheduleId}
{COUNTRY_DOMAIN}: Your Rappi Country Domain. See the list of Country Domains.{corridorProductScheduleId}: This is the identifier of the product schedule.{integrationId}: This is the identifier of your store.{corridorId}: This is the identifier of the corridor.{sku}: This is the identifier of your product.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/{sku}/corridor/{corridorId}/integration/{integrationId}/{corridorProductScheduleId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888/254");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888/254',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888/254"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/sku/schedule/987/corridor/123/integration/888/254"
method := "DELETE"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Sample Response
This is an example of the response:
{
"sku": 987,
"corridor_id": 123,
"integration_id": "888",
"schedule_details": [
{
"id": 4,
"days": "mon,tue,wed,thu,fri,sat,sun,hol",
"starts_time": "08:00:00",
"ends_time": "23:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
skuinteger |
Identifier of your product. |
corridor_idinteger |
Identifier of the corridor. |
integration_idinteger |
Identifier of your store. (The parent store identifier in case of child store request) |
schedule_detailsarray of objects |
List of the schedules that are still available. |
schedule_details.idinteger |
Identifier of the product schedule. |
schedule_details.daysstring |
Days of the schedule. Days of the week: "mon,tue,wed,thu,fri,sat,sun", Holidays: "hol". |
schedule_details.starts_timestring |
A specific time where the product begins to be available for users. 24 hour format HH:mm:ss |
schedule_details.ends_timestring |
A specific time where the product becomes unavailable for users. 24 hour format HH:mm:ss |
Utils Store hours
Use Utils to configure your stores hours.
The following table shows the content of the stores hours:
| Resource | Description |
|---|---|
GET store/schedule/{storeId} |
Returns all regular store hours |
GET store/schedule/{storeId}/holiday |
Returns all holiday hours |
GET store/schedule/{storeId}/special |
Returns all the hours of the store's special days |
POST store/schedule/{storeId} |
Create a time slot on a regular schedule day of the store |
POST store/schedule/{storeId}/holiday/{holidayDayId} |
Create a time slot on a holiday |
POST store/schedule/{storeId}/special |
Create a special day for the store |
POST store/schedule/{storeId}/special/{specialDayId} |
Create a time slot on a store's special day |
PUT store/schedule/{storeId}/{storeScheduleId} |
Update a time slot |
DELETE store/schedule/{storeId}/{storeScheduleId} |
Delete a time slot |
DELETE store/schedule/{storeId}/special/{specialDayId} |
Delete a special day |
GET store/schedule/{storeId}
Use this endpoint to get all your store's regular hours
Endpoint URL
Use this URL to call the endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
Sample Response
This is an example of the response:
{
"storeScheduleDays": [
{
"day": "mon",
"storeSchedules": [
{
"id": 1171828,
"startsTime": "07:00:00",
"endsTime": "09:00:00"
}
]
},
{
"day": "tue",
"storeSchedules": [
{
"id": 21126084,
"startsTime": "00:00:00",
"endsTime": "05:00:00"
}
]
},
{
"day": "sun",
"storeSchedules": [
{
"id": 1171833,
"startsTime": "00:00:00",
"endsTime": "13:00:00"
}
]
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
daystring |
Day identifier. |
storeScheduleslist |
Time Slots List. |
storeSchedules.idinteger |
Time slot ID. |
startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
GET store/schedule/{storeId}/holiday
Use this endpoint to get all the hours for holidays
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/holiday
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999/holiday',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
Sample Response
This is an example of the response:
{
"storeSpecialScheduleDays": [
{
"id": 270,
"name": "Festivo",
"month": 2,
"day": 22,
"cityId": null,
"storeSchedules": []
},
{
"id": 10342,
"name": "Festivo",
"month": 3,
"day": 15,
"cityId": null,
"storeSchedules": [
{
"id": 2334763,
"startsTime": "00:00:00",
"endsTime": "10:00:00"
}
]
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
storeSpecialScheduleDayslist |
Holidays List. |
storeSpecialScheduleDays.idinteger |
Holiday ID. |
storeSpecialScheduleDays.namestring |
Holiday's name. |
storeSpecialScheduleDays.monthinteger |
Holiday's month. |
storeSpecialScheduleDays.dayinteger |
Holiday's number. |
storeSpecialScheduleDays.cityIdinteger |
City ID (Optional). |
storeSpecialScheduleDays.storeScheduleslist |
Time Slots List. |
storeSpecialScheduleDays.storeSchedules.idinteger |
Time slot ID. |
storeSpecialScheduleDays.storeSchedules.startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
storeSpecialScheduleDays.storeSchedules.endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
GET store/schedule/{storeId}/special
Use this endpoint to get all the hours for your store's special days.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/special
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
Sample Response
This is an example of the response:
{
"storeSpecialScheduleDays": [
{
"id": 270,
"name": "Cumpleaños de Daniel",
"month": 6,
"day": 20,
"cityId": null,
"storeSchedules": []
},
{
"id": 10342,
"name": "Aniversario",
"month": 3,
"day": 15,
"cityId": null,
"storeSchedules": [
{
"id": 2334761,
"startsTime": "00:00:00",
"endsTime": "10:00:00"
}
]
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
storeSpecialScheduleDayslist |
Special days list. |
storeSpecialScheduleDays.idinteger |
Special day's ID. |
storeSpecialScheduleDays.namestring |
Special day's name. |
storeSpecialScheduleDays.monthinteger |
Special day's month. |
storeSpecialScheduleDays.dayinteger |
Special day's number. |
storeSpecialScheduleDays.cityIdinteger |
City ID (Optional). |
storeSpecialScheduleDays.storeScheduleslist |
Time Slots List. |
storeSpecialScheduleDays.storeSchedules.idinteger |
Time slot ID. |
storeSpecialScheduleDays.storeSchedules.startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
storeSpecialScheduleDays.storeSchedules.endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
POST store/schedule/{storeId}
Use this endpoint to create a new time slot for your store
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.
Sample Request
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999
This is an example of the request:
{
"day": "mon",
"starts_time": "08:00:00",
"ends_time": "09:00:00"
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString =
" {\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n"
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"day": "mon",
"starts_time": "08:00:00",
"ends_time": "09:00:00"
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999"
payload = "{\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999"
method := "POST"
payload := strings.NewReader(""{\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
daystring |
required |
Schedule day. "mon, tue, wed, thu, fri, sat, sun" |
starts_timestring |
required |
Start of the time slot in 24-hour format HH:mm:ss. |
ends_timestring |
required |
End of time slot in 24-hour format HH:mm:ss. |
Sample Response
This is an example of the response:
{
"day": "mon",
"storeSchedules": [
{
"id": 21126292,
"starts_time": "08:00:00",
"ends_time": "09:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
daystring |
Day identifier. |
storeScheduleslist |
Time Slots List. |
storeSchedules.idinteger |
Time slot ID. |
startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
POST store/schedule/{storeId}/holiday/{holidayDayId}
Use this endpoint to create a new time slot for your store on a holiday
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/holiday/{holidayDayId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.{holidayDayId}: It is the holiday's identifier in Rappi.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday/{holidayDayId}
This is an example of the request:
[
{
"startsTime": "10:00:00",
"endsTime": "12:00:00"
}
]
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday/{holidayDayId}");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString =
"[\n" +
" {\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n"
"]\n"
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999/holiday/{holidayDayId}',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify([{
"day": "mon",
"starts_time": "08:00:00",
"ends_time": "09:00:00"
}]);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday/{holidayDayId}"
payload = "[\n" +
"{\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}\n"
"]\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/holiday/{holidayDayId}"
method := "POST"
payload := strings.NewReader(""[{\n" +
" \"day\": \"mon\",\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}]")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
starts_timestring |
required |
Start of the time slot in 24-hour format HH:mm:ss. |
ends_timestring |
required |
End of time slot in 24-hour format HH:mm:ss. |
!!! note It is possible to create multiple time slots at the same time on a holiday
Sample Response
This is an example of the response:
[
{
"id": 21126293,
"startsTime": "10:00:00",
"endsTime": "12:00:00"
},
{
"id": 21126294,
"startsTime": "13:00:00",
"endsTime": "15:00:00"
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
idinteger |
Time slot ID. |
startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
POST store/schedule/{storeId}/special
Use this endpoint to create a special day for your store
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/special
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special
This is an example of the request:
{
"day": 10,
"month": 10,
"name": "Dia especial",
"schedules": [
{
"startsTime": "09:00:00",
"endsTime": "12:00:00"
},
{
"startsTime": "15:00:00",
"endsTime": "16:00:00"
}
]
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString =
"{\n" +
" \"day\": \"10\",\n" +
" \"month\": \"10\",\n" +
" \"name\": \"Dia especial\",\n" +
" \"schedules\": [ \n" +
" {\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n" +
" ]\n"
"}\n"
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/{storeId}/special',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"day": 10,
"month": 10,
"name": "Dia especial",
"schedules": [
{
"startsTime": "09:00:00",
"endsTime": "12:00:00"
},
{
"startsTime": "15:00:00",
"endsTime": "16:00:00"
}
]
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special"
payload = "{\n" +
" \"day\": \"10\",\n" +
" \"month\": \"10\",\n" +
" \"name\": \"Dia especial\",\n" +
" \"schedules\": [ \n" +
" {\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n" +
" ]\n"
"}\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special"
method := "POST"
payload := strings.NewReader("{\n" +
" \"day\": \"10\",\n" +
" \"month\": \"10\",\n" +
" \"name\": \"Dia especial\",\n" +
" \"schedules\": [ \n" +
" {\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n" +
" ]\n"
"}\n")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
dayinteger |
required |
Special day's number. |
monthinteger |
required |
Special day's month. |
namestring |
required |
Special day's name. |
scheduleslist |
required |
Time Slots List. |
schedules.starts_timestring |
required |
Start of the time slot in 24-hour format HH:mm:ss. |
schedules.ends_timestring |
required |
End of time slot in 24-hour format HH:mm:ss. |
Sample Response
This is an example of the response:
{
"name": "Dia especial",
"month": 11,
"day": 10,
"storeSchedules": [
{
"id": 21126295,
"startsTime": "09:00:00",
"endsTime": "12:00:00"
},
{
"id": 21126296,
"startsTime": "15:00:00",
"endsTime": "16:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
namestring |
Special day's name.. |
monthinteger |
Special day's month. |
dayinteger |
Special day's number. |
storeScheduleslist |
Time Slots List. |
storeSchedules.idinteger |
Time slot ID |
storeSchedules.startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
storeSchedules.endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
POST store/schedule/{storeId}/special/{specialDayId}
Use this endpoint to create a new time slot for your store on a special day
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.{specialDayId}: It is the special day's identifier in Rappi.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
POST https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}
This is an example of the request:
[
{
"startsTime": "08:00:00",
"endsTime": "20:00:00"
}
]
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("POST");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString =
"[\n" +
" {\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
" }\n"
"]\n"
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'POST',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify([{
"starts_time": "08:00:00",
"ends_time": "09:00:00"
}]);
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}"
payload = "[\n" +
"{\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}\n"
"]\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/special/{specialDayId}"
method := "POST"
payload := strings.NewReader(""[{\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}]")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Description |
|---|---|---|
starts_timestring |
required |
Start of the time slot in 24-hour format HH:mm:ss. |
ends_timestring |
required |
End of time slot in 24-hour format HH:mm:ss. |
Sample Response
This is an example of the response:
[
{
"id": 21126293,
"startsTime": "08:00:00",
"endsTime": "20:00:00"
}
]
This table describes the objects contained in the response example:
| Response Object | Object Description |
|---|---|
idinteger |
Time slot ID. |
startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
PUT store/schedule/{storeId}/{storeScheduleId}
Use this endpoint to update a time slot for your store
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.{storeScheduleId}: It is the time slot's identifier.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Request body requirements | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad Request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
PUT https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}
This is an example of the request:
{
"startsTime": "07:00:00",
"endsTime": "08:00:00"
}
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("PUT");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
connection.setDoOutput(true);
String jsonInputString =
"{\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}\n"
try (OutputStream os = connection.getOutputStream()) {
byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
os.write(input, 0, input.length);
}
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'PUT',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"starts_time": "08:00:00",
"ends_time": "09:00:00"
});
req.write(postData);
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}"
payload = "{\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}\n"
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("PUT", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}"
method := "PUT"
payload := strings.NewReader(""{\n" +
" \"starts_time\": \"08:00:00\",\n" +
" \"ends_time\": \"20:00:00\"\n" +
"}")
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
This table describes the attributes that the JSON of your request requires:
| Attributes | Requirement | Object Description |
|---|---|---|
starts_timestring |
required |
Start of the time slot in 24-hour format HH:mm:ss. |
ends_timestring |
required |
End of time slot in 24-hour format HH:mm:ss. |
Sample Response
This is an example of the response:
{
"day": "mon",
"storeSchedules": [
{
"id": 1171828,
"startsTime": "07:00:00",
"endsTime": "08:00:00"
}
]
}
This table describes the objects contained in the response example:
| Response Object | Description |
|---|---|
daystring |
Day identifier. |
storeScheduleslist |
Time Slots List. |
startsTimestring |
Start of the time slot in 24-hour format HH:mm:ss. |
endsTimestring |
End of time slot in 24-hour format HH:mm:ss. |
DELETE store/schedule/{storeId}/{storeScheduleId}
Use this endpoint to delete a time slot from your store.
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.{storeScheduleId}: It is the time slot's identifier.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/{storeId}/{storeScheduleId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/5432");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999/5432',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/5432"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/5432"
method := "DELETE"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
DELETE store/schedule/{storeId}/special/{specialDayId}
Use this endpoint to remove a special day from your store
Endpoint URL
Use this URL to make a request with this endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/DELETE store/schedule/{storeId}/special/{specialDayId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{storeId}: It is the store's identifier in Rappi.{specialDayId}: Special day's ID.
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
No message
400
Bad request message error
401
Invalid credentials
Sample Request
This is an example of an API request using this endpoint:
DELETE https://microservices.dev.rappi.com/api/rest-ops-utils/DELETE store/schedule/{storeId}/special/{specialDayId}
This is an example of the request:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special/5678");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("DELETE");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'DELETE',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/store/schedule/999/special/5678',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
},
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special/5678"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("DELETE", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/store/schedule/999/special/5678"
method := "DELETE"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Utils Products Status
Use Utils to check the status of the products in your store.
| Resource | Description |
|---|---|
GET menu/integration/{integrationId} |
Return the list of products and toppings with status and their availability |
GET menu/integration/{integrationId}
Use this endpoint to get list of products and toppings with status and their availability.
Endpoint URL
Use this URL to call the endpoint:
https://{COUNTRY_DOMAIN}/api/rest-ops-utils/menu/integration/{integrationId}
{COUNTRY_DOMAIN}: This is your Rappi Country Domain. See the list of Country Domains.{integrationId}: It is the store's identifier from the ally.
Sample Request
This is an example of an API request using this endpoint:
GET https://microservices.dev.rappi.com/api/rest-ops-utils/menu/integration/910001
This is an example of the response:
URL url = new URL("https://microservices.dev.rappi.com/api/rest-ops-utils/menu/integration/910001");
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");
connection.setRequestProperty("User-Agent", "Mozilla/5.0");
connection.setRequestProperty("Content-Type", "application/json");
connection.setRequestProperty("Accept", "application/json");
connection.setRequestProperty("x-authorization", "bearer YOUR_TOKEN");
try (BufferedReader br = new BufferedReader(
new InputStreamReader(connection.getInputStream(), StandardCharsets.UTF_8))) {
StringBuilder response = new StringBuilder();
String responseLine;
while ((responseLine = br.readLine()) != null) {
response.append(responseLine.trim());
}
System.out.println("Response body: " + response.toString());
}
System.out.println("Response Code : " + connection.getResponseCode());
var https = require('https');
var options = {
'method': 'GET',
'hostname': 'microservices.dev.rappi.com',
'path': '/api/rest-ops-utils/menu/integration/910001',
'headers': {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
import requests
url = "https://microservices.dev.rappi.com/api/rest-ops-utils/menu/integration/910001"
payload = {}
headers = {
'Content-Type': 'application/json',
'x-authorization': 'bearer YOUR_TOKEN'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://microservices.dev.rappi.com/api/rest-ops-utils/menu/integration/910001"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("x-authorization", "bearer YOUR_TOKEN")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
Endpoint Properties
This resource has the following properties:
| Response formats | JSON |
|
| Authentication requirements | Token |
Parameters
This endpoint does not permit additional parameters.
Status Codes
These are the possible status codes of the response for this endpoint:
200
Success
401
Invalid Credentials
400
Bad request message error
Sample Response
This is an example of the response:
{
"corridors": [
{
"id": "2090062012",
"name": "Alimentos",
"description": "",
"storeId": "900113661",
"integrationId": "900113662"
}
],
"products": [
{
"id": "2136363834",
"sku": "0003339",
"name": "Combo Ant. De Lomo",
"description": "Combo ant. de lomo",
"active": true,
"isAvailable": true,
"corridorId": "2090062012"
}
],
"toppingsCategories": [
{
"id": "1247309613",
"sku": null,
"description": "Otros",
"productId": "2136363834",
"toppings": [
{
"id": "341611638",
"sku": "0000105",
"description": "Anticucho de lomo fino",
"activated": true
},
{
"id": "341611639",
"sku": "0003341",
"description": "Cusqueña doble malta",
"activated": true
},
{
"id": "341611640",
"sku": "0002991",
"description": "Aji diablo",
"activated": true
}
]
}
]
}
This table describes the attributes that the JSON of your request requires:
| Response Object | Object Description |
|---|---|
corridorsarray of objects |
Corridor list from products. |
corridors.idstring |
Corridor id. |
corridors.namestring |
Corridor name. |
corridors.descriptionstring |
Corridor description. |
corridors.storeIdstring |
Store Id from corridor. |
corridors.integrationIdstring |
Integration id from store from corridor. |
productsarray of objects |
Product List. |
products.idstring |
Product Id. |
products.skustring |
Product SKU. |
products.namestring |
Product name. |
products.descriptionstring |
Product description. |
products.activestring |
Product status. |
products.isAvailablestring |
Product availability. |
products.corridorIdstring |
Corridor id from product. |
toppingsCategoriesarray of objects |
Category list. |
toppingsCategories.idstring |
Category id. |
toppingsCategories.descriptionstring |
Category description. |
toppingsCategories.productIdstring |
Product Id from category. |
toppingsCategories.toppingsarray of objects |
Topping list. |
toppingsCategories.toppings.idstring |
Topping id. |
toppingsCategories.toppings.skustring |
Topping SKU. |
toppingsCategories.toppings.descriptionstring |
Topping description. |
toppingsCategories.toppings.activatedstring |
Topping status. |
Sample Response "Invalid credentials 401"
This is an example of the response "Invalid credentials 401":
{
"message": "Not a valid token"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
Sample Response "App Client not found 404"
This is an example of the response "App Client not found 404":
{
"message": "Not found appClient of client id {clientId}"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |
Sample Response "integration Id not found Bad Request 400"
This is an example of the response "integration Id not found Bad Request 400":
{
"message": "IntegrationId {integrationId} not found"
}
This table describes the objects contained in the response example:
| Object | Description |
|---|---|
messagestring |
Descriptive error message |