Class NetcupApi

Hierarchy

  • NetcupApi

Constructors

Properties

authData: NetcupAuth = ...
restApi: NetcupRestApi = ...

Methods

  • Returns Promise<void>

  • Updates DNS records of a domain with the current public ip.

    Example

    // update ipv4 only
    await api.updateDnsRecordsWithCurrentIp({
    domainname: 'example.com',
    hostname: 'www',
    })

    Example

    // update ipv4 and ipv6
    await api.updateDnsRecordsWithCurrentIp({
    domainname: 'example.com',
    hostname: 'www',
    useIpv4AndIpv6: true,
    })

    Example

    // update ipv6 only
    await api.updateDnsRecordsWithCurrentIp({
    domainname: 'example.com',
    hostname: 'www',
    useIpv6Only: true,
    })

    Returns Promise<UpdateDNSRecordsResponse>

  • Updates DNS records of a domain and only those that are specified.

    Example

    await api.updateDnsRecords({
    domainname: 'example.com',
    dnsrecordset: {
    dnsrecords: [{ name: 'www', type: 'A', destination: 'some-ip' }],
    },
    })

    Example

    // can also be used to delete records
    await api.updateDnsRecords({
    domainname: 'example.com',
    dnsrecordset: {
    dnsrecords: [
    { name: 'www', type: 'A', destination: 'some-ip', deleterecord: true },
    ],
    },
    })

    Parameters

    Returns Promise<UpdateDNSRecordsResponse>

Generated using TypeDoc