planethoster_api 0.0.3 → 1.0.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 +62 -3
- data/lib/planethoster_api.rb +1 -0
- data/lib/planethoster_api/domain.rb +1 -1
- data/lib/planethoster_api/version.rb +1 -1
- data/lib/utilities/api_client.rb +2 -2
- data/planethoster_api.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 68170f22305923e2c10038e03dac0653802223c0546b6e4d263574d1956f9271
|
4
|
+
data.tar.gz: ce0d009dacffe0013904640f11f2137157755114f79c316d69f5f302f92e23ca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1cddc8e0e9d0d2d13c3730c0f8112c22160d5b2d0fd39fb9587667b434fc2eb48e58c590ca51c2b12311711fbd825fc6b986e0dd9723fbe9d7878a2235e4e8d
|
7
|
+
data.tar.gz: 5856db0f347394e55c34c2253dde6c5e5949ea0ca064ad5231a73d3e28749b56085e6193c04bca5dfb1817b02b09805431d4ed8d488fb81ae91932eaa4e7d078
|
data/README.md
CHANGED
@@ -1,8 +1,13 @@
|
|
1
|
+

|
1
2
|
[](https://travis-ci.org/PlanetHoster/planethoster-node)
|
3
|
+

|
2
4
|
|
3
5
|
# Planethoster-ruby
|
4
6
|
|
5
|
-
PlanetHoster API
|
7
|
+
PlanetHoster API wrapper
|
8
|
+
|
9
|
+
Please refer to the documentation of the [PlanetHoster API](https://apidoc.planethoster.com/) for all calls explanation.
|
10
|
+
|
6
11
|
|
7
12
|
## Installation
|
8
13
|
|
@@ -22,7 +27,61 @@ Or install it yourself as:
|
|
22
27
|
|
23
28
|
## Usage
|
24
29
|
|
25
|
-
|
30
|
+
You need to initialize api credentials.
|
31
|
+
```ruby
|
32
|
+
require 'planethoster_api'
|
33
|
+
|
34
|
+
PlanethosterApi.configuration do |config|
|
35
|
+
config.api_user = API_USER
|
36
|
+
config.api_key = API_KEY
|
37
|
+
end
|
38
|
+
```
|
39
|
+
|
40
|
+
Then, you can test api connection with this code
|
41
|
+
```ruby
|
42
|
+
PlanethosterApi.domain.test_connection
|
43
|
+
```
|
44
|
+
|
45
|
+
## Possible functions
|
46
|
+
|
47
|
+
Make sure to checkout documentation for specific parameters and more explanation [ApiDoc](https://apidoc.planethoster.com/)
|
48
|
+
|
49
|
+
### Domain
|
50
|
+
```ruby
|
51
|
+
PlanethosterApi.domain[...] # options down below
|
52
|
+
```
|
53
|
+
```ruby
|
54
|
+
.tld_prices() # Returns domain name prices for registration, renewal and transfer.
|
55
|
+
.account_info() # Returns information pertinent to your reseller account. (active doamin, credit left, etc..)
|
56
|
+
.check_availability() # Checks whether a domain name is available to register.
|
57
|
+
.domain_info() # Retrieve information for a domain which you successfully registered or created a transfer order.
|
58
|
+
.get_contact_details() # Returns the contact information (WHOIS information) for the active domain name.
|
59
|
+
.get_nameservers() # Returns the nameservers for a registered domain name.
|
60
|
+
.get_ph_dns_records() # Retrieves the DNS records for the active domain name registered with PlanetHoster.
|
61
|
+
.get_registrar_lock() # Get the lock status of a registered domain name.
|
62
|
+
.save_contact_details() # Saves the contact information (WHOIS information) for the given active domain name.
|
63
|
+
.save_nameservers() # Update nameservers associated with your domain.
|
64
|
+
.save_ph_dns_records() # Saves the DNS records for the active domain name registered with PlanetHoster.
|
65
|
+
.save_registrar_lock() # Lock or unlock a registered and active domain name.
|
66
|
+
.email_epp_code() # Email the domain name registrant their EPP code (also called Auth Info) for the given domain.
|
67
|
+
.register_domain() # Attempts to register a domain name for 1 to 10 years.
|
68
|
+
.renew_domain() # Renew an already active domain name for 1-10 years.
|
69
|
+
.transfer_domain() # Transfer a domain name from your current registrar to PlanetHoster.
|
70
|
+
.delete_ph_dns_zone() # Deletes the DNS zone on the PlanetHoster DNS servers for the given domain.
|
71
|
+
```
|
72
|
+
### World (Hosting)
|
73
|
+
[What is a world hosting?](https://www.planethoster.com/en/World-Hosting)
|
74
|
+
```ruby
|
75
|
+
PlanethosterApi.world[...] # options down below
|
76
|
+
```
|
77
|
+
```ruby
|
78
|
+
.get_accounts() # Displays The World account and all World sub accounts information.
|
79
|
+
.create_account() # Creates a world hosting account, assigns the requested resources and install a CMS
|
80
|
+
.suspend_account() # Proceed to the suspension of a World account.
|
81
|
+
.unsuspend_account() # Reactivate suspended world account.
|
82
|
+
.modify_ressources() # Modify the resources associated with a World account.
|
83
|
+
.upgrade_plan() # Increases resources associated with The World account.
|
84
|
+
```
|
26
85
|
|
27
86
|
## Development
|
28
87
|
|
@@ -30,7 +89,7 @@ After checking out the repo, run `bin/setup` to install dependencies. Then, run
|
|
30
89
|
|
31
90
|
## Contributing
|
32
91
|
|
33
|
-
Bug reports
|
92
|
+
Bug reports are welcome on GitHub at https://github.com/PlanetHoster/planethoster-ruby/issues.
|
34
93
|
|
35
94
|
## License
|
36
95
|
|
data/lib/planethoster_api.rb
CHANGED
@@ -16,7 +16,7 @@ module PlanethosterApi
|
|
16
16
|
save_nameservers: [:post, '/save-nameservers'],
|
17
17
|
save_ph_dns_records: [:post, '/save-ph-dns-records'],
|
18
18
|
save_registrar_lock: [:post, '/save-registrar-lock'],
|
19
|
-
|
19
|
+
email_epp_code: [:post, '/email-epp-code'],
|
20
20
|
register_domain: [:post, '/register-domain'],
|
21
21
|
renew_domain: [:post, '/renew-domain'],
|
22
22
|
transfer_domain: [:post, '/transfer-domain'],
|
data/lib/utilities/api_client.rb
CHANGED
data/planethoster_api.gemspec
CHANGED
@@ -27,6 +27,6 @@ Gem::Specification.new do |spec|
|
|
27
27
|
spec.require_paths = ["lib"]
|
28
28
|
|
29
29
|
spec.add_development_dependency "bundler", "~> 2.0"
|
30
|
-
spec.add_development_dependency "rake", "~>
|
30
|
+
spec.add_development_dependency "rake", "~> 12.3.3"
|
31
31
|
spec.add_development_dependency "rspec", "~> 3.0"
|
32
32
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: planethoster_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- marcandreg
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-04-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
33
|
+
version: 12.3.3
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version:
|
40
|
+
version: 12.3.3
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -98,7 +98,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
98
98
|
- !ruby/object:Gem::Version
|
99
99
|
version: '0'
|
100
100
|
requirements: []
|
101
|
-
rubygems_version: 3.0.
|
101
|
+
rubygems_version: 3.0.8
|
102
102
|
signing_key:
|
103
103
|
specification_version: 4
|
104
104
|
summary: PlanetHoster API wrapper
|