List products
curl --request GET \
--url https://api.mymorabaa.com/external/v1/products \
--header 'X-Api-Key: <x-api-key>'import requests
url = "https://api.mymorabaa.com/external/v1/products"
headers = {"X-Api-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Api-Key': '<x-api-key>'}};
fetch('https://api.mymorabaa.com/external/v1/products', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mymorabaa.com/external/v1/products",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mymorabaa.com/external/v1/products"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mymorabaa.com/external/v1/products")
.header("X-Api-Key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mymorabaa.com/external/v1/products")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "<string>",
"name": "<string>",
"sku": {},
"quantity": {},
"price": 123,
"sellPrice": 123,
"isAvailable": true,
"productImageUrl": {},
"variants": [
{}
],
"combinations": [
{}
]
}
],
"page": 123,
"pageSize": 123,
"total": 123
}API reference
List products
Search and filter products available to your API key.
GET
https://api.mymorabaa.com
/
external
/
v1
/
products
List products
curl --request GET \
--url https://api.mymorabaa.com/external/v1/products \
--header 'X-Api-Key: <x-api-key>'import requests
url = "https://api.mymorabaa.com/external/v1/products"
headers = {"X-Api-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Api-Key': '<x-api-key>'}};
fetch('https://api.mymorabaa.com/external/v1/products', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mymorabaa.com/external/v1/products",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mymorabaa.com/external/v1/products"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Api-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mymorabaa.com/external/v1/products")
.header("X-Api-Key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mymorabaa.com/external/v1/products")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "<string>",
"name": "<string>",
"sku": {},
"quantity": {},
"price": 123,
"sellPrice": 123,
"isAvailable": true,
"productImageUrl": {},
"variants": [
{}
],
"combinations": [
{}
]
}
],
"page": 123,
"pageSize": 123,
"total": 123
}Returns a paginated product list. Your API key needs the
Each page contains up to 25 products.
products:list scope.
Headers
string
required
Your API key. You can use
Authorization: Api-Key your_key instead.Query parameters
string
Search text.
integer
default:"1"
One-based page number. Values below
1 are treated as 1.boolean
Filter by availability.
string
Comma-separated category GUIDs. Invalid GUIDs are ignored.
string
Comma-separated brand GUIDs. Invalid GUIDs are ignored.
string
Filter by barcode.
string
Filter by SKU.
Request example
curl --get "$MORABAA_API_URL/external/v1/products" \
--header "X-Api-Key: $MORABAA_API_KEY" \
--data-urlencode "query=coffee" \
--data-urlencode "isAvailable=true" \
--data-urlencode "page=1"
Response
price is the list price. sellPrice is the effective price after an active discount, when one applies.
object[]
required
Products on the current page.
Show Product fields
Show Product fields
UUID
required
Product ID.
string
required
Product name.
string | null
Product SKU.
number | null
Available quantity.
number
required
List price.
number
required
Effective selling price.
boolean
required
Whether the product is available.
string | null
Product image URL.
object[]
required
Product variants and their options.
object[]
required
Available option combinations, including IDs, option IDs, SKU, barcode, quantity, prices, availability, and image URL.
integer
required
Current page.
integer
required
Maximum items per page. Always
25.integer
required
Total matching products.
{
"items": [
{
"id": "11111111-1111-1111-1111-111111111111",
"name": "Arabic coffee",
"sku": "COFFEE-250",
"quantity": 18,
"price": 12000,
"sellPrice": 10000,
"isAvailable": true,
"productImageUrl": "https://cdn.example.com/products/coffee.jpg",
"variants": [],
"combinations": []
}
],
"page": 1,
"pageSize": 25,
"total": 1
}
Errors
| Status | Cause |
|---|---|
401 | The API key is missing or invalid. |
403 | The key lacks the products:list scope. |
429 | The rate limit was exceeded. |
500 | An unexpected error occurred. |