KyPanelDocs

API reference

Nodes

Email and database nodes paired with this server.

List nodes

GET/api/v1/nodes

Who
root
API tokens
admin token area: server
Operation
nodeList · ky call nodeList

Responses

  • 200 OK
    Body
    FieldType
    itemsarray of map of any
    panel_hostnamestring
    panel_versionstring
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 500 Internal Server Error: internal

Pair a node

POST/api/v1/nodes

Who
root
API tokens
admin token area: server
Operation
nodePair · ky call nodePair

Request body

FieldType
codestring
namestring

Responses

  • 201 Created
    Body

    map of any

  • 400 Bad Request: validation
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)

Remove a node

DELETE/api/v1/nodes/{nid}

Who
root
API tokens
admin token area: server
Operation
nodeDelete · ky call nodeDelete

Parameters

NameIn
nidpath

Responses

  • 204 Done, no content
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 409 Conflict: in-use
  • 500 Internal Server Error: internal

Update a node

PUT/api/v1/nodes/{nid}

Who
root
API tokens
admin token area: server
Operation
nodeUpdate · ky call nodeUpdate

Parameters

NameIn
nidpath

Request body

FieldType
is_defaultboolean
namestring
public_ipstring

Responses

  • 200 OK
    Body
    FieldType
    nodeStoreNode
  • 400 Bad Request: validation
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 404 Not Found: not-found
  • 500 Internal Server Error: internal

Check a node's connection and services

POST/api/v1/nodes/{nid}/check

Who
root
API tokens
admin token area: server
Operation
nodeCheck · ky call nodeCheck

Parameters

NameIn
nidpath

Responses

  • 200 OK
    Body
    FieldType
    nodeStoreNode
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 404 Not Found: not-found
  • 500 Internal Server Error: internal

Get a node's firewall

GET/api/v1/nodes/{nid}/firewall

Who
root
API tokens
admin token area: server
Operation
getNodesNidFirewall · ky call getNodesNidFirewall

Parameters

NameIn
nidpath
serverquery

Responses

  • 200 OK
    Body

    map of any

  • 400 Bad Request: rejected
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 500 Internal Server Error: internal

Open or close ports on a node

PUT/api/v1/nodes/{nid}/firewall/ports

Who
root
API tokens
admin token area: server
Operation
putNodesNidFirewallPorts · ky call putNodesNidFirewallPorts

Parameters

NameIn
nidpath
serverquery

Request body

FieldType
openboolean
portinteger
protocolstring

Responses

  • 200 OK
    Body

    map of any

  • 400 Bad Request: rejected
  • 401 Unauthorized: no session, or an invalid or expired token
  • 403 Forbidden: the caller can't use this (privileges, token scope, feature turned off)
  • 500 Internal Server Error: internal