Introduction
API documentation for TuckerFox - a Laravel application
This documentation aims to provide all the information you need to work with our API.
Authenticating requests
To authenticate requests, include an Authorization header with the value "Bearer YOUR_API_TOKEN".
All authenticated endpoints are marked with a requires authentication badge in the documentation below.
You can retrieve your token from FMK.
Company
APIs for managing company profiles and settings
List Companies
Get a list of all registered companies.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies?search=Tuckerfox" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies"
);
const params = {
"search": "Tuckerfox",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'query' => [
'search' => 'Tuckerfox',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Companies listed successfully",
"statusCode": 200,
"data": []
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Company
Register a new company in the system.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Tuckerfox\",
\"description\": \"Tuckerfox is a food delivery company.\",
\"logo\": \"https:\\/\\/tuckerfox.com\\/logo.png\",
\"background_image\": \"https:\\/\\/tuckerfox.com\\/background.png\",
\"working_hours_from\": \"0900\",
\"working_hours_to\": \"1800\",
\"address_name\": \"123 Main St, Sydney\",
\"latitude\": \"-33.8688\",
\"longitude\": \"151.2153\",
\"google_place_id\": \"ChIJN1t_tYagMctQHhEQwTH3msc\",
\"map_iframe\": \"https:\\/\\/www.google.com\\/maps\\/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau\",
\"delivery_fee_min\": 10,
\"delivery_fee_max\": 20,
\"meta_title\": \"Tuckerfox\",
\"meta_description\": \"Tuckerfox is a food delivery company.\",
\"meta_viewport\": \"width=device-width, initial-scale=1.0\",
\"reservation_button\": \"Reserve Now\",
\"order_button\": \"Order Now\",
\"pre_order_button\": \"Pre-Order Now\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Tuckerfox",
"description": "Tuckerfox is a food delivery company.",
"logo": "https:\/\/tuckerfox.com\/logo.png",
"background_image": "https:\/\/tuckerfox.com\/background.png",
"working_hours_from": "0900",
"working_hours_to": "1800",
"address_name": "123 Main St, Sydney",
"latitude": "-33.8688",
"longitude": "151.2153",
"google_place_id": "ChIJN1t_tYagMctQHhEQwTH3msc",
"map_iframe": "https:\/\/www.google.com\/maps\/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau",
"delivery_fee_min": 10,
"delivery_fee_max": 20,
"meta_title": "Tuckerfox",
"meta_description": "Tuckerfox is a food delivery company.",
"meta_viewport": "width=device-width, initial-scale=1.0",
"reservation_button": "Reserve Now",
"order_button": "Order Now",
"pre_order_button": "Pre-Order Now"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Tuckerfox',
'description' => 'Tuckerfox is a food delivery company.',
'logo' => 'https://tuckerfox.com/logo.png',
'background_image' => 'https://tuckerfox.com/background.png',
'working_hours_from' => '0900',
'working_hours_to' => '1800',
'address_name' => '123 Main St, Sydney',
'latitude' => '-33.8688',
'longitude' => '151.2153',
'google_place_id' => 'ChIJN1t_tYagMctQHhEQwTH3msc',
'map_iframe' => 'https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau',
'delivery_fee_min' => 10.0,
'delivery_fee_max' => 20.0,
'meta_title' => 'Tuckerfox',
'meta_description' => 'Tuckerfox is a food delivery company.',
'meta_viewport' => 'width=device-width, initial-scale=1.0',
'reservation_button' => 'Reserve Now',
'order_button' => 'Order Now',
'pre_order_button' => 'Pre-Order Now',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Company
Get detailed information about a specific company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Company retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"header": {
"name": "PizzaBros",
"description": "PizzaBros has been providing Melbourne with the best and tastiest pizzas since 1999. All pizzas are handcrafted using a range of local produce. Dough and toppings are prepared daily to guarantee you a fresh and delicious taste. Choose from our extensive range of traditional or gourmet oven baked pizzas, individualise your own pizza, or try our signature tasty Texan ribs, baked chicken meals and fresh salads. Enjoy the ultimate pizza experience at PizzaBros: dine in, take away or home delivery.",
"logo": "https://tuckerfox.fmstech.com.tr/assets/images/pizzabros_logo.png",
"backgroundImage": "https://tuckerfox.fmstech.com.tr/assets/images/pizzabros_background.png",
"workingHours": {
"from": "0800",
"to": "1700"
},
"address": {
"name": "149 Quarry Rd, Woodend VIC 3442",
"latitude": null,
"longitude": null,
"googlePlaceId": null
},
"location": {
"mapIframe": "https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3152.0000000000005!2d144.53000000000003!3d-37.35000000000002!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6ad6b9b1b1b1b1b1%3A0x6ad6b9b1b1b1b1b1!2sPizzaBros!5e0!3m2!1sen!2sau!4v1632210000000!5m2!1sen!2sau"
},
"deliveryFee": {
"min": 3,
"max": 6
},
"htmlMetaTags": {
"title": "PizzaBros",
"description": "PizzaBros has been providing Melbourne with the best and tastiest pizzas since 1999. All pizzas are handcrafted using a range of local produce.",
"viewport": "width=device-width, initial-scale=1.0"
},
"reservationButton": "Make A Reservation",
"orderButton": "Make an Order",
"preOrderButton": "Pre Order Online"
},
"operatingHours": {
"delivery": {
"hasIntervals": true,
"schedule": {
"monday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2345"
}
},
"tuesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1600"
},
"dinner": {
"start": "1600",
"end": "2245"
}
},
"wednesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2045"
}
},
"thursday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2145"
}
},
"friday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2245"
}
},
"saturday": {
"isClosed": true
},
"sunday": {
"isClosed": true
}
}
},
"pickup": {
"hasIntervals": true,
"schedule": {
"monday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2345"
}
},
"tuesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1600"
},
"dinner": {
"start": "1600",
"end": "2245"
}
},
"wednesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2045"
}
},
"thursday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2145"
}
},
"friday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2245"
}
},
"saturday": {
"isClosed": true
},
"sunday": {
"isClosed": true
}
}
}
},
"promotions": [
{
"id": 1,
"icon": "percentage",
"title": "First Order Discount",
"description": "10% OFF on first orders over $10.00",
"discountPercentage": "10.00",
"discountFlat": null,
"minOrderAmount": "10.00",
"maxDiscountAmount": "10.00",
"canBeCombined": false,
"isFreeDelivery": false
},
{
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
},
{
"id": 3,
"icon": "percentage",
"title": "Big Order Discount",
"description": "20% OFF on all orders over $50.00",
"discountPercentage": "20.00",
"discountFlat": null,
"minOrderAmount": "50.00",
"maxDiscountAmount": "50.00",
"canBeCombined": false,
"isFreeDelivery": false
},
{
"id": 4,
"icon": "percentage",
"title": "Voila!",
"description": "5% OFF on all orders over $1.00",
"discountPercentage": "5.00",
"discountFlat": null,
"minOrderAmount": "1.00",
"maxDiscountAmount": "5.00",
"canBeCombined": true,
"isFreeDelivery": false
},
{
"id": 5,
"icon": "percentage",
"title": "Eureka!",
"description": "5% OFF on all orders over $1.00",
"discountPercentage": "5.00",
"discountFlat": null,
"minOrderAmount": "1.00",
"maxDiscountAmount": "5.00",
"canBeCombined": true,
"isFreeDelivery": false
}
],
"topSellers": [
{
"id": 3,
"name": "Steam Rice",
"description": "Contains honey, chicken, praw.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/steam_rice.png",
"price": "3.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true
},
{
"id": 6,
"name": "Honey Chicken",
"description": "Sweet and savory honey-glazed chicken.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/honey_chicken.png",
"price": "16.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true
},
{
"id": 8,
"name": "Special Fried Rice",
"description": "Regular Meat Container, 2 x Pita Bread, 1 x Tub Of Garlic Sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/special_fried_rice.png",
"price": "16.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true
},
{
"id": 9,
"name": "Spring Roll (3pcs)",
"description": "Contains BBQ pork, chicken, prawns.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/spring_roll.png",
"price": "6.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true
},
{
"id": 14,
"name": "Deal 1",
"description": "1 Medium Pizza, 1 Garlic Bread, 1.25L Drink.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/deal_1.png",
"price": "27.60",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true
}
],
"deliverySuburbs": [
{
"id": 1,
"name": "Woodend",
"deliveryFee": "3.00"
},
{
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
{
"id": 3,
"name": "Gisborne",
"deliveryFee": "5.00"
},
{
"id": 4,
"name": "Kyneton",
"deliveryFee": "6.00"
}
],
"footerLinks": [
{
"id": 1,
"name": "Home",
"href": "/"
},
{
"id": 2,
"name": "Menu",
"href": "/menu"
},
{
"id": 3,
"name": "Checkout",
"href": "/checkout"
},
{
"id": 4,
"name": "Privacy Policy",
"href": "/privacy-policy"
},
{
"id": 5,
"name": "Terms and Conditions",
"href": "/terms-and-conditions"
}
],
"paymentMethods": [
{
"id": 1,
"name": "Visa",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/visa.png"
},
{
"id": 2,
"name": "Mastercard",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/mastercard.png"
},
{
"id": 3,
"name": "PayPal",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/paypal.png"
}
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Company
Update the details and settings of an existing company.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Dürümle\",
\"description\": \"Dürümle is a food delivery company.\",
\"logo\": \"https:\\/\\/durumle.com\\/logo.png\",
\"background_image\": \"https:\\/\\/durumle.com\\/background.png\",
\"working_hours_from\": \"0900\",
\"working_hours_to\": \"1800\",
\"address_name\": \"123 Main St, Sydney\",
\"latitude\": \"-33.8688\",
\"longitude\": \"151.2153\",
\"google_place_id\": \"ChIJN1t_tYagMctQHhEQwTH3msc\",
\"map_iframe\": \"https:\\/\\/www.google.com\\/maps\\/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau\",
\"delivery_fee_min\": 10,
\"delivery_fee_max\": 20,
\"meta_title\": \"Dürümle\",
\"meta_description\": \"Dürümle is a food delivery company.\",
\"meta_viewport\": \"width=device-width, initial-scale=1.0\",
\"reservation_button\": \"Reserve Now\",
\"order_button\": \"Order Now\",
\"pre_order_button\": \"Pre-Order Now\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Dürümle",
"description": "Dürümle is a food delivery company.",
"logo": "https:\/\/durumle.com\/logo.png",
"background_image": "https:\/\/durumle.com\/background.png",
"working_hours_from": "0900",
"working_hours_to": "1800",
"address_name": "123 Main St, Sydney",
"latitude": "-33.8688",
"longitude": "151.2153",
"google_place_id": "ChIJN1t_tYagMctQHhEQwTH3msc",
"map_iframe": "https:\/\/www.google.com\/maps\/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau",
"delivery_fee_min": 10,
"delivery_fee_max": 20,
"meta_title": "Dürümle",
"meta_description": "Dürümle is a food delivery company.",
"meta_viewport": "width=device-width, initial-scale=1.0",
"reservation_button": "Reserve Now",
"order_button": "Order Now",
"pre_order_button": "Pre-Order Now"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Dürümle',
'description' => 'Dürümle is a food delivery company.',
'logo' => 'https://durumle.com/logo.png',
'background_image' => 'https://durumle.com/background.png',
'working_hours_from' => '0900',
'working_hours_to' => '1800',
'address_name' => '123 Main St, Sydney',
'latitude' => '-33.8688',
'longitude' => '151.2153',
'google_place_id' => 'ChIJN1t_tYagMctQHhEQwTH3msc',
'map_iframe' => 'https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3153.184488888889!2d151.215296375!3d-33.86884988064162!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6b129838f39a7431%3A0x239d63554bf40907!2sCentral%20Station%2C%20Sydney%20NSW%202000!5e0!3m2!1sen!2sau!4v1716336383088!5m2!1sen!2sau',
'delivery_fee_min' => 10.0,
'delivery_fee_max' => 20.0,
'meta_title' => 'Dürümle',
'meta_description' => 'Dürümle is a food delivery company.',
'meta_viewport' => 'width=device-width, initial-scale=1.0',
'reservation_button' => 'Reserve Now',
'order_button' => 'Order Now',
'pre_order_button' => 'Pre-Order Now',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Company
Remove a company from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get a company's menu
Get a company's meta tags
Operating Hours
APIs for managing company operating hours and business schedules
List Operating Hours
Get a list of all operating hours for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Operating hours listed successfully",
"statusCode": 200,
"data": {
"delivery": {
"hasIntervals": true,
"schedule": {
"monday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2345"
}
},
"tuesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1600"
},
"dinner": {
"start": "1600",
"end": "2245"
}
},
"wednesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2045"
}
},
"thursday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2145"
}
},
"friday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2245"
}
},
"saturday": {
"isClosed": true
},
"sunday": {
"isClosed": true
}
}
},
"pickup": {
"hasIntervals": true,
"schedule": {
"monday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2345"
}
},
"tuesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1600"
},
"dinner": {
"start": "1600",
"end": "2245"
}
},
"wednesday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1700"
},
"dinner": {
"start": "1700",
"end": "2045"
}
},
"thursday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2145"
}
},
"friday": {
"isClosed": false,
"lunch": {
"start": "0700",
"end": "1800"
},
"dinner": {
"start": "1800",
"end": "2245"
}
},
"saturday": {
"isClosed": true
},
"sunday": {
"isClosed": true
}
}
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Set Operating Hour
Set new operating hours for a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"service_type\": \"delivery\",
\"day_of_week\": 0,
\"meal_type\": \"lunch\",
\"start_time\": \"1000\",
\"end_time\": \"2200\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"service_type": "delivery",
"day_of_week": 0,
"meal_type": "lunch",
"start_time": "1000",
"end_time": "2200"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/operating-hours';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'service_type' => 'delivery',
'day_of_week' => 0,
'meal_type' => 'lunch',
'start_time' => '1000',
'end_time' => '2200',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delivery Suburb
CRUD operations for company delivery suburbs
List Delivery Suburbs
Retrieve a list of delivery suburbs for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Delivery suburbs listed successfully",
"statusCode": 200,
"data": [
{
"id": 4,
"name": "Kyneton",
"deliveryFee": "6.00"
},
{
"id": 3,
"name": "Gisborne",
"deliveryFee": "5.00"
},
{
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
{
"id": 1,
"name": "Woodend",
"deliveryFee": "3.00"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Delivery Suburb
Create a new delivery suburb for a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Istanbul\",
\"delivery_fee\": 10.5
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Istanbul",
"delivery_fee": 10.5
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Istanbul',
'delivery_fee' => 10.5,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show Delivery Suburb
Retrieve details of a specific delivery suburb for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Delivery suburb retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"name": "Woodend",
"deliveryFee": "3.00"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Delivery Suburb
Update the details of a specific delivery suburb for a company.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Istanbul\",
\"delivery_fee\": 10.5
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Istanbul",
"delivery_fee": 10.5
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Istanbul',
'delivery_fee' => 10.5,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Delivery Suburb
Delete a specific delivery suburb for a company.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/4"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/delivery-suburbs/4';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Footer Link
APIs for managing company footer links and navigation
List Footer Links
Get a list of all footer links for a company.
Create Footer Link
Add a new footer link to a company's website.
Get Footer Link
Get detailed information about a specific footer link.
Update Footer Link
Update the details of an existing footer link.
Delete Footer Link
Remove a footer link from a company's website.
Payment Method
APIs for managing company payment methods
List Payment Methods
Get a list of all available payment methods for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Payment methods listed successfully",
"statusCode": 200,
"data": [
{
"id": 3,
"name": "PayPal",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/paypal.png"
},
{
"id": 2,
"name": "Mastercard",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/mastercard.png"
},
{
"id": 1,
"name": "Visa",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/visa.png"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Payment Method
Add a new payment method to a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Stripe\",
\"icon\": \"https:\\/\\/tuckerfox.fmstech.com.tr\\/assets\\/images\\/visa.png\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Stripe",
"icon": "https:\/\/tuckerfox.fmstech.com.tr\/assets\/images\/visa.png"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Stripe',
'icon' => 'https://tuckerfox.fmstech.com.tr/assets/images/visa.png',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Payment Method
Get detailed information about a specific payment method.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Payment method retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"name": "Visa",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/visa.png"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Payment Method
Update the details of an existing payment method.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Troy\",
\"icon\": \"https:\\/\\/tuckerfox.fmstech.com.tr\\/assets\\/images\\/mastercard.png\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Troy",
"icon": "https:\/\/tuckerfox.fmstech.com.tr\/assets\/images\/mastercard.png"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Troy',
'icon' => 'https://tuckerfox.fmstech.com.tr/assets/images/mastercard.png',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Payment Method
Remove a payment method from a company.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/payment-methods/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Promotion
APIs for managing company promotions and discount codes
List Promotions
Get a list of all promotions and discount codes for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Promotions listed successfully",
"statusCode": 200,
"data": [
{
"id": 5,
"icon": "percentage",
"title": "Eureka!",
"description": "5% OFF on all orders over $1.00",
"discountPercentage": "5.00",
"discountFlat": null,
"minOrderAmount": "1.00",
"maxDiscountAmount": "5.00",
"canBeCombined": true,
"isFreeDelivery": false
},
{
"id": 4,
"icon": "percentage",
"title": "Voila!",
"description": "5% OFF on all orders over $1.00",
"discountPercentage": "5.00",
"discountFlat": null,
"minOrderAmount": "1.00",
"maxDiscountAmount": "5.00",
"canBeCombined": true,
"isFreeDelivery": false
},
{
"id": 3,
"icon": "percentage",
"title": "Big Order Discount",
"description": "20% OFF on all orders over $50.00",
"discountPercentage": "20.00",
"discountFlat": null,
"minOrderAmount": "50.00",
"maxDiscountAmount": "50.00",
"canBeCombined": false,
"isFreeDelivery": false
},
{
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
},
{
"id": 1,
"icon": "percentage",
"title": "First Order Discount",
"description": "10% OFF on first orders over $10.00",
"discountPercentage": "10.00",
"discountFlat": null,
"minOrderAmount": "10.00",
"maxDiscountAmount": "10.00",
"canBeCombined": false,
"isFreeDelivery": false
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Promotion
Create a new promotion or discount code for a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"icon\": \"vespa\",
\"title\": \"25% Discount\",
\"description\": \"Get 25% off your order\",
\"discount_percentage\": 25,
\"discount_flat\": 0,
\"min_order_amount\": 10,
\"max_discount_amount\": 25,
\"can_be_combined\": true,
\"is_free_delivery\": false
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"icon": "vespa",
"title": "25% Discount",
"description": "Get 25% off your order",
"discount_percentage": 25,
"discount_flat": 0,
"min_order_amount": 10,
"max_discount_amount": 25,
"can_be_combined": true,
"is_free_delivery": false
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'icon' => 'vespa',
'title' => '25% Discount',
'description' => 'Get 25% off your order',
'discount_percentage' => 25.0,
'discount_flat' => 0.0,
'min_order_amount' => 10.0,
'max_discount_amount' => 25.0,
'can_be_combined' => true,
'is_free_delivery' => false,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Promotion
Get detailed information about a specific promotion.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Promotion retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"icon": "percentage",
"title": "First Order Discount",
"description": "10% OFF on first orders over $10.00",
"discountPercentage": "10.00",
"discountFlat": null,
"minOrderAmount": "10.00",
"maxDiscountAmount": "10.00",
"canBeCombined": false,
"isFreeDelivery": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Promotion
Update the details of an existing promotion.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"icon\": \"vespa\",
\"title\": \"11% Discount\",
\"description\": \"Get 11% off your order\",
\"discount_percentage\": 11,
\"discount_flat\": null,
\"min_order_amount\": 10,
\"max_discount_amount\": 24,
\"can_be_combined\": false,
\"is_free_delivery\": false
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"icon": "vespa",
"title": "11% Discount",
"description": "Get 11% off your order",
"discount_percentage": 11,
"discount_flat": null,
"min_order_amount": 10,
"max_discount_amount": 24,
"can_be_combined": false,
"is_free_delivery": false
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'icon' => 'vespa',
'title' => '11% Discount',
'description' => 'Get 11% off your order',
'discount_percentage' => 11.0,
'discount_flat' => null,
'min_order_amount' => 10.0,
'max_discount_amount' => 24.0,
'can_be_combined' => false,
'is_free_delivery' => false,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Promotion
Remove a promotion from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/promotions/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Category
APIs for managing company categories
List Categories
Get a list of all categories for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Categories listed successfully",
"statusCode": 200,
"data": [
{
"id": 7,
"name": "Pork Dishes"
},
{
"id": 6,
"name": "Desserts"
},
{
"id": 5,
"name": "Salads"
},
{
"id": 4,
"name": "Pizza"
},
{
"id": 3,
"name": "Appetizers"
},
{
"id": 2,
"name": "Main Course"
},
{
"id": 1,
"name": "Entree"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Category
Create a new category for a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Drinks\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Drinks"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Drinks',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Category
Get detailed information about a specific category.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Category retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"name": "Entree"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Category
Update an existing category's information.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Wines\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Wines"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Wines',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Category
Remove a category from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/categories/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product
APIs for managing company products
List Products
Get a list of all products for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Products listed successfully",
"statusCode": 200,
"data": [
{
"id": 18,
"name": "Crispy Pork Belly",
"description": "Crispy pork belly with a side of pickled vegetables.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/crispy_pork_belly.png",
"price": "9.99",
"deliveryAvailable": false,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [],
"bulletPoints": [
{
"id": 50,
"productId": 18,
"text": "Crispy and flavorful pork belly"
},
{
"id": 51,
"productId": 18,
"text": "Served with tangy pickled vegetables"
},
{
"id": 52,
"productId": 18,
"text": "A delicious and satisfying dish"
}
]
},
{
"id": 17,
"name": "Pulled Pork Sandwich",
"description": "Slow-cooked pulled pork on a toasted bun with BBQ sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/pulled_pork_sandwich.png",
"price": "8.49",
"deliveryAvailable": true,
"pickupAvailable": false,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 47,
"productId": 17,
"text": "Tender slow-cooked pulled pork"
},
{
"id": 48,
"productId": 17,
"text": "Toasted bun with BBQ sauce"
},
{
"id": 49,
"productId": 17,
"text": "A hearty and delicious sandwich"
}
]
},
{
"id": 16,
"name": "Vanilla Cheesecake",
"description": "Classic creamy vanilla cheesecake with a graham cracker crust.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/vanilla_cheesecake.png",
"price": "5.49",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 44,
"productId": 16,
"text": "Creamy and rich vanilla flavor"
},
{
"id": 45,
"productId": 16,
"text": "Graham cracker crust"
},
{
"id": 46,
"productId": 16,
"text": "Perfect for dessert lovers"
}
]
},
{
"id": 15,
"name": "Chocolate Lava Cake",
"description": "Rich chocolate cake with a gooey molten center.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/chocolate_lava_cake.png",
"price": "4.99",
"deliveryAvailable": false,
"pickupAvailable": false,
"available": true,
"isTopSeller": false,
"options": [],
"bulletPoints": [
{
"id": 41,
"productId": 15,
"text": "Rich and decadent chocolate flavor"
},
{
"id": 42,
"productId": 15,
"text": "Molten chocolate center"
},
{
"id": 43,
"productId": 15,
"text": "Perfect dessert for chocolate lovers"
}
]
},
{
"id": 14,
"name": "Deal 1",
"description": "1 Medium Pizza, 1 Garlic Bread, 1.25L Drink.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/deal_1.png",
"price": "27.60",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true,
"options": [
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 38,
"productId": 14,
"text": "Includes a medium pizza"
},
{
"id": 39,
"productId": 14,
"text": "Comes with garlic bread and drink"
},
{
"id": 40,
"productId": 14,
"text": "A great meal deal for sharing"
}
]
},
{
"id": 13,
"name": "Caesar Salad",
"description": "Crisp romaine lettuce, croutons, and Caesar dressing.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/caesar_salad.png",
"price": "6.49",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
},
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 35,
"productId": 13,
"text": "Crisp romaine lettuce"
},
{
"id": 36,
"productId": 13,
"text": "Crunchy croutons"
},
{
"id": 37,
"productId": 13,
"text": "Creamy Caesar dressing"
}
]
},
{
"id": 12,
"name": "Grilled Salmon Salad",
"description": "Mixed greens topped with grilled salmon and a light dressing.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/grilled_salmon_salad.png",
"price": "9.99",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 32,
"productId": 12,
"text": "Mixed greens and fresh vegetables"
},
{
"id": 33,
"productId": 12,
"text": "Perfectly grilled salmon"
},
{
"id": 34,
"productId": 12,
"text": "Served with a light vinaigrette"
}
]
},
{
"id": 11,
"name": "Margherita Pizza",
"description": "Fresh basil, mozzarella, and tomato sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/margherita_pizza.png",
"price": "7.49",
"deliveryAvailable": false,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 29,
"productId": 11,
"text": "Fresh basil leaves"
},
{
"id": 30,
"productId": 11,
"text": "Rich tomato sauce and mozzarella"
},
{
"id": 31,
"productId": 11,
"text": "Light and flavorful classic"
}
]
},
{
"id": 10,
"name": "Pepperoni Pizza",
"description": "Classic pepperoni pizza with a cheesy crust.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/pepperoni_pizza.png",
"price": "8.99",
"deliveryAvailable": true,
"pickupAvailable": false,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
},
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 26,
"productId": 10,
"text": "Cheesy and delicious crust"
},
{
"id": 27,
"productId": 10,
"text": "Loaded with pepperoni slices"
},
{
"id": 28,
"productId": 10,
"text": "A favorite for all pizza lovers"
}
]
},
{
"id": 9,
"name": "Spring Roll (3pcs)",
"description": "Contains BBQ pork, chicken, prawns.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/spring_roll.png",
"price": "6.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 23,
"productId": 9,
"text": "Crispy and golden brown"
},
{
"id": 24,
"productId": 9,
"text": "Filled with savory ingredients"
},
{
"id": 25,
"productId": 9,
"text": "A perfect appetizer"
}
]
},
{
"id": 8,
"name": "Special Fried Rice",
"description": "Regular Meat Container, 2 x Pita Bread, 1 x Tub Of Garlic Sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/special_fried_rice.png",
"price": "16.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 20,
"productId": 8,
"text": "Rich and flavorful fried rice"
},
{
"id": 21,
"productId": 8,
"text": "Includes meat and garlic sauce"
},
{
"id": 22,
"productId": 8,
"text": "Perfect for a hearty meal"
}
]
},
{
"id": 7,
"name": "Vegetarian Spring Rolls",
"description": "Crispy spring rolls filled with fresh vegetables.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/vegetarian_spring_rolls.png",
"price": "4.99",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 18,
"productId": 7,
"text": "Crispy on the outside"
},
{
"id": 19,
"productId": 7,
"text": "Filled with fresh, seasonal vegetables"
}
]
},
{
"id": 6,
"name": "Honey Chicken",
"description": "Sweet and savory honey-glazed chicken.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/honey_chicken.png",
"price": "16.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true,
"options": [
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 15,
"productId": 6,
"text": "Tender chicken pieces"
},
{
"id": 16,
"productId": 6,
"text": "Glazed with a sweet honey sauce"
},
{
"id": 17,
"productId": 6,
"text": "Perfect for chicken lovers"
}
]
},
{
"id": 5,
"name": "BBQ Pork Ribs",
"description": "Slow-cooked pork ribs smothered in BBQ sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/bbq_pork_ribs.png",
"price": "9.99",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 12,
"productId": 5,
"text": "Tender slow-cooked pork ribs"
},
{
"id": 13,
"productId": 5,
"text": "Coated in a smoky BBQ sauce"
},
{
"id": 14,
"productId": 5,
"text": "Great with fries or a salad"
}
]
},
{
"id": 4,
"name": "Garlic Butter Prawns",
"description": "Juicy prawns cooked in a rich garlic butter sauce.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/garlic_butter_prawns.png",
"price": "7.49",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 10,
"productId": 4,
"text": "Succulent prawns in garlic butter"
},
{
"id": 11,
"productId": 4,
"text": "Perfect for seafood lovers"
}
]
},
{
"id": 3,
"name": "Steam Rice",
"description": "Contains honey, chicken, praw.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/steam_rice.png",
"price": "3.80",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": true,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 7,
"productId": 3,
"text": "Steamed to perfection"
},
{
"id": 8,
"productId": 3,
"text": "Great as a side dish"
},
{
"id": 9,
"productId": 3,
"text": "Simple yet flavorful"
}
]
},
{
"id": 2,
"name": "Salted Edamame",
"description": "Freshly steamed edamame lightly seasoned with sea salt.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/salted_edamame.png",
"price": "3.49",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 4,
"productId": 2,
"text": "Freshly steamed soybeans"
},
{
"id": 5,
"productId": 2,
"text": "Seasoned with sea salt for a light taste"
},
{
"id": 6,
"productId": 2,
"text": "A perfect healthy snack"
}
]
},
{
"id": 1,
"name": "Spicy Chicken Wings",
"description": "Crispy and spicy chicken wings with a bold flavor.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/spicy_chicken_wings.png",
"price": "5.99",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 1,
"productId": 1,
"text": "Perfectly crispy chicken wings"
},
{
"id": 2,
"productId": 1,
"text": "Infused with a bold spicy flavor"
},
{
"id": 3,
"productId": 1,
"text": "Served with a side of ranch dip"
}
]
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Product
Create a new product for a company.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"category_id\": 1,
\"name\": \"Lahmacun\",
\"description\": \"A delicious lahmacun\",
\"image\": \"https:\\/\\/tuckerfox.fmstech.com.tr\\/assets\\/images\\/food1.png\",
\"price\": 5.99,
\"delivery_available\": true,
\"pickup_available\": true,
\"available\": true,
\"is_top_seller\": false
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"category_id": 1,
"name": "Lahmacun",
"description": "A delicious lahmacun",
"image": "https:\/\/tuckerfox.fmstech.com.tr\/assets\/images\/food1.png",
"price": 5.99,
"delivery_available": true,
"pickup_available": true,
"available": true,
"is_top_seller": false
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'category_id' => 1,
'name' => 'Lahmacun',
'description' => 'A delicious lahmacun',
'image' => 'https://tuckerfox.fmstech.com.tr/assets/images/food1.png',
'price' => 5.99,
'delivery_available' => true,
'pickup_available' => true,
'available' => true,
'is_top_seller' => false,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Product
Get detailed information about a specific product.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Product retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"name": "Spicy Chicken Wings",
"description": "Crispy and spicy chicken wings with a bold flavor.",
"image": "https://tuckerfox.fmstech.com.tr/assets/images/spicy_chicken_wings.png",
"price": "5.99",
"deliveryAvailable": true,
"pickupAvailable": true,
"available": true,
"isTopSeller": false,
"options": [
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
}
],
"bulletPoints": [
{
"id": 1,
"productId": 1,
"text": "Perfectly crispy chicken wings"
},
{
"id": 2,
"productId": 1,
"text": "Infused with a bold spicy flavor"
},
{
"id": 3,
"productId": 1,
"text": "Served with a side of ranch dip"
}
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Product
Update an existing product's information.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Kunafah\",
\"description\": \"The best kunafah in the world\",
\"image\": \"https:\\/\\/tuckerfox.fmstech.com.tr\\/assets\\/images\\/food2.png\",
\"price\": 6.99,
\"delivery_available\": true,
\"pickup_available\": true,
\"available\": true,
\"is_top_seller\": false
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Kunafah",
"description": "The best kunafah in the world",
"image": "https:\/\/tuckerfox.fmstech.com.tr\/assets\/images\/food2.png",
"price": 6.99,
"delivery_available": true,
"pickup_available": true,
"available": true,
"is_top_seller": false
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Kunafah',
'description' => 'The best kunafah in the world',
'image' => 'https://tuckerfox.fmstech.com.tr/assets/images/food2.png',
'price' => 6.99,
'delivery_available' => true,
'pickup_available' => true,
'available' => true,
'is_top_seller' => false,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Product
Remove a product from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add Bullet Point
Add a new bullet point to a product.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"text\": \"Crispy and creamy\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"text": "Crispy and creamy"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'text' => 'Crispy and creamy',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Bullet Point
Update an existing bullet point of a product.
Example request:
curl --request PUT \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"text\": \"Delicious and crispy\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"text": "Delicious and crispy"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1';
$response = $client->put(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'text' => 'Delicious and crispy',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Bullet point updated successfully",
"statusCode": 200,
"data": {
"id": 1,
"productId": 1,
"text": "Delicious and crispy"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Bullet Point
Remove a bullet point from a product.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/bullet-points/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add Option
Add a new option to a product.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"option_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"option_id": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'option_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Option
Remove an option from a product.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/products/1/options/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Option
APIs for managing product options and customizations
List Product Options
Get a list of all available options for products.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Product options listed successfully",
"statusCode": 200,
"data": [
{
"id": 8,
"name": "Extra Toppings",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 2,
"options": [
{
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
},
{
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
},
{
"id": 11,
"name": "Beef",
"price": 2.5,
"type": "option"
},
{
"id": 12,
"name": "Pork",
"price": 2.5,
"type": "option"
}
]
},
{
"id": 4,
"name": "Extra Sauce",
"price": 0,
"type": "select",
"minSelect": 0,
"maxSelect": 3,
"options": [
{
"id": 5,
"name": "Garlic Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
},
{
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
]
},
{
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Product Option
Create a new option or customization for products.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"parent_option_id\": null,
\"name\": \"Extra Cheese\",
\"price\": null,
\"type\": \"select\",
\"min_select\": 1,
\"max_select\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"parent_option_id": null,
"name": "Extra Cheese",
"price": null,
"type": "select",
"min_select": 1,
"max_select": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'parent_option_id' => null,
'name' => 'Extra Cheese',
'price' => null,
'type' => 'select',
'min_select' => 1,
'max_select' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Product Option
Get detailed information about a specific product option.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Product option retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"name": "Spicy",
"price": 0,
"type": "select",
"minSelect": 1,
"maxSelect": 1,
"options": [
{
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
},
{
"id": 3,
"name": "Spicy: No",
"price": 0,
"type": "option"
}
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Product Option
Update the details of an existing product option.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Extra Cheese for Your Pizza\",
\"price\": null,
\"type\": \"select\",
\"min_select\": 1,
\"max_select\": 2
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Extra Cheese for Your Pizza",
"price": null,
"type": "select",
"min_select": 1,
"max_select": 2
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Extra Cheese for Your Pizza',
'price' => null,
'type' => 'select',
'min_select' => 1,
'max_select' => 2,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Product Option
Remove a product option from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/product-options/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Basket
APIs for managing shopping baskets
List Baskets
Get a list of all shopping baskets for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Baskets retrieved successfully",
"statusCode": 200,
"data": [
{
"id": 2,
"status": "ordered",
"productsTotal": "24.47",
"optionsTotal": "10.50",
"deliveryTotal": "0.00",
"discountsTotal": "10.99",
"total": "23.98",
"suburb": {
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
"products": [
{
"id": 4,
"basketId": 2,
"productId": 10,
"name": "Pepperoni Pizza",
"quantity": 2,
"unitPrice": "8.99",
"productTotal": "17.98",
"optionsTotal": "8.00",
"total": "25.98",
"options": [
{
"id": 5,
"basketProductId": 4,
"name": "Extra Sauce: BBQ Sauce",
"price": "1.50",
"total": "3.00",
"option": {
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
}
},
{
"id": 6,
"basketProductId": 4,
"name": "Extra Toppings: Chicken",
"price": "2.50",
"total": "5.00",
"option": {
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
}
}
]
},
{
"id": 5,
"basketId": 2,
"productId": 13,
"name": "Caesar Salad",
"quantity": 1,
"unitPrice": "6.49",
"productTotal": "6.49",
"optionsTotal": "2.50",
"total": "8.99",
"options": [
{
"id": 7,
"basketProductId": 5,
"name": "Extra Toppings: Prawns",
"price": "2.50",
"total": "2.50",
"option": {
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
}
}
]
}
],
"discounts": [
{
"id": 3,
"amount": "6.99",
"promotion": {
"id": 3,
"icon": "percentage",
"title": "Big Order Discount",
"description": "20% OFF on all orders over $50.00",
"discountPercentage": "20.00",
"discountFlat": null,
"minOrderAmount": "50.00",
"maxDiscountAmount": "50.00",
"canBeCombined": false,
"isFreeDelivery": false
}
},
{
"id": 4,
"amount": "4.00",
"promotion": {
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
}
}
]
},
{
"id": 1,
"status": "pending",
"productsTotal": "47.20",
"optionsTotal": "9.00",
"deliveryTotal": "0.00",
"discountsTotal": "8.62",
"total": "47.58",
"suburb": {
"id": 1,
"name": "Woodend",
"deliveryFee": "3.00"
},
"products": [
{
"id": 1,
"basketId": 1,
"productId": 6,
"name": "Honey Chicken",
"quantity": 1,
"unitPrice": "16.80",
"productTotal": "16.80",
"optionsTotal": "1.50",
"total": "18.30",
"options": [
{
"id": 1,
"basketProductId": 1,
"name": "Extra Sauce: BBQ Sauce",
"price": "1.50",
"total": "1.50",
"option": {
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
}
}
]
},
{
"id": 2,
"basketId": 1,
"productId": 8,
"name": "Special Fried Rice",
"quantity": 1,
"unitPrice": "16.80",
"productTotal": "16.80",
"optionsTotal": "2.50",
"total": "19.30",
"options": [
{
"id": 2,
"basketProductId": 2,
"name": "Spicy: Spicy: Yes",
"price": "1.00",
"total": "1.00",
"option": {
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
}
},
{
"id": 3,
"basketProductId": 2,
"name": "Extra Sauce: Sweet Chilli Sauce",
"price": "1.50",
"total": "1.50",
"option": {
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
}
]
},
{
"id": 3,
"basketId": 1,
"productId": 9,
"name": "Spring Roll (3pcs)",
"quantity": 2,
"unitPrice": "6.80",
"productTotal": "13.60",
"optionsTotal": "5.00",
"total": "18.60",
"options": [
{
"id": 4,
"basketProductId": 3,
"name": "Extra Toppings: Prawns",
"price": "2.50",
"total": "5.00",
"option": {
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
}
}
]
}
],
"discounts": [
{
"id": 1,
"amount": "5.62",
"promotion": {
"id": 1,
"icon": "percentage",
"title": "First Order Discount",
"description": "10% OFF on first orders over $10.00",
"discountPercentage": "10.00",
"discountFlat": null,
"minOrderAmount": "10.00",
"maxDiscountAmount": "10.00",
"canBeCombined": false,
"isFreeDelivery": false
}
},
{
"id": 2,
"amount": "3.00",
"promotion": {
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
}
}
]
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Basket
Create a new empty shopping basket.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/create" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/create"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/create';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show Basket
Get details of a specific shopping basket.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Basket retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"status": "pending",
"productsTotal": "47.20",
"optionsTotal": "9.00",
"deliveryTotal": "0.00",
"discountsTotal": "8.62",
"total": "47.58",
"suburb": {
"id": 1,
"name": "Woodend",
"deliveryFee": "3.00"
},
"products": [
{
"id": 1,
"basketId": 1,
"productId": 6,
"name": "Honey Chicken",
"quantity": 1,
"unitPrice": "16.80",
"productTotal": "16.80",
"optionsTotal": "1.50",
"total": "18.30",
"options": [
{
"id": 1,
"basketProductId": 1,
"name": "Extra Sauce: BBQ Sauce",
"price": "1.50",
"total": "1.50",
"option": {
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
}
}
]
},
{
"id": 2,
"basketId": 1,
"productId": 8,
"name": "Special Fried Rice",
"quantity": 1,
"unitPrice": "16.80",
"productTotal": "16.80",
"optionsTotal": "2.50",
"total": "19.30",
"options": [
{
"id": 2,
"basketProductId": 2,
"name": "Spicy: Spicy: Yes",
"price": "1.00",
"total": "1.00",
"option": {
"id": 2,
"name": "Spicy: Yes",
"price": 1,
"type": "option"
}
},
{
"id": 3,
"basketProductId": 2,
"name": "Extra Sauce: Sweet Chilli Sauce",
"price": "1.50",
"total": "1.50",
"option": {
"id": 7,
"name": "Sweet Chilli Sauce",
"price": 1.5,
"type": "option"
}
}
]
},
{
"id": 3,
"basketId": 1,
"productId": 9,
"name": "Spring Roll (3pcs)",
"quantity": 2,
"unitPrice": "6.80",
"productTotal": "13.60",
"optionsTotal": "5.00",
"total": "18.60",
"options": [
{
"id": 4,
"basketProductId": 3,
"name": "Extra Toppings: Prawns",
"price": "2.50",
"total": "5.00",
"option": {
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
}
}
]
}
],
"discounts": [
{
"id": 1,
"amount": "5.62",
"promotion": {
"id": 1,
"icon": "percentage",
"title": "First Order Discount",
"description": "10% OFF on first orders over $10.00",
"discountPercentage": "10.00",
"discountFlat": null,
"minOrderAmount": "10.00",
"maxDiscountAmount": "10.00",
"canBeCombined": false,
"isFreeDelivery": false
}
},
{
"id": 2,
"amount": "3.00",
"promotion": {
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
}
}
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Basket
Remove a shopping basket and all its contents.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Set Suburb
Assign a delivery suburb to the basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/set-suburb" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"suburb_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/set-suburb"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"suburb_id": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/set-suburb';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'suburb_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add Product to Basket
Add a product to an existing shopping basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-product" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"product_id\": 1,
\"options\": \"[2, 3]\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-product"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"product_id": 1,
"options": "[2, 3]"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-product';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'product_id' => 1,
'options' => '[2, 3]',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove Product from Basket
Remove a product from a shopping basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-product" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"basket_product_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-product"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"basket_product_id": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-product';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'basket_product_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Product Quantity
Update the quantity of a product in a shopping basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/update-product-quantity" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"basket_product_id\": 1,
\"quantity\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/update-product-quantity"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"basket_product_id": 1,
"quantity": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/update-product-quantity';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'basket_product_id' => 1,
'quantity' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add Promotion to Basket
Add a promotion code to the basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-promotion" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"promotion_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-promotion"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"promotion_id": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/add-promotion';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'promotion_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove Promotion from Basket
Remove a promotion code from the basket.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-promotion" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"basket_promotion_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-promotion"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"basket_promotion_id": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/baskets/1/remove-promotion';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'basket_promotion_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Order
APIs for managing company orders
List Orders
Get a list of all orders for a company.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Orders listed successfully",
"statusCode": 200,
"data": [
{
"id": 1,
"companyId": 1,
"deliverySuburbId": 2,
"paymentMethodId": 1,
"basketId": 2,
"orderNumber": "PBI41PQK",
"status": "pending",
"contactName": "John",
"contactSurname": "Doe",
"contactEmail": "john.doe@example.com",
"contactMobile": "+61412345678",
"deliveryStreet": "15 Smith Street",
"deliveryApartment": "Unit 4",
"deliveryInstructions": "Please ring the doorbell twice",
"deliveryMethod": "delivery",
"deliveryTime": "2025-01-30T13:24:58.000000Z",
"productsTotal": "24.47",
"optionsTotal": "10.50",
"deliveryTotal": "0.00",
"discountsTotal": "10.99",
"total": "23.98",
"deliverySuburb": {
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
"paymentMethod": {
"id": 1,
"name": "Visa",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/visa.png"
},
"basket": {
"id": 2,
"status": "ordered",
"productsTotal": "24.47",
"optionsTotal": "10.50",
"deliveryTotal": "0.00",
"discountsTotal": "10.99",
"total": "23.98",
"suburb": {
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
"products": [
{
"id": 4,
"basketId": 2,
"productId": 10,
"name": "Pepperoni Pizza",
"quantity": 2,
"unitPrice": "8.99",
"productTotal": "17.98",
"optionsTotal": "8.00",
"total": "25.98",
"options": [
{
"id": 5,
"basketProductId": 4,
"name": "Extra Sauce: BBQ Sauce",
"price": "1.50",
"total": "3.00",
"option": {
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
}
},
{
"id": 6,
"basketProductId": 4,
"name": "Extra Toppings: Chicken",
"price": "2.50",
"total": "5.00",
"option": {
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
}
}
]
},
{
"id": 5,
"basketId": 2,
"productId": 13,
"name": "Caesar Salad",
"quantity": 1,
"unitPrice": "6.49",
"productTotal": "6.49",
"optionsTotal": "2.50",
"total": "8.99",
"options": [
{
"id": 7,
"basketProductId": 5,
"name": "Extra Toppings: Prawns",
"price": "2.50",
"total": "2.50",
"option": {
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
}
}
]
}
],
"discounts": [
{
"id": 3,
"amount": "6.99",
"promotion": {
"id": 3,
"icon": "percentage",
"title": "Big Order Discount",
"description": "20% OFF on all orders over $50.00",
"discountPercentage": "20.00",
"discountFlat": null,
"minOrderAmount": "50.00",
"maxDiscountAmount": "50.00",
"canBeCombined": false,
"isFreeDelivery": false
}
},
{
"id": 4,
"amount": "4.00",
"promotion": {
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
}
}
]
}
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create Order
Create a new order from a shopping basket.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"payment_method_id\": 1,
\"basket_id\": 1,
\"contact_name\": \"Fatih\",
\"contact_surname\": \"Johnson\",
\"contact_email\": \"fatih.johnson@example.com\",
\"contact_mobile\": \"05555555555\",
\"delivery_street\": \"123 Main St\",
\"delivery_apartment\": \"101\",
\"delivery_instructions\": \"Leave at the door\",
\"delivery_method\": \"delivery\",
\"delivery_time\": \"2025-01-01 10:00:00\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"payment_method_id": 1,
"basket_id": 1,
"contact_name": "Fatih",
"contact_surname": "Johnson",
"contact_email": "fatih.johnson@example.com",
"contact_mobile": "05555555555",
"delivery_street": "123 Main St",
"delivery_apartment": "101",
"delivery_instructions": "Leave at the door",
"delivery_method": "delivery",
"delivery_time": "2025-01-01 10:00:00"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'payment_method_id' => 1,
'basket_id' => 1,
'contact_name' => 'Fatih',
'contact_surname' => 'Johnson',
'contact_email' => 'fatih.johnson@example.com',
'contact_mobile' => '05555555555',
'delivery_street' => '123 Main St',
'delivery_apartment' => '101',
'delivery_instructions' => 'Leave at the door',
'delivery_method' => 'delivery',
'delivery_time' => '2025-01-01 10:00:00',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Order
Get detailed information about a specific order.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "Order retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"companyId": 1,
"deliverySuburbId": 2,
"paymentMethodId": 1,
"basketId": 2,
"orderNumber": "PBI41PQK",
"status": "pending",
"contactName": "John",
"contactSurname": "Doe",
"contactEmail": "john.doe@example.com",
"contactMobile": "+61412345678",
"deliveryStreet": "15 Smith Street",
"deliveryApartment": "Unit 4",
"deliveryInstructions": "Please ring the doorbell twice",
"deliveryMethod": "delivery",
"deliveryTime": "2025-01-30T13:24:58.000000Z",
"productsTotal": "24.47",
"optionsTotal": "10.50",
"deliveryTotal": "0.00",
"discountsTotal": "10.99",
"total": "23.98",
"deliverySuburb": {
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
"paymentMethod": {
"id": 1,
"name": "Visa",
"icon": "https://tuckerfox.fmstech.com.tr/assets/images/visa.png"
},
"basket": {
"id": 2,
"status": "ordered",
"productsTotal": "24.47",
"optionsTotal": "10.50",
"deliveryTotal": "0.00",
"discountsTotal": "10.99",
"total": "23.98",
"suburb": {
"id": 2,
"name": "Macedon",
"deliveryFee": "4.00"
},
"products": [
{
"id": 4,
"basketId": 2,
"productId": 10,
"name": "Pepperoni Pizza",
"quantity": 2,
"unitPrice": "8.99",
"productTotal": "17.98",
"optionsTotal": "8.00",
"total": "25.98",
"options": [
{
"id": 5,
"basketProductId": 4,
"name": "Extra Sauce: BBQ Sauce",
"price": "1.50",
"total": "3.00",
"option": {
"id": 6,
"name": "BBQ Sauce",
"price": 1.5,
"type": "option"
}
},
{
"id": 6,
"basketProductId": 4,
"name": "Extra Toppings: Chicken",
"price": "2.50",
"total": "5.00",
"option": {
"id": 10,
"name": "Chicken",
"price": 2.5,
"type": "option"
}
}
]
},
{
"id": 5,
"basketId": 2,
"productId": 13,
"name": "Caesar Salad",
"quantity": 1,
"unitPrice": "6.49",
"productTotal": "6.49",
"optionsTotal": "2.50",
"total": "8.99",
"options": [
{
"id": 7,
"basketProductId": 5,
"name": "Extra Toppings: Prawns",
"price": "2.50",
"total": "2.50",
"option": {
"id": 9,
"name": "Prawns",
"price": 2.5,
"type": "option"
}
}
]
}
],
"discounts": [
{
"id": 3,
"amount": "6.99",
"promotion": {
"id": 3,
"icon": "percentage",
"title": "Big Order Discount",
"description": "20% OFF on all orders over $50.00",
"discountPercentage": "20.00",
"discountFlat": null,
"minOrderAmount": "50.00",
"maxDiscountAmount": "50.00",
"canBeCombined": false,
"isFreeDelivery": false
}
},
{
"id": 4,
"amount": "4.00",
"promotion": {
"id": 2,
"icon": "vespa",
"title": "Free Delivery",
"description": "Free Delivery on delivery orders over $5.00",
"discountPercentage": null,
"discountFlat": null,
"minOrderAmount": "5.00",
"maxDiscountAmount": null,
"canBeCombined": true,
"isFreeDelivery": true
}
}
]
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Order
Update an existing order's information.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contact_name\": \"Berkay\",
\"contact_surname\": \"Stonebig\",
\"contact_email\": \"berkay.stonebig@example.com\",
\"contact_mobile\": \"05432165432\",
\"delivery_street\": \"123 Main St\",
\"delivery_apartment\": \"101\",
\"delivery_instructions\": \"Leave at the door\",
\"delivery_method\": \"delivery\",
\"delivery_time\": \"2025-01-01 15:00:00\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contact_name": "Berkay",
"contact_surname": "Stonebig",
"contact_email": "berkay.stonebig@example.com",
"contact_mobile": "05432165432",
"delivery_street": "123 Main St",
"delivery_apartment": "101",
"delivery_instructions": "Leave at the door",
"delivery_method": "delivery",
"delivery_time": "2025-01-01 15:00:00"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'contact_name' => 'Berkay',
'contact_surname' => 'Stonebig',
'contact_email' => 'berkay.stonebig@example.com',
'contact_mobile' => '05432165432',
'delivery_street' => '123 Main St',
'delivery_apartment' => '101',
'delivery_instructions' => 'Leave at the door',
'delivery_method' => 'delivery',
'delivery_time' => '2025-01-01 15:00:00',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Order
Remove an order from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Set Order Status
Update the status of an order. Only pending orders can be modified.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1/status" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"status\": \"pending\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1/status"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"status": "pending"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/companies/1/orders/1/status';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'status' => 'pending',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
URL Rule
APIs for managing URL rules
List URL Rules
Get a list of all URL rules.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/url-rules" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "URL rules listed successfully",
"statusCode": 200,
"data": [
{
"id": 2,
"domain": "tf-store-2.fmstech.com.tr",
"companyType": "whitelabel",
"companyId": 2,
"createdAt": "2025-01-30T12:24:58.000000Z",
"updatedAt": "2025-01-30T12:24:58.000000Z"
},
{
"id": 1,
"domain": "tf-store-1.fmstech.com.tr",
"companyType": "whitelabel",
"companyId": 1,
"createdAt": "2025-01-30T12:24:58.000000Z",
"updatedAt": "2025-01-30T12:24:58.000000Z"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create URL Rule
Add a new URL rule to the system.
Example request:
curl --request POST \
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"domain\": \"example.com\",
\"company_type\": \"whitelabel\",
\"company_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"domain": "example.com",
"company_type": "whitelabel",
"company_id": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules';
$response = $client->post(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'domain' => 'example.com',
'company_type' => 'whitelabel',
'company_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for POST & PATCH requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Find URL Rule by Domain
Find a URL rule by its domain name.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/url-rules/find-by-domain?domain=example.com" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"domain\": \"epxahu\"
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/find-by-domain"
);
const params = {
"domain": "example.com",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"domain": "epxahu"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules/find-by-domain';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'query' => [
'domain' => 'example.com',
],
'json' => [
'domain' => 'epxahu',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (404):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "URL rule not found",
"statusCode": 404
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get URL Rule
Get detailed information about a specific URL rule.
Example request:
curl --request GET \
--get "https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1';
$response = $client->get(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": true,
"message": "URL rule retrieved successfully",
"statusCode": 200,
"data": {
"id": 1,
"domain": "tf-store-1.fmstech.com.tr",
"companyType": "whitelabel",
"companyId": 1,
"createdAt": "2025-01-30T12:24:58.000000Z",
"updatedAt": "2025-01-30T12:24:58.000000Z"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update URL Rule
Update the details of an existing URL rule.
Example request:
curl --request PATCH \
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"domain\": \"example.com\",
\"company_type\": \"whitelabel\",
\"company_id\": 1
}"
const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"domain": "example.com",
"company_type": "whitelabel",
"company_id": 1
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1';
$response = $client->patch(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'domain' => 'example.com',
'company_type' => 'whitelabel',
'company_id' => 1,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete URL Rule
Remove a URL rule from the system.
Example request:
curl --request DELETE \
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());$client = new \GuzzleHttp\Client();
$url = 'https://tuckerfox.fmstech.com.tr/api/v1/url-rules/1';
$response = $client->delete(
$url,
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
{
"success": false,
"message": "API token is required for DELETE requests",
"statusCode": 401
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.