dnsmadeeasy-rest-api 1.0.7 → 1.0.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 95e48aae6489a7c19d5eee16d0ca0c95c01aa008
4
- data.tar.gz: 996ecf8de372b80ee847ce9dab8b1b399acc4c98
3
+ metadata.gz: ea11e9f3e4bd98ca1e7c96fa950103ced863745b
4
+ data.tar.gz: 1bef7b48f3f0941cd6c8b5eae87f7cac2b08abac
5
5
  SHA512:
6
- metadata.gz: e2409092505b38aeed75b5ccff9a73aa27eefcc7e5b9ddadcf556c02f54424a742b5b3a2a6a67e06a0c41ada3dcc2291cea2c8383ae56386e54954789ac7e349
7
- data.tar.gz: 0c8878d7d29658379fbce1f234016c16948e10fb342f411d5f7b252c4892d87321dd842bf27596b588a8fd545ea1d0c540091cfa1d06230d250d5538f26057ab
6
+ metadata.gz: e667b4ebdc8a24286130def23c20009d6fb55132e42daa12bb9366c1fcb5d8d46002d21ddb9336a0dd7df3331b09dc4f819735431f09e356359f97ceea5aab0a
7
+ data.tar.gz: 1a58213c6cc533fa722f75403694302ea115aa1c1f7576657c575555eadf3547d711abdd1c714966c06ac2353a2c4b5d494b00b26c094769fcc635e14d3469ff
data/README.md CHANGED
@@ -29,9 +29,15 @@ Start by creating a new instance of the `DnsMadeEasy` class, and passing your ap
29
29
  api = DnsMadeEasy.new('awesome-api-key', 'super-secret-and-awesome-api-secret')
30
30
  ```
31
31
 
32
+ Optionally, you can connect to the sandbox API if you want to play around.
33
+
34
+ ```ruby
35
+ api = DnsMadeEasy.new('awesome-api-key', 'super-secret-and-awesome-api-secret', sandbox=TRUE)
36
+ ```
37
+
32
38
  All return values are the direct JSON responses from DNS Made Easy converted into a Hash.
33
39
 
34
- See: [http://www.dnsmadeeasy.com/integration/pdf/API-Docv2.pdf](http://www.dnsmadeeasy.com/integration/pdf/API-Docv2.pdf)
40
+ See: [https://api-docs.dnsmadeeasy.com/](https://api-docs.dnsmadeeasy.com/)
35
41
 
36
42
  ### Managing Domains
37
43
 
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'dnsmadeeasy-rest-api'
3
- s.version = '1.0.7'
3
+ s.version = '1.0.8'
4
4
  s.authors = ['Arnoud Vermeer', 'Paul Henry', 'James Hart']
5
5
  s.email = ['a.vermeer@freshway.biz', 'ops@wanelo.com']
6
6
  s.license = 'Apache'
@@ -21,7 +21,7 @@ class DnsMadeEasy
21
21
  @request_limit = -1
22
22
 
23
23
  if sandbox
24
- self.base_uri = 'https://sandboxapi.dnsmadeeasy.com/V2.0'
24
+ self.base_uri = 'https://api.sandbox.dnsmadeeasy.com/V2.0'
25
25
  else
26
26
  self.base_uri = 'https://api.dnsmadeeasy.com/V2.0'
27
27
  end
@@ -206,8 +206,8 @@ class DnsMadeEasy
206
206
  put "/monitor/#{record_id}", body
207
207
  end
208
208
 
209
- def disable_failover(record_id)
210
- put "/monitor/#{record_id}", { 'failover' => false, 'monitor' => false }
209
+ def disable_failover(record_id, options={})
210
+ put "/monitor/#{record_id}", { 'failover' => false, 'monitor' => false }.merge(options)
211
211
  end
212
212
 
213
213
  private
@@ -388,14 +388,14 @@ describe DnsMadeEasy do
388
388
 
389
389
  describe '#disable_failover' do
390
390
  let(:response) { "{}" }
391
- let(:body) { '{"failover":false,"monitor":false}' }
391
+ let(:body) { '{"failover":false,"monitor":false,"port":80,"sensitivity":5}' }
392
392
 
393
393
  it 'disables the failover config for a failover enabled record' do
394
394
  stub_request(:put, "https://api.dnsmadeeasy.com/V2.0/monitor/21").
395
395
  with(headers: request_headers, body: body).
396
396
  to_return(status: 200, body: response, headers: {})
397
397
 
398
- expect(subject.disable_failover(21)).to eq({})
398
+ expect(subject.disable_failover(21, { 'port' => 80, 'sensitivity' => 5 })).to eq({})
399
399
  end
400
400
  end
401
401
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dnsmadeeasy-rest-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arnoud Vermeer
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2018-01-08 00:00:00.000000000 Z
13
+ date: 2018-03-30 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rspec
@@ -106,7 +106,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
106
106
  version: '0'
107
107
  requirements: []
108
108
  rubyforge_project:
109
- rubygems_version: 2.6.11
109
+ rubygems_version: 2.5.2
110
110
  signing_key:
111
111
  specification_version: 4
112
112
  summary: DNS Made Easy V2.0 REST API client for Ruby