Skip to content

Latest commit

 

History

History
420 lines (280 loc) · 10.9 KB

StoreGroupsApi.md

File metadata and controls

420 lines (280 loc) · 10.9 KB

Flipdish.StoreGroupsApi

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

Method HTTP request Description
assignStoresToStoreGroup POST /api/v1.0/{appId}/storegroups/{storeGroupId}/assignStores
createStoreGroup POST /api/v1.0/{appNameId}/storegroups
getStoreGroup GET /api/v1.0/storegroups/{storeGroupId}
getStoreGroups GET /api/v1.0/{appNameId}/storegroups
getStoreGroupsExtended GET /api/v1.0/{appNameId}/storegroups/extended
removeStoreGroup DELETE /api/v1.0/storegroups/{storeGroupId}
setCustomerMessages POST /api/v1.0/storegroups/{storeGroupId}/CustomerMessages
updateStoreGroup POST /api/v1.0/storegroups/{storeGroupId}

assignStoresToStoreGroup

assignStoresToStoreGroup(appId, storeGroupId, storeIds)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let appId = "appId_example"; // String | 
let storeGroupId = 56; // Number | 
let storeIds = [null]; // [Number] | 
apiInstance.assignStoresToStoreGroup(appId, storeGroupId, storeIds, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
});

Parameters

Name Type Description Notes
appId String
storeGroupId Number
storeIds [Number]

Return type

null (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

createStoreGroup

RestApiResultStoreGroup createStoreGroup(appNameId, storeGroup)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let appNameId = "appNameId_example"; // String | 
let storeGroup = new Flipdish.StoreGroupBase(); // StoreGroupBase | 
apiInstance.createStoreGroup(appNameId, storeGroup, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
appNameId String
storeGroup StoreGroupBase

Return type

RestApiResultStoreGroup

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, Data

getStoreGroup

RestApiResultStoreGroup getStoreGroup(storeGroupId)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let storeGroupId = 56; // Number | 
apiInstance.getStoreGroup(storeGroupId, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
storeGroupId Number

Return type

RestApiResultStoreGroup

Authorization

oauth2

HTTP request headers

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

getStoreGroups

RestApiPaginationResultStoreGroup getStoreGroups(appNameId, opts)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let appNameId = "appNameId_example"; // String | 
let opts = {
  'searchQuery': "searchQuery_example", // String | 
  'page': 56, // Number | 
  'limit': 56 // Number | 
};
apiInstance.getStoreGroups(appNameId, opts, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
appNameId String
searchQuery String [optional]
page Number [optional]
limit Number [optional]

Return type

RestApiPaginationResultStoreGroup

Authorization

oauth2

HTTP request headers

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

getStoreGroupsExtended

RestApiPaginationResultStoreGroupExtended getStoreGroupsExtended(appNameId, opts)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let appNameId = "appNameId_example"; // String | 
let opts = {
  'searchQuery': "searchQuery_example", // String | 
  'page': 56, // Number | 
  'limit': 56, // Number | 
  'groupingRadius': 56 // Number | 
};
apiInstance.getStoreGroupsExtended(appNameId, opts, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
appNameId String
searchQuery String [optional]
page Number [optional]
limit Number [optional]
groupingRadius Number [optional]

Return type

RestApiPaginationResultStoreGroupExtended

Authorization

oauth2

HTTP request headers

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

removeStoreGroup

removeStoreGroup(storeGroupId)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let storeGroupId = 56; // Number | 
apiInstance.removeStoreGroup(storeGroupId, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
});

Parameters

Name Type Description Notes
storeGroupId Number

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

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

setCustomerMessages

setCustomerMessages(storeGroupId, customerMessages)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let storeGroupId = 56; // Number | 
let customerMessages = new Flipdish.CustomerMessages(); // CustomerMessages | 
apiInstance.setCustomerMessages(storeGroupId, customerMessages, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
});

Parameters

Name Type Description Notes
storeGroupId Number
customerMessages CustomerMessages

Return type

null (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

updateStoreGroup

RestApiResultStoreGroupBase updateStoreGroup(storeGroupId, storeGroup)

Example

import Flipdish from '@flipdish/api-client-javascript';
let defaultClient = Flipdish.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';

let apiInstance = new Flipdish.StoreGroupsApi();
let storeGroupId = 56; // Number | 
let storeGroup = new Flipdish.StoreGroupBase(); // StoreGroupBase | 
apiInstance.updateStoreGroup(storeGroupId, storeGroup, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
storeGroupId Number
storeGroup StoreGroupBase

Return type

RestApiResultStoreGroupBase

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, Data