rdx/fxw-api

FXW DNS API by scraping

Maintainers

Package info

github.com/rudiedirkx/fxw-dns-api-client

pkg:composer/rdx/fxw-api

Statistics

Installs: 23

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

1.1 2018-04-01 01:16 UTC

This package is auto-updated.

Last update: 2026-03-01 00:11:42 UTC


README

Manages FXW DNS records, by scraping their control panel, since they don't have an API.

$client = new rdx\fxwdns\Client(new rdx\fxwdns\WebAuth('mail@address.com', 'p@assword'));

// Explicit log in
$bool = $client->logIn();

// $client->customer->{id,name} contains some customer info from dashboard

// Get managed domains
$domains = $client->getDomains();

// Get specific domain
$domain = $client->getDomain('example.com');

// Get domain's DNS records
$records = $client->getDnsRecords($domain);

// Add DNS record
$record = new rdx\fxwdns\DnsRecord(0, 'sub.example.com', 'A', '12.34.56.78', 3600);
$bool = $client->addDnsRecord($domain, $record);

// Find specific DNS record(s)
$records = $client->findDnsRecords(['type' => 'TXT', 'name' => 'sup.example.com']);

// Remove DNS record
$bool = $client->deleteDnsRecord($domain, $records[0]);