Public share links

What someone with a share link sees, without signing in: the item (or folder listing), unlocking a password-protected link, downloading, and thumbnails.

MethodPathSummary
GET/api/public/:tokenOpen a share link
POST/api/public/:token/unlockUnlock a password-protected share link
GET/api/public/:token/contentDownload from a share link
GET/api/public/:token/thumbThumbnail from a share link

#Open a share link

GET/api/public/:token
Address
https://<your-org>.brambleit.cloud/drive/api/public/:token
Requires
None: public, or protected by a token in the address or body.

Path parameters

NameTypeDescription
tokenrequiredstring

Query parameters

NameTypeDescription
itemnumberInside a shared folder, the item to show.

Response 200

FieldTypeDescription
needs_passwordboolean
Example response
JSON
{
  "…base": "…",
  "needs_password": false
}

Example request

Bash
curl -X GET 'https://<your-org>.brambleit.cloud/drive/api/public/%E2%80%A6' \
  -H "X-API-Key: $BRAMBLE_KEY"

#Unlock a password-protected share link

POST/api/public/:token/unlock
Address
https://<your-org>.brambleit.cloud/drive/api/public/:token/unlock
Requires
None: public, or protected by a token in the address or body.
Headers
x-forwarded-proto

Path parameters

NameTypeDescription
tokenrequiredstring

Request body JSON

NameTypeDescription
passwordanyThe link's password.

Response 200

FieldTypeDescription
okboolean
Example response
JSON
{
  "ok": true
}

Errors

StatusMessage
403That password isn't right

Example request

Bash
curl -X POST 'https://<your-org>.brambleit.cloud/drive/api/public/%E2%80%A6/unlock' \
  -H "X-API-Key: $BRAMBLE_KEY" \
  -H "Content-Type: application/json" \
  -d '{"password":"…"}'

#Download from a share link

GET/api/public/:token/content
Address
https://<your-org>.brambleit.cloud/drive/api/public/:token/content
Requires
None: public, or protected by a token in the address or body.

Path parameters

NameTypeDescription
tokenrequiredstring

Query parameters

NameTypeDescription
itemnumber
downloadboolean

Errors

StatusMessage
400Not a file
403Downloading is turned off for this link

Example request

Bash
curl -X GET 'https://<your-org>.brambleit.cloud/drive/api/public/%E2%80%A6/content' \
  -H "X-API-Key: $BRAMBLE_KEY"

#Thumbnail from a share link

GET/api/public/:token/thumb
Address
https://<your-org>.brambleit.cloud/drive/api/public/:token/thumb
Requires
None: public, or protected by a token in the address or body.

Path parameters

NameTypeDescription
tokenrequiredstring

Query parameters

NameTypeDescription
itemnumber
snumber

Response

A body.

Errors

StatusMessage
404No thumbnail

Example request

Bash
curl -X GET 'https://<your-org>.brambleit.cloud/drive/api/public/%E2%80%A6/thumb' \
  -H "X-API-Key: $BRAMBLE_KEY"