From a5785ca7fbc4d53037604322144223a7ae3144e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 14:07:48 +0200 Subject: [PATCH 1/9] Update domain.md Documentation for request of contact details related to a domain. --- doc/repp/v1/domain.md | 82 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) diff --git a/doc/repp/v1/domain.md b/doc/repp/v1/domain.md index 79e002b6c..b5733f998 100644 --- a/doc/repp/v1/domain.md +++ b/doc/repp/v1/domain.md @@ -1,3 +1,5 @@ +# Domain listing + ## GET /repp/v1/domains Returns domains of the current registrar. @@ -98,3 +100,83 @@ Content-Type: application/json "total_number_of_records": 2 } ``` + +# Details of contacts + +## GET /repp/v1/domains/*domainname.ee*/transfer_info +Returns details of contacts associated with other registrar. Necessary for pre-transfer checks and better user experience in automated registrar systems. + +Please note the domain name in the path + +#### Request +``` +GET /repp/v1/domains?limit=1&details=true HTTP/1.1 +Accept: application/json +Authorization: Basic Z2l0bGFiOmdoeXQ5ZTRmdQ== +Content-Length: 0 +Content-Type: application/json +Auth-Code: authinfopw +``` + +Please note that domain transfer/authorisation code must be placed in header - *Auth-Code* + +#### Response +``` +HTTP/1.1 200 OK +Cache-Control: max-age=0, private, must-revalidate +Content-Length: 784 +Content-Type: application/json + +{ + "domain":"ee-test.ee", + "registrant":{ + "code":"EE:R1", + "ident_type":"org", + "ident_country_code":"EE", + "phone":"+372.1234567", + "email":"registrant@cache.ee", + "street":"Businesstreet 1", + "city":"Tallinn", + "zip":"10101", + "country_code":"EE", + "statuses":[ + "ok", + "linked" + ] + }, + "admin_contacts":[ + { + "code":"EE:A1", + "ident_type":"priv", + "ident_country_code":"EE", + "phone":"+372.7654321", + "email":"admin@cache.ee", + "street":"Adminstreet 2", + "city":"Tallinn", + "zip":"12345", + "country_code":"EE", + "statuses":[ + "ok", + "linked" + ] + } + ], + "tech_contacts":[ + { + "code":"EE:T1", + "ident_type":"org", + "ident_country_code":"EE", + "phone":"+372.7654321", + "email":"tech@cache.ee", + "street":"Techstreet 1", + "city":"Tallinn", + "zip":"12345", + "country_code":"EE", + "statuses":[ + "ok", + "linked" + ] + } + ] +} +``` From 06e5ec99fade9920f0743e1c22150e305df16c61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 14:11:00 +0200 Subject: [PATCH 2/9] Update domain.md Typo fixes in transfer info documentation --- doc/repp/v1/domain.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/repp/v1/domain.md b/doc/repp/v1/domain.md index b5733f998..fc417b47f 100644 --- a/doc/repp/v1/domain.md +++ b/doc/repp/v1/domain.md @@ -101,16 +101,16 @@ Content-Type: application/json } ``` -# Details of contacts +# Transfer info ## GET /repp/v1/domains/*domainname.ee*/transfer_info -Returns details of contacts associated with other registrar. Necessary for pre-transfer checks and better user experience in automated registrar systems. +Returns details of contacts associated with a domain to be transfered. Necessary for pre-transfer checks and better user experience in automated registrar systems. Please note the domain name in the path #### Request ``` -GET /repp/v1/domains?limit=1&details=true HTTP/1.1 +GET /repp/v1/domains/ee-test.ee/transfer_info HTTP/1.1 Accept: application/json Authorization: Basic Z2l0bGFiOmdoeXQ5ZTRmdQ== Content-Length: 0 From fd78aa9205033f059e9526af641b9100cc005d27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 14:35:34 +0200 Subject: [PATCH 3/9] Update all-ee-1.0.xsd structural fixes, added missing host-1.0.xsd --- doc/schemas/all-ee-1.0.xsd | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/doc/schemas/all-ee-1.0.xsd b/doc/schemas/all-ee-1.0.xsd index 124f53d24..bd4aeba0c 100644 --- a/doc/schemas/all-ee-1.0.xsd +++ b/doc/schemas/all-ee-1.0.xsd @@ -20,15 +20,19 @@ schemaLocation="eppcom-1.0.xsd"/> + + + + + - - - + From af023edf3a12de5cb593cef50c6c40fc906a1c26 Mon Sep 17 00:00:00 2001 From: Stas Date: Thu, 26 Nov 2015 15:01:23 +0200 Subject: [PATCH 4/9] 107821878-typo --- app/mailers/contact_mailer.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/mailers/contact_mailer.rb b/app/mailers/contact_mailer.rb index 71e635540..110ce6a71 100644 --- a/app/mailers/contact_mailer.rb +++ b/app/mailers/contact_mailer.rb @@ -4,7 +4,7 @@ class ContactMailer < ApplicationMailer def email_updated(email, contact_id, should_deliver) @contact = Contact.find_by(id: contact_id) return unless email || @contact - return if delivery_off?(contact, should_deliver) + return if delivery_off?(@contact, should_deliver) return if whitelist_blocked?(email) begin From c82cb72a27913a75514fe1e07a98ca2abbb2b01f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 15:06:10 +0200 Subject: [PATCH 5/9] Update contact-eis-1.0.xsd removed unnecessary schemaLocations on namespace import --- doc/schemas/contact-eis-1.0.xsd | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/schemas/contact-eis-1.0.xsd b/doc/schemas/contact-eis-1.0.xsd index e1fb084a5..b8050b681 100644 --- a/doc/schemas/contact-eis-1.0.xsd +++ b/doc/schemas/contact-eis-1.0.xsd @@ -10,9 +10,9 @@ - - - + + + From 03d00b9294871015c27b4e9214500913ab077733 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 15:32:23 +0200 Subject: [PATCH 6/9] Update domain-eis-1.0.xsd removed unnecessary schemaLocations on namespace import, added missing statusValueTypes --- doc/schemas/domain-eis-1.0.xsd | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/doc/schemas/domain-eis-1.0.xsd b/doc/schemas/domain-eis-1.0.xsd index 62da465fe..3fe1188ea 100644 --- a/doc/schemas/domain-eis-1.0.xsd +++ b/doc/schemas/domain-eis-1.0.xsd @@ -11,11 +11,11 @@ - - - - - + + + + + @@ -92,7 +92,6 @@ @@ -386,16 +385,24 @@ + + + + + + + + From 1be64ef96f0b7f7ed7ee3cfd4bf4f76665f4630e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20V=C3=B5hmar?= Date: Thu, 26 Nov 2015 15:40:18 +0200 Subject: [PATCH 7/9] Update contact-eis-1.0.xsd typo fix to import namespaces --- doc/schemas/contact-eis-1.0.xsd | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/schemas/contact-eis-1.0.xsd b/doc/schemas/contact-eis-1.0.xsd index b8050b681..cec571cec 100644 --- a/doc/schemas/contact-eis-1.0.xsd +++ b/doc/schemas/contact-eis-1.0.xsd @@ -10,9 +10,9 @@ - - - + + + From e85d2f52d22af13f1f1c18d4f8df83fe48ec70c6 Mon Sep 17 00:00:00 2001 From: Vladimir Krylov Date: Thu, 26 Nov 2015 16:04:19 +0200 Subject: [PATCH 8/9] Story#108553816 add ident to the contacts json output --- app/api/repp/domain_v1.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/api/repp/domain_v1.rb b/app/api/repp/domain_v1.rb index 859cb14da..7b4a02004 100644 --- a/app/api/repp/domain_v1.rb +++ b/app/api/repp/domain_v1.rb @@ -35,7 +35,7 @@ module Repp error! I18n.t('errors.messages.epp_authorization_error'), 401 unless domain.auth_info.eql? request.headers['Auth-Code'] contact_repp_json = proc{|contact| - contact.attributes.slice("code", "ident_type", "ident_country_code", "phone", "email", "street", "city", "zip","country_code", "statuses") + contact.attributes.slice("code", "ident", "ident_type", "ident_country_code", "phone", "email", "street", "city", "zip","country_code", "statuses") } @response = { From 72c895db993ed5d9809db7ed459ef87afc0bedae Mon Sep 17 00:00:00 2001 From: Vladimir Krylov Date: Thu, 26 Nov 2015 17:20:39 +0200 Subject: [PATCH 9/9] Story#108553816 add name to the contacts json output --- app/api/repp/domain_v1.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/api/repp/domain_v1.rb b/app/api/repp/domain_v1.rb index 7b4a02004..9275e611f 100644 --- a/app/api/repp/domain_v1.rb +++ b/app/api/repp/domain_v1.rb @@ -35,7 +35,7 @@ module Repp error! I18n.t('errors.messages.epp_authorization_error'), 401 unless domain.auth_info.eql? request.headers['Auth-Code'] contact_repp_json = proc{|contact| - contact.attributes.slice("code", "ident", "ident_type", "ident_country_code", "phone", "email", "street", "city", "zip","country_code", "statuses") + contact.attributes.slice("code", "name", "ident", "ident_type", "ident_country_code", "phone", "email", "street", "city", "zip","country_code", "statuses") } @response = {