Selaa lähdekoodia

migrate to open API 3.0.1

Matthew R Kasun 2 vuotta sitten
vanhempi
commit
87b845f98d
2 muutettua tiedostoa jossa 1465 lisäystä ja 1866 poistoa
  1. 0 1866
      swagger.yaml
  2. 1465 0
      swagger.yml

+ 0 - 1866
swagger.yaml

@@ -1,1866 +0,0 @@
-basePath: /
-consumes:
-    - application/json
-definitions:
-    ACL:
-        additionalProperties:
-            format: uint8
-            type: integer
-        description: ACL - the ACL of other nodes in a NetworkACL for a single unique node
-        type: object
-        x-go-package: github.com/gravitl/netmaker/logic/acls
-    ACLContainer:
-        additionalProperties:
-            $ref: '#/definitions/ACL'
-        description: ACLContainer - the total list of all node's ACL in a given network
-        type: object
-        x-go-package: github.com/gravitl/netmaker/logic/acls
-    AccessKey:
-        description: AccessKey - access key struct
-        properties:
-            accessstring:
-                type: string
-                x-go-name: AccessString
-            name:
-                type: string
-                x-go-name: Name
-            uses:
-                format: int64
-                type: integer
-                x-go-name: Uses
-            value:
-                type: string
-                x-go-name: Value
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    AttributeTypeAndValue:
-        description: |-
-            AttributeTypeAndValue mirrors the ASN.1 structure of the same name in
-            RFC 5280, Section 4.1.2.4.
-        properties:
-            Type:
-                $ref: '#/definitions/ObjectIdentifier'
-            Value: {}
-        type: object
-        x-go-package: crypto/x509/pkix
-    AuthParams:
-        description: AuthParams - struct for auth params
-        properties:
-            id:
-                type: string
-                x-go-name: ID
-            macaddress:
-                type: string
-                x-go-name: MacAddress
-            password:
-                type: string
-                x-go-name: Password
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    CustomExtClient:
-        description: CustomExtClient - struct for CustomExtClient params
-        properties:
-            clientid:
-                type: string
-                x-go-name: ClientID
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    DNSEntry:
-        description: DNSEntry - a DNS entry represented as struct
-        properties:
-            address:
-                type: string
-                x-go-name: Address
-            address6:
-                type: string
-                x-go-name: Address6
-            name:
-                type: string
-                x-go-name: Name
-            network:
-                type: string
-                x-go-name: Network
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    Duration:
-        description: |-
-            A Duration represents the elapsed time between two instants
-            as an int64 nanosecond count. The representation limits the
-            largest representable duration to approximately 290 years.
-        format: int64
-        type: integer
-        x-go-package: time
-    EgressGatewayRequest:
-        description: EgressGatewayRequest - egress gateway request
-        properties:
-            interface:
-                type: string
-                x-go-name: Interface
-            natenabled:
-                type: string
-                x-go-name: NatEnabled
-            netid:
-                type: string
-                x-go-name: NetID
-            nodeid:
-                type: string
-                x-go-name: NodeID
-            ranges:
-                items:
-                    type: string
-                type: array
-                x-go-name: Ranges
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    ExtClient:
-        description: ExtClient - struct for external clients
-        properties:
-            address:
-                type: string
-                x-go-name: Address
-            address6:
-                type: string
-                x-go-name: Address6
-            clientid:
-                type: string
-                x-go-name: ClientID
-            description:
-                type: string
-                x-go-name: Description
-            enabled:
-                type: boolean
-                x-go-name: Enabled
-            ingressgatewayendpoint:
-                type: string
-                x-go-name: IngressGatewayEndpoint
-            ingressgatewayid:
-                type: string
-                x-go-name: IngressGatewayID
-            lastmodified:
-                format: int64
-                type: integer
-                x-go-name: LastModified
-            network:
-                type: string
-                x-go-name: Network
-            privatekey:
-                type: string
-                x-go-name: PrivateKey
-            publickey:
-                type: string
-                x-go-name: PublicKey
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    IPMask:
-        description: See type IPNet and func ParseCIDR for details.
-        items:
-            format: uint8
-            type: integer
-        title: |-
-            An IPMask is a bitmask that can be used to manipulate
-            IP addresses for IP addressing and routing.
-        type: array
-        x-go-package: net
-    IPNet:
-        properties:
-            IP:
-                type: string
-            Mask:
-                $ref: '#/definitions/IPMask'
-        title: An IPNet represents an IP network.
-        type: object
-        x-go-package: net
-    Key:
-        description: |-
-            A Key is a public, private, or pre-shared secret key.  The Key constructor
-            functions in this package can be used to create Keys suitable for each of
-            these applications.
-        items:
-            format: uint8
-            type: integer
-        type: array
-        x-go-package: golang.zx2c4.com/wireguard/wgctrl/wgtypes
-    Name:
-        description: |-
-            Name represents an X.509 distinguished name. This only includes the common
-            elements of a DN. Note that Name is only an approximation of the X.509
-            structure. If an accurate representation is needed, asn1.Unmarshal the raw
-            subject or issuer as an RDNSequence.
-        properties:
-            Country:
-                items:
-                    type: string
-                type: array
-                x-go-name: OrganizationalUnit
-            ExtraNames:
-                description: |-
-                    ExtraNames contains attributes to be copied, raw, into any marshaled
-                    distinguished names. Values override any attributes with the same OID.
-                    The ExtraNames field is not populated when parsing, see Names.
-                items:
-                    $ref: '#/definitions/AttributeTypeAndValue'
-                type: array
-            Locality:
-                items:
-                    type: string
-                type: array
-                x-go-name: Province
-            Names:
-                description: |-
-                    Names contains all parsed attributes. When parsing distinguished names,
-                    this can be used to extract non-standard attributes that are not parsed
-                    by this package. When marshaling to RDNSequences, the Names field is
-                    ignored, see ExtraNames.
-                items:
-                    $ref: '#/definitions/AttributeTypeAndValue'
-                type: array
-            SerialNumber:
-                type: string
-                x-go-name: CommonName
-            StreetAddress:
-                items:
-                    type: string
-                type: array
-                x-go-name: PostalCode
-        type: object
-        x-go-package: crypto/x509/pkix
-    Network:
-        description: |-
-            Network Struct - contains info for a given unique network
-            At  some point, need to replace all instances of Name with something else like  Identifier
-        properties:
-            accesskeys:
-                items:
-                    $ref: '#/definitions/AccessKey'
-                type: array
-                x-go-name: AccessKeys
-            addressrange:
-                type: string
-                x-go-name: AddressRange
-            addressrange6:
-                type: string
-                x-go-name: AddressRange6
-            allowmanualsignup:
-                type: string
-                x-go-name: AllowManualSignUp
-            defaultacl:
-                type: string
-                x-go-name: DefaultACL
-            defaultextclientdns:
-                type: string
-                x-go-name: DefaultExtClientDNS
-            defaultinterface:
-                type: string
-                x-go-name: DefaultInterface
-            defaultkeepalive:
-                format: int32
-                type: integer
-                x-go-name: DefaultKeepalive
-            defaultlistenport:
-                format: int32
-                type: integer
-                x-go-name: DefaultListenPort
-            defaultmtu:
-                format: int32
-                type: integer
-                x-go-name: DefaultMTU
-            defaultudpholepunch:
-                type: string
-                x-go-name: DefaultUDPHolePunch
-            isipv4:
-                type: string
-                x-go-name: IsIPv4
-            isipv6:
-                type: string
-                x-go-name: IsIPv6
-            ispointtosite:
-                type: string
-                x-go-name: IsPointToSite
-            netid:
-                type: string
-                x-go-name: NetID
-            networklastmodified:
-                format: int64
-                type: integer
-                x-go-name: NetworkLastModified
-            nodelimit:
-                format: int32
-                type: integer
-                x-go-name: NodeLimit
-            nodeslastmodified:
-                format: int64
-                type: integer
-                x-go-name: NodesLastModified
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    Node:
-        description: Node - struct for node model
-        properties:
-            accesskey:
-                type: string
-                x-go-name: AccessKey
-            action:
-                type: string
-                x-go-name: Action
-            address:
-                type: string
-                x-go-name: Address
-            address6:
-                type: string
-                x-go-name: Address6
-            allowedips:
-                items:
-                    type: string
-                type: array
-                x-go-name: AllowedIPs
-            connected:
-                type: string
-                x-go-name: Connected
-            dnson:
-                type: string
-                x-go-name: DNSOn
-            egressgatewaynatenabled:
-                type: string
-                x-go-name: EgressGatewayNatEnabled
-            egressgatewayranges:
-                items:
-                    type: string
-                type: array
-                x-go-name: EgressGatewayRanges
-            egressgatewayrequest:
-                $ref: '#/definitions/EgressGatewayRequest'
-            endpoint:
-                type: string
-                x-go-name: Endpoint
-            expdatetime:
-                format: int64
-                type: integer
-                x-go-name: ExpirationDateTime
-            firewallinuse:
-                type: string
-                x-go-name: FirewallInUse
-            id:
-                type: string
-                x-go-name: ID
-            ingressgatewayrange:
-                type: string
-                x-go-name: IngressGatewayRange
-            ingressgatewayrange6:
-                type: string
-                x-go-name: IngressGatewayRange6
-            interface:
-                type: string
-                x-go-name: Interface
-            internetgateway:
-                type: string
-                x-go-name: InternetGateway
-            ipforwarding:
-                type: string
-                x-go-name: IPForwarding
-            isdocker:
-                type: string
-                x-go-name: IsDocker
-            isegressgateway:
-                type: string
-                x-go-name: IsEgressGateway
-            ishub:
-                type: string
-                x-go-name: IsHub
-            isingressgateway:
-                type: string
-                x-go-name: IsIngressGateway
-            isk8s:
-                type: string
-                x-go-name: IsK8S
-            ispending:
-                type: string
-                x-go-name: IsPending
-            isrelay:
-                type: string
-                x-go-name: IsRelay
-            isrelayed:
-                type: string
-                x-go-name: IsRelayed
-            isserver:
-                type: string
-                x-go-name: IsServer
-            isstatic:
-                description: IsStatic - refers to if the Endpoint is set manually or dynamically
-                type: string
-                x-go-name: IsStatic
-            lastcheckin:
-                format: int64
-                type: integer
-                x-go-name: LastCheckIn
-            lastmodified:
-                format: int64
-                type: integer
-                x-go-name: LastModified
-            lastpeerupdate:
-                format: int64
-                type: integer
-                x-go-name: LastPeerUpdate
-            listenport:
-                format: int32
-                type: integer
-                x-go-name: ListenPort
-            localaddress:
-                type: string
-                x-go-name: LocalAddress
-            locallistenport:
-                format: int32
-                type: integer
-                x-go-name: LocalListenPort
-            macaddress:
-                type: string
-                x-go-name: MacAddress
-            mtu:
-                format: int32
-                type: integer
-                x-go-name: MTU
-            name:
-                type: string
-                x-go-name: Name
-            network:
-                type: string
-                x-go-name: Network
-            networksettings:
-                $ref: '#/definitions/Network'
-            os:
-                type: string
-                x-go-name: OS
-            password:
-                type: string
-                x-go-name: Password
-            persistentkeepalive:
-                format: int32
-                type: integer
-                x-go-name: PersistentKeepalive
-            publickey:
-                type: string
-                x-go-name: PublicKey
-            relayaddrs:
-                items:
-                    type: string
-                type: array
-                x-go-name: RelayAddrs
-            server:
-                type: string
-                x-go-name: Server
-            traffickeys:
-                $ref: '#/definitions/TrafficKeys'
-            udpholepunch:
-                type: string
-                x-go-name: UDPHolePunch
-            version:
-                type: string
-                x-go-name: Version
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    NodeGet:
-        description: NodeGet - struct for a single node get response
-        properties:
-            node:
-                $ref: '#/definitions/Node'
-            peers:
-                items:
-                    $ref: '#/definitions/PeerConfig'
-                type: array
-                x-go-name: Peers
-            serverconfig:
-                $ref: '#/definitions/ServerConfig'
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    ObjectIdentifier:
-        items:
-            format: int64
-            type: integer
-        title: An ObjectIdentifier represents an ASN.1 OBJECT IDENTIFIER.
-        type: array
-        x-go-package: encoding/asn1
-    PeerConfig:
-        description: |-
-            Because the zero value of some Go types may be significant to WireGuard for
-            PeerConfig fields, pointer types are used for some of these fields. Only
-            pointer fields which are not nil will be applied when configuring a peer.
-        properties:
-            AllowedIPs:
-                description: |-
-                    AllowedIPs specifies a list of allowed IP addresses in CIDR notation
-                    for this peer.
-                items:
-                    $ref: '#/definitions/IPNet'
-                type: array
-            Endpoint:
-                $ref: '#/definitions/UDPAddr'
-            PersistentKeepaliveInterval:
-                $ref: '#/definitions/Duration'
-            PresharedKey:
-                $ref: '#/definitions/Key'
-            PublicKey:
-                $ref: '#/definitions/Key'
-            Remove:
-                description: |-
-                    Remove specifies if the peer with this public key should be removed
-                    from a device's peer list.
-                type: boolean
-            ReplaceAllowedIPs:
-                description: |-
-                    ReplaceAllowedIPs specifies if the allowed IPs specified in this peer
-                    configuration should replace any existing ones, instead of appending them
-                    to the allowed IPs list.
-                type: boolean
-            UpdateOnly:
-                description: |-
-                    UpdateOnly specifies that an operation will only occur on this peer
-                    if the peer already exists as part of the interface.
-                type: boolean
-        title: A PeerConfig is a WireGuard device peer configuration.
-        type: object
-        x-go-package: golang.zx2c4.com/wireguard/wgctrl/wgtypes
-    PrivateKey:
-        items:
-            format: uint8
-            type: integer
-        title: PrivateKey is the type of Ed25519 private keys. It implements crypto.Signer.
-        type: array
-        x-go-package: crypto/ed25519
-    RegisterRequest:
-        description: RegisterRequest - struct for registation with netmaker server
-        properties:
-            CommonName:
-                $ref: '#/definitions/Name'
-            Key:
-                $ref: '#/definitions/PrivateKey'
-        type: object
-        x-go-package: github.com/gravitl/netmaker/netclient/config
-    RelayRequest:
-        description: RelayRequest - relay request struct
-        properties:
-            netid:
-                type: string
-                x-go-name: NetID
-            nodeid:
-                type: string
-                x-go-name: NodeID
-            relayaddrs:
-                items:
-                    type: string
-                type: array
-                x-go-name: RelayAddrs
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    ServerConfig:
-        description: ServerConfig - server conf struct
-        properties:
-            APIConnString:
-                type: string
-            APIHost:
-                type: string
-            APIPort:
-                type: string
-            AllowedOrigin:
-                type: string
-            AuthProvider:
-                type: string
-            AzureTenant:
-                type: string
-            ClientID:
-                type: string
-            ClientSecret:
-                type: string
-            CoreDNSAddr:
-                type: string
-            DNSKey:
-                type: string
-            DNSMode:
-                type: string
-            Database:
-                type: string
-            DisableRemoteIPCheck:
-                type: string
-            DisplayKeys:
-                type: string
-            FrontendURL:
-                type: string
-            HostNetwork:
-                type: string
-            MQHOST:
-                type: string
-            MQPort:
-                type: string
-            MQServerPort:
-                type: string
-            ManageIPTables:
-                type: string
-            MasterKey:
-                type: string
-            MessageQueueBackend:
-                type: string
-            NodeID:
-                type: string
-            OIDCIssuer:
-                type: string
-            Platform:
-                type: string
-            PortForwardServices:
-                type: string
-            PublicIPService:
-                type: string
-            RestBackend:
-                type: string
-            SQLConn:
-                type: string
-            Server:
-                type: string
-            Telemetry:
-                type: string
-            Verbosity:
-                format: int32
-                type: integer
-            Version:
-                type: string
-        type: object
-        x-go-package: github.com/gravitl/netmaker/config
-    SuccessResponse:
-        properties:
-            Code:
-                format: int64
-                type: integer
-            Message:
-                type: string
-            Response: {}
-        title: SuccessResponse is struct for sending error message with code.
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    TrafficKeys:
-        description: TrafficKeys - struct to hold public keys
-        properties:
-            mine:
-                items:
-                    format: uint8
-                    type: integer
-                type: array
-                x-go-name: Mine
-            server:
-                items:
-                    format: uint8
-                    type: integer
-                type: array
-                x-go-name: Server
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    UDPAddr:
-        properties:
-            IP:
-                type: string
-            Port:
-                format: int64
-                type: integer
-            Zone:
-                type: string
-        title: UDPAddr represents the address of a UDP end point.
-        type: object
-        x-go-package: net
-    User:
-        description: User struct - struct for Users
-        properties:
-            isadmin:
-                type: boolean
-                x-go-name: IsAdmin
-            networks:
-                items:
-                    type: string
-                type: array
-                x-go-name: Networks
-            password:
-                type: string
-                x-go-name: Password
-            username:
-                type: string
-                x-go-name: UserName
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-    UserAuthParams:
-        description: UserAuthParams - user auth params struct
-        properties:
-            password:
-                type: string
-                x-go-name: Password
-            username:
-                type: string
-                x-go-name: UserName
-        type: object
-        x-go-package: github.com/gravitl/netmaker/models
-host: netmaker.io
-info:
-    description: |-
-        API Usage
-
-        Most actions that can be performed via API can be performed via UI. We recommend managing your networks using the official netmaker-ui project. However, Netmaker can also be run without the UI, and all functions can be achieved via API calls. If your use case requires using Netmaker without the UI or you need to do some troubleshooting/advanced configuration, using the API directly may help.
-
-
-        Authentication
-
-        API calls must be authenticated via a header of the format -H “Authorization: Bearer <YOUR_SECRET_KEY>” There are two methods to obtain YOUR_SECRET_KEY: 1. Using the masterkey. By default, this value is “secret key,” but you should change this on your instance and keep it secure. This value can be set via env var at startup or in a config file (config/environments/< env >.yaml). See the [Netmaker](https://docs.netmaker.org/index.html) documentation for more details. 2. Using a JWT received for a node. This can be retrieved by calling the /api/nodes/<network>/authenticate endpoint, as documented below.
-    title: Netmaker
-    version: 0.21.0
-paths:
-    /api/dns:
-        get:
-            operationId: getAllDNS
-            responses:
-                "200":
-                    $ref: '#/responses/dnsResponse'
-            schemes:
-                - https
-            summary: Gets all DNS entries.
-            tags:
-                - dns
-    /api/dns/{network}:
-        post:
-            operationId: createDNS
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: DNS Entry
-                  in: body
-                  name: body
-                  schema:
-                    items:
-                        $ref: '#/definitions/DNSEntry'
-                    type: array
-                  x-go-name: Body
-            responses:
-                "200":
-                    $ref: '#/responses/dnsResponse'
-            schemes:
-                - https
-            summary: Create a DNS entry.
-            tags:
-                - dns
-    /api/dns/{network}/{domain}:
-        delete:
-            operationId: deleteDNS
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Domain
-                  in: path
-                  name: domain
-                  required: true
-                  type: string
-                  x-go-name: Domain
-            responses:
-                "200":
-                    $ref: '#/responses/stringJSONResponse'
-            schemes:
-                - https
-            summary: Delete a DNS entry.
-            tags:
-                - dns
-    /api/dns/adm/{network}:
-        get:
-            operationId: getDNS
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/dnsResponse'
-            schemes:
-                - https
-            summary: Gets all DNS entries associated with the network.
-            tags:
-                - dns
-    /api/dns/adm/{network}/custom:
-        get:
-            operationId: getCustomDNS
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/dnsResponse'
-            schemes:
-                - https
-            summary: Gets custom DNS entries associated with a network.
-            tags:
-                - dns
-    /api/dns/adm/{network}/nodes:
-        get:
-            operationId: getNodeDNS
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            schemes:
-                - https
-            summary: Gets node DNS entries associated with a network.
-            tags:
-                - dns
-    /api/dns/adm/pushdns:
-        post:
-            operationId: pushDNS
-            responses:
-                "200":
-                    $ref: '#/responses/dnsStringJSONResponse'
-            schemes:
-                - https
-            summary: Push DNS entries to nameserver.
-            tags:
-                - dns
-    /api/extclients:
-        get:
-            operationId: getAllExtClients
-            parameters:
-                - description: Networks
-                  in: body
-                  name: networks
-                  schema:
-                    items:
-                        type: string
-                    type: array
-                  x-go-name: Networks
-            responses:
-                "200":
-                    $ref: '#/responses/extClientSliceResponse'
-            schemes:
-                - https
-            summary: A separate function to get all extclients, not just extclients for a particular network.
-            tags:
-                - ext_client
-    /api/extclients/{network}:
-        get:
-            description: Gets all extclients associated with network, including pending extclients.
-            operationId: getNetworkExtClients
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/extClientSliceResponse'
-            schemes:
-                - https
-            summary: Get all extclients associated with network.
-            tags:
-                - ext_client
-    /api/extclients/{network}/{clientid}:
-        delete:
-            operationId: deleteExtClient
-            parameters:
-                - description: Client ID
-                  in: path
-                  name: clientid
-                  required: true
-                  type: string
-                  x-go-name: ClientID
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/successResponse'
-            schemes:
-                - https
-            summary: Delete an individual extclient.
-            tags:
-                - ext_client
-        get:
-            operationId: getExtClient
-            parameters:
-                - description: Client ID
-                  in: path
-                  name: clientid
-                  required: true
-                  type: string
-                  x-go-name: ClientID
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/extClientResponse'
-            schemes:
-                - https
-            summary: Get an individual extclient.
-            tags:
-                - ext_client
-        put:
-            operationId: updateExtClient
-            parameters:
-                - description: Client ID
-                  in: path
-                  name: clientid
-                  required: true
-                  type: string
-                  x-go-name: ClientID
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: ExtClient
-                  in: body
-                  name: ext_client
-                  schema:
-                    $ref: '#/definitions/ExtClient'
-                  x-go-name: ExtClient
-            responses:
-                "200":
-                    $ref: '#/responses/extClientResponse'
-            schemes:
-                - https
-            summary: Update an individual extclient.
-            tags:
-                - ext_client
-    /api/extclients/{network}/{clientid}/{type}:
-        get:
-            operationId: getExtClientConf
-            parameters:
-                - description: Client ID
-                  in: path
-                  name: clientid
-                  required: true
-                  type: string
-                  x-go-name: ClientID
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/extClientResponse'
-            schemes:
-                - https
-            summary: Get an individual extclient.
-            tags:
-                - ext_client
-    /api/extclients/{network}/{nodeid}:
-        post:
-            operationId: createExtClient
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: node
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-                - description: Custom ExtClient
-                  in: body
-                  name: custom_ext_client
-                  schema:
-                    $ref: '#/definitions/CustomExtClient'
-                  x-go-name: CustomExtClient
-            schemes:
-                - https
-            summary: Create an individual extclient.  Must have valid key and be unique.
-            tags:
-                - ext_client
-    /api/getip:
-        get:
-            operationId: getPublicIP
-            responses:
-                "200":
-                    $ref: '#/responses/byteArrayResponse'
-            schemes:
-                - https
-            summary: Get the current public IP address.
-            tags:
-                - ipservice
-    /api/networks:
-        get:
-            operationId: getNetworks
-            parameters:
-                - description: 'name: networks'
-                  in: header
-                  items:
-                    type: string
-                  name: networks
-                  type: array
-                  x-go-name: Networks
-            responses:
-                "200":
-                    $ref: '#/responses/getNetworksSliceResponse'
-            schemes:
-                - https
-            summary: Lists all networks.
-            tags:
-                - networks
-        post:
-            operationId: createNetwork
-            parameters:
-                - description: Network
-                  in: body
-                  name: network
-                  schema:
-                    $ref: '#/definitions/Network'
-                  x-go-name: Network
-            responses:
-                "200":
-                    $ref: '#/responses/networkBodyResponse'
-            schemes:
-                - https
-            summary: Create a network.
-            tags:
-                - networks
-    /api/networks/{networkname}:
-        delete:
-            operationId: deleteNetwork
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-            responses:
-                "200":
-                    $ref: '#/responses/stringJSONResponse'
-            schemes:
-                - https
-            summary: Delete a network.  Will not delete if there are any nodes that belong to the network.
-            tags:
-                - networks
-        get:
-            operationId: getNetwork
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-            responses:
-                "200":
-                    $ref: '#/responses/networkBodyResponse'
-            schemes:
-                - https
-            summary: Get a network.
-            tags:
-                - networks
-        put:
-            operationId: updateNetwork
-            parameters:
-                - description: Network
-                  in: body
-                  name: network
-                  schema:
-                    $ref: '#/definitions/Network'
-                  x-go-name: Network
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-            responses:
-                "200":
-                    $ref: '#/responses/networkBodyResponse'
-            schemes:
-                - https
-            summary: Update a network.
-            tags:
-                - networks
-    /api/networks/{networkname}/acls:
-        get:
-            operationId: getNetworkACL
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-                - description: ACL Container
-                  in: body
-                  name: acl_container
-                  schema:
-                    $ref: '#/definitions/ACLContainer'
-                  x-go-name: ACLContainer
-            responses:
-                "200":
-                    $ref: '#/responses/aclContainerResponse'
-            schemes:
-                - https
-            summary: Get a network ACL (Access Control List).
-            tags:
-                - networks
-        put:
-            operationId: updateNetworkACL
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-                - description: ACL Container
-                  in: body
-                  name: acl_container
-                  schema:
-                    $ref: '#/definitions/ACLContainer'
-                  x-go-name: ACLContainer
-            responses:
-                "200":
-                    $ref: '#/responses/aclContainerResponse'
-            schemes:
-                - https
-            summary: Update a network ACL (Access Control List).
-            tags:
-                - networks
-    /api/networks/{networkname}/keys:
-        get:
-            operationId: getAccessKeys
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-            responses:
-                "200":
-                    $ref: '#/responses/accessKeySliceBodyResponse'
-            schemes:
-                - https
-            summary: Get network access keys for a network.
-            tags:
-                - networks
-        post:
-            operationId: createAccessKey
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-                - description: Access Key
-                  in: body
-                  name: access_key
-                  schema:
-                    $ref: '#/definitions/AccessKey'
-                  x-go-name: AccessKey
-            responses:
-                "200":
-                    $ref: '#/responses/accessKeyBodyResponse'
-            schemes:
-                - https
-            summary: Create a network access key.
-            tags:
-                - networks
-    /api/networks/{networkname}/keys/{name}:
-        delete:
-            operationId: deleteAccessKey
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-                - description: Access Key Name
-                  in: path
-                  name: access_key_name
-                  required: true
-                  type: string
-                  x-go-name: AccessKeyName
-            responses:
-                "200":
-                    description: ""
-            schemes:
-                - https
-            summary: Delete a network access key.
-            tags:
-                - networks
-    /api/networks/{networkname}/keyupdate:
-        post:
-            operationId: keyUpdate
-            parameters:
-                - description: Network Name
-                  in: path
-                  name: networkname
-                  required: true
-                  type: string
-                  x-go-name: NetworkName
-            responses:
-                "200":
-                    $ref: '#/responses/networkBodyResponse'
-            schemes:
-                - https
-            summary: Update keys for a network.
-            tags:
-                - networks
-    /api/nodes:
-        get:
-            operationId: getAllNodes
-            responses:
-                "200":
-                    $ref: '#/responses/nodeSliceResponse'
-            schemes:
-                - https
-            summary: Get all nodes across all networks.
-            tags:
-                - nodes
-    /api/nodes/{network}:
-        get:
-            operationId: getNetworkNodes
-            responses:
-                "200":
-                    $ref: '#/responses/nodeSliceResponse'
-            schemes:
-                - https
-            summary: Gets all nodes associated with network including pending nodes.
-            tags:
-                - nodes
-        post:
-            operationId: createNode
-            responses:
-                "200":
-                    $ref: '#/responses/nodeGetResponse'
-            schemes:
-                - https
-            summary: Create a node on a network.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}:
-        delete:
-            operationId: deleteNode
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-                - description: Node
-                  in: body
-                  name: node
-                  schema:
-                    $ref: '#/definitions/Node'
-                  x-go-name: Node
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Delete an individual node.
-            tags:
-                - nodes
-        get:
-            operationId: getNode
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Get an individual node.
-            tags:
-                - nodes
-        put:
-            operationId: updateNode
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-                - description: Node
-                  in: body
-                  name: node
-                  schema:
-                    $ref: '#/definitions/Node'
-                  x-go-name: Node
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Update an individual node.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/approve:
-        post:
-            operationId: uncordonNode
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Takes a node out of pending state.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/creategateway:
-        post:
-            operationId: createEgressGateway
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-                - description: Egress Gateway Request
-                  in: body
-                  name: egress_gateway_request
-                  schema:
-                    $ref: '#/definitions/EgressGatewayRequest'
-                  x-go-name: EgressGatewayRequest
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Create an egress gateway.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/createingress:
-        post:
-            operationId: createIngressGateway
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Create an ingress gateway.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/createrelay:
-        post:
-            operationId: createRelay
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-                - description: Relay Request
-                  in: body
-                  name: relay_request
-                  schema:
-                    $ref: '#/definitions/RelayRequest'
-                  x-go-name: RelayRequest
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Create a relay.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/deletegateway:
-        delete:
-            operationId: deleteEgressGateway
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Delete an egress gateway.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/deleteingress:
-        delete:
-            operationId: deleteIngressGateway
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Delete an ingress gateway.
-            tags:
-                - nodes
-    /api/nodes/{network}/{nodeid}/deleterelay:
-        delete:
-            operationId: deleteRelay
-            parameters:
-                - description: Network
-                  in: path
-                  name: network
-                  required: true
-                  type: string
-                  x-go-name: Network
-                - description: Node ID
-                  in: path
-                  name: nodeid
-                  required: true
-                  type: string
-                  x-go-name: NodeID
-            responses:
-                "200":
-                    $ref: '#/responses/nodeResponse'
-            schemes:
-                - https
-            summary: Remove a relay.
-            tags:
-                - nodes
-    /api/nodes/adm/{network}/authenticate:
-        post:
-            operationId: authenticate
-            parameters:
-                - description: AuthParams
-                  in: body
-                  name: auth_params
-                  schema:
-                    $ref: '#/definitions/AuthParams'
-                  x-go-name: AuthParams
-            responses:
-                "200":
-                    $ref: '#/responses/successResponse'
-            schemes:
-                - https
-            summary: Authenticate to make further API calls related to a network.
-            tags:
-                - nodes
-    /api/oauth/login:
-        get:
-            operationId: HandleAuthLogin
-            schemes:
-                - https
-            summary: Handles OAuth login.
-            tags:
-                - nodes
-    /api/server/getconfig:
-        get:
-            operationId: getConfig
-            responses:
-                "200":
-                    $ref: '#/responses/serverConfigResponse'
-            schemes:
-                - https
-            summary: Get the server configuration.
-            tags:
-                - server
-    /api/server/getserverinfo:
-        get:
-            operationId: getServerInfo
-            responses:
-                "200":
-                    $ref: '#/responses/serverConfigResponse'
-            schemes:
-                - https
-            summary: Get the server configuration.
-            tags:
-                - server
-    /api/server/register:
-        post:
-            operationId: register
-            parameters:
-                - description: Register Request
-                  in: body
-                  name: register_request
-                  schema:
-                    $ref: '#/definitions/RegisterRequest'
-                  x-go-name: RegisterRequest
-            responses:
-                "200":
-                    $ref: '#/responses/registerResponse'
-            schemes:
-                - https
-            summary: Registers a client with the server and return the Certificate Authority and certificate.
-            tags:
-                - server
-    /api/users:
-        get:
-            operationId: getUsers
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Get all users.
-            tags:
-                - user
-    /api/users/{username}:
-        delete:
-            operationId: deleteUser
-            parameters:
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Delete a user.
-            tags:
-                - user
-        get:
-            operationId: getUser
-            parameters:
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Get an individual user.
-            tags:
-                - user
-        post:
-            operationId: createUser
-            parameters:
-                - description: User
-                  in: body
-                  name: user
-                  schema:
-                    $ref: '#/definitions/User'
-                  x-go-name: User
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Create a user.
-            tags:
-                - user
-        put:
-            operationId: updateUser
-            parameters:
-                - description: User
-                  in: body
-                  name: user
-                  schema:
-                    $ref: '#/definitions/User'
-                  x-go-name: User
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Update a user.
-            tags:
-                - user
-    /api/users/{username}/adm:
-        put:
-            operationId: updateUserAdm
-            parameters:
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Updates the given admin user's info (as long as the user is an admin).
-            tags:
-                - user
-    /api/users/adm/authenticate:
-        post:
-            operationId: authenticateUser
-            parameters:
-                - description: User Auth Params
-                  in: body
-                  name: user_auth_params
-                  schema:
-                    $ref: '#/definitions/UserAuthParams'
-                  x-go-name: UserAuthParams
-            responses:
-                "200":
-                    $ref: '#/responses/successResponse'
-            schemes:
-                - https
-            summary: Node authenticates using its password and retrieves a JWT for authorization.
-            tags:
-                - user
-    /api/users/adm/createadmin:
-        post:
-            operationId: createAdmin
-            parameters:
-                - description: User
-                  in: body
-                  name: user
-                  schema:
-                    $ref: '#/definitions/User'
-                  x-go-name: User
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Make a user an admin.
-            tags:
-                - user
-    /api/users/adm/hasadmin:
-        get:
-            operationId: hasAdmin
-            responses:
-                "200":
-                    $ref: '#/responses/successResponse'
-            schemes:
-                - https
-            summary: Checks whether the server has an admin.
-            tags:
-                - user
-    /api/users/networks/{username}:
-        put:
-            operationId: updateUserNetworks
-            parameters:
-                - description: User
-                  in: body
-                  name: user
-                  schema:
-                    $ref: '#/definitions/User'
-                  x-go-name: User
-                - description: Username
-                  in: path
-                  name: username
-                  required: true
-                  type: string
-                  x-go-name: Username
-            responses:
-                "200":
-                    $ref: '#/responses/userBodyResponse'
-            schemes:
-                - https
-            summary: Updates the networks of the given user.
-            tags:
-                - user
-    /meshclient/files/{filename}:
-        get:
-            operationId: fileServer
-            schemes:
-                - https
-            summary: Retrieve a file from the file server.
-            tags:
-                - meshclient
-produces:
-    - application/json
-responses:
-    accessKeyBodyResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/AccessKey'
-    accessKeySliceBodyResponse:
-        description: ""
-        schema:
-            items:
-                $ref: '#/definitions/AccessKey'
-            type: array
-    aclContainerResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/ACLContainer'
-    boolResponse:
-        description: ""
-    byteArrayResponse:
-        description: ""
-        schema:
-            items:
-                format: uint8
-                type: integer
-            type: array
-    dnsResponse:
-        description: Success
-        schema:
-            items:
-                $ref: '#/definitions/DNSEntry'
-            type: array
-    extClientResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/ExtClient'
-    extClientSliceResponse:
-        description: ""
-        schema:
-            items:
-                $ref: '#/definitions/ExtClient'
-            type: array
-    getNetworksSliceResponse:
-        description: ""
-        schema:
-            items:
-                $ref: '#/definitions/Network'
-            type: array
-    networkBodyResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/Network'
-    nodeGetResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/NodeGet'
-    nodeLastModifiedResponse:
-        description: ""
-    nodeResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/Node'
-    nodeSliceResponse:
-        description: ""
-        schema:
-            items:
-                $ref: '#/definitions/Node'
-            type: array
-    serverConfigResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/ServerConfig'
-    stringJSONResponse:
-        description: ""
-    successResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/SuccessResponse'
-    userBodyResponse:
-        description: ""
-        schema:
-            $ref: '#/definitions/User'
-schemes:
-    - https
-swagger: "2.0"

