Drive > Files > Share link > Manage

Create share-link

Changed on

Create a share link

post/2/drive/{drive_id}/files/{file_id}/link

Request

  • Base URL
    https://api.infomaniak.com
  • URL
    https://api.infomaniak.com/2/drive/{drive_id}/files/{file_id}/link
  • Auth
    HTTP bearer

Path parameters

drive_idinteger required

Drive identifier

file_idinteger required

File identifier

Query parameters

withstring

Optional : Allows loading additional data about a resource, which may include related resources.

Request body

can_commentboolean

Allow users to to comment the shared files. It takes the same value as can_edit if unset or null

can_downloadboolean

Allow users to download shared content

can_editboolean

Allow users to edit the file content using the shared link

can_request_accessboolean

Allow connected users to join the folder via the shared link. It is not possible to join a file via a shared link

can_see_infoboolean

Allow users to see information about the shared files

can_see_statsboolean

Allow users to see statistics

passwordstring

The password if the permission password is set

right'password' | 'public' required

Permission of the shared link: no restriction (public) or public but protected by a password (password)

valid_untilinteger nullable

Maximum validity timestamp of the shared link

Response

Created

result'success' | 'error' | 'asynchronous' required

Result of the HTTP request

Example response

{
  "result": "success",
  "data": {
    "url": "https://kdrive.infomaniak.com/app/share/xxxx/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx",
    "right": "inherit"
  }
}

Changes

    • warning

      added the new forbidden_error enum value to the // response property for the response status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • breaking

      removed the enum value inherit of the request property