# Task\_destinations

## Lists all task destinations.

> \*\*API Key Scope\*\*: task\_destinations / index

```json
{"openapi":"3.0.1","info":{"title":"Nodeum API","version":"2.1.0"},"servers":[{"url":"{url}/api/v2","variables":{"url":{"default":"http://localhost","description":"URL of server"}}}],"security":[{"BasicAuth":[]},{"BearerAuth":[]},{"JWT":[]}],"components":{"securitySchemes":{"BasicAuth":{"type":"http","scheme":"basic","description":"Pass the username and password of a user in the authorization header.\nThis currently gives full access."},"BearerAuth":{"type":"apiKey","description":"Create an API Key associated to user.\nAccess can be restricted with the scope.\nEach API call described below has a scoped mentionned in its description.\n\nFor example :\n\n**API Key Scope**: files / index\n\nThis means that the API key should have a scope with controller as *files*\nand the action as *index*.","name":"Authorization","in":"header"},"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"parameters":{"limit":{"name":"limit","in":"query","description":"The number of items to display for pagination.","schema":{"type":"integer"}},"offset":{"name":"offset","in":"query","description":"The number of items to skip for pagination.","schema":{"type":"integer"}}},"responses":{"task_destinations_index":{"description":"List of task destinations.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination_collection"}}}}},"schemas":{"task_destination_collection":{"type":"object","properties":{"count":{"type":"integer","readOnly":true},"task_destinations":{"type":"array","readOnly":true,"items":{"$ref":"#/components/schemas/task_destination"}}}},"task_destination":{"properties":{"id":{"type":"string","readOnly":true},"type":{"type":"string","enum":["primary_nas","secondary_nas","nas","primary_cloud","secondary_cloud","cloud"]},"node_path":{"type":"string"},"pool_id":{"type":"integer"},"parent_storage_id":{"type":"integer","format":"int64"},"storage_id":{"type":"integer","format":"int64"},"storage_name":{"type":"string"},"pool":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/pool"}]}}},"pool":{"type":"object","properties":{"id":{"type":"integer","readOnly":true},"name":{"type":"string"},"comment":{"type":"string"},"type":{"type":"string","enum":["active_archive","offline_archive","data_exchange","scratch","data_enrichment","primary"]},"content":{"type":"string","enum":["cloud","nas"]},"storage_id":{"type":"integer","description":"For pools, used to link to a storage id","format":"int64"}}}}},"paths":{"/tasks/{task_id}/task_destinations":{"get":{"summary":"Lists all task destinations.","operationId":"index_task_destinations","tags":["task_destinations"],"description":"**API Key Scope**: task_destinations / index","parameters":[{"$ref":"#/components/parameters/limit"},{"$ref":"#/components/parameters/offset"}],"responses":{"200":{"$ref":"#/components/responses/task_destinations_index"}}}}}}
```

## Creates a new task destination.

> \*\*API Key Scope\*\*: task\_destinations / create

