Update a Sharebox
PUT {{api-server}}/{{token}}/v5/share/:sharebox_uuid
This endpoint allows you to update the settings of an existing Sharebox by its UUID. The Sharebox UUID can be taken from the response of the endpoint List existing Shareboxes.
Use this endpoint to modify the settings of an existing Sharebox, such as its title, description, shared items, and access controls. Or to extend the validity of a Sharebox by updating the expires_at
field.
Request Body
uuid
(string, required): The unique identifier of the Sharebox you want to update.title
(string, optional): The new title for the Sharebox. If not provided, the current title remains unchanged.description
(string, optional): Description of the Sharebox.items
(array, required): An array of the uuids of the files and/or folders shared in this Sharebox. It overwrites the initial values.identifiers
(array): the UUIds of the files and/or folders shared with this Sharebox.type
(string): Type of the item (file/folder).
starts_at
(string, optional): The start time of the Sharebox. It should be in ISO 8601 format (e.g., 2024-12-31T23:59:59Z).expires_at
(string, optional): The expiration time of the Sharebox. It should be in ISO 8601 format (e.g., 2025-12-31T23:59:59Z).starts_tz
(string, optional): Timezone of the start time.expires_tz
(string, optional): Timezone of the expiration time.auth
(array, optional): Array of authentication details.pass
(string): Password for authentication.user
(string): Username for authentication.
share_uri
(string, optional): The link you share with others to give them access to your Sharebox.show_starts_at
(boolean): Indicates whether to display the start time.show_expires_at
(boolean): Indicates whether to display the expiration time.
Response
The response is in JSON format and includes the following schema:
{
"type": "object",
"properties": {
"status": {"type": "string"},
"msg": {"type": "string"},
"share": {
"type": "object",
"properties": {
"uuid": {"type": "string"},
"title": {"type": "string"},
"description": {"type": "string"},
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"identifiers": {
"type": "array",
"items": {"type": "string"}
},
"type": {"type": "string"}
}
}
},
"starts_at": {"type": "null"},
"expires_at": {"type": "null"},
"starts_tz": {"type": "string"},
"expires_tz": {"type": "string"},
"auth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"pass": {"type": "null"},
"user": {"type": "string"}
}
}
},
"share_uri": {"type": "string"},
"puid": {"type": "string"}
}
},
"info": {
"type": "object",
"properties": {
"duration": {"type": "number"},
"api_version": {"type": "number"}
}
},
"api_version": {
"type": "object",
"properties": {
"hash": {"type": "string"},
"datetime": {"type": "string"},
"module": {"type": "string"}
}
}
}
}
Request Body
{"uuid"=>"028f53bb-0148-409f-88ed-483dd8c33e6e", "title"=>"My share link", "description"=>"Short description 123", "items"=>[{"identifiers"=>["59aac4eb-ccf1-56b3-a4d6-634e77750000", "f2ebf6f6-39f2-56e6-ba74-d9b956c50000"], "type"=>"file_uuid"}], "starts_at"=>nil, "expires_at"=>nil, "starts_tz"=>"Europe/London", "expires_tz"=>"Europe/London", "auth"=>[{"pass"=>nil, "user"=>""}], "share_uri"=>"https://share.filerobot.com/token/v5/s/sY6mkuRLxuhXh81YccsLSwE0fu/my-share-link-08-17-2024-06:29-pm", "puid"=>"sY6mkuRLxuhXh81YccsLSwE0fu", "show_starts_at"=>false, "show_expires_at"=>false}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
X-Filerobot-Key | string |
RESPONSES
status: OK
{"status":"success","msg":"Your share was updated successfully","share":{"uuid":"028f53bb-0148-409f-88ed-483dd8c33e6e","title":"My share link","description":"Short description 123","items":[{"identifiers":["59aac4eb-ccf1-56b3-a4d6-634e77750000","f2ebf6f6-39f2-56e6-ba74-d9b956c50000"],"type":"file_uuid"}],"starts_at":null,"expires_at":null,"starts_tz":"Europe/London","expires_tz":"Europe/London","auth":[{"pass":null,"user":""}],"share_uri":"https://share.filerobot.com/token/v3/s/sY6mkuRLxuhXh81YccsLSwE0fu/my-share-link","puid":"sY6mkuRLxuhXh81YccsLSwE0fu"},"info":{"duration":0.13550734519958496,"api_version":5},"api_version":{"hash":"1ce24f12ff9f3205395f34065a5b87bbfa619e25","datetime":"2024-08-13T12:13:54+07:00","module":"elastic_v2"}}