Sha256: 8a41f3d1624b5483200b14561bde4bad9c0a54c3ff18ebce33da1483cf72f5af

Contents?: true

Size: 1.07 KB

Versions: 4

Compression:

Stored size: 1.07 KB

Contents

module Fog
  module DNS
    class Slicehost
      class Real

        require 'fog/slicehost/parsers/dns/get_record'

        # Get an individual DNS record from the specified zone
        #
        # ==== Returns
        # * response<~Excon::Response>:
        #   * body<~Hash>:
        #     * 'record_type'<~String> - type of DNS record to create (A, CNAME, etc)
        #     * 'zone_id'<~Integer> - ID of the zone to update
        #     * 'name'<~String> - host name this DNS record is for
        #     * 'data'<~String> - data for the DNS record (ie for an A record, the IP address)
        #     * 'ttl'<~Integer> - time to live in seconds
        #     * 'active'<~String> - whether this record is active or not ('Y' or 'N')
        #     * 'aux'<~String> - extra data required by the record
        def get_record(record_id)
          request(
            :expects  => 200,
            :method   => 'GET',
            :parser   => Fog::Parsers::DNS::Slicehost::GetRecords.new,
            :path     => "records/#{record_id}.xml"
          )
        end

      end
    end
  end
end

Version data entries

4 entries across 4 versions & 3 rubygems

Version Path
brightbox-cli-0.16.0 lib/brightbox-cli/vendor/fog/lib/fog/slicehost/requests/dns/get_record.rb
brightbox-cli-0.15.0 lib/brightbox-cli/vendor/fog/lib/fog/slicehost/requests/dns/get_record.rb
tag-fog-1.0.1 lib/fog/slicehost/requests/dns/get_record.rb
fog-1.0.0 lib/fog/slicehost/requests/dns/get_record.rb