```json
{"openapi":"3.0.1","info":{"title":"Nodeum API","version":"2.1.0"},"servers":[{"url":"{url}/api/v2","variables":{"url":{"default":"http://localhost","description":"URL of server"}}}],"security":[{"BasicAuth":[]},{"BearerAuth":[]},{"JWT":[]}],"components":{"securitySchemes":{"BasicAuth":{"type":"http","scheme":"basic","description":"Pass the username and password of a user in the authorization header.\nThis currently gives full access."},"BearerAuth":{"type":"apiKey","description":"Create an API Key associated to user.\nAccess can be restricted with the scope.\nEach API call described below has a scoped mentionned in its description.\n\nFor example :\n\n**API Key Scope**: files / index\n\nThis means that the API key should have a scope with controller as *files*\nand the action as *index*.","name":"Authorization","in":"header"},"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"responses":{"task_destinations_show":{"description":"A specific task destination.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination"}}}},"unprocessable_entity":{"description":"The received resource was not correctly formatted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/model_error"}}}}},"schemas":{"task_destination":{"properties":{"id":{"type":"string","readOnly":true},"type":{"type":"string","enum":["primary_nas","secondary_nas","nas","primary_cloud","secondary_cloud","cloud"]},"node_path":{"type":"string"},"pool_id":{"type":"integer"},"parent_storage_id":{"type":"integer","format":"int64"},"storage_id":{"type":"integer","format":"int64"},"storage_name":{"type":"string"},"pool":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/pool"}]}}},"pool":{"type":"object","properties":{"id":{"type":"integer","readOnly":true},"name":{"type":"string"},"comment":{"type":"string"},"type":{"type":"string","enum":["active_archive","offline_archive","data_exchange","scratch","data_enrichment","primary"]},"content":{"type":"string","enum":["cloud","nas"]},"storage_id":{"type":"integer","description":"For pools, used to link to a storage id","format":"int64"}}},"model_error":{"type":"object","properties":{"details":{"type":"object","additionalProperties":{"type":"array","items":{"$ref":"#/components/schemas/attribute_error"}},"description":"Parsable objects describing the errors. The key is the invalid attribute name."},"messages":{"type":"array","description":"English description of the errors.","items":{"type":"string"}}}},"attribute_error":{"required":["error"],"type":"object","properties":{"error":{"type":"string"}},"discriminator":{"propertyName":"error"}}},"requestBodies":{"task_destination_body":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination"}}},"required":true}}},"paths":{"/tasks/{task_id}/task_destinations":{"post":{"summary":"Creates a new task destination.","operationId":"create_task_destination","description":"**API Key Scope**: task_destinations / create","tags":["task_destinations"],"responses":{"201":{"$ref":"#/components/responses/task_destinations_show"},"422":{"$ref":"#/components/responses/unprocessable_entity"}},"requestBody":{"$ref":"#/components/requestBodies/task_destination_body"}}}}}
```

## Displays a specific task destination.

> \*\*API Key Scope\*\*: task\_destinations / show

```json
{"openapi":"3.0.1","info":{"title":"Nodeum API","version":"2.1.0"},"servers":[{"url":"{url}/api/v2","variables":{"url":{"default":"http://localhost","description":"URL of server"}}}],"security":[{"BasicAuth":[]},{"BearerAuth":[]},{"JWT":[]}],"components":{"securitySchemes":{"BasicAuth":{"type":"http","scheme":"basic","description":"Pass the username and password of a user in the authorization header.\nThis currently gives full access."},"BearerAuth":{"type":"apiKey","description":"Create an API Key associated to user.\nAccess can be restricted with the scope.\nEach API call described below has a scoped mentionned in its description.\n\nFor example :\n\n**API Key Scope**: files / index\n\nThis means that the API key should have a scope with controller as *files*\nand the action as *index*.","name":"Authorization","in":"header"},"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"responses":{"task_destinations_show":{"description":"A specific task destination.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination"}}}},"not_found":{"description":"The requested resource was not found. The detailed error will be of type `not_found`.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/model_error"}}}}},"schemas":{"task_destination":{"properties":{"id":{"type":"string","readOnly":true},"type":{"type":"string","enum":["primary_nas","secondary_nas","nas","primary_cloud","secondary_cloud","cloud"]},"node_path":{"type":"string"},"pool_id":{"type":"integer"},"parent_storage_id":{"type":"integer","format":"int64"},"storage_id":{"type":"integer","format":"int64"},"storage_name":{"type":"string"},"pool":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/pool"}]}}},"pool":{"type":"object","properties":{"id":{"type":"integer","readOnly":true},"name":{"type":"string"},"comment":{"type":"string"},"type":{"type":"string","enum":["active_archive","offline_archive","data_exchange","scratch","data_enrichment","primary"]},"content":{"type":"string","enum":["cloud","nas"]},"storage_id":{"type":"integer","description":"For pools, used to link to a storage id","format":"int64"}}},"model_error":{"type":"object","properties":{"details":{"type":"object","additionalProperties":{"type":"array","items":{"$ref":"#/components/schemas/attribute_error"}},"description":"Parsable objects describing the errors. The key is the invalid attribute name."},"messages":{"type":"array","description":"English description of the errors.","items":{"type":"string"}}}},"attribute_error":{"required":["error"],"type":"object","properties":{"error":{"type":"string"}},"discriminator":{"propertyName":"error"}}}},"paths":{"/tasks/{task_id}/task_destinations/{task_destination_id}":{"get":{"summary":"Displays a specific task destination.","operationId":"show_task_destination","description":"**API Key Scope**: task_destinations / show","tags":["task_destinations"],"responses":{"200":{"$ref":"#/components/responses/task_destinations_show"},"404":{"$ref":"#/components/responses/not_found"}}}}}}
```

