Stores & Checkouts
Retrieve the stores and checkouts associated with your merchant account.
When creating a Static QR Code, you need to provide a valid store_id and checkout_id that belong to your merchant account. Use the endpoints below to discover them.
List Stores
GET /v2/stores
Returns all stores associated with your merchant account.
Example Request
const url = "baseURL/v2/stores"
const response = await fetch(url, {
method: "GET",
headers: {
Authorization: `Bearer ${access_token}`,
},
});import requests
url = "baseURL/v2/stores"
headers = {
"Authorization": f"Bearer {access_token}",
}
response = requests.get(url, headers=headers)package main
import (
"fmt"
"net/http"
)
func main() {
url := "baseURL/v2/stores"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", fmt.Sprintf("Bearer %s", access_token))
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
fmt.Println("Error making request:", err)
return
}
defer resp.Body.Close()
}Response
[
{
"merchant_id": 1,
"store_id": 1,
"store_name": "Main Store",
"address": "Av. Paulista 1000",
"phone_number": "+5511999999999",
"email": "store@example.com"
}
]{
"message": "Unauthorized",
"request_id": "30e87ab5xxxxxxxxxxxxf8249f594cfb"
}{
"detail": "Internal Server Error"
}Response Fields
| Field | Type | Description |
|---|---|---|
| merchant_id | integer | Your merchant ID. |
| store_id | integer | Store identifier. Use this when creating a Static QR. |
| store_name | string | Name of the store. |
| address | string | Store address. |
| phone_number | string | Store phone number. |
| string | Store email. |
List Checkouts for a Store
GET /v2/stores/{store_id}/checkouts
Returns all checkouts for a given store, scoped to your merchant account. Returns 404 if the store doesn't exist or belongs to a different merchant.
Path Parameters
| Name | Type | Description |
|---|---|---|
| store_id | integer | Required. The store ID to query checkouts for. |
Example Request
const store_id = 1
const url = `baseURL/v2/stores/${store_id}/checkouts`
const response = await fetch(url, {
method: "GET",
headers: {
Authorization: `Bearer ${access_token}`,
},
});import requests
store_id = 1
url = f"baseURL/v2/stores/{store_id}/checkouts"
headers = {
"Authorization": f"Bearer {access_token}",
}
response = requests.get(url, headers=headers)package main
import (
"fmt"
"net/http"
)
func main() {
store_id := 1
url := fmt.Sprintf("baseURL/v2/stores/%d/checkouts", store_id)
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", fmt.Sprintf("Bearer %s", access_token))
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
fmt.Println("Error making request:", err)
return
}
defer resp.Body.Close()
}Response
[
{
"merchant_id": 1,
"store_id": 1,
"checkout_id": 2,
"checkout_desc": "Online checkout",
"wallet_id": 3
}
]{
"message": "Unauthorized",
"request_id": "30e87ab5xxxxxxxxxxxxf8249f594cfb"
}{
"detail": "Store not found"
}{
"detail": "Internal Server Error"
}Response Fields
| Field | Type | Description |
|---|---|---|
| merchant_id | integer | Your merchant ID. |
| store_id | integer | The store this checkout belongs to. |
| checkout_id | integer | Checkout identifier. Use this when creating a Static QR. |
| checkout_desc | string | Description of the checkout. |
| wallet_id | integer | Wallet associated with this checkout. The Static QR address must match this wallet. |