HN SSC API (0.0.1)

Download OpenAPI specification:

This documents the API provided by WK-Serv/Netzhoster to be used by its own customer SSC as well as direct connections from customer's infrastructure.

Generic funtione

sends "pong" back to client

just a simple ping to ensure server (and authentification) are working

Authorizations:
BasicAuthBearerAuth

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": "authorized pong"
}

requests token to be used for GUI/TUI access

performs authentification of the user and respnses with an API-token to be used as authorization for GUI/TUI acces (preventing sending credentials on every request). Usage of token is mandatory if user has 2FA configured

Authorizations:
BasicAuth

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

delets login token (logout)

deletes login token from database, no further requests authorised

Authorizations:
BearerAuth

Responses

sends 2FA authentification details

sends 2FA information to finish login/token request

Authorizations:
BearerAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "otpType": 3,
  • "otp": "xXxXxX"
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

initiating password reset process (step 1/2)

initiates password reset process: sending reset-code via email; Attention for BasicAuth: "user" has to be the user login, "password" to be set to the users contact email address

Authorizations:
BasicAuth

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

finalise password reset process (step 2/2)

finalise password reset by checking security code and setting new password (no auto-login!)

Authorizations:
BearerAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "resetCode": "xXxXxX",
  • "newPassword": "changeMeNew1234",
  • "otpType": 3,
  • "otp": "xXxXxX"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

sets new password for user

sets new password for user

Authorizations:
BearerAuthBasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "newPassword": "changeMeNew1234"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

setting configuration for 2FA autentification (step 1/2)

initiates 2FA configuration process: requesting setup for specific otpType. any existing configuration for given otpType will be overwritten after confirmation!

Authorizations:
BearerAuthBasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
Example
{
  • "otpType": 1
}

Response samples

Content type
application/json
Example
{
  • "status": "success",
  • "data": {
    }
}

finalise 2FA setup (step 2/2)

finalise 2FA setup by confirming otp method offers valid token

Authorizations:
BearerAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "otpType": 3,
  • "otp": "xXxXxX"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

deletes 2FA configuration for given otpType for current user

deletes 2FA configuration for given otpType for current user

Authorizations:
BearerAuth
path Parameters
otpType
required
integer

type of otp to delete

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

get customer overview

get list all available customer this user is allowed to act on

Authorizations:
BearerAuthBasicAuth

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

User account management

returns list of login accounts associated with current user

Authorizations:
BearerAuthBasicAuth
query Parameters
sub
boolean

false (default): only current customer is looked at, true: customers belonging to current customer are included

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

set password for specified user

Authorizations:
BearerAuthBasicAuth
path Parameters
uid
required
string

uid of account to set password for, can be numeric userID (eg. 7, PREFERRED) or userNAME (eg. aaa-muster1, does not work for numeric primary users)

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "newPassword": "xXxXxX"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

changes active status on user login

Authorizations:
BearerAuthBasicAuth
path Parameters
uid
required
integer

uid of account to set password for

query Parameters
active
required
boolean

true/false

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "newPassword": "xXxXxX"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

create new user account

WARNING: function still in development!

creates new user account. if customer is omitted in request body the current customer is assumed; if modules is omitted, current users module permissions are copied 1:1; if modules is set permissions are set in extend to the customers privilege levels.

given userame will be prepended by customer prefix automatically

Authorizations:
BearerAuthBasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "login": "exampleuser",
  • "password": "xXxXxX",
  • "displayName": "John Doe",
  • "contact": "john.doe@example.com",
  • "active": true,
  • "customer": "optional",
  • "modules": {
    }
}

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": "xxx-exampleuser"
}

deletes user login

Authorizations:
BearerAuthBasicAuth
path Parameters
uid
required
integer

uid of account to delete (numeric uid PREFERRED)

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

Domain registration

check domain availability

Authorizations:
BearerAuthBasicAuth
path Parameters
domain
required
string

name of domain to check

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

check domain availability

Authorizations:
BearerAuthBasicAuth
path Parameters
tld
required
string

tld (top-level-domain) to check

sld
required
string

sld (second-level-domain) to check

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

retrieved list of registered domains

Authorizations:
BearerAuthBasicAuth
query Parameters
sub
boolean

false (default): only current customer is looked at, true: customers belonging to current customer are included

recursive
boolean

false (default): only fist sub-customer-level is checked, true: customers are collected recursively (include sub*-sub-customers)

deleted
boolean

include deleted (marked as deleted) domains

limittld
string

limit list to given tld(s) (comma-separated)

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

DNS Zone management

returns list of DNS zones for customer(s)

Authorizations:
BearerAuthBasicAuth
query Parameters
sub
boolean

