class OceanKit::Resource::Domain

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.cr

Instance Method Summary

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 all #

Return all domain list as JSON


[View source]
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}}

[View source]
def delete(name, id) #

Update an existing record def update(options) put("/domain/#{name}/records/#{id}", options) end Return status_code


[View source]
def domains #

[View source]
def find(domain_name : String) #

[View source]