yandex_domains 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +23 -8
- data/lib/yandex_domains/version.rb +1 -1
- data/lib/yandex_domains.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 277c32eb2b75d01b8cca09f0773b346d765db57c
|
4
|
+
data.tar.gz: 310dc2aecdfd994aaf533a84b766895cd8e31f8c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9daf3719232de306e16a54d90f37d64e85d9d202dbbc582d30a62e1a65828e97efce6a698fa913384d64ae89394e17b2c083e1be12d5abfba071e14625ac0615
|
7
|
+
data.tar.gz: e7e792b58a978042312ad074b3df0da1d5995d7d3ccc7ea517d3c3860bf8988c12cd94194371288df895dff80cf55d3f43ea1bfa490536a099d3f17df8185733
|
data/README.md
CHANGED
@@ -1,8 +1,6 @@
|
|
1
1
|
# YandexDomains
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
TODO: Delete this and the text above, and describe your gem
|
3
|
+
Ruby client for [Yandex.Mail for Domains API](https://tech.yandex.com/domain).
|
6
4
|
|
7
5
|
## Installation
|
8
6
|
|
@@ -22,17 +20,34 @@ Or install it yourself as:
|
|
22
20
|
|
23
21
|
## Usage
|
24
22
|
|
25
|
-
|
23
|
+
This client works for only **Administrator** access. More details about Administrator user is [here](https://tech.yandex.com/domain/doc/concepts/termin-docpage/). In order to use the client and API features, the PDD token is required. You can get a PDD token on the [token management](https://pddimp.yandex.ru/api2/admin/get_token) page by entering a domain name that has already been verified.
|
24
|
+
|
25
|
+
** Initialize a client
|
26
|
+
```ruby
|
27
|
+
client = YandexDomains::Client.new(pdd_token)
|
28
|
+
```
|
26
29
|
|
27
|
-
##
|
30
|
+
## Usage Examples
|
31
|
+
After configuring a client, you can do the followings.
|
28
32
|
|
29
|
-
|
33
|
+
**Signing up a domain**
|
34
|
+
```ruby
|
35
|
+
client.connect('google.com')
|
36
|
+
```
|
30
37
|
|
31
|
-
|
38
|
+
** Adding a mailbox for a domain**
|
39
|
+
```ruby
|
40
|
+
client.add_mailbox('google.com', 'hi', 'strongpassword')
|
41
|
+
```
|
42
|
+
|
43
|
+
** Deleting a mailbox on a domain**
|
44
|
+
```ruby
|
45
|
+
client.delete_mailbox('google.com', 'hi')
|
46
|
+
```
|
32
47
|
|
33
48
|
## Contributing
|
34
49
|
|
35
|
-
1. Fork it ( https://github.com/
|
50
|
+
1. Fork it ( https://github.com/beydogan/yandex_domains/fork )
|
36
51
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
37
52
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
38
53
|
4. Push to the branch (`git push origin my-new-feature`)
|
data/lib/yandex_domains.rb
CHANGED
@@ -127,7 +127,7 @@ module YandexDomains
|
|
127
127
|
req = self.class.post("/admin/email/edit", query: query)
|
128
128
|
req.parsed_response
|
129
129
|
end
|
130
|
-
# Used for
|
130
|
+
# Used for deleting a mailbox on a domain
|
131
131
|
# @param domain [String] Name of the domain.
|
132
132
|
# @param login [String] The email address of the mailbox, in the format “username@domain.com” or “username”.
|
133
133
|
# @return [Hash] Parsed Response
|