## Updates a specific task destination.

> \*\*API Key Scope\*\*: task\_destinations / update

```json
{"openapi":"3.0.1","info":{"title":"Nodeum API","version":"2.1.0"},"servers":[{"url":"{url}/api/v2","variables":{"url":{"default":"http://localhost","description":"URL of server"}}}],"security":[{"BasicAuth":[]},{"BearerAuth":[]},{"JWT":[]}],"components":{"securitySchemes":{"BasicAuth":{"type":"http","scheme":"basic","description":"Pass the username and password of a user in the authorization header.\nThis currently gives full access."},"BearerAuth":{"type":"apiKey","description":"Create an API Key associated to user.\nAccess can be restricted with the scope.\nEach API call described below has a scoped mentionned in its description.\n\nFor example :\n\n**API Key Scope**: files / index\n\nThis means that the API key should have a scope with controller as *files*\nand the action as *index*.","name":"Authorization","in":"header"},"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"responses":{"task_destinations_show":{"description":"A specific task destination.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination"}}}},"unprocessable_entity":{"description":"The received resource was not correctly formatted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/model_error"}}}}},"schemas":{"task_destination":{"properties":{"id":{"type":"string","readOnly":true},"type":{"type":"string","enum":["primary_nas","secondary_nas","nas","primary_cloud","secondary_cloud","cloud"]},"node_path":{"type":"string"},"pool_id":{"type":"integer"},"parent_storage_id":{"type":"integer","format":"int64"},"storage_id":{"type":"integer","format":"int64"},"storage_name":{"type":"string"},"pool":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/pool"}]}}},"pool":{"type":"object","properties":{"id":{"type":"integer","readOnly":true},"name":{"type":"string"},"comment":{"type":"string"},"type":{"type":"string","enum":["active_archive","offline_archive","data_exchange","scratch","data_enrichment","primary"]},"content":{"type":"string","enum":["cloud","nas"]},"storage_id":{"type":"integer","description":"For pools, used to link to a storage id","format":"int64"}}},"model_error":{"type":"object","properties":{"details":{"type":"object","additionalProperties":{"type":"array","items":{"$ref":"#/components/schemas/attribute_error"}},"description":"Parsable objects describing the errors. The key is the invalid attribute name."},"messages":{"type":"array","description":"English description of the errors.","items":{"type":"string"}}}},"attribute_error":{"required":["error"],"type":"object","properties":{"error":{"type":"string"}},"discriminator":{"propertyName":"error"}}},"requestBodies":{"task_destination_body":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/task_destination"}}},"required":true}}},"paths":{"/tasks/{task_id}/task_destinations/{task_destination_id}":{"put":{"summary":"Updates a specific task destination.","operationId":"update_task_destination","description":"**API Key Scope**: task_destinations / update","tags":["task_destinations"],"responses":{"200":{"$ref":"#/components/responses/task_destinations_show"},"422":{"$ref":"#/components/responses/unprocessable_entity"}},"requestBody":{"$ref":"#/components/requestBodies/task_destination_body"}}}}}
```

## Destroys a specific task destination.

> \*\*API Key Scope\*\*: task\_destinations / destroy

```json
{"openapi":"3.0.1","info":{"title":"Nodeum API","version":"2.1.0"},"servers":[{"url":"{url}/api/v2","variables":{"url":{"default":"http://localhost","description":"URL of server"}}}],"security":[{"BasicAuth":[]},{"BearerAuth":[]},{"JWT":[]}],"components":{"securitySchemes":{"BasicAuth":{"type":"http","scheme":"basic","description":"Pass the username and password of a user in the authorization header.\nThis currently gives full access."},"BearerAuth":{"type":"apiKey","description":"Create an API Key associated to user.\nAccess can be restricted with the scope.\nEach API call described below has a scoped mentionned in its description.\n\nFor example :\n\n**API Key Scope**: files / index\n\nThis means that the API key should have a scope with controller as *files*\nand the action as *index*.","name":"Authorization","in":"header"},"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}},"paths":{"/tasks/{task_id}/task_destinations/{task_destination_id}":{"delete":{"summary":"Destroys a specific task destination.","operationId":"destroy_task_destination","description":"**API Key Scope**: task_destinations / destroy","tags":["task_destinations"],"responses":{"204":{"description":"Task destination destroyed."}}}}}}
```
