Hello to you all
I am quite new to Box (coming from pCloud, with reliability issues)
I have an issues when creating folder shared links with an API call.
I do receive a folder shared_link.url, but no shared_link.download_url
(I have the link that displays the content of the shared folder, I look for the link that would download the archive of the shared folder)
In the JSON returned by the BOX API, at the shared_link.download_url variable, I am receiving a ‘null’ value. In the API documentation, an URL is received.
If you have an idea about this, would you be so kind as to share it with me ?
Kind regards,
Pierre
I place the following call
(PUT) https://api.box.com/2.0/folders/XXXXXXX?fields=shared_link
Body:
{
"shared_link": {
"access": "open",
"password": null,
"unshared_at": "2024-06-05T08:03:38",
"permissions": {
"can_download": true,
"can_edit": false
}
}
}
The answer I receive:
HTTP/1.1 200 OK
Transfer-Encoding: chunked
x-envoy-upstream-service-time: 308
box-request-id: XXXXXXX
strict-transport-security: max-age=31536000
Alt-Svc: h3=":443"; ma=2592000,h3-29=":443"; ma=2592000
Connection: close
Cache-Control: no-cache, no-store
Content-Type: application/json
Date: Mon, 06 May 2024 06:03:39 GMT
ETag: "0"
Via: 1.1 google
{
"type": "folder",
"id": "262171966836",
"etag": "0",
"shared_link": {
"url": "https://XXXXXXXXX.XXXXXXX.",
"download_url": null,
"vanity_url": null,
"vanity_name": null,
"effective_access": "open",
"effective_permission": "can_download",
"is_password_enabled": false,
"unshared_at": "2024-06-05T08:03:38-07:00",
"download_count": 0,
"preview_count": 0,
"access": "open",
"permissions": {
"can_preview": true,
"can_download": true,
"can_edit": false
}
}
}