false (default): only current customer is looked at, true: customers belonging to current customer are included

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

create new DNS zone

Authorizations:
BearerAuthBasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "name": "example.org",
  • "type": "e",
  • "owner": 3
}

Response samples

Content type
application/json
{
  • "status": "success"
}

get zone details

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to get

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

modify zone

modify owner and type of zone (omitted details will be unchanged)

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "owner": 7,
  • "type": "e"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

delete zone

deletes dns zone including ressource records and dnsupdate/dyndns-ACL

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to delete

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

toggle DNSSEC enabled

togggles status of DNSSec for zone:

  • requests craetion/removal of DNSSec keys
  • if applicable: updates domain with registry
Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to set DNSSec for

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

retrieve DNSSEC details

retrieves current DNSSec-information for zone (keys, dn-/dnskey-records, nsec3 information)

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to get DNSSec information for

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

add TSigKey to zone

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

keyname
required
string

name of TSigKey to add to allow-list

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

remove TSigKey from zone

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

keyname
required
string

name of TSigKey to remove from allow-list

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

DNS Record management

create new record in DNS zone

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to put record in

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "name": "sub.example.org",
  • "type": "A",
  • "content": "127.0.0.1",
  • "ttl": 7200,
  • "prio": 0,
  • "disabled": false
}

Response samples

Content type
application/json
{
  • "status": "success"
}

get ressource record

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to delete

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

modify ressource record

modifies/patches given ressource record, all data omitted in request body will be unchanged

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to modify

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "content": "127.0.0.1",
  • "ttl": 7200,
  • "prio": 0
}

Response samples

Content type
application/json
{
  • "status": "success"
}

delete ressource record

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to delete

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

enable/disable record (toggle setting)

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to en-/disable

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

get dyndns-ACL for record

retrieves list of users allowed to modify this record using the DynDNS-protocol

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to retieve data for

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {
    }
}

delete dyndns-ACL for record

deletes user(s) from list of users allowed to modify this record using the DynDNS-protocol

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to delete ACL for

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

sets dyndns-ACL for record

adds user(s) to list of users allowed to modify this record using the DynDNS-protocol

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone to modify

recordid
required
integer

id of record to delete ACL for

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "dyndnsUsers": [
    ]
}

Response samples

Content type
application/json
{
  • "status": "success"
}

perform DynDNS update

Authorizations:
BasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "ip": "127.0.0.1",
  • "hostname": [
    ]
}

Response samples

Content type
application/json
{
  • "status": "success"
}

get fwdServer configuration

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone

hostname
required
string

hostname to get configuration for

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": {}
}

sets fwdServer configuration

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone

hostname
required
string

hostname to get configuration for

query Parameters
force
boolean

configure fwdServer even if A/AAAA-records for hostname exist and not point to fwdServer

Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "status": "success"
}

delete fwdServer configuration

Authorizations:
BearerAuthBasicAuth
path Parameters
zone
required
string

name of DNS zone

hostname
required
string

hostname to get configuration for

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}

TSig-Key management

returns list of TSigKeys for customer(s)

Authorizations:
BearerAuthBasicAuth
query Parameters
sub
boolean

false (default): only current customer is looked at, true: customers belonging to current customer are included

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": [
    ]
}

request generation of new TSigKey

request generation of new TSigKey with given name (customer prefix automatically added) and algorithm. Key is generated asynchronously and can be retieved later

owner is optional - will be assumed as current customer if omitted

allowed algorithms are:

  • hmac-md5
  • hmac-sha1
  • hmac-sha224
  • hmac-sha256
  • hmac-sha384
  • hmac-sha512
Authorizations:
BearerAuthBasicAuth
Request Body schema: application/json
Schema not provided

Responses

Request samples

Content type
application/json
{
  • "name": "examplekeyname",
  • "owner": 3,
  • "algorithm": "hmac-sha512"
}

Response samples

Content type
application/json
{
  • "status": "success"
}

retieve TSigKey

returns named TSigKey as unencrypted string

Authorizations:
BearerAuthBasicAuth
path Parameters
keyname
required
string

name of TSigKey to retrieve

Responses

Response samples

Content type
application/json
{
  • "status": "success",
  • "data": "VUVAC0\\/c+hme48dwxRtzjz2QF8\\/PlwM2d8RBsmQfL+6sz2PbLt+\\/5DVzIwQbt8DAq79tFLDqW9A+vjsRfUTSaQ=="
}

delete TSigKey

Authorizations:
BearerAuthBasicAuth
path Parameters
keyname
required
string

name of TSigKey to delete

Responses

Response samples

Content type
application/json
{
  • "status": "success"
}