Purpose

Send new settings to the agent. Method access is limited

Request typeAsynchronous/synchronous
Supported agent versionv2
PluggetSystemTypeAgentInternal

Request format


JSON

{
  "taskType": "ServicePushAgentSettings",
  "params": {
    "async": {
      "objectId": number,
       "timeout": number
    },
    "sync": {
      "objectId": number,
       "timeout": number
    },
    "settings":{}
  }
}

Parameter

Type

Mandatory

Description

taskTypestringyesTask type. For this method, the value is ServicePushAgentSettings
-async

Asynchronous method call: either synchronous or asynchronous
-sync

Synchronous method call: either synchronous or asynchronous
--timeoutintnoAgent response time in seconds. Default is 120 seconds
--objectIdintyesRestaurant code in the licensing system
settingsobjectyesAgent settings as a json object

Synchronous response format


JSON

{
   "responseCommon":{
      "taskGuid":"guid",
      "taskType":"ServicePushAgentSettings",
      "objectId": 0
   },
   "error":{
      "wsError":{
         "code":"string",
         "desc":"string"
      }
   }
}

Parameter

Type

Description

-taskGuidguidUnique code for this task. Used when receiving a task via the queue
-taskTypestring enumТип задачи
-objectIdintRestaurant code in the licensing system
error
Error container, for more details see the article Error Description

Asynchronous response format

Successful response


JSON

{
  "responseCommon": {
    "taskGuid": "string",
    "taskType": "ServicePushAgentSettings",
    "objectId": 0
  }
}



Response with error


JSON

{
  "taskResponse":{
 
      },
  "responseCommon": {
    "taskGuid": "string",
    "taskType": "ServicePushAgentSettings",
    "objectId": 0
  },
  "error": {
    "wsError": {
      "code": "string",
      "desc": "string"
    },
    "agentError": {
      "code": "string",
      "desc": "string"
    }
  }
}

Parameter

Parameter type

Mandatory

Description

taskResponseobjectyesFor the contents of the taskResponse block, see the GetAgentInfo model article.
errorstring enum
Error container, see article Error description

Response with access error


JSON

{
  "responseCommon": {
    "taskGuid": "34398dc7-5488-49d1-a499-fef9e8826f40",
    "taskType": "ServicePushAgentSettings",
    "objectId": 199995826
  },
  "error": {
    "wsError": {
      "code": "AuthFailed"
    }
  }
}