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 postdown: type: string x-go-name: PostDown postup: type: string x-go-name: PostUp 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 defaultpostdown: type: string x-go-name: DefaultPostDown defaultpostup: type: string x-go-name: DefaultPostUp defaultudpholepunch: type: string x-go-name: DefaultUDPHolePunch isipv4: type: string x-go-name: IsIPv4 isipv6: type: string x-go-name: IsIPv6 islocal: type: string x-go-name: IsLocal ispointtosite: type: string x-go-name: IsPointToSite localrange: type: string x-go-name: LocalRange 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 islocal: type: string x-go-name: IsLocal 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 localrange: type: string x-go-name: LocalRange 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 postdown: type: string x-go-name: PostDown postup: type: string x-go-name: PostUp 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 AgentBackend: type: string AllowedOrigin: type: string AuthProvider: type: string AzureTenant: type: string ClientID: type: string ClientMode: type: string ClientSecret: type: string CoreDNSAddr: type: string DNSKey: type: string DNSMode: type: string Database: type: string DefaultNodeLimit: format: int32 type: integer 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 RCE: type: string RestBackend: type: string SQLConn: type: string Server: type: string ServerCheckinInterval: format: int64 type: integer 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 ” 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//authenticate endpoint, as documented below. title: Netmaker version: 0.16.3 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/networks/{networkname}/nodelimit: put: operationId: updateNetworkNodeLimit 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 a network's node limit. 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/nodes/adm/{network}/lastmodified: get: operationId: getLastModified responses: "200": $ref: '#/responses/nodeLastModifiedResponse' schemes: - https summary: Get the time that a network of nodes was last modified. 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"