class OceanKit::Resource::Domain
- OceanKit::Resource::Domain
- OceanKit::Resource::Base
- Reference
- Object
Overview
ocean_kit = OceanKit::Client.new("API-KEY")
ocean_kit.domains.create(name: "mydomain", ip_address: "1.2.3.4")
#=> {}
ocean_kit.domains.find("sdada")
#=> {}
ocean_kit.domains.delete(name: "dds")
Defined in:
ocean_kit/resources/domain.crInstance Method Summary
-
#all
Return all domain list as
JSON
-
#create(name, ip_address)
Return
JSON::Any
-
#delete(name, id)
Update an existing record def update(options) put("/domain/#{name}/records/#{id}", options) end Return status_code
- #domains
- #find(domain_name : String)
Constructor methods inherited from class OceanKit::Resource::Base
new(headers : HTTP::Headers | Nil)
new
Instance methods inherited from module OceanKit::Client::Connection
destroy(path, options = nil)
destroy,
get(path, options = nil)
get,
post(path, options)
post,
put(path, options)
put,
request(http_method, path, options)
request
Instance Method Detail
def create(name, ip_address)
#
Return JSON::Any
ocean_kit = OceanKit::Client.new("API-KEY")
ok.domains.create("yndx.host", "1.2.3.4")
# => {"domain":{"name":"string.yndx.host","ttl":null,"zone_file":null}}
def delete(name, id)
#
Update an existing record def update(options) put("/domain/#{name}/records/#{id}", options) end Return status_code