+ 1465 - 0
swagger.yml

@@ -0,0 +1,1465 @@
+---
+openapi: "3.0.1"
+servers:
+    - url: "https://api.demo.netmaker.io"
+info:
+    description: |-
+        API Usage
+
+        Most actions that can be performed via API can be performed via UI. We recommend managing your networks using the official netmaker-ui project. However, Netmaker can also be run without the UI, and all functions can be achieved via API calls. If your use case requires using Netmaker without the UI or you need to do some troubleshooting/advanced configuration, using the API directly may help.
+
+
+        Authentication
+
+        API calls must be authenticated via a header of the format -H “Authorization: Bearer <YOUR_SECRET_KEY>” There are two methods to obtain YOUR_SECRET_KEY: 1. Using the masterkey. This value can be set via env var at startup or in a config file (config/environments/< env >.yaml). See the [Netmaker](https://docs.netmaker.org/index.html) documentation for more details. 2. Using a JWT received for a node. This can be retrieved by calling the /api/nodes/<network>/authenticate endpoint, as documented below.
+    title: Netmaker
+    version: 0.20.6
+security:
+  - bearerAuth: []
+paths:
+    /api/nodes/adm/{network}/authenticate:
+        post:
+            operationId: authenticate
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            requestBody:
+                $ref: '#/components/requestBodies/nodeAuth'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Node authenticates using its password and retrieves a JWT.
+            tags:
+                - authorization
+    /api/users/adm/authenticate:
+        post:
+            operationId: authenticateUser
+            requestBody:
+                $ref: '#/components/requestBodies/userAuth'
+            responses:
+                "200":
+                    $ref: '#/components/responses/successResponse'
+            summary: user authenticates using its password and retrieves a JWT.
+            tags:
+                - authorization
+    /api/dns:
+        get:
+            operationId: getAllDNS
+            responses:
+                "200":
+                    $ref: '#/components/responses/dns'
+                "403":
+                    $ref: '#/components/responses/errorResponse'
+            summary: Gets all DNS entries.
+            tags:
+                - dns
+    /api/dns/{network}:
+        post:
+            operationId: createDNS
+            parameters:
+            - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/dns'
+                "403":
+                    $ref: '#/components/responses/errorResponse'                        
+                "400":
+                    $ref: '#/components/responses/badResponse'                        
+            summary: Create a DNS entry.
+            tags:
+                - dns
+    /api/dns/{network}/{host}:
+        delete:
+            operationId: deleteDNS
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - description: Host
+                  in: path
+                  name: host
+                  required: true
+                  x-go-name: Domain
+                  schema:
+                    type: string    
+            responses:
+                "200":
+                    description: "deletion successful"
+                    content:
+                        application/json:
+                            schema:
+                                type: string
+                            examples:
+                                success:
+                                    value: "{host}.{network} deleted"
+            summary: Delete a DNS entry.
+            tags:
+                - dns
+    /api/dns/adm/{network}:
+        get:
+            operationId: getDNS
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/dns'
+            summary: Gets all DNS entries associated with the network.
+            tags:
+                - dns
+    /api/dns/adm/{network}/custom:
+        get:
+            operationId: getCustomDNS
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/dns'
+            summary: Gets custom DNS entries associated with a network.
+            tags:
+                - dns
+    /api/dns/adm/{network}/nodes:
+        get:
+            operationId: getNodeDNS
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            summary: Gets node DNS entries associated with a network.
+            tags:
+                - dns
+            responses:
+                "200":
+                    $ref: '#/components/responses/dns'
+                "403":
+                    $ref: '#/components/responses/errorResponse'                        
+    /api/dns/adm/pushdns:
+        post:
+            operationId: pushDNS
+            responses:
+                "200":
+                    description: "success"
+                    content:
+                        application/json:
+                            schema:
+                                type: string
+                            examples:
+                                success:
+                                    value: "DNS entries pushed to nameserver"
+            summary: Push DNS entries to nameserver.
+            tags:
+                - dns
+    /api/v1/enrollment-keys:
+        get:
+            operationId: getAllEnrollmentKeys
+            responses:
+                "200":
+                    $ref: '#/components/responses/enrollmentKeys'
+            summary: Get all en keys.
+            tags:
+                - enrollment_keys
+        post:
+            operationId: createEnrollmentKey
+            requestBody:
+                $ref: '#/components/responses/enrollmentKey'
+            responses:
+                "200":
+                    $ref: '#/components/responses/enrollmentKey'
+            summary: Create an access key.
+            tags:
+                - enrollment_keys
+    /api/v1/enrollment-keys/{key}:
+        delete:
+            operationId: deleteEnrollmentKey
+            parameters:
+                - description: Key
+                  in: path
+                  name: key
+                  required: true
+                  schema:
+                    type: string
+            responses:
+                "200":
+                    description: "success"
+                "403":
+                    $ref: '#/components/responses/errorResponse'
+                "500":
+                    description: "Internal Server Error"
+                    content:
+                        application/json:
+                            schema:
+                                type: object
+                                properties:
+                                    Code:
+                                        type: integer
+                                    Message:
+                                        type: string
+                            example:
+                                    {
+                                        "Code": 500,
+                                        "Message": "no enrollmentkey found"
+                                    }
+            summary: Delete an access key.
+            tags:
+                - enrollment_keys
+    /api/v1/host/register/{token}:
+        post:
+            operationId: registerHost
+            parameters:
+                - description: Token
+                  in: path
+                  name: token
+                  required: true
+                  schema:
+                    type: string
+            requestBody:
+                $ref: '#/components/requestBodies/host'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Register a node using a token.
+            tags:
+                - enrollment_keys
+
+    /api/extclients:
+        get:
+            operationId: getAllExtClients
+            responses:
+                "200":
+                    description: "extclients"
+                    content:
+                        application/json:
+                            schema:
+                                type: array
+                                items:
+                                    $ref: '#/components/responses/extClient'    
+            summary: A separate function to get all extclients, not just extclients for a particular network.
+            tags:
+                - ext_client
+    /api/extclients/{network}:
+        get:
+            description: Gets all extclients associated with network, including pending extclients.
+            operationId: getNetworkExtClients
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/extClients'
+            summary: Get all extclients associated with network.
+            tags:
+                - ext_client
+    /api/extclients/{network}/{clientid}:
+        get:
+            operationId: getExtClient
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/extclientID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/extClient'
+            summary: Get an individual extclient.
+            tags:
+                - ext_client
+        put:
+            operationId: updateExtClient
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/extclientID'
+            requestBody:
+                $ref: '#/components/requestBodies/customExtClient'
+            responses:
+                "200":
+                    $ref: '#/components/responses/extClient'
+            summary: Update an individual extclient.
+            tags:
+                - ext_client
+        delete:
+            operationId: deleteExtClient
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/extclientID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/successResponse'
+            summary: Delete an individual extclient.
+            tags:
+                - ext_client
+    /api/extclients/{network}/{clientid}/{type}:
+        get:
+            operationId: getExtClientConf
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/extclientID'
+                - description: Type
+                  in: path
+                  name: type
+                  required: true
+                  schema:
+                    type: string
+                  examples:
+                    file:
+                        value: "wg"
+                    qr code:
+                        value: "qr"
+            responses:
+                "200":
+                    $ref: '#/components/responses/extClient'
+            summary: Get an individual extclient.
+            tags:
+                - ext_client
+    /api/extclients/{network}/{nodeid}:
+        post:
+            operationId: createExtClient
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            requestBody:
+                $ref: '#/components/requestBodies/customExtClient'
+                description: Custom ExtClient
+                content:
+                    application/json:
+                        schema:
+                required: true
+                x-go-name: CustomExtClient
+            summary: Create an individual extclient.  Must have valid key and be unique.
+            tags:
+                - ext_client
+            responses:
+                "200":
+                    $ref: '#/components/responses/extClient'
+    /api/getip:
+        get:
+            operationId: getIP
+            responses:
+                "200":
+                    description: IP Address
+                    content:
+                       application/json:
+                        schema:
+                            type: string
+                        examples:
+                            result:
+                                value:
+                                    "192.168.0.25"
+            summary: Get the current public IP address.
+            tags:
+                - ipservice
+
+    /api/hosts:
+        get:
+            operationId: getAllHosts
+            responses:
+                "200":
+                    $ref: '#/components/responses/host'
+            summary: Get all hosts across all networks.
+            tags:
+                - hosts
+    /api/hosts/keys:
+        put:
+            operationId: updateAllKeys
+            responses:
+                "200":
+                    description: "success"
+                "400":
+                    $ref: '#/components/responses/badResponse'
+            summary: Update all wireguard keys .
+            tags:
+                - hosts                
+    /api/hosts/{hostid}/keys:
+        put:
+            operationId: updateKeys
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+            responses:
+                "200":
+                    description: "success"
+                "400":
+                    $ref: '#/components/responses/badResponse'
+            summary: Update wireguard keys for a host.
+            tags:
+                - hosts
+    /api/hosts/{hostid}/sync:
+        put:
+            operationId: syncHost
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+            responses:
+                "200":
+                    description: "success"
+                "400":
+                    $ref: '#/components/responses/badResponse'
+            summary: Sync a host.
+            tags:
+                - hosts
+    /api/hosts/{hostid}:
+        put:
+            operationId: updateHost
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+            requestBody:
+                $ref: '#/components/responses/host'
+            responses:
+                "200":
+                    $ref: '#/components/responses/host'
+            summary: Update an individual host.
+            tags:
+                - hosts
+        delete:
+            operationId: deleteHost
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/host'
+            summary: Delete an individual host.
+            tags:
+                - hosts
+    /api/hosts/{hostid}/networks/{network}:
+        post:
+            operationId: addHostToNetwork
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    description: "success"
+            summary: Create an individual host.
+            tags:
+                - hosts
+        delete:
+            operationId: deletedHostFromNetwork
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+                - $ref: '#/components/parameters/networkName'
+                - description: force
+                  in: query
+                  name: force
+                  required: false
+                  schema:
+                    type: boolean
+            responses:
+                "200":
+                    description: "success"
+            summary: Delete an individual host.
+            tags:
+                - hosts
+    /api/v1/host:
+        get:
+            operationId: pull
+            responses:
+                "200":
+                    description: "success"
+                    $ref: '#/components/responses/host'
+            summary: Get an individual host.
+            tags:
+                - hosts
+    /api/v1/host/{hostid}/signalpeer:
+        post:
+            operationId: signalPeer
+            parameters:
+                - $ref: '#/components/parameters/hostID'
+            requestBody:
+                $ref: '#/components/responses/signal'
+            responses:
+                "200":
+                    description: "success"
+                    $ref: '#/components/responses/signal'
+            summary: Get an individual host.
+            tags:
+                - hosts
+
+    /api/v1/legacy/nodes:
+        delete:
+            operationId: wipeLegayNodes
+            responses:
+                "200":
+                    description: "success"
+                    $ref: '#/components/responses/successResponse'
+            summary: Delete all legacy nodes across all networks.
+            tags:
+                - legacy
+    
+    /api/logs:
+        get:
+            operationId: getLogs
+            responses:
+                "200":
+                    description: "logs"
+                    content:
+                        application/json:
+                            schema:
+                                type: array
+                                items:
+                                    type: string
+            summary: Get all logs across all networks.
+            tags:
+                - logs
+
+    /api/v1/nodes/migrate:
+        post:
+            operationId: migrate
+            requestBody:
+                $ref: '#/components/requestBodies/migrate'
+            responses:
+                "200":
+                    description: "success"
+                    content:
+                        application/json:
+                            schema:
+                                type: object
+                                properties:
+                                  NodeID:
+                                    type: string
+                                  NetID:
+                                    type: string
+                                  NatEnabled:
+                                    type: boolean
+                                  Ranges:
+                                    type: array
+                                    items:
+                                        type: string
+            summary: Migrate legacy nodes into host/nodes.
+            tags:
+                - migration
+
+    /api/networks:
+        get:
+            operationId: getAllNetworks
+            responses:
+                "200":
+                    $ref: '#/components/responses/networks'
+            summary: Lists all networks.
+            tags:
+                - networks
+        post:
+            operationId: createNetwork
+            requestBody:
+                $ref: '#/components/responses/network'
+                required: true
+            responses:
+                "200":
+                    $ref: '#/components/responses/network'
+            summary: Create a network.
+            tags:
+                - networks
+    /api/networks/{networkname}:
+        delete:
+            operationId: deleteNetwork
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/successResponse'
+            summary: Delete a network.  Will not delete if there are any nodes that belong to the network.
+            tags:
+                - networks
+        get:
+            operationId: getNetwork
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/network'
+            summary: Get a network.
+            tags:
+                - networks
+        put:
+            operationId: updateNetwork
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            requestBody:
+                    $ref: '#/components/responses/network'
+            responses:
+                "200":
+                    $ref: '#/components/responses/network'
+            summary: Update a network.
+            tags:
+                - networks
+    /api/networks/{networkname}/acls:
+        get:
+            operationId: getNetworkACLs
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    description: "acls"
+                    content:
+                        application/json:
+                            schema:
+                                type: object
+                                example: {
+                                    "4bf4f244-6882-44dd-a18d-83abefcd7330":{
+                                        "5e58ada3-11a4-4073-9249-9bcdfded9dc7":2
+                                    }
+                                }
+                                    
+            summary: Get a network ACL (Access Control List).
+            tags:
+                - networks
+        put:
+            operationId: updateNetworkACLs
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+            requestBody:
+                description: ACL Container
+                required: true
+                content:
+                    application/json:
+                        schema:
+                            type: object
+                            example: {
+                                "4bf4f244-6882-44dd-a18d-83abefcd7330":{
+                                    "5e58ada3-11a4-4073-9249-9bcdfded9dc7":2
+                                    }
+                                }
+            responses:
+                "200":
+                    description: "acls"
+                    content:
+                        application/json:
+                            schema:
+                                type: object
+                                example: {
+                                    "4bf4f244-6882-44dd-a18d-83abefcd7330":{
+                                        "5e58ada3-11a4-4073-9249-9bcdfded9dc7":2
+                                    }
+                                }
+                                    
+            summary: Update a network ACL (Access Control List).
+            tags:
+                - networks
+    /api/nodes:
+        get:
+            operationId: getAllNodes
+            responses:
+                "200":
+                    $ref: '#/components/responses/nodes'
+            summary: Get all nodes across all networks.
+            tags:
+                - nodes
+    /api/nodes/{network}:
+        get:
+            operationId: getNetworkNodes
+            parameters:
+              - $ref: '#/components/parameters/networkName'
+            responses:
+                "200":
+                    $ref: '#/components/responses/nodes'
+            summary: Gets all nodes associated with network including pending nodes.
+            tags:
+                - nodes
+    /api/nodes/{network}/{nodeid}:
+        get:
+            operationId: getNode
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Get an individual node.
+            tags:
+                - nodes
+        put:
+            operationId: updateNode
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            requestBody:
+                $ref: '#/components/responses/node'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Update an individual node from UI.
+            tags:
+                - nodes
+        post:
+            operationId: updateNodeFromHost
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            requestBody:
+                $ref: '#/components/responses/node'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Update an individual node from host.
+            tags:
+                - nodes
+        delete:
+            operationId: deleteNode
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/successResponse'
+            summary: Delete an individual node.
+            tags:
+                - nodes
+    /api/nodes/{network}/{nodeid}/creategateway:
+        post:
+            operationId: createEgressGateway
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            requestBody:
+                description: Egress Gateway Request
+                required: true
+                content:
+                    application/json:
+                        schema:
+                            description: Egress Gateway Request
+                            type: object
+                            properties:
+                                NodeID:
+                                    type: string
+                                NetID:
+                                    type: string
+                                NatEnabled:
+                                    type: boolean
+                                Ranges:
+                                    type: array
+                                    items:
+                                        type: string
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Create an egress gateway.
+            tags:
+                - nodes
+    /api/nodes/{network}/{nodeid}/deletegateway:
+        delete:
+            operationId: deleteEgressGateway
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Delete an egress gateway.
+            tags:
+                - nodes
+    /api/nodes/{network}/{nodeid}/createingress:
+        post:
+            operationId: createIngressGateway
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            requestBody:
+                description: Ingress Gateway Request
+                required: true
+                content:
+                    application/json:
+                        schema:
+                            description: Ingress Gateway Request
+                            type: object
+                            properties:
+                                ExtClientDNS:
+                                    type: string
+                                FailOver:
+                                    type: string
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Create an ingress gateway.
+            tags:
+                - nodes
+    /api/nodes/{network}/{nodeid}/deleteingress:
+        delete:
+            operationId: deleteIngressGateway
+            parameters:
+                - $ref: '#/components/parameters/networkName'
+                - $ref: '#/components/parameters/nodeID'
+            responses:
+                "200":
+                    $ref: '#/components/responses/node'
+            summary: Create an ingress gateway.
+            tags:
+                - nodes
+components:
+    securitySchemes:
+        bearerAuth:
+            type: http
+            scheme: bearer
+            bearerFormat: JWT
+    parameters:
+        networkName:
+            description: Network Name
+            in: path
+            name: network
+            required: true
+            schema:
+                type: string
+        extclientID:
+            description: Client ID
+            in: path
+            name: clientid
+            required: true
+            schema:
+                type: string
+        hostID:        
+            description: Host ID
+            in: path
+            name: hostid
+            required: true
+            x-go-name: HostID
+            schema:
+              type: string
+        nodeID:
+            description: node ID
+            in: path
+            name: nodeid
+            required: true
+            schema:
+                type: string
+    responses:
+
+        errorResponse:
+            description: Error
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            Code:
+                                type: integer
+                            Message:
+                                type: string
+                    examples:
+                        error:
+                            value:
+                                Code: 403
+                                Message: "forbidden"
+
+        badResponse:
+            description: Error
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            Code:
+                                type: integer
+                            Message:
+                                type: string
+                    examples:
+                        error:
+                            value:
+                                Code: 400
+                                Message: "Key: 'DNSEntry.Address' Error:Field validation for 'Address' failed on the 'required' tag"
+
+        successResponse:
+            description: Success
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            Code: 
+                                type: integer
+                            Message: 
+                                type: string
+                            Response: 
+                                type: string # todo interface{}
+                    examples:
+                        success:
+                            value:
+                                Code: 200
+                                Message: "success"
+                                Response: "success"
+
+        dns:
+            description: DNSEntry
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            name:
+                                type: string
+                            network:
+                                type: string
+                            address:
+                                type: string
+                            address6:
+                                type: string
+        accessKey:
+            description: "AccessKey"
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            Expiration:
+                                type: string
+                            UsesRemaining:
+                                type: integer
+                            value:
+                                type: string
+                            networks:
+                                type: string
+                            unlimited:
+                                type: boolean
+                            Tags: 
+                                type: string
+                            Token:
+                                type: string
+        enrollmentKeys:
+            description: "Enrollement Keys"
+            content:
+              application/json:
+                schema:
+                    type: array
+                    items:
+                        $ref: '#/components/responses/enrollmentKey'
+        enrollmentKey:    
+            description: "Enrollement Key"
+            content:
+              application/json:
+                schema:
+                    type: object
+                    properties:
+                        Key:
+                            type: string
+                        Name:
+                            type: string
+                        Notes:
+                            type: string
+                        Tags:
+                            type: string
+                        Unlimited:
+                            type: boolean
+                        UsesRemaining:
+                            type: integer
+                        Expiration:
+                            type: string
+        extClients:
+            description: "ExtClients"
+            content:
+              application/json:
+                schema:
+                    type: array
+                    items:
+                        $ref: '#/components/responses/extClient'    
+        extClient:
+            description: "ExtClient"
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            ClientID:
+                                type: string
+                            PrivateKey:
+                                type: string
+                            PublicKey:
+                                type: string
+                            Network:
+                                type: string
+                            DNS:
+                                type: string
+                            Address:
+                                type: string
+                            Address6:
+                                type: string
+                            ExtraAllowedIPs:
+                                type: array
+                                items:
+                                    type: string
+                            IngressGatewayID:
+                                type: string
+                            IngressGatewayEndpoint:
+                                type: string
+                            LastModified:
+                                type: integer
+                            Enabled:
+                                type: boolean
+                            OwnerID:
+                                type: string
+                            DeniedACLs:
+                                type: string # todo map[string]struct{}
+        networks:
+            description: "Networks"
+            content:
+              application/json:
+                schema:
+                    type: array
+                    items:
+                        $ref: '#/components/responses/network'    
+        network:
+            description: "Network"
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                            AddressRange:
+                                type: string
+                            AddressRange6:
+                                type: string
+                            NetID:
+                                type: string
+                            NodesLastModified:
+                                type: integer
+                            DefaultListenPort:
+                                type: integer
+                            NodeLimit:
+                                type: integer
+                            DefaultKeepAlive:
+                                type: integer
+                            IsIPv4: 
+                                type: string
+                            IsIPv6:  
+                                type: string
+                            DefaultACL:
+                                type: string
+                            ProSettings:
+                                type: string # todo promodels.ProNetwork
+        node:
+            description: "Node"
+            content:
+                applicaton/json:
+                    schema:
+                        type: object
+                        properties:
+                          ID:
+                            type: string
+                          HostID:
+                            type: string
+                          Network:
+                            type: string
+                          NetworkRange:
+                            type: string
+                          NetworkRange6:
+                            type: string
+                          InternetGateway:
+                            type: string
+                          Server:
+                            type: string
+                          Connected:
+                            type: boolean
+                          Address:
+                            type: string
+                          Address6:
+                            type: string
+                          Action:
+                            type: string
+                          LocalAddress:
+                            type: string
+                          IsEgressGateway:
+                            type: boolean
+                          EgressGatewayRanges:
+                            type: array
+                            items:
+                              type: string
+                          IsIngressGateway: 
+                            type: boolean
+                          IsRelayed:
+                            type: boolean
+                          RelayedBy:
+                            type: string
+                          RelayedNodes:
+                            type: array
+                            items:
+                              type: string
+                          IngressDNS:
+                            type: string
+                          DNSOn:
+                            type: boolean
+                          PersistentKeepaliveInterval:
+                            type: integer
+        nodes:
+            description: "Nodes"
+            content:
+              application/json:
+                schema:
+                    type: array
+                    items:
+                        $ref: '#/components/responses/node'
+        
+        signal:
+            description: "Signal"
+            content:
+                application/json:
+                    schema:
+                        type: object
+                        properties:
+                          Server:
+                            type: string
+                          FromHostPubicKey:
+                            type: string
+                          TurnRelayEndpoint:
+                            type: string
+                          Reply:
+                            type: boolean
+                          Action: 
+                            type: string
+                          Timestamp:
+                            type: integer
+
+        host:
+            description: "Host"
+            content:
+              application/json:
+                schema:
+                    type: object
+                    properties:
+                      ID:
+                        type: string
+                      Verbosity:
+                        type: string
+                      FirewallIInUse:
+                        type: string
+                      Version:
+                        type: string
+                      DaemonInstlled:
+                        type: boolean
+                      AutoUpdate:
+                        type: boolean
+                      HostPass:
+                        type: string
+                      Name:
+                        type: string
+                      OS:
+                        type: string
+                      Interface:
+                        type: string
+                      Debug:
+                        type: boolean
+                      ListenPort:
+                        type: integer
+                      WgPublicListenPort:
+                        type: integer
+                      MTU:
+                        type: integer
+                      PublicKey:
+                        type: string
+                      MacAddress:
+                        type: string
+                      TrafficKeyPublic:
+                        type: string
+                      Nodes: 
+                        type: array
+                        items:
+                          type: string
+                      Interfaces:
+                        type: array
+                        items:
+                          type: string
+                      DefaultInterface:
+                        type: string
+                      EndpointIP:
+                        type: string
+                      IsDocker:
+                        type: boolean
+                      IsK8s:
+                        type: boolean
+                      IsStatic:
+                        type: boolean
+                      IsDefault:
+                        type: boolean
+                      NatType:
+                        type: string
+                      TurnEndpoint:
+                        type: string
+#       aclContainerResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/ACLContainer'
+#                type: array
+#        extClient:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/ExtClient'
+#        extClientSliceResponse:
+#            description: ""
+#            schema:
+#                items:
+#                    $ref: '#/definitions/ExtClient'
+#                type: array
+#        getNetworksSliceResponse:
+#            description: ""
+#            schema:
+#                items:
+#                    $ref: '#/definitions/Network'
+#                type: array
+#        networkBodyResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/Network'
+#        nodeGetResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/NodeGet'
+#        nodeLastModifiedResponse:
+#            description: ""
+#        node:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/Node'
+#        nodeSliceResponse:
+#            description: ""
+#            schema:
+#                items:
+#                    $ref: '#/definitions/Node'
+#                type: array
+#        serverConfigResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/ServerConfig'
+#        stringJSONResponse:
+#            description: ""
+#        successResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/SuccessResponse'
+#        userBodyResponse:
+#            description: ""
+#            schema:
+#                $ref: '#/definitions/User'
+#
+    requestBodies:
+      nodeAuth:
+        content:
+          application/json:
+            schema:
+                type: object
+                properties:
+                  MacAddress:
+                    type: string
+                  ID:
+                    type: string
+                  Password:
+                    type: string
+        description: NodeAuth
+        required: true
+      userAuth:
+        content:
+          application/json:
+            schema:
+                type: object
+                properties:
+                  Username:
+                    type: string
+                  Password:
+                    type: string
+      customExtClient:
+        content:
+          application/json:
+            schema:
+                type: object
+                properties:
+                  ClientID:
+                    type: string
+                  PublicKey:
+                    type: string
+                  DNS:
+                    type: string
+                  ExtraAllowedIPs:
+                    type: array
+                    items:
+                      type: string
+                  Enabled:
+                    type: boolean
+                  DeniedACLs:
+                    type: string # todo map[string]struct{}
+        description: ExtClient
+        required: true
+      host:
+        content:
+          application/json:
+            schema:
+                type: object
+                properties:
+                  ID:
+                    type: string
+                  Verbosity:
+                    type: string
+                  FirewallIInUse:
+                    type: string
+                  Version:
+                    type: string
+                  DaemonInstlled:
+                    type: boolean
+                  AutoUpdate:
+                    type: boolean
+                  HostPass:
+                    type: string
+                  Name:
+                    type: string
+                  OS:
+                    type: string
+                  Interface:
+                    type: string
+                  Debug:
+                    type: boolean
+                  ListenPort:
+                    type: integer
+                  WgPublicListenPort:
+                    type: integer
+                  MTU:
+                    type: integer
+                  PublicKey:
+                    type: string
+                  MacAddress:
+                    type: string
+                  TrafficKeyPublic:
+                    type: string
+                  Nodes: 
+                    type: array
+                    items:
+                      type: string
+                  Interfaces:
+                    type: array
+                    items:
+                      type: string
+                  DefaultInterface:
+                    type: string
+                  EndpointIP:
+                    type: string
+                  IsDocker:
+                    type: boolean
+                  IsK8s:
+                    type: boolean
+                  IsStatic:
+                    type: boolean
+                  IsDefault:
+                    type: boolean
+                  NatType:
+                    type: string
+                  TurnEndpoint:
+                    type: string
+        description: Host
+        required: true
+      migrate:
+        content:
+          application/json:
+            schema:
+                type: object
+                properties:
+                  ID:
+                    type: string
+                  Address:
+                    type: string
+                  Address6:
+                    type: string
+                  LocalAddress:
+                    type: string
+                  Interfaces:
+                    type: array
+                    items:
+                      type: string
+                  NetworkSetttings:
+                    $ref: '#/components/responses/network'
+                  ListenPort:
+                    type: integer
+                  LocalListenPort:
+                    type: integer
+                  PublicKey:
+                    type: string
+                  Endpoint:
+                    type: string
+                  AllowedIPs:
+                    type: array
+                    items:
+                      type: string
+                  PersistentKeepalive:
+                    type: integer
+                  IsHub:
+                    type: boolean
+                  AccessKey:
+                    type: string
+                  Interface:
+                    type: string
+                  LastModified:
+                    type: integer
+                  ExpirationDateTime:
+                    type: string
+                  LastPeerUpdate:
+                    type: integer
+                  MacAddress:
+                    type: string
+                  Password:
+                    type: string
+                  Network:
+                    type: string
+                  IsRelayed:
+                    type: boolean
+                  IsPending:
+                    type: boolean
+                  IsDocker:
+                    type: boolean
+                  IsK8s:
+                    type: boolean
+                  IsEgressGateway:
+                    type: boolean
+                  IsIngressGateway:
+                    type: boolean
+                  EgressGatewayRanges:
+                    type: array
+                    items:
+                      type: string
+                  EgressGatewayNatEnabled:
+                    type: boolean
+                  EgressGatewayRequest:
+                     type: object
+                     properties:
+                        NodeID:
+                            type: string
+                        NetID:
+                            type: string
+                        NatEnabled:
+                            type: boolean
+                        Ranges:
+                            type: array
+                            items:
+                                type: string
+                  RelayAddrs:
+                    type: array
+                    items:
+                      type: string
+                  FailoverNode:
+                    type: string
+                  IngressGatewayRange:
+                    type: string
+                  IngressGatewayRange6:
+                    type: string
+                  IsStatic:
+                    type: boolean
+                  UDPHolePunch:
+                    type: boolean
+                  DNSOn:
+                    type: boolean
+                  IsServer:
+                    type: boolean
+                  Action:
+                    type: string
+                  IPForwarding:
+                    type: boolean
+                  OS:
+                    type: string
+                  MTU:
+                    type: integer
+                  Version:
+                    type: string
+                  Server:
+                    type: string
+                  TrafficKeys:
+                    type: object
+                    properties:
+                      Private:
+                        type: string
+                      Public:
+                        type: string
+                  FirewallInUse:
+                    type: string
+                  InternetGateway:
+                    type: string
+                  Connected:
+                    type: boolean
+                  DefaultACL:
+                    type: string
+                  OwnerID:
+                    type: string
+                  FailOver:
+                    type: string
+                  
+
+
+        description: Migrate
+        required: true