Skip to main content

Update

Description

Use a HTTP PUT request to update a resource.

Request

HTTP Method: PUT

ParameterDescription
idThe ID of the resource to update.
nameName of the resource.
valueContents of the resource.
folder_idOptional ID of folder to which the resource will be located
read_accessOptional Control where this resource can be used (TEAM, GLOBAL). default: TEAM
descriptionOptional Description of the resource. default: "" (empty string)

Sample request

curl -X PUT \
https://<tenant-domain>/api/v1/global_resources/<resource-id> \
-H 'content-type: application/json' \
-H 'x-user-email: <email-address>' \
-H 'x-user-token: <api-token>' \
-d '{
"name": "an array resource",
"value":"[1,2,3,4,5]"
}'

Response

A successful request will return a JSON object describing the created resource.

Field description

ParameterDescription
idResource ID.
user_idID of user associated with the resource.
nameName of the resource.
team_idID of team to which the resource belongs.
folder_idID of folder to which the resource belongs.
read_accessControl where this resource can be used.
descriptionDescription of the resource.
created_atISO 8601 Timestamp representing date and time the resource was created.
updated_atISO 8601 Timestamp representing date and time the resource was last updated.

Sample response

{
"id": 9,
"name": "an array resource",
"value": "[1,2,3,4,5]",
"team_id": 1,
"folder_id": 1,
"user_id": 1,
"read_access": "TEAM",
"slug": "an_array_resource",
"created_at": "2020-02-05T20:40:32.313Z",
"updated_at": "2020-02-05T20:55:18.239Z",
"description": ""
}