From c43495831d8d584104adbebe73048ebe66bf87f5 Mon Sep 17 00:00:00 2001
From: Juan Ku Quintana This parameter is optional; if you never call this method, the SDK will omit
- * {@code trustee_service} from the JSON request payload.
This parameter is optional; if you never call this method, the SDK will omit - * {@code trustee_service} from the JSON request payload.
+ * {@code trustee} from the JSON request payload. */ - public TransferOptions trusteeService() { + public TransferOptions trustee() { return new TransferOptions(registrantId, authCode, whoisPrivacy, autoRenew, extendedAttributes, premiumPrice, true); } } diff --git a/src/test/java/com/dnsimple/endpoints/DomainsTest.java b/src/test/java/com/dnsimple/endpoints/DomainsTest.java index 019c39d..146f797 100644 --- a/src/test/java/com/dnsimple/endpoints/DomainsTest.java +++ b/src/test/java/com/dnsimple/endpoints/DomainsTest.java @@ -74,7 +74,7 @@ public void testGetDomain() { assertThat(domain.getState(), is("registered")); assertThat(domain.hasAutoRenew(), is(false)); assertThat(domain.hasPrivateWhois(), is(false)); - assertThat(domain.hasTrusteeService(), is(false)); + assertThat(domain.hasTrustee(), is(false)); assertThat(domain.getExpiresAt(), is(OffsetDateTime.of(2021, 6, 5, 2, 15, 0, 0, UTC))); assertThat(domain.getCreatedAt(), is(OffsetDateTime.of(2020, 6, 4, 19, 15, 14, 0, UTC))); assertThat(domain.getUpdatedAt(), is(OffsetDateTime.of(2020, 6, 4, 19, 15, 21, 0, UTC))); diff --git a/src/test/java/com/dnsimple/endpoints/RegistrarTest.java b/src/test/java/com/dnsimple/endpoints/RegistrarTest.java index 92977dd..fc2dbdb 100644 --- a/src/test/java/com/dnsimple/endpoints/RegistrarTest.java +++ b/src/test/java/com/dnsimple/endpoints/RegistrarTest.java @@ -45,7 +45,7 @@ public void testGetDomainPrices() { assertThat(prices.getRegistrationPrice(), is(20.0)); assertThat(prices.getRenewalPrice(), is(20.0)); assertThat(prices.getTransferPrice(), is(20.0)); - assertThat(prices.getTrusteeServicePrice(), is(20.0)); + assertThat(prices.getTrusteePrice(), is(20.0)); } @Test(expected = DnsimpleException.class) @@ -70,7 +70,7 @@ public void testGetDomainRegistration() { assertThat(registration.getState(), is("registering")); assertThat(registration.hasAutoRenew(), is(false)); assertThat(registration.hasWhoisPrivacy(), is(false)); - assertThat(registration.hasTrusteeService(), is(false)); + assertThat(registration.hasTrustee(), is(false)); assertThat(registration.getCreatedAt(), is(OffsetDateTime.of(2023, 1, 27, 17, 44, 32, 0, UTC))); assertThat(registration.getUpdatedAt(), is(OffsetDateTime.of(2023, 1, 27, 17, 44, 40, 0, UTC))); } @@ -106,7 +106,7 @@ public void testRegisterDomain() { assertThat(registration.getState(), is("new")); assertThat(registration.hasAutoRenew(), is(false)); assertThat(registration.hasWhoisPrivacy(), is(false)); - assertThat(registration.hasTrusteeService(), is(false)); + assertThat(registration.hasTrustee(), is(false)); assertThat(registration.getCreatedAt(), is(OffsetDateTime.of(2016, 12, 9, 19, 35, 31, 0, UTC))); assertThat(registration.getUpdatedAt(), is(OffsetDateTime.of(2016, 12, 9, 19, 35, 31, 0, UTC))); } @@ -165,7 +165,7 @@ public void testGetDomainTransfer() { assertThat(transfer.getState(), is("cancelled")); assertThat(transfer.hasAutoRenew(), is(false)); assertThat(transfer.hasWhoisPrivacy(), is(false)); - assertThat(transfer.hasTrusteeService(), is(false)); + assertThat(transfer.hasTrustee(), is(false)); assertThat(transfer.getStatusDescription(), is("Canceled by customer")); assertThat(transfer.getCreatedAt(), is("2020-06-05T18:08:00Z")); assertThat(transfer.getUpdatedAt(), is("2020-06-05T18:10:01Z")); @@ -184,7 +184,7 @@ public void testCancelDomainTransfer() { assertThat(transfer.getState(), is("transferring")); assertThat(transfer.hasAutoRenew(), is(false)); assertThat(transfer.hasWhoisPrivacy(), is(false)); - assertThat(transfer.hasTrusteeService(), is(false)); + assertThat(transfer.hasTrustee(), is(false)); assertThat(transfer.getStatusDescription(), isEmptyOrNullString()); assertThat(transfer.getCreatedAt(), is("2020-06-05T18:08:00Z")); assertThat(transfer.getUpdatedAt(), is("2020-06-05T18:08:04Z")); diff --git a/src/test/resources/com/dnsimple/cancelDomainTransfer/success.http b/src/test/resources/com/dnsimple/cancelDomainTransfer/success.http index 72e58a0..80d1b02 100644 --- a/src/test/resources/com/dnsimple/cancelDomainTransfer/success.http +++ b/src/test/resources/com/dnsimple/cancelDomainTransfer/success.http @@ -15,4 +15,4 @@ x-xss-protection: 1; mode=block x-download-options: noopen x-permitted-cross-domain-policies: none -{"data":{"id":361,"domain_id":182245,"registrant_id":2715,"state":"transferring","auto_renew":false,"whois_privacy":false,"trustee_service":false,"status_description":null,"created_at":"2020-06-05T18:08:00Z","updated_at":"2020-06-05T18:08:04Z"}} +{"data":{"id":361,"domain_id":182245,"registrant_id":2715,"state":"transferring","auto_renew":false,"whois_privacy":false,"trustee":false,"status_description":null,"created_at":"2020-06-05T18:08:00Z","updated_at":"2020-06-05T18:08:04Z"}} diff --git a/src/test/resources/com/dnsimple/getDomain/success.http b/src/test/resources/com/dnsimple/getDomain/success.http index 6b86fa8..227eef6 100644 --- a/src/test/resources/com/dnsimple/getDomain/success.http +++ b/src/test/resources/com/dnsimple/getDomain/success.http @@ -17,4 +17,4 @@ x-download-options: noopen x-permitted-cross-domain-policies: none strict-transport-security: max-age=31536000 -{"data":{"id":181984,"account_id":1385,"registrant_id":2715,"name":"example-alpha.com","unicode_name":"example-alpha.com","state":"registered","auto_renew":false,"private_whois":false,"trustee_service":false,"expires_on":"2021-06-05","expires_at":"2021-06-05T02:15:00Z","created_at":"2020-06-04T19:15:14Z","updated_at":"2020-06-04T19:15:21Z"}} +{"data":{"id":181984,"account_id":1385,"registrant_id":2715,"name":"example-alpha.com","unicode_name":"example-alpha.com","state":"registered","auto_renew":false,"private_whois":false,"trustee":false,"expires_on":"2021-06-05","expires_at":"2021-06-05T02:15:00Z","created_at":"2020-06-04T19:15:14Z","updated_at":"2020-06-04T19:15:21Z"}} diff --git a/src/test/resources/com/dnsimple/getDomainPrices/success.http b/src/test/resources/com/dnsimple/getDomainPrices/success.http index 66b0e5c..fcbbbd5 100644 --- a/src/test/resources/com/dnsimple/getDomainPrices/success.http +++ b/src/test/resources/com/dnsimple/getDomainPrices/success.http @@ -18,4 +18,4 @@ x-permitted-cross-domain-policies: none content-security-policy: frame-ancestors 'none' strict-transport-security: max-age=31536000 -{"data":{"domain":"bingo.pizza","premium":true,"registration_price":20.0,"renewal_price":20.0,"transfer_price":20.0,"restore_price":20.0,"trustee_service_price":20.0}} +{"data":{"domain":"bingo.pizza","premium":true,"registration_price":20.0,"renewal_price":20.0,"transfer_price":20.0,"restore_price":20.0,"trustee_price":20.0}} diff --git a/src/test/resources/com/dnsimple/getDomainRegistration/success.http b/src/test/resources/com/dnsimple/getDomainRegistration/success.http index 5cfd190..32379b2 100644 --- a/src/test/resources/com/dnsimple/getDomainRegistration/success.http +++ b/src/test/resources/com/dnsimple/getDomainRegistration/success.http @@ -17,4 +17,4 @@ x-download-options: noopen x-permitted-cross-domain-policies: none strict-transport-security: max-age=31536000 -{"data":{"id":361,"domain_id":104040,"registrant_id":2715,"period":1,"state":"registering","auto_renew":false,"whois_privacy":false,"trustee_service":false,"created_at":"2023-01-27T17:44:32Z","updated_at":"2023-01-27T17:44:40Z"}} +{"data":{"id":361,"domain_id":104040,"registrant_id":2715,"period":1,"state":"registering","auto_renew":false,"whois_privacy":false,"trustee":false,"created_at":"2023-01-27T17:44:32Z","updated_at":"2023-01-27T17:44:40Z"}} diff --git a/src/test/resources/com/dnsimple/getDomainTransfer/success.http b/src/test/resources/com/dnsimple/getDomainTransfer/success.http index 44fe7d9..795d85d 100644 --- a/src/test/resources/com/dnsimple/getDomainTransfer/success.http +++ b/src/test/resources/com/dnsimple/getDomainTransfer/success.http @@ -17,4 +17,4 @@ x-download-options: noopen x-permitted-cross-domain-policies: none strict-transport-security: max-age=31536000 -{"data":{"id":361,"domain_id":182245,"registrant_id":2715,"state":"cancelled","auto_renew":false,"whois_privacy":false,"trustee_service":false,"status_description":"Canceled by customer","created_at":"2020-06-05T18:08:00Z","updated_at":"2020-06-05T18:10:01Z"}} +{"data":{"id":361,"domain_id":182245,"registrant_id":2715,"state":"cancelled","auto_renew":false,"whois_privacy":false,"trustee":false,"status_description":"Canceled by customer","created_at":"2020-06-05T18:08:00Z","updated_at":"2020-06-05T18:10:01Z"}} diff --git a/src/test/resources/com/dnsimple/listCharges/success.http b/src/test/resources/com/dnsimple/listCharges/success.http index 851d232..fd62b0f 100644 --- a/src/test/resources/com/dnsimple/listCharges/success.http +++ b/src/test/resources/com/dnsimple/listCharges/success.http @@ -9,4 +9,4 @@ cache-control: no-store, must-revalidate, private, max-age=0 x-request-id: a57a87c8-626a-4361-9fb8-b55ca9be8e5d x-runtime: 0.060526 -{"data":[{"invoiced_at":"2023-08-17T05:53:36Z","total_amount":"14.50","balance_amount":"0.00","reference":"1-2","state":"collected","items":[{"description":"Register bubble-registered.com","amount":"14.50","product_id":1,"product_type":"domain-registration","product_reference":"bubble-registered.com"}]},{"invoiced_at":"2023-08-17T05:57:53Z","total_amount":"14.50","balance_amount":"0.00","reference":"2-2","state":"refunded","items":[{"description":"Register example.com","amount":"14.50","product_id":2,"product_type":"domain-registration","product_reference":"example.com"}]},{"invoiced_at":"2023-10-24T07:49:05Z","total_amount":"1099999.99","balance_amount":"0.00","reference":"4-2","state":"collected","items":[{"description":"Test Line Item 1","amount":"99999.99","product_id":null,"product_type":"manual","product_reference":null},{"description":"Test Line Item 2","amount":"1000000.00","product_id":null,"product_type":"manual","product_reference":null}]},{"invoiced_at":"2023-10-24T09:00:00Z","total_amount":"20.00","balance_amount":"0.00","reference":"5-2","state":"collected","items":[{"description":"Purchase Certificate www.bubble-registered.com","amount":"20.00","product_id":42,"product_type":"certificate-purchase","product_reference":"42"}]}],"pagination":{"current_page":1,"per_page":30,"total_entries":4,"total_pages":1}} +{"data":[{"invoiced_at":"2023-08-17T05:53:36Z","total_amount":"14.50","balance_amount":"0.00","reference":"1-2","state":"collected","items":[{"description":"Register bubble-registered.com","amount":"14.50","product_id":1,"product_type":"domain-registration","product_reference":"bubble-registered.com"}]},{"invoiced_at":"2023-08-17T05:57:53Z","total_amount":"14.50","balance_amount":"0.00","reference":"2-2","state":"refunded","items":[{"description":"Register example.com","amount":"14.50","product_id":2,"product_type":"domain-registration","product_reference":"example.com"}]},{"invoiced_at":"2023-10-24T07:49:05Z","total_amount":"1099999.99","balance_amount":"0.00","reference":"4-2","state":"collected","items":[{"description":"Test Line Item 1","amount":"99999.99","product_id":null,"product_type":"manual","product_reference":null},{"description":"Test Line Item 2","amount":"1000000.00","product_id":null,"product_type":"manual","product_reference":null}]},{"invoiced_at":"2023-10-24T09:00:00Z","total_amount":"20.00","balance_amount":"0.00","reference":"5-2","state":"collected","items":[{"description":"Purchase Certificate www.bubble-registered.com","amount":"20.00","product_id":42,"product_type":"certificate-purchase","product_reference":"42"}]}],"pagination":{"current_page":1,"per_page":30,"total_entries":4,"total_pages":1}} \ No newline at end of file diff --git a/src/test/resources/com/dnsimple/registerDomain/success.http b/src/test/resources/com/dnsimple/registerDomain/success.http index a991ed0..c682d7e 100644 --- a/src/test/resources/com/dnsimple/registerDomain/success.http +++ b/src/test/resources/com/dnsimple/registerDomain/success.http @@ -17,4 +17,4 @@ x-permitted-cross-domain-policies: none x-xss-protection: 1; mode=block strict-transport-security: max-age=31536000 -{"data":{"id":1,"domain_id":999,"registrant_id":2,"period":1,"state":"new","auto_renew":false,"whois_privacy":false,"trustee_service":false,"created_at":"2016-12-09T19:35:31Z","updated_at":"2016-12-09T19:35:31Z"}} +{"data":{"id":1,"domain_id":999,"registrant_id":2,"period":1,"state":"new","auto_renew":false,"whois_privacy":false,"trustee":false,"created_at":"2016-12-09T19:35:31Z","updated_at":"2016-12-09T19:35:31Z"}} diff --git a/src/test/resources/com/dnsimple/transferDomain/success.http b/src/test/resources/com/dnsimple/transferDomain/success.http index 52b2dce..8ae6d21 100644 --- a/src/test/resources/com/dnsimple/transferDomain/success.http +++ b/src/test/resources/com/dnsimple/transferDomain/success.http @@ -17,4 +17,4 @@ x-permitted-cross-domain-policies: none x-xss-protection: 1; mode=block strict-transport-security: max-age=31536000 -{"data":{"id":1,"domain_id":999,"registrant_id":2,"state":"transferring","auto_renew":false,"whois_privacy":false,"trustee_service":false,"created_at":"2016-12-09T19:43:41Z","updated_at":"2016-12-09T19:43:43Z"}} +{"data":{"id":1,"domain_id":999,"registrant_id":2,"state":"transferring","auto_renew":false,"whois_privacy":false,"trustee":false,"created_at":"2016-12-09T19:43:41Z","updated_at":"2016-12-09T19:43:43Z"}}