NAME
Mojo::Cloudflare::Record - Represent a Cloudflare DNS record
DESCRIPTION
Mojo::Cloudflare::Record represents a DNS record in the Mojo::Cloudflare module.
This module inherit from Mojo::JSON::Pointer.
ATTRIBUTES
content
$str = $self->content;
$self = $self->content($str);
The content of the DNS record, will depend on the the type of record being added.
This attribute is required to do anything useful with this object.
id
$str = $self->id;
The identifier from Cloudflare. Can only be set in constructor.
name
$str = $self->name;
$self = $self->name($str);
Name of the DNS record.
This attribute is required to do anything useful with this object.
priority
$int = $self->priority;
$self = $self->priority($int);
MX record priority.
ttl
$int = $self->ttl;
$self = $self->ttl($int);
TTL of record in seconds. 1 (default) = Automatic, otherwise, value must in between 120 and 86400 seconds.
service_mode
$int = $self->service_mode;
$self = $self->service_mode($int);
Status of CloudFlare Proxy: 1 = orange cloud (active), 0 = grey cloud (deactive).
type
$str = $self->type;
$self = $self->type($str);
Type of the DNS record: A, CNAME, MX, TXT, SPF, AAAA, NS, SRV, or LOC.
This attribute is required to do anything useful with this object.
METHODS
delete
$self = $self->delete(sub { my($self, $err) = @_; ... });
$self = $self->delete; # die $err on failure
Used to save delete record from Cloudflare.
save
$self = $self->save(sub { my($self, $err) = @_; ... });
$self = $self->save; # die $err on failure
Used to save record to Cloudflare.
COPYRIGHT AND LICENSE
Copyright (C) 2014, Jan Henning Thorsen
This program is free software, you can redistribute it and/or modify it under the terms of the Artistic License version 2.0.
AUTHOR
Jan Henning Thorsen - jhthorsen@cpan.org