# ApplicationInstanceTask

Application instance task execution

## GET /v3/applicationInstance/task/template

> Get all available task templates for application instance

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskTemplate":{"type":"object","required":["id","name","description","actions"],"properties":{"id":{"type":"integer","format":"integer","description":"Task template ID","readOnly":true},"name":{"type":"string","format":"","description":"Task template name","readOnly":true},"description":{"type":"string","format":"","description":"Task template description","readOnly":true},"actions":{"type":"array","items":{"$ref":"#/components/schemas/TaskTemplateAction"},"description":"Task template actions","readOnly":true}},"additionalProperties":false},"TaskTemplateAction":{"type":"object","required":["idx","actionType","requiredParams"],"properties":{"idx":{"type":"integer","format":"integer","description":"Task template action execution order","readOnly":true},"actionType":{"type":"string","format":"","description":"Task template action type","readOnly":true},"requiredParams":{"type":"array","items":{"type":"string","format":""},"description":"Parameters required by this argument","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task/template":{"get":{"tags":["ApplicationInstanceTask"],"summary":"Get all available task templates for application instance","operationId":"getApplicationInstanceTaskTemplates","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskTemplate"}}}}},"403":{"description":"Invalid credentials"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## GET /v3/applicationInstance/task

> Get the last 100 tasks you have created

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskStatus":{"type":"object","required":["id","name","batchId","categoryId","entityId","currentActionIdx","executeAt","lastActivityAt","finishedAt","resultCode","resultText"],"properties":{"id":{"type":"integer","format":"integer","description":"Task ID","readOnly":true},"name":{"type":"string","format":"","description":"Task name","readOnly":true},"batchId":{"type":"integer","format":"integer","description":"The ID of the batch the task belongs to","readOnly":true},"categoryId":{"type":"integer","format":"integer","description":"The ID of the task category. Valid values are:\n- 1: game server","readOnly":true},"entityId":{"type":"integer","format":"integer","description":"The ID of the entity the task is being executed for. E.g. a game server ID (categoryId 1)","readOnly":true},"currentActionIdx":{"type":"integer","format":"integer","description":"Currently active action index - relates to the action index as found in the template.","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating the start of execution.","readOnly":true},"lastActivityAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating lastest activity.","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"Unix timestamp at which the task was finished.","readOnly":true},"resultCode":{"type":"integer","format":"integer","description":"The result of the task. 0: pending, 1: in progress, 2: paused, 125: cancelled, 126: done with error, 127: done","readOnly":true},"resultText":{"type":"string","format":"","description":"The result of the task in message form.","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task":{"get":{"tags":["ApplicationInstanceTask"],"summary":"Get the last 100 tasks you have created","operationId":"getApplicationInstanceTasks","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskStatus"}}}}},"403":{"description":"Invalid credentials"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## POST /v3/applicationInstance/task

> Create a new task batch for given application instance Ids, using the provided task template Id

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"ApplicationInstanceTaskCreate":{"type":"object","required":["taskTemplateId"],"properties":{"taskTemplateId":{"type":"string","format":"","description":"Task template ID, as seen in GET /applicationInstance/task/template"},"applicationInstanceIds":{"type":"array","items":{"type":"string","format":""},"description":"Array of application instance IDs to create the tasks for"},"fleetId":{"type":"string","format":"","description":"If > 0, we gather all game server IDs for this fleet and add those to the gameServerIds property"},"regionId":{"type":"string","format":"","description":"If > 0, we gather all game server IDs for this region and add those to the gameServerIds property"},"labels":{"type":"array","items":{"$ref":"#/components/schemas/Label"},"description":"Optionally select game servers by label key/value pairs."},"executeAt":{"type":"integer","format":"integer","description":"A unix timestamp indicating the time at which to execute the task (to schedule tasks for future execution)"},"taskActionParam":{"type":"array","items":{"$ref":"#/components/schemas/TaskTemplateActionParameters"},"description":"The list of required action parameters for a template. See the task templates (/applicationInstance/task/template) end point for more information."}},"additionalProperties":false},"Label":{"type":"object","required":["key","value"],"properties":{"key":{"type":"string","format":"","description":"Label key, only hyphens (-), underscores (_), lowercase characters and numbers are allowed. Keys must start with a lowercase character."},"value":{"type":"string","format":"","description":"Label value, maximum length is 150 characters"}},"additionalProperties":false},"TaskTemplateActionParameters":{"type":"object","required":["paramName","paramValue"],"properties":{"paramName":{"type":"string","format":"","description":"Name of required parameters by task template."},"paramValue":{"type":"string","format":"","description":"Value of required parameters."}},"additionalProperties":false},"TaskBatchStatus":{"type":"object","required":["id","createdAt","executeAt","finishedAt","numTasks","numTasksOk","numTasksFailed","numTasksCancelled","taskIds"],"properties":{"id":{"type":"integer","format":"integer","description":"Task Batch ID","readOnly":true},"createdAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was created","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch started execution","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was finished","readOnly":true},"numTasks":{"type":"integer","format":"integer","description":"The total number of tasks in this batch","readOnly":true},"numTasksOk":{"type":"integer","format":"integer","description":"The number of successfully executed tasks","readOnly":true},"numTasksFailed":{"type":"integer","format":"integer","description":"The number of failed tasks","readOnly":true},"numTasksCancelled":{"type":"integer","format":"integer","description":"The number of cancelled tasks","readOnly":true},"taskIds":{"type":"array","items":{"type":"integer","format":"integer"},"description":"All the task IDs in this batch","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task":{"post":{"tags":["ApplicationInstanceTask"],"summary":"Create a new task batch for given application instance Ids, using the provided task template Id","operationId":"createApplicationInstanceTask","requestBody":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplicationInstanceTaskCreate"}}},"required":true},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskBatchStatus"}}}}},"403":{"description":"Invalid credentials"},"422":{"description":"Unprocessable Entity"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## GET /v3/applicationInstance/task/{taskId}

> Get the status of a task

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskStatus":{"type":"object","required":["id","name","batchId","categoryId","entityId","currentActionIdx","executeAt","lastActivityAt","finishedAt","resultCode","resultText"],"properties":{"id":{"type":"integer","format":"integer","description":"Task ID","readOnly":true},"name":{"type":"string","format":"","description":"Task name","readOnly":true},"batchId":{"type":"integer","format":"integer","description":"The ID of the batch the task belongs to","readOnly":true},"categoryId":{"type":"integer","format":"integer","description":"The ID of the task category. Valid values are:\n- 1: game server","readOnly":true},"entityId":{"type":"integer","format":"integer","description":"The ID of the entity the task is being executed for. E.g. a game server ID (categoryId 1)","readOnly":true},"currentActionIdx":{"type":"integer","format":"integer","description":"Currently active action index - relates to the action index as found in the template.","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating the start of execution.","readOnly":true},"lastActivityAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating lastest activity.","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"Unix timestamp at which the task was finished.","readOnly":true},"resultCode":{"type":"integer","format":"integer","description":"The result of the task. 0: pending, 1: in progress, 2: paused, 125: cancelled, 126: done with error, 127: done","readOnly":true},"resultText":{"type":"string","format":"","description":"The result of the task in message form.","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task/{taskId}":{"get":{"tags":["ApplicationInstanceTask"],"summary":"Get the status of a task","operationId":"getApplicationInstanceTask","parameters":[{"name":"taskId","in":"path","description":"The Id of the task","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskStatus"}}}}},"403":{"description":"Invalid credentials"},"404":{"description":"Invalid taskId"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## PUT /v3/applicationInstance/task/{taskId}

> Pause the given task if it's not done yet. Or if the task is paused already, resume it.

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskStatus":{"type":"object","required":["id","name","batchId","categoryId","entityId","currentActionIdx","executeAt","lastActivityAt","finishedAt","resultCode","resultText"],"properties":{"id":{"type":"integer","format":"integer","description":"Task ID","readOnly":true},"name":{"type":"string","format":"","description":"Task name","readOnly":true},"batchId":{"type":"integer","format":"integer","description":"The ID of the batch the task belongs to","readOnly":true},"categoryId":{"type":"integer","format":"integer","description":"The ID of the task category. Valid values are:\n- 1: game server","readOnly":true},"entityId":{"type":"integer","format":"integer","description":"The ID of the entity the task is being executed for. E.g. a game server ID (categoryId 1)","readOnly":true},"currentActionIdx":{"type":"integer","format":"integer","description":"Currently active action index - relates to the action index as found in the template.","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating the start of execution.","readOnly":true},"lastActivityAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating lastest activity.","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"Unix timestamp at which the task was finished.","readOnly":true},"resultCode":{"type":"integer","format":"integer","description":"The result of the task. 0: pending, 1: in progress, 2: paused, 125: cancelled, 126: done with error, 127: done","readOnly":true},"resultText":{"type":"string","format":"","description":"The result of the task in message form.","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task/{taskId}":{"put":{"tags":["ApplicationInstanceTask"],"summary":"Pause the given task if it's not done yet. Or if the task is paused already, resume it.","operationId":"updateApplicationInstanceTask","parameters":[{"name":"taskId","in":"path","description":"The Id of the task","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskStatus"}}}}},"403":{"description":"Invalid credentials"},"404":{"description":"Invalid taskId"},"409":{"description":"Task cannot be pause"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## DELETE /v3/applicationInstance/task/{taskId}

> Cancel the given task

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskStatus":{"type":"object","required":["id","name","batchId","categoryId","entityId","currentActionIdx","executeAt","lastActivityAt","finishedAt","resultCode","resultText"],"properties":{"id":{"type":"integer","format":"integer","description":"Task ID","readOnly":true},"name":{"type":"string","format":"","description":"Task name","readOnly":true},"batchId":{"type":"integer","format":"integer","description":"The ID of the batch the task belongs to","readOnly":true},"categoryId":{"type":"integer","format":"integer","description":"The ID of the task category. Valid values are:\n- 1: game server","readOnly":true},"entityId":{"type":"integer","format":"integer","description":"The ID of the entity the task is being executed for. E.g. a game server ID (categoryId 1)","readOnly":true},"currentActionIdx":{"type":"integer","format":"integer","description":"Currently active action index - relates to the action index as found in the template.","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating the start of execution.","readOnly":true},"lastActivityAt":{"type":"integer","format":"integer","description":"Unix timestamp indicating lastest activity.","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"Unix timestamp at which the task was finished.","readOnly":true},"resultCode":{"type":"integer","format":"integer","description":"The result of the task. 0: pending, 1: in progress, 2: paused, 125: cancelled, 126: done with error, 127: done","readOnly":true},"resultText":{"type":"string","format":"","description":"The result of the task in message form.","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/task/{taskId}":{"delete":{"tags":["ApplicationInstanceTask"],"summary":"Cancel the given task","operationId":"deleteApplicationInstanceTask","parameters":[{"name":"taskId","in":"path","description":"The Id of the task","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskStatus"}}}}},"403":{"description":"Invalid credentials"},"404":{"description":"Invalid taskId"},"409":{"description":"Task cannot be cancelled"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## GET /v3/applicationInstance/taskBatch

> Get the last 100 task batches you have created

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskBatchStatus":{"type":"object","required":["id","createdAt","executeAt","finishedAt","numTasks","numTasksOk","numTasksFailed","numTasksCancelled","taskIds"],"properties":{"id":{"type":"integer","format":"integer","description":"Task Batch ID","readOnly":true},"createdAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was created","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch started execution","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was finished","readOnly":true},"numTasks":{"type":"integer","format":"integer","description":"The total number of tasks in this batch","readOnly":true},"numTasksOk":{"type":"integer","format":"integer","description":"The number of successfully executed tasks","readOnly":true},"numTasksFailed":{"type":"integer","format":"integer","description":"The number of failed tasks","readOnly":true},"numTasksCancelled":{"type":"integer","format":"integer","description":"The number of cancelled tasks","readOnly":true},"taskIds":{"type":"array","items":{"type":"integer","format":"integer"},"description":"All the task IDs in this batch","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/taskBatch":{"get":{"tags":["ApplicationInstanceTask"],"summary":"Get the last 100 task batches you have created","operationId":"getApplicationInstanceTaskBatches","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskBatchStatus"}}}}},"403":{"description":"Invalid credentials"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## GET /v3/applicationInstance/taskBatch/{taskBatchId}

> Get the status of a task batch

```json
{"openapi":"3.0.1","info":{"title":"i3D.net One-Deployment-Platform Endpoints","version":"3.0.0"},"tags":[{"name":"ApplicationInstanceTask","description":"Application instance task execution"}],"servers":[{"url":"https://api.i3d.net"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","name":"PRIVATE-TOKEN","in":"header"}},"schemas":{"TaskBatchStatus":{"type":"object","required":["id","createdAt","executeAt","finishedAt","numTasks","numTasksOk","numTasksFailed","numTasksCancelled","taskIds"],"properties":{"id":{"type":"integer","format":"integer","description":"Task Batch ID","readOnly":true},"createdAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was created","readOnly":true},"executeAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch started execution","readOnly":true},"finishedAt":{"type":"integer","format":"integer","description":"The unix timestamp at which this batch was finished","readOnly":true},"numTasks":{"type":"integer","format":"integer","description":"The total number of tasks in this batch","readOnly":true},"numTasksOk":{"type":"integer","format":"integer","description":"The number of successfully executed tasks","readOnly":true},"numTasksFailed":{"type":"integer","format":"integer","description":"The number of failed tasks","readOnly":true},"numTasksCancelled":{"type":"integer","format":"integer","description":"The number of cancelled tasks","readOnly":true},"taskIds":{"type":"array","items":{"type":"integer","format":"integer"},"description":"All the task IDs in this batch","readOnly":true}},"additionalProperties":false},"Error":{"type":"object","required":["errorCode","errorMessage","errors"],"properties":{"errorCode":{"type":"integer","format":"integer","description":"Error code"},"errorMessage":{"type":"string","format":"","description":"Error message"},"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetails"},"description":"Error details"}},"additionalProperties":false},"ErrorDetails":{"type":"object","required":["property","message"],"properties":{"property":{"type":"string","format":"","description":"Property in which there is an error"},"message":{"type":"string","format":"","description":"Error message"}},"additionalProperties":false}}},"paths":{"/v3/applicationInstance/taskBatch/{taskBatchId}":{"get":{"tags":["ApplicationInstanceTask"],"summary":"Get the status of a task batch","operationId":"getApplicationInstanceTaskBatch","parameters":[{"name":"taskBatchId","in":"path","description":"The Id of the task batch","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TaskBatchStatus"}}}}},"403":{"description":"Invalid credentials"},"404":{"description":"Invalid taskBatchId"},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.i3d.net/api-references/game/applicationinstancetask.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
