Create Or Update Tape Media Pool
Creates or updates a tape media pool.
Endpoint
https://<Director_IP_address>:4443/c/router
Tenant Endpoint
For tenants of the multi-tenant product the endpoint must be:
https://<Director_IP_address>:4443/t/<tenant_UUID>/c/router
Request Examples
This is an example of creating a tape media pool.
curl --request POST \
--url https://<Director_IP_address>:4443/c/router \
--header "content-type: application/json" \
--cookie @cookies.txt \
--data "{
"action": "TapeMediaPoolManagement",
"method": "createOrUpdate",
"data": [
{
"id": null,
"name": "Media Pool 001",
"description": "Description for MP",
"autoAddFreeTapes": true,
"defaultOfflineLocationId": 1
}
],
"type": "rpc",
"tid": 1
}"
This is an example of updating a tape media pool.
curl --request POST \
--url https://<Director_IP_address>:4443/c/router \
--header "content-type: application/json" \
--cookie @cookies.txt \
--data "{
"action": "TapeMediaPoolManagement",
"method": "createOrUpdate",
"data": [
{
"id": 65,
"name": "Media Pool 001",
"description": "Description for Media",
"autoAddFreeTapes": true,
"defaultOfflineLocationId": 1
}
],
"type": "rpc",
"tid": 1
}"
Request Fields
Field
|
Type
|
Value(s)
|
Description |
---|---|---|---|
action
|
string |
|
The action that is invoked |
method
|
string |
|
The method that is invoked |
data
|
array |
|
Data of a media to be created or updated |
type
|
string |
|
Type of communication protocol |
tid
|
int |
|
Transaction ID. Used to identify the request by both the client and the server |
data
Field
|
Type
|
Description
|
---|---|---|
|
long |
The media pool ID. For the |
|
string |
The media pool name |
|
string |
The description of media pool |
|
long |
Default offline location ID |
|
boolean |
|
Response Sample
{
"action": "TapeMediaPoolManagement",
"method": "createOrUpdate",
"tid": "1",
"type": "rpc",
"message": null,
"where": null,
"cause": null,
"data": 65
}
Response Fields
Field
|
Value
|
Description
|
---|---|---|
message
|
string | Message if the request failed |
where
|
string | Reference to the method where problem occurred |
cause
|
string | Cause of failure |
data | long | ID of the tape media pool |