Method: Acme::Client#account_update

Defined in:
lib/acme/client.rb

#account_update(contact: nil, terms_of_service_agreed: nil) ⇒ Object



85
86
87
88
89
90
91
92
93
# File 'lib/acme/client.rb', line 85

def (contact: nil, terms_of_service_agreed: nil)
  payload = {}
  payload[:contact] = Array(contact) if contact
  payload[:termsOfServiceAgreed] = terms_of_service_agreed if terms_of_service_agreed

  response = post(kid, payload: payload)
  arguments = (response)
  Acme::Client::Resources::.new(self, url: kid, **arguments)
end