Skip to content

Latest commit

 

History

History
604 lines (435 loc) · 20.2 KB

File metadata and controls

604 lines (435 loc) · 20.2 KB

Flipdish\Client\MenuZonesApi

All URIs are relative to https://api.flipdish.co

Method HTTP request Description
addMenuZone POST /api/v1.0/menus/{menuId}/zones Adds a new menu zone to a menu.
deleteMenuZone DELETE /api/v1.0/menus/{menuId}/zones/{menuZoneId} Deletes a menu zone.
deleteMenuZoneImage DELETE /api/v1.0/menus/{menuId}/zones/{menuZoneId}/image Deletes a menu zone image.
flipMenuZones PUT /api/v1.0/menus/{menuId}/zones/{menuZoneId}/flip/{menuZoneI2} Flips the order of two menu zones.
getMenuZone GET /api/v1.0/menus/{menuId}/zones/{menuZoneId} Gets a specific menu zone for a given zone id
getMenuZonesForMenuId GET /api/v1.0/menus/{menuId}/zones Gets all the menu zones for a menu
setMenuSectionMenuZone PUT /api/v1.0/menus/{menuId}/zones/{menuZoneId}/section/{menuSectionId} Assigns a zone to a menu section.
setMenuZoneDescription PUT /api/v1.0/menus/{menuId}/zones/{menuZoneId}/description Sets the description of a menu zone.
setMenuZoneName PUT /api/v1.0/menus/{menuId}/zones/{menuZoneId}/name/{menuZoneName} Sets the name of a menu zone.
updateMenuZone PUT /api/v1.0/menus/{menuId}/zones/{menuZoneId} Updates a menu zone.
uploadMenuZoneImage POST /api/v1.0/menus/{menuId}/zones/{menuZoneId}/image Uploads an image for a menu zone.

addMenuZone

\Flipdish\Client\Models\RestApiResultMenuZone addMenuZone($menu_id, $menu_zone)

Adds a new menu zone to a menu.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_id = 56; // int | The menu id.
$menu_zone = new \Flipdish\\Client\Models\MenuZone(); // \Flipdish\\Client\Models\MenuZone | The object containing the new zone. This is optional and not supplying it will generate an empty default zone.

try {
    $result = $apiInstance->addMenuZone($menu_id, $menu_zone);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->addMenuZone: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_id int The menu id.
menu_zone \Flipdish\Client\Models\MenuZone The object containing the new zone. This is optional and not supplying it will generate an empty default zone.

Return type

\Flipdish\Client\Models\RestApiResultMenuZone

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

deleteMenuZone

deleteMenuZone($menu_zone_id, $menu_id)

Deletes a menu zone.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The menu zone id.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->deleteMenuZone($menu_zone_id, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->deleteMenuZone: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The menu zone id.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

deleteMenuZoneImage

deleteMenuZoneImage($menu_zone_id, $menu_id)

Deletes a menu zone image.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The zone Id/
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->deleteMenuZoneImage($menu_zone_id, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->deleteMenuZoneImage: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The zone Id/
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

flipMenuZones

flipMenuZones($menu_zone_id, $menu_zone_i2, $menu_id)

Flips the order of two menu zones.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | Source.
$menu_zone_i2 = 56; // int | Destination.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->flipMenuZones($menu_zone_id, $menu_zone_i2, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->flipMenuZones: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int Source.
menu_zone_i2 int Destination.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getMenuZone

\Flipdish\Client\Models\RestApiResultMenuZone getMenuZone($menu_id, $menu_zone_id)

Gets a specific menu zone for a given zone id

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_id = 56; // int | The menu id.
$menu_zone_id = 56; // int | The menu zone id.

try {
    $result = $apiInstance->getMenuZone($menu_id, $menu_zone_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->getMenuZone: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_id int The menu id.
menu_zone_id int The menu zone id.

Return type

\Flipdish\Client\Models\RestApiResultMenuZone

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getMenuZonesForMenuId

\Flipdish\Client\Models\RestApiArrayResultMenuZone getMenuZonesForMenuId($menu_id)

Gets all the menu zones for a menu

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_id = 56; // int | The menu id to load zones for

try {
    $result = $apiInstance->getMenuZonesForMenuId($menu_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->getMenuZonesForMenuId: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_id int The menu id to load zones for

Return type

\Flipdish\Client\Models\RestApiArrayResultMenuZone

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

setMenuSectionMenuZone

setMenuSectionMenuZone($menu_zone_id, $menu_section_id, $menu_id)

Assigns a zone to a menu section.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The menu id.
$menu_section_id = 56; // int | The menu section id.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->setMenuSectionMenuZone($menu_zone_id, $menu_section_id, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->setMenuSectionMenuZone: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The menu id.
menu_section_id int The menu section id.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

setMenuZoneDescription

setMenuZoneDescription($menu_zone_id, $description, $menu_id)

Sets the description of a menu zone.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The zone id.
$description = "description_example"; // string | The new description. Add as a raw string in the request, without any JSON wrapper.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->setMenuZoneDescription($menu_zone_id, $description, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->setMenuZoneDescription: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The zone id.
description string The new description. Add as a raw string in the request, without any JSON wrapper.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

setMenuZoneName

setMenuZoneName($menu_zone_id, $menu_zone_name, $menu_id)

Sets the name of a menu zone.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The menu zone id.
$menu_zone_name = "menu_zone_name_example"; // string | The new name.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->setMenuZoneName($menu_zone_id, $menu_zone_name, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->setMenuZoneName: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The menu zone id.
menu_zone_name string The new name.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

updateMenuZone

updateMenuZone($menu_id, $menu_zone_id, $menu_zone)

Updates a menu zone.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_id = 56; // int | The menu id.
$menu_zone_id = 56; // int | The menu zone id.
$menu_zone = new \Flipdish\\Client\Models\MenuZone(); // \Flipdish\\Client\Models\MenuZone | The object containing the updated values.

try {
    $apiInstance->updateMenuZone($menu_id, $menu_zone_id, $menu_zone);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->updateMenuZone: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_id int The menu id.
menu_zone_id int The menu zone id.
menu_zone \Flipdish\Client\Models\MenuZone The object containing the updated values.

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

uploadMenuZoneImage

uploadMenuZoneImage($menu_zone_id, $file, $menu_id)

Uploads an image for a menu zone.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth2
$config = Flipdish\\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Flipdish\\Client\Api\MenuZonesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$menu_zone_id = 56; // int | The zone id.
$file = array(new \Flipdish\\Client\Models\HttpPostedFileBase()); // \Flipdish\\Client\Models\HttpPostedFileBase[] | The file to upload.
$menu_id = "menu_id_example"; // string | 

try {
    $apiInstance->uploadMenuZoneImage($menu_zone_id, $file, $menu_id);
} catch (Exception $e) {
    echo 'Exception when calling MenuZonesApi->uploadMenuZoneImage: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
menu_zone_id int The zone id.
file \Flipdish\Client\Models\HttpPostedFileBase[] The file to upload.
menu_id string

Return type

void (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
  • Accept: application/json, text/json, application/xml, text/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]