Data about the user's Yandex Disk

The API returns general information about the user's Yandex Disk: the available space, system folder paths, and so on.

Request format

Use the GET method to request data about the user's Yandex Disk.

https://cloud-api.yandex.net/v1/disk/

Response format

If the request is processed without errors, the API returns the 200 OK code and the information about the Yandex Disk within the Disk object in the response body.

If the request caused an error, the relevant response code is returned, and the response body contains an error description.

Sample response:

{
  "trash_size": 4631577437,
  "total_space": 319975063552,
  "used_space": 26157681270,
  "system_folders":
  {
    "applications": "disk:/Applications",
    "downloads": "disk:/Downloads/"
  }
}

Element

Description

trash_size

Space used by files in Trash (bytes).

total_space

Space available to the user on Yandex Disk (bytes).

used_space

Space used by files on Yandex Disk (bytes).

system_folders

Absolute paths of Yandex Disk system folders. Folder names depend on the interface language used when the user's personal Yandex Disk was created. For example, the Downloads folder is created for an English-speaking user, Загрузки for a Russian-speaking user, and so on.

The following folders are currently supported:

  • Applications — Folder for app files.
  • Downloads — Folder for files downloaded from the internet (not from the user's device).