https://github.com/smolget/yadisk
Yandex.Disk API client (ruby gem)
https://github.com/smolget/yadisk
api-client hacktoberfest ruby yandex yandex-disk yandex-disk-client
Last synced: about 1 year ago
JSON representation
Yandex.Disk API client (ruby gem)
- Host: GitHub
- URL: https://github.com/smolget/yadisk
- Owner: Smolget
- License: mit
- Created: 2014-09-08T12:15:26.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2023-04-24T07:10:29.000Z (about 3 years ago)
- Last Synced: 2025-03-27T05:11:46.629Z (about 1 year ago)
- Topics: api-client, hacktoberfest, ruby, yandex, yandex-disk, yandex-disk-client
- Language: Ruby
- Homepage:
- Size: 58.6 KB
- Stars: 3
- Watchers: 0
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Yadisk - Yandex.Disk API client (ruby gem)
[](https://badge.fury.io/rb/yadisk-client)

[](https://github.com/Smolget/yadisk/actions/workflows/CI.yml)
[](https://coveralls.io/github/Smolget/yadisk?branch=master)
## Install
```sh
gem install yadisk-client
```
Gemfile
```gemfile
gem 'yadisk-client', '~> 1.11', '>= 1.11.2'
```
## Development
```sh
rake console
```
## Available methods
> **Note**
> `**params` not included in requests, but will be later
> `**attributes` used in `update_meta` method only
```ruby
client = Yadisk::Client.new(token: 'paste your token here')
client.disk.info
client.disk.upload(path:)
client.disk.upload_from_file(upload_link:, src:)
client.disk.upload_by_url(path:, url:)
client.disk.delete(path:)
client.disk.get_meta(path:, **params)
# client.disk.update_meta(path: "dir_or_file_path", any_key_name: "value", other_key_name: "any_value")
client.disk.update_meta(path:, **attributes)
client.disk.create_dir(path:)
client.disk.copy(from:, to:)
client.disk.download(path:, **params)
client.disk.list_files(**params)
client.disk.last_uploaded(**params)
client.disk.move(from:, to:)
client.disk.list_public(**params)
client.disk.publish(path:)
client.disk.unpublish(path:)
client.public_resource.meta(public_key:, **params)
client.public_resource.link(public_key:, **params)
client.public_resource.save(public_key:, **params)
client.operation.status(operation_id:)
client.trash.delete(path:, **params)
client.trash.list(path:, **params)
client.trash.restore(path:)
```
## TODOs
- ~~tests~~
- examples
- ~~readme~~