dnsimple 2.0.0.alpha2 → 2.0.0.alpha3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.markdown +6 -2
- data/README.markdown +32 -30
- data/dnsimple.gemspec +1 -2
- data/lib/dnsimple.rb +2 -13
- data/lib/dnsimple/client.rb +164 -53
- data/lib/dnsimple/client/certificates_service.rb +98 -0
- data/lib/dnsimple/client/client_service.rb +8 -0
- data/lib/dnsimple/client/contacts_service.rb +82 -0
- data/lib/dnsimple/client/domains_service.rb +333 -0
- data/lib/dnsimple/client/name_servers_service.rb +69 -0
- data/lib/dnsimple/client/registrars_service.rb +105 -0
- data/lib/dnsimple/client/services_service.rb +95 -0
- data/lib/dnsimple/client/templates_service.rb +180 -0
- data/lib/dnsimple/client/users_service.rb +37 -0
- data/lib/dnsimple/compatibility.rb +46 -0
- data/lib/dnsimple/default.rb +86 -0
- data/lib/dnsimple/error.rb +7 -11
- data/lib/dnsimple/extra.rb +54 -0
- data/lib/dnsimple/struct.rb +29 -0
- data/lib/dnsimple/struct/certificate.rb +56 -0
- data/lib/dnsimple/struct/contact.rb +61 -0
- data/lib/dnsimple/struct/domain.rb +40 -0
- data/lib/dnsimple/struct/email_forward.rb +14 -0
- data/lib/dnsimple/struct/extended_attribute.rb +39 -0
- data/lib/dnsimple/struct/membership.rb +22 -0
- data/lib/dnsimple/struct/price.rb +16 -0
- data/lib/dnsimple/struct/record.rb +22 -0
- data/lib/dnsimple/struct/service.rb +19 -0
- data/lib/dnsimple/struct/template.rb +19 -0
- data/lib/dnsimple/struct/template_record.rb +24 -0
- data/lib/dnsimple/struct/transfer_order.rb +10 -0
- data/lib/dnsimple/struct/user.rb +17 -0
- data/lib/dnsimple/struct/whois_privacy.rb +19 -0
- data/lib/dnsimple/version.rb +1 -1
- data/spec/dnsimple/client/certificates_service_spec.rb +196 -0
- data/spec/dnsimple/client/contacts_service_spec.rb +179 -0
- data/spec/dnsimple/client/domains_service_spec.rb +662 -0
- data/spec/dnsimple/client/name_servers_service_spec.rb +131 -0
- data/spec/dnsimple/client/registrars_service_spec.rb +160 -0
- data/spec/dnsimple/client/services_service_spec.rb +162 -0
- data/spec/dnsimple/client/templates_service_spec.rb +371 -0
- data/spec/dnsimple/client/users_service_spec.rb +70 -0
- data/spec/dnsimple/client_spec.rb +108 -99
- data/spec/dnsimple/compatibility_spec.rb +57 -0
- data/spec/files/2fa/exchange-token.http +8 -11
- data/spec/files/badgateway.http +14 -0
- data/spec/files/certificates/configure/success.http +19 -0
- data/spec/files/certificates/index/success.http +1 -1
- data/spec/files/certificates/notfound.http +19 -0
- data/spec/files/certificates/purchase/success.http +19 -0
- data/spec/files/certificates/show/success.http +1 -1
- data/spec/files/certificates/submit/success.http +19 -0
- data/spec/files/contacts/create/badrequest-missingcontact.http +19 -0
- data/spec/files/contacts/create/badrequest-validationerror.http +19 -0
- data/spec/files/contacts/create/created.http +22 -0
- data/spec/files/contacts/delete/success-204.http +18 -0
- data/spec/files/{extended_attributes/com.http → contacts/delete/success.http} +5 -5
- data/spec/files/{domains/auto_renewal_enable → contacts/index}/success.http +6 -6
- data/spec/files/contacts/notfound.http +19 -0
- data/spec/files/contacts/update/success.http +21 -0
- data/spec/files/domains/create/created.http +21 -0
- data/spec/files/domains/index/success.http +11 -9
- data/spec/files/domains/notfound.http +11 -9
- data/spec/files/domains/show/success.http +12 -10
- data/spec/files/domains_autorenewal/disable/success.http +21 -0
- data/spec/files/domains_autorenewal/enable/success.http +21 -0
- data/spec/files/domains_autorenewal/notfound-domain.http +19 -0
- data/spec/files/domains_forwards/create/created.http +22 -0
- data/spec/files/domains_forwards/delete/success.http +17 -0
- data/spec/files/domains_forwards/get/success.http +21 -0
- data/spec/files/domains_forwards/list/success.http +21 -0
- data/spec/files/domains_forwards/notfound-domain.http +19 -0
- data/spec/files/domains_forwards/notfound.http +19 -0
- data/spec/files/domains_records/create/created.http +21 -0
- data/spec/files/domains_records/delete/success-204.http +18 -0
- data/spec/files/{contacts/show/notfound.http → domains_records/delete/success.http} +9 -7
- data/spec/files/{records → domains_records}/index/success.http +0 -0
- data/spec/files/{records/show → domains_records}/notfound.http +1 -1
- data/spec/files/{records → domains_records}/show/success.http +0 -0
- data/spec/files/domains_records/update/success.http +21 -0
- data/spec/files/domains_sharing/create/success.http +21 -0
- data/spec/files/domains_sharing/delete/success.http +17 -0
- data/spec/files/domains_sharing/list/success.http +21 -0
- data/spec/files/domains_sharing/notfound-domain.http +19 -0
- data/spec/files/domains_sharing/notfound.http +19 -0
- data/spec/files/domains_whois_privacy/disable/success.http +21 -0
- data/spec/files/domains_whois_privacy/enable/success.http +22 -0
- data/spec/files/domains_zones/get/success.http +21 -0
- data/spec/files/domains_zones/notfound-domain.http +19 -0
- data/spec/files/{domains/auto_renewal_disable/notfound.http → nameservers/change/success.http} +23 -21
- data/spec/files/nameservers/deregister/success.http +17 -0
- data/spec/files/{domains/auto_renewal_enable/notfound.http → nameservers/list/success.http} +23 -21
- data/spec/files/nameservers/notfound-domain.http +19 -0
- data/spec/files/nameservers/register/badrequest-valueerror.http +19 -0
- data/spec/files/nameservers/register/success.http +21 -0
- data/spec/files/registrars/check/available.http +19 -0
- data/spec/files/registrars/check/registered.http +21 -0
- data/spec/files/registrars/register/badrequest-missingdomain.http +19 -0
- data/spec/files/registrars/register/badrequest-missingregistrant.http +19 -0
- data/spec/files/registrars/register/success.http +21 -0
- data/spec/files/registrars/renew/badrequest-missingrenewal.http +19 -0
- data/spec/files/registrars/renew/badrequest-unable.http +19 -0
- data/spec/files/registrars/renew/success.http +21 -0
- data/spec/files/registrars/transfer/success.http +21 -0
- data/spec/files/registrars_extended_attributes/list/success.http +21 -0
- data/spec/files/registrars_prices/list/success.http +21 -0
- data/spec/files/services/applied/success.http +21 -0
- data/spec/files/services/apply/success.http +21 -0
- data/spec/files/services/available/success.http +21 -0
- data/spec/files/services/index/success.http +21 -0
- data/spec/files/services/notfound.http +19 -0
- data/spec/files/services/show/success.http +21 -0
- data/spec/files/services/unapply/success.http +21 -0
- data/spec/files/subscription/show/success.http +21 -0
- data/spec/files/templates/apply/success.http +21 -0
- data/spec/files/templates/create/created.http +22 -0
- data/spec/files/templates/delete/success-204.http +21 -0
- data/spec/files/templates/delete/success.http +21 -0
- data/spec/files/templates/index/success.http +21 -0
- data/spec/files/templates/notfound.http +19 -0
- data/spec/files/templates/show/success.http +12 -10
- data/spec/files/templates/update/success.http +21 -0
- data/spec/files/templates_records/create/created.http +22 -0
- data/spec/files/templates_records/delete/success-204.http +19 -0
- data/spec/files/templates_records/delete/success.http +21 -0
- data/spec/files/templates_records/index/success.http +21 -0
- data/spec/files/templates_records/notfound.http +19 -0
- data/spec/files/templates_records/show/success.http +21 -0
- data/spec/files/templates_records/update/success.http +21 -0
- data/spec/files/users/user/success.http +21 -0
- data/spec/spec_helper.rb +0 -2
- metadata +206 -73
- data/lib/dnsimple/base.rb +0 -10
- data/lib/dnsimple/certificate.rb +0 -143
- data/lib/dnsimple/contact.rb +0 -157
- data/lib/dnsimple/domain.rb +0 -252
- data/lib/dnsimple/extended_attribute.rb +0 -52
- data/lib/dnsimple/record.rb +0 -94
- data/lib/dnsimple/service.rb +0 -42
- data/lib/dnsimple/template.rb +0 -65
- data/lib/dnsimple/template_record.rb +0 -80
- data/lib/dnsimple/transfer_order.rb +0 -34
- data/lib/dnsimple/user.rb +0 -50
- data/spec/dnsimple/certificate_spec.rb +0 -59
- data/spec/dnsimple/contact_spec.rb +0 -45
- data/spec/dnsimple/domain_spec.rb +0 -241
- data/spec/dnsimple/extended_attributes_spec.rb +0 -54
- data/spec/dnsimple/record_spec.rb +0 -51
- data/spec/dnsimple/template_spec.rb +0 -31
- data/spec/dnsimple/user_spec.rb +0 -70
- data/spec/files/account/user/success.http +0 -19
- data/spec/files/certificates/show/notfound.http +0 -17
- data/spec/files/domains/auto_renewal_disable/success.http +0 -23
- data/spec/files/domains/create/success.http +0 -19
- data/spec/files/extended_attributes/ca.http +0 -19
- data/spec/files/extended_attributes/success.http +0 -19
- data/spec/files/templates/show/notfound.http +0 -17
@@ -0,0 +1,57 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Dnsimple::Client do
|
4
|
+
|
5
|
+
describe "class-level configs" do
|
6
|
+
before do
|
7
|
+
@_1 = described_class.base_uri
|
8
|
+
@_2 = described_class.username
|
9
|
+
@_3 = described_class.password
|
10
|
+
@_4 = described_class.api_token
|
11
|
+
@_5 = described_class.domain_api_token
|
12
|
+
@_6 = described_class.exchange_token
|
13
|
+
end
|
14
|
+
|
15
|
+
after do
|
16
|
+
described_class.base_uri = @_1
|
17
|
+
described_class.username = @_2
|
18
|
+
described_class.password = @_3
|
19
|
+
described_class.api_token = @_4
|
20
|
+
described_class.domain_api_token = @_5
|
21
|
+
described_class.exchange_token = @_6
|
22
|
+
end
|
23
|
+
|
24
|
+
it "passes configs to the client" do
|
25
|
+
described_class.base_uri = "https://api.example.com/"
|
26
|
+
described_class.username = "hello"
|
27
|
+
described_class.password = "world"
|
28
|
+
described_class.api_token = "api-token"
|
29
|
+
described_class.domain_api_token = "domain-api-token"
|
30
|
+
described_class.exchange_token = "exchange-token"
|
31
|
+
|
32
|
+
expect(described_class).to receive(:new).with({
|
33
|
+
api_endpoint: "https://api.example.com/",
|
34
|
+
username: "hello",
|
35
|
+
password: "world",
|
36
|
+
api_token: "api-token",
|
37
|
+
domain_api_token: "domain-api-token",
|
38
|
+
exchange_token: "exchange-token",
|
39
|
+
})
|
40
|
+
|
41
|
+
described_class.client
|
42
|
+
end
|
43
|
+
end
|
44
|
+
|
45
|
+
[:get, :post, :put, :delete].each do |method|
|
46
|
+
describe ".#{method}" do
|
47
|
+
it "delegates to .client" do
|
48
|
+
client = double()
|
49
|
+
expect(client).to receive(method).with('path', { foo: 'bar' })
|
50
|
+
|
51
|
+
expect(described_class).to receive(:client).and_return(client)
|
52
|
+
described_class.send(method, 'path', { :foo => 'bar' })
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
end
|
@@ -1,25 +1,22 @@
|
|
1
1
|
HTTP/1.1 200 OK
|
2
2
|
Server: nginx
|
3
|
-
Date:
|
3
|
+
Date: Mon, 15 Dec 2014 17:04:41 GMT
|
4
4
|
Content-Type: application/json; charset=utf-8
|
5
5
|
Transfer-Encoding: chunked
|
6
|
-
Connection:
|
6
|
+
Connection: keep-alive
|
7
7
|
Status: 200 OK
|
8
8
|
Strict-Transport-Security: max-age=631138519
|
9
9
|
X-Frame-Options: SAMEORIGIN
|
10
10
|
X-XSS-Protection: 1
|
11
11
|
X-Content-Type-Options: nosniff
|
12
|
-
X-UA-Compatible: chrome=1
|
13
12
|
Access-Control-Allow-Origin: *
|
14
|
-
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
15
14
|
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
16
|
-
|
17
|
-
ETag: "8f991ac7debfbe00277cb74b6d41c9a4"
|
15
|
+
ETag: "535b1edb37f32b4388c1be8682e8c15a"
|
18
16
|
Cache-Control: max-age=0, private, must-revalidate
|
19
|
-
|
20
|
-
|
21
|
-
X-Request-Id: 7e658b27-a46f-42bc-acb7-56fc94a5a623
|
22
|
-
X-Runtime: 0.437686
|
17
|
+
X-Request-Id: ee1f0ee3-082a-4e59-8891-17d5068e857c
|
18
|
+
X-Runtime: 0.073436
|
23
19
|
Strict-Transport-Security: max-age=315360000
|
20
|
+
X-Dnsimple-OTP-Token: 0c622716aaa64124219963075bc1c870
|
24
21
|
|
25
|
-
{"user":{"id":
|
22
|
+
{"user":{"id":1,"email":"example@example.com","referral_token":"referral-token","api_token":"api-token","domain_count":32,"domain_limit":1000,"login_count":2,"failed_login_count":1,"created_at":"2011-03-17T21:30:25.731Z","updated_at":"2014-12-13T13:52:08.343Z"}}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
HTTP/1.1 502 Bad Gateway
|
2
|
+
Server: nginx
|
3
|
+
Date: Mon, 22 Dec 2014 14:16:12 GMT
|
4
|
+
Content-Type: text/html
|
5
|
+
Content-Length: 166
|
6
|
+
Connection: close
|
7
|
+
|
8
|
+
<html>
|
9
|
+
<head><title>502 Bad Gateway</title></head>
|
10
|
+
<body bgcolor="white">
|
11
|
+
<center><h1>502 Bad Gateway</h1></center>
|
12
|
+
<hr><center>nginx</center>
|
13
|
+
</body>
|
14
|
+
</html>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 200 OK
|
2
|
+
Server: nginx/1.5.8
|
3
|
+
Date: Tue, 14 Jan 2014 18:40:28 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: close
|
7
|
+
Status: 200 OK
|
8
|
+
X-Dnsimple-API-Version: 1.0.0
|
9
|
+
Access-Control-Allow-Origin: *
|
10
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-Dnsimple-Token,X-Dnsimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
+
X-UA-Compatible: IE=Edge,chrome=1
|
13
|
+
ETag: "2b76f0ea88c7e95384506ac576d23d01"
|
14
|
+
Cache-Control: max-age=0, private, must-revalidate
|
15
|
+
X-Request-Id: aaf5915a32924165d4f45779689831fa
|
16
|
+
X-Runtime: 0.042263
|
17
|
+
Strict-Transport-Security: max-age=315360000
|
18
|
+
|
19
|
+
{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"configured","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":null,"approver_emails":["admin@example.com", "admin@www.example.com"],"expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"}}
|
@@ -16,4 +16,4 @@ X-Request-Id: f06a7d3fc56223e9db4c14f548c43d7a
|
|
16
16
|
X-Runtime: 0.046608
|
17
17
|
Strict-Transport-Security: max-age=315360000
|
18
18
|
|
19
|
-
[{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"cancelled","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.com","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"
|
19
|
+
[{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"cancelled","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.com","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"}},{"certificate":{"id":4578,"domain_id":79569,"contact_id":11549,"name":"www","state":"cancelled","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\n2iT9OvY4afImf2ZcXnYZGrfXCx4GOxeMDpNcQm0RT3gLGw==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nwDj89yRezuhCL5K1MSVohQyhyESr9Vz93p4r31DZxAmgFbCRE+g=\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.com","expires_on":"2014-09-17","created_at":"2013-09-17T22:30:03Z","updated_at":"2013-09-17T22:30:41Z","configured_at":"2013-09-17T22:30:08Z"}}]
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 404 Not Found
|
2
|
+
Server: nginx
|
3
|
+
Date: Tue, 16 Dec 2014 00:31:39 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: close
|
7
|
+
Status: 404 Not Found
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
Cache-Control: no-cache
|
16
|
+
X-Request-Id: 5c210ca0-0f2c-4cb4-8a06-6d6f352bc3b7
|
17
|
+
X-Runtime: 0.043528
|
18
|
+
|
19
|
+
{"message":"Certificate `0' not found"}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 200 OK
|
2
|
+
Server: nginx/1.5.8
|
3
|
+
Date: Tue, 14 Jan 2014 18:40:28 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: close
|
7
|
+
Status: 200 OK
|
8
|
+
X-Dnsimple-API-Version: 1.0.0
|
9
|
+
Access-Control-Allow-Origin: *
|
10
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-Dnsimple-Token,X-Dnsimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
+
X-UA-Compatible: IE=Edge,chrome=1
|
13
|
+
ETag: "2b76f0ea88c7e95384506ac576d23d01"
|
14
|
+
Cache-Control: max-age=0, private, must-revalidate
|
15
|
+
X-Request-Id: aaf5915a32924165d4f45779689831fa
|
16
|
+
X-Runtime: 0.042263
|
17
|
+
Strict-Transport-Security: max-age=315360000
|
18
|
+
|
19
|
+
{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"purchased","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.net","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"}}
|
@@ -16,4 +16,4 @@ X-Request-Id: aaf5915a32924165d4f45779689831fa
|
|
16
16
|
X-Runtime: 0.042263
|
17
17
|
Strict-Transport-Security: max-age=315360000
|
18
18
|
|
19
|
-
{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"cancelled","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":"-----BEGIN CERTIFICATE-----\nXwTkw5UCPpaVyUYcwHlvaprOe9ZbwIyEHm2AT1rW+70=\n-----END CERTIFICATE-----\n","private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.net","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"
|
19
|
+
{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"cancelled","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":"-----BEGIN CERTIFICATE-----\nXwTkw5UCPpaVyUYcwHlvaprOe9ZbwIyEHm2AT1rW+70=\n-----END CERTIFICATE-----\n","private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.net","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"}}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 200 OK
|
2
|
+
Server: nginx/1.5.8
|
3
|
+
Date: Tue, 14 Jan 2014 18:40:28 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: close
|
7
|
+
Status: 200 OK
|
8
|
+
X-Dnsimple-API-Version: 1.0.0
|
9
|
+
Access-Control-Allow-Origin: *
|
10
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-Dnsimple-Token,X-Dnsimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
+
X-UA-Compatible: IE=Edge,chrome=1
|
13
|
+
ETag: "2b76f0ea88c7e95384506ac576d23d01"
|
14
|
+
Cache-Control: max-age=0, private, must-revalidate
|
15
|
+
X-Request-Id: aaf5915a32924165d4f45779689831fa
|
16
|
+
X-Runtime: 0.042263
|
17
|
+
Strict-Transport-Security: max-age=315360000
|
18
|
+
|
19
|
+
{"certificate":{"id":4576,"domain_id":79569,"contact_id":11549,"name":"www","state":"submitted","csr":"-----BEGIN NEW CERTIFICATE REQUEST-----\nRHr2akB4KMba6FMAsvlStnO/2ika16hNx+d3smPNsER+HA==\n-----END NEW CERTIFICATE REQUEST-----\n","ssl_certificate":null,"private_key":"-----BEGIN RSA PRIVATE KEY-----\nUeXbFi7o+nuPfRhpBFQEKwacKFc3Hnc1hH6UsnC0KY25cUif7yz38A==\n-----END RSA PRIVATE KEY-----\n","approver_email":"example@example.net","expires_on":"2014-09-17","created_at":"2013-09-17T21:54:42Z","updated_at":"2013-09-17T22:25:36Z","configured_at":"2013-09-17T22:25:01Z"}}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 400 Bad Request
|
2
|
+
Server: nginx
|
3
|
+
Date: Sun, 14 Dec 2014 23:27:25 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 400 Bad Request
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
Cache-Control: no-cache
|
16
|
+
X-Request-Id: 6f5ca4d6-1f39-4aad-ba3d-c19cd1450747
|
17
|
+
X-Runtime: 0.043306
|
18
|
+
|
19
|
+
{"message":"Required parameter missing: contact"}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 400 Bad Request
|
2
|
+
Server: nginx
|
3
|
+
Date: Sun, 14 Dec 2014 23:28:59 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 400 Bad Request
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
Cache-Control: no-cache
|
16
|
+
X-Request-Id: 8f5813e3-33ad-4024-bff9-8da2fad15c33
|
17
|
+
X-Runtime: 0.041768
|
18
|
+
|
19
|
+
{"errors":{"phone":["is probably not a phone number"],"fax":["is probably not a phone number"]}}
|
@@ -0,0 +1,22 @@
|
|
1
|
+
HTTP/1.1 201 Created
|
2
|
+
Server: nginx
|
3
|
+
Date: Sun, 14 Dec 2014 23:30:15 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 201 Created
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
Location: https://api.dnsimple.com/contacts/22968
|
16
|
+
ETag: "ca2737f80fe8f50f9d769c3217f1a4f6"
|
17
|
+
Cache-Control: max-age=0, private, must-revalidate
|
18
|
+
X-Request-Id: 3656ad24-0fc1-4f1a-99ad-1cc930224bcb
|
19
|
+
X-Runtime: 0.061358
|
20
|
+
Strict-Transport-Security: max-age=315360000
|
21
|
+
|
22
|
+
{"contact":{"id":22968,"user_id":null,"label":"Test","first_name":"Simone","last_name":"Carletti","job_title":"Underwater Programmer","organization_name":"Dnsimple","email_address":"example@example.com","phone":"+39 339 000000","fax":"+39 339 000000","address1":"Awesome Street","address2":"c/o Someone","city":"Rome","state_province":"RM","postal_code":"00171","country":"IT","created_at":"2014-12-14T23:30:15.096Z","updated_at":"2014-12-14T23:30:15.096Z"}}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
HTTP/1.1 204 No Content
|
2
|
+
Server: nginx/1.4.4
|
3
|
+
Date: Tue, 14 Jan 2014 19:03:37 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: close
|
7
|
+
Status: 204 No Content
|
8
|
+
X-Dnsimple-API-Version: 1.0.0
|
9
|
+
Access-Control-Allow-Origin: *
|
10
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-Dnsimple-Token,X-Dnsimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
+
X-UA-Compatible: IE=Edge,chrome=1
|
13
|
+
ETag: "3f9496912d04f422c7f083b93bd6e9e3"
|
14
|
+
Cache-Control: max-age=0, private, must-revalidate
|
15
|
+
X-Request-Id: eec6552de5a2aa5ae570139b388ffb9b
|
16
|
+
X-Runtime: 0.046892
|
17
|
+
Strict-Transport-Security: max-age=315360000
|
18
|
+
|
@@ -1,6 +1,6 @@
|
|
1
1
|
HTTP/1.1 200 OK
|
2
2
|
Server: nginx/1.4.4
|
3
|
-
Date: Tue, 14 Jan 2014
|
3
|
+
Date: Tue, 14 Jan 2014 19:03:37 GMT
|
4
4
|
Content-Type: application/json; charset=utf-8
|
5
5
|
Transfer-Encoding: chunked
|
6
6
|
Connection: close
|
@@ -10,10 +10,10 @@ Access-Control-Allow-Origin: *
|
|
10
10
|
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-Dnsimple-Token,X-Dnsimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
11
|
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
12
|
X-UA-Compatible: IE=Edge,chrome=1
|
13
|
-
ETag: "
|
13
|
+
ETag: "3f9496912d04f422c7f083b93bd6e9e3"
|
14
14
|
Cache-Control: max-age=0, private, must-revalidate
|
15
|
-
X-Request-Id:
|
16
|
-
X-Runtime: 0.
|
15
|
+
X-Request-Id: eec6552de5a2aa5ae570139b388ffb9b
|
16
|
+
X-Runtime: 0.046892
|
17
17
|
Strict-Transport-Security: max-age=315360000
|
18
18
|
|
19
|
-
|
19
|
+
{}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
HTTP/1.1 200 OK
|
2
2
|
Server: nginx/1.4.7
|
3
|
-
Date: Tue, 01 Jul 2014
|
3
|
+
Date: Tue, 01 Jul 2014 14:58:44 GMT
|
4
4
|
Content-Type: application/json; charset=utf-8
|
5
5
|
Transfer-Encoding: chunked
|
6
6
|
Connection: close
|
@@ -11,13 +11,13 @@ X-XSS-Protection: 1
|
|
11
11
|
X-Content-Type-Options: nosniff
|
12
12
|
X-UA-Compatible: chrome=1
|
13
13
|
Access-Control-Allow-Origin: *
|
14
|
-
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-
|
14
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
15
15
|
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
16
16
|
Content-Security-Policy: default-src 'self'; connect-src 'self'; font-src 'self' data: netdna.bootstrapcdn.com *.edgecastcdn.net; frame-src 'self'; img-src 'self' data: *.nr-data.net; media-src 'self'; object-src 'self'; script-src 'self' data: 'unsafe-inline' 'unsafe-eval' *.getdrip.com *.visualwebsiteoptimizer.com *.doubleclick.net *.pathful.com *.newrelic.com; style-src 'self' data: 'unsafe-inline' 'unsafe-eval' netdna.bootstrapcdn.com cloud.webtype.com cloud.typography.com;
|
17
|
-
ETag: "
|
17
|
+
ETag: "a037fcce7e739f5ba6d94efe2fb63f77"
|
18
18
|
Cache-Control: max-age=0, private, must-revalidate
|
19
|
-
X-Request-Id:
|
20
|
-
X-Runtime:
|
19
|
+
X-Request-Id: 935327a1-d72e-4c11-b382-e817200496b6
|
20
|
+
X-Runtime: 0.018471
|
21
21
|
Strict-Transport-Security: max-age=315360000
|
22
22
|
|
23
|
-
{"
|
23
|
+
[{"contact":{"id":28,"user_id":19,"label":"Simone","first_name":"Simone","last_name":"Carletti","job_title":"Underwater Programmer","organization_name":"DNSimple","email_address":"simone.carletti@dnsimple.com","phone":"+1 111 4567890","fax":"+1 222 4567890","address1":"Awesome Street","address2":"c/o Someone","city":"Rome","state_province":"RM","postal_code":"00171","country":"IT","created_at":"2014-01-15T22:08:07.390Z","updated_at":"2014-01-15T22:08:07.390Z","phone_ext":null}}]
|
@@ -0,0 +1,19 @@
|
|
1
|
+
HTTP/1.1 404 Not Found
|
2
|
+
Server: nginx
|
3
|
+
Date: Sun, 14 Dec 2014 21:01:05 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 404 Not Found
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
Cache-Control: no-cache
|
16
|
+
X-Request-Id: 34138912-6358-4ef9-8838-c0852137b5b9
|
17
|
+
X-Runtime: 0.046436
|
18
|
+
|
19
|
+
{"message":"Contact `0' not found"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
HTTP/1.1 200 OK
|
2
|
+
Server: nginx
|
3
|
+
Date: Sun, 14 Dec 2014 23:40:28 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 200 OK
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
ETag: "ca2737f80fe8f50f9d769c3217f1a4f6"
|
16
|
+
Cache-Control: max-age=0, private, must-revalidate
|
17
|
+
X-Request-Id: 5873272b-59a5-47d9-ae8c-c0393fe9b242
|
18
|
+
X-Runtime: 0.089584
|
19
|
+
Strict-Transport-Security: max-age=315360000
|
20
|
+
|
21
|
+
{"contact":{"id":22968,"user_id":null,"label":"Test","first_name":"Simone","last_name":"Carletti","job_title":"Underwater Programmer","organization_name":"Dnsimple","email_address":"example@example.com","phone":"+39 339 000000","fax":"+39 339 000000","address1":"Awesome Street","address2":"c/o Someone","city":"Rome","state_province":"RM","postal_code":"00171","country":"IT","created_at":"2014-12-14T23:30:15.096Z","updated_at":"2014-12-14T23:30:15.096Z"}}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
HTTP/1.1 201 Created
|
2
|
+
Server: nginx
|
3
|
+
Date: Mon, 15 Dec 2014 20:27:04 GMT
|
4
|
+
Content-Type: application/json; charset=utf-8
|
5
|
+
Transfer-Encoding: chunked
|
6
|
+
Connection: keep-alive
|
7
|
+
Status: 201 Created
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
12
|
+
Access-Control-Allow-Origin: *
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
14
|
+
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
15
|
+
ETag: "882c85c0756e35625681ceb5262b0fe6"
|
16
|
+
Cache-Control: max-age=0, private, must-revalidate
|
17
|
+
X-Request-Id: 9a8e4510-d956-4a94-8a76-dd86669afef4
|
18
|
+
X-Runtime: 0.395985
|
19
|
+
Strict-Transport-Security: max-age=315360000
|
20
|
+
|
21
|
+
{"domain":{"id":1,"user_id":21,"registrant_id":321,"name":"example.com","unicode_name":"example.com","token":"domain-token","state":"registered","language":null,"lockable":false,"auto_renew":true,"whois_protected":false,"record_count":5,"service_count":1,"expires_on":"2015-09-27","created_at":"2012-09-27T14:25:57.646Z","updated_at":"2014-12-15T20:27:04.552Z"}}
|
@@ -1,19 +1,21 @@
|
|
1
1
|
HTTP/1.1 200 OK
|
2
|
-
Server: nginx
|
3
|
-
Date:
|
2
|
+
Server: nginx
|
3
|
+
Date: Mon, 15 Dec 2014 20:27:04 GMT
|
4
4
|
Content-Type: application/json; charset=utf-8
|
5
5
|
Transfer-Encoding: chunked
|
6
|
-
Connection:
|
6
|
+
Connection: keep-alive
|
7
7
|
Status: 200 OK
|
8
|
-
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
9
12
|
Access-Control-Allow-Origin: *
|
10
13
|
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
14
|
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
-
|
13
|
-
ETag: "e745f0c40f69125f6ae89bf85f438aeb"
|
15
|
+
ETag: "882c85c0756e35625681ceb5262b0fe6"
|
14
16
|
Cache-Control: max-age=0, private, must-revalidate
|
15
|
-
X-Request-Id:
|
16
|
-
X-Runtime: 0.
|
17
|
+
X-Request-Id: 9a8e4510-d956-4a94-8a76-dd86669afef4
|
18
|
+
X-Runtime: 0.395985
|
17
19
|
Strict-Transport-Security: max-age=315360000
|
18
20
|
|
19
|
-
[{"domain":{"id":
|
21
|
+
[{"domain":{"id":1,"user_id":21,"registrant_id":321,"name":"example.com","unicode_name":"example.com","token":"domain-token","state":"registered","language":null,"lockable":false,"auto_renew":true,"whois_protected":false,"record_count":5,"service_count":1,"expires_on":"2015-09-27","created_at":"2012-09-27T14:25:57.646Z","updated_at":"2014-12-15T20:27:04.552Z"}},{"domain":{"id":2,"user_id":21,"registrant_id":321,"name":"example.com","unicode_name":"example.it","token":"domain-token","state":"hosted","language":null,"lockable":false,"auto_renew":true,"whois_protected":false,"record_count":5,"service_count":1,"expires_on":null,"created_at":"2012-09-27T14:25:57.646Z","updated_at":"2014-12-15T20:27:04.552Z"}}]
|
@@ -1,17 +1,19 @@
|
|
1
1
|
HTTP/1.1 404 Not Found
|
2
|
-
Server: nginx
|
3
|
-
Date:
|
2
|
+
Server: nginx
|
3
|
+
Date: Mon, 15 Dec 2014 20:55:36 GMT
|
4
4
|
Content-Type: application/json; charset=utf-8
|
5
5
|
Transfer-Encoding: chunked
|
6
|
-
Connection:
|
6
|
+
Connection: keep-alive
|
7
7
|
Status: 404 Not Found
|
8
|
-
|
8
|
+
Strict-Transport-Security: max-age=631138519
|
9
|
+
X-Frame-Options: SAMEORIGIN
|
10
|
+
X-XSS-Protection: 1
|
11
|
+
X-Content-Type-Options: nosniff
|
9
12
|
Access-Control-Allow-Origin: *
|
10
|
-
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-
|
13
|
+
Access-Control-Allow-Headers: Authorization,Accepts,Content-Type,X-DNSimple-Token,X-DNSimple-Domain-Token,X-CSRF-Token,x-requested-with
|
11
14
|
Access-Control-Allow-Methods: GET,POST,PUT,DELETE,OPTIONS
|
12
|
-
X-UA-Compatible: IE=Edge,chrome=1
|
13
15
|
Cache-Control: no-cache
|
14
|
-
X-Request-Id:
|
15
|
-
X-Runtime: 0.
|
16
|
+
X-Request-Id: 8d96a3b2-be45-4734-9a76-7dde39e0c94e
|
17
|
+
X-Runtime: 0.048082
|
16
18
|
|
17
|
-
{"
|
19
|
+
{"message":"Domain `0' not found"}
|