mirror of
https://github.com/h44z/wg-portal.git
synced 2025-07-12 16:16:58 +00:00
Deployed 6cbccf6 to master with MkDocs 1.6.1 and mike 2.1.3
This commit is contained in:
parent
c230f8105d
commit
e726d99921
@ -45,16 +45,14 @@ definitions:
|
||||
models.Interface:
|
||||
properties:
|
||||
Addresses:
|
||||
description: Addresses is a list of IP addresses (in CIDR format) that are
|
||||
assigned to the interface.
|
||||
description: Addresses is a list of IP addresses (in CIDR format) that are assigned to the interface.
|
||||
example:
|
||||
- 10.11.12.1/24
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
Disabled:
|
||||
description: Disabled is a flag that specifies if the interface is enabled
|
||||
(up) or not (down). Disabled interfaces are not able to accept connections.
|
||||
description: Disabled is a flag that specifies if the interface is enabled (up) or not (down). Disabled interfaces are not able to accept connections.
|
||||
example: false
|
||||
type: boolean
|
||||
DisabledReason:
|
||||
@ -67,45 +65,38 @@ definitions:
|
||||
maxLength: 64
|
||||
type: string
|
||||
Dns:
|
||||
description: Dns is a list of DNS servers that should be set if the interface
|
||||
is up.
|
||||
description: Dns is a list of DNS servers that should be set if the interface is up.
|
||||
example:
|
||||
- 1.1.1.1
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
DnsSearch:
|
||||
description: DnsSearch is the dns search option string that should be set
|
||||
if the interface is up, will be appended to Dns servers.
|
||||
description: DnsSearch is the dns search option string that should be set if the interface is up, will be appended to Dns servers.
|
||||
example:
|
||||
- wg.local
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
EnabledPeers:
|
||||
description: EnabledPeers is the number of enabled peers for this interface.
|
||||
Only enabled peers are able to connect.
|
||||
description: EnabledPeers is the number of enabled peers for this interface. Only enabled peers are able to connect.
|
||||
readOnly: true
|
||||
type: integer
|
||||
FirewallMark:
|
||||
description: FirewallMark is an optional firewall mark which is used to handle
|
||||
interface traffic.
|
||||
description: FirewallMark is an optional firewall mark which is used to handle interface traffic.
|
||||
type: integer
|
||||
Identifier:
|
||||
description: Identifier is the unique identifier of the interface. It is always
|
||||
equal to the device name of the interface.
|
||||
description: Identifier is the unique identifier of the interface. It is always equal to the device name of the interface.
|
||||
example: wg0
|
||||
type: string
|
||||
ListenPort:
|
||||
description: 'ListenPort is the listening port, for example: 51820. The listening
|
||||
port is only required for server interfaces.'
|
||||
description: 'ListenPort is the listening port, for example: 51820. The listening port is only required for server interfaces.'
|
||||
example: 51820
|
||||
maximum: 65535
|
||||
minimum: 1
|
||||
type: integer
|
||||
Mode:
|
||||
description: Mode is the interface type, either 'server', 'client' or 'any'.
|
||||
The mode specifies how WireGuard Portal handles peers for this interface.
|
||||
description: Mode is the interface type, either 'server', 'client' or 'any'. The mode specifies how WireGuard Portal handles peers for this interface.
|
||||
enum:
|
||||
- server
|
||||
- client
|
||||
@ -119,8 +110,7 @@ definitions:
|
||||
minimum: 1
|
||||
type: integer
|
||||
PeerDefAllowedIPs:
|
||||
description: PeerDefAllowedIPs specifies the default allowed IP addresses
|
||||
for a new peer.
|
||||
description: PeerDefAllowedIPs specifies the default allowed IP addresses for a new peer.
|
||||
example:
|
||||
- 10.11.12.0/24
|
||||
items:
|
||||
@ -134,8 +124,7 @@ definitions:
|
||||
type: string
|
||||
type: array
|
||||
PeerDefDnsSearch:
|
||||
description: PeerDefDnsSearch specifies the default dns search options for
|
||||
a new peer.
|
||||
description: PeerDefDnsSearch specifies the default dns search options for a new peer.
|
||||
example:
|
||||
- wg.local
|
||||
items:
|
||||
@ -146,64 +135,52 @@ definitions:
|
||||
example: wg.example.com:51820
|
||||
type: string
|
||||
PeerDefFirewallMark:
|
||||
description: PeerDefFirewallMark specifies the default firewall mark for a
|
||||
new peer.
|
||||
description: PeerDefFirewallMark specifies the default firewall mark for a new peer.
|
||||
type: integer
|
||||
PeerDefMtu:
|
||||
description: PeerDefMtu specifies the default device MTU for a new peer.
|
||||
example: 1420
|
||||
type: integer
|
||||
PeerDefNetwork:
|
||||
description: PeerDefNetwork specifies the default subnets from which new peers
|
||||
will get their IP addresses. The subnet is specified in CIDR format.
|
||||
description: PeerDefNetwork specifies the default subnets from which new peers will get their IP addresses. The subnet is specified in CIDR format.
|
||||
example:
|
||||
- 10.11.12.0/24
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
PeerDefPersistentKeepalive:
|
||||
description: PeerDefPersistentKeepalive specifies the default persistent keep-alive
|
||||
value in seconds for a new peer.
|
||||
description: PeerDefPersistentKeepalive specifies the default persistent keep-alive value in seconds for a new peer.
|
||||
example: 25
|
||||
type: integer
|
||||
PeerDefPostDown:
|
||||
description: PeerDefPostDown specifies the default action that is executed
|
||||
after the device is down for a new peer.
|
||||
description: PeerDefPostDown specifies the default action that is executed after the device is down for a new peer.
|
||||
type: string
|
||||
PeerDefPostUp:
|
||||
description: PeerDefPostUp specifies the default action that is executed after
|
||||
the device is up for a new peer.
|
||||
description: PeerDefPostUp specifies the default action that is executed after the device is up for a new peer.
|
||||
type: string
|
||||
PeerDefPreDown:
|
||||
description: PeerDefPreDown specifies the default action that is executed
|
||||
before the device is down for a new peer.
|
||||
description: PeerDefPreDown specifies the default action that is executed before the device is down for a new peer.
|
||||
type: string
|
||||
PeerDefPreUp:
|
||||
description: PeerDefPreUp specifies the default action that is executed before
|
||||
the device is up for a new peer.
|
||||
description: PeerDefPreUp specifies the default action that is executed before the device is up for a new peer.
|
||||
type: string
|
||||
PeerDefRoutingTable:
|
||||
description: PeerDefRoutingTable specifies the default routing table for a
|
||||
new peer.
|
||||
description: PeerDefRoutingTable specifies the default routing table for a new peer.
|
||||
type: string
|
||||
PostDown:
|
||||
description: PostDown is an optional action that is executed after the device
|
||||
is down.
|
||||
description: PostDown is an optional action that is executed after the device is down.
|
||||
example: echo 'Interface is down'
|
||||
type: string
|
||||
PostUp:
|
||||
description: PostUp is an optional action that is executed after the device
|
||||
is up.
|
||||
description: PostUp is an optional action that is executed after the device is up.
|
||||
example: iptables -A FORWARD -i %i -j ACCEPT
|
||||
type: string
|
||||
PreDown:
|
||||
description: PreDown is an optional action that is executed before the device
|
||||
is down.
|
||||
description: PreDown is an optional action that is executed before the device is down.
|
||||
example: iptables -D FORWARD -i %i -j ACCEPT
|
||||
type: string
|
||||
PreUp:
|
||||
description: PreUp is an optional action that is executed before the device
|
||||
is up.
|
||||
description: PreUp is an optional action that is executed before the device is up.
|
||||
example: echo 'Interface is up'
|
||||
type: string
|
||||
PrivateKey:
|
||||
@ -211,17 +188,14 @@ definitions:
|
||||
example: gI6EdUSYvn8ugXOt8QQD6Yc+JyiZxIhp3GInSWRfWGE=
|
||||
type: string
|
||||
PublicKey:
|
||||
description: PublicKey is the public key of the server interface. The public
|
||||
key is used by peers to connect to the server.
|
||||
description: PublicKey is the public key of the server interface. The public key is used by peers to connect to the server.
|
||||
example: HIgo9xNzJMWLKASShiTqIybxZ0U3wGLiUeJ1PKf8ykw=
|
||||
type: string
|
||||
RoutingTable:
|
||||
description: RoutingTable is an optional routing table which is used to route
|
||||
interface traffic.
|
||||
description: RoutingTable is an optional routing table which is used to route interface traffic.
|
||||
type: string
|
||||
SaveConfig:
|
||||
description: SaveConfig is a flag that specifies if the configuration should
|
||||
be saved to the configuration file (wgX.conf in wg-quick format).
|
||||
description: SaveConfig is a flag that specifies if the configuration should be saved to the configuration file (wgX.conf in wg-quick format).
|
||||
example: false
|
||||
type: boolean
|
||||
TotalPeers:
|
||||
@ -252,8 +226,7 @@ definitions:
|
||||
models.Peer:
|
||||
properties:
|
||||
Addresses:
|
||||
description: Addresses is a list of IP addresses in CIDR format (both IPv4
|
||||
and IPv6) for the peer.
|
||||
description: Addresses is a list of IP addresses in CIDR format (both IPv4 and IPv6) for the peer.
|
||||
example:
|
||||
- 10.11.12.2/24
|
||||
items:
|
||||
@ -264,13 +237,11 @@ definitions:
|
||||
- $ref: '#/definitions/models.ConfigOption-array_string'
|
||||
description: AllowedIPs is a list of allowed IP subnets for the peer.
|
||||
CheckAliveAddress:
|
||||
description: CheckAliveAddress is an optional ip address or DNS name that
|
||||
is used for ping checks.
|
||||
description: CheckAliveAddress is an optional ip address or DNS name that is used for ping checks.
|
||||
example: 1.1.1.1
|
||||
type: string
|
||||
Disabled:
|
||||
description: Disabled is a flag that specifies if the peer is enabled or not.
|
||||
Disabled peers are not able to connect.
|
||||
description: Disabled is a flag that specifies if the peer is enabled or not. Disabled peers are not able to connect.
|
||||
example: false
|
||||
type: boolean
|
||||
DisabledReason:
|
||||
@ -285,13 +256,11 @@ definitions:
|
||||
Dns:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-array_string'
|
||||
description: Dns is a list of DNS servers that should be set if the peer interface
|
||||
is up.
|
||||
description: Dns is a list of DNS servers that should be set if the peer interface is up.
|
||||
DnsSearch:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-array_string'
|
||||
description: DnsSearch is the dns search option string that should be set
|
||||
if the peer interface is up, will be appended to Dns servers.
|
||||
description: DnsSearch is the dns search option string that should be set if the peer interface is up, will be appended to Dns servers.
|
||||
Endpoint:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
@ -301,28 +270,23 @@ definitions:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: EndpointPublicKey is the endpoint public key.
|
||||
ExpiresAt:
|
||||
description: ExpiresAt is the expiry date of the peer in YYYY-MM-DD format.
|
||||
An expired peer is not able to connect.
|
||||
description: ExpiresAt is the expiry date of the peer in YYYY-MM-DD format. An expired peer is not able to connect.
|
||||
type: string
|
||||
ExtraAllowedIPs:
|
||||
description: ExtraAllowedIPs is a list of additional allowed IP subnets for
|
||||
the peer. These allowed IP subnets are added on the server side.
|
||||
description: ExtraAllowedIPs is a list of additional allowed IP subnets for the peer. These allowed IP subnets are added on the server side.
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
FirewallMark:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-uint32'
|
||||
description: FirewallMark is an optional firewall mark which is used to handle
|
||||
peer traffic.
|
||||
description: FirewallMark is an optional firewall mark which is used to handle peer traffic.
|
||||
Identifier:
|
||||
description: Identifier is the unique identifier of the peer. It is always
|
||||
equal to the public key of the peer.
|
||||
description: Identifier is the unique identifier of the peer. It is always equal to the public key of the peer.
|
||||
example: xTIBA5rboUvnH4htodjb6e697QjLERt1NAB4mZqp8Dg=
|
||||
type: string
|
||||
InterfaceIdentifier:
|
||||
description: InterfaceIdentifier is the identifier of the interface the peer
|
||||
is linked to.
|
||||
description: InterfaceIdentifier is the identifier of the interface the peer is linked to.
|
||||
example: wg0
|
||||
type: string
|
||||
Mode:
|
||||
@ -344,28 +308,23 @@ definitions:
|
||||
PersistentKeepalive:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-int'
|
||||
description: PersistentKeepalive is the optional persistent keep-alive interval
|
||||
in seconds.
|
||||
description: PersistentKeepalive is the optional persistent keep-alive interval in seconds.
|
||||
PostDown:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: PostDown is an optional action that is executed after the device
|
||||
is down.
|
||||
description: PostDown is an optional action that is executed after the device is down.
|
||||
PostUp:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: PostUp is an optional action that is executed after the device
|
||||
is up.
|
||||
description: PostUp is an optional action that is executed after the device is up.
|
||||
PreDown:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: PreDown is an optional action that is executed before the device
|
||||
is down.
|
||||
description: PreDown is an optional action that is executed before the device is down.
|
||||
PreUp:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: PreUp is an optional action that is executed before the device
|
||||
is up.
|
||||
description: PreUp is an optional action that is executed before the device is up.
|
||||
PresharedKey:
|
||||
description: PresharedKey is the optional pre-shared Key of the peer.
|
||||
example: yAnz5TF+lXXJte14tji3zlMNq+hd2rYUIgJBgB3fBmk=
|
||||
@ -381,8 +340,7 @@ definitions:
|
||||
RoutingTable:
|
||||
allOf:
|
||||
- $ref: '#/definitions/models.ConfigOption-string'
|
||||
description: RoutingTable is an optional routing table which is used to route
|
||||
peer traffic.
|
||||
description: RoutingTable is an optional routing table which is used to route peer traffic.
|
||||
UserIdentifier:
|
||||
description: UserIdentifier is the identifier of the user that owns the peer.
|
||||
example: uid-1234567
|
||||
@ -430,18 +388,15 @@ definitions:
|
||||
models.ProvisioningRequest:
|
||||
properties:
|
||||
InterfaceIdentifier:
|
||||
description: InterfaceIdentifier is the identifier of the WireGuard interface
|
||||
the peer should be linked to.
|
||||
description: InterfaceIdentifier is the identifier of the WireGuard interface the peer should be linked to.
|
||||
example: wg0
|
||||
type: string
|
||||
PresharedKey:
|
||||
description: PresharedKey is the optional pre-shared key of the peer. If no
|
||||
pre-shared key is set, a new key is generated.
|
||||
description: PresharedKey is the optional pre-shared key of the peer. If no pre-shared key is set, a new key is generated.
|
||||
example: yAnz5TF+lXXJte14tji3zlMNq+hd2rYUIgJBgB3fBmk=
|
||||
type: string
|
||||
PublicKey:
|
||||
description: PublicKey is the optional public key of the peer. If no public
|
||||
key is set, a new key pair is generated.
|
||||
description: PublicKey is the optional public key of the peer. If no public key is set, a new key pair is generated.
|
||||
example: xTIBA5rboUvnH4htodjb6e697QjLERt1NAB4mZqp8Dg=
|
||||
type: string
|
||||
UserIdentifier:
|
||||
@ -456,14 +411,12 @@ definitions:
|
||||
models.User:
|
||||
properties:
|
||||
ApiEnabled:
|
||||
description: If this field is set, the user is allowed to use the RESTful
|
||||
API. This field is read-only.
|
||||
description: If this field is set, the user is allowed to use the RESTful API. This field is read-only.
|
||||
example: false
|
||||
readOnly: true
|
||||
type: boolean
|
||||
ApiToken:
|
||||
description: The API token of the user. This field is never populated on bulk
|
||||
read operations.
|
||||
description: The API token of the user. This field is never populated on bulk read operations.
|
||||
example: ""
|
||||
maxLength: 64
|
||||
minLength: 32
|
||||
@ -502,8 +455,7 @@ definitions:
|
||||
example: Muster
|
||||
type: string
|
||||
Locked:
|
||||
description: If this field is set, the user is locked and thus unable to log
|
||||
in to WireGuard Portal.
|
||||
description: If this field is set, the user is locked and thus unable to log in to WireGuard Portal.
|
||||
example: false
|
||||
type: boolean
|
||||
LockedReason:
|
||||
@ -515,8 +467,7 @@ definitions:
|
||||
example: some sample notes
|
||||
type: string
|
||||
Password:
|
||||
description: The password of the user. This field is never populated on read
|
||||
operations.
|
||||
description: The password of the user. This field is never populated on read operations.
|
||||
example: ""
|
||||
maxLength: 64
|
||||
minLength: 16
|
||||
@ -567,39 +518,33 @@ definitions:
|
||||
example: My iPhone
|
||||
type: string
|
||||
Identifier:
|
||||
description: Identifier is the unique identifier of the peer. It equals the
|
||||
public key of the peer.
|
||||
description: Identifier is the unique identifier of the peer. It equals the public key of the peer.
|
||||
example: peer-1234567
|
||||
type: string
|
||||
InterfaceIdentifier:
|
||||
description: InterfaceIdentifier is the unique identifier of the WireGuard
|
||||
Portal device the peer is connected to.
|
||||
description: InterfaceIdentifier is the unique identifier of the WireGuard Portal device the peer is connected to.
|
||||
example: wg0
|
||||
type: string
|
||||
IpAddresses:
|
||||
description: IPAddresses is a list of IP addresses in CIDR format assigned
|
||||
to the peer.
|
||||
description: IPAddresses is a list of IP addresses in CIDR format assigned to the peer.
|
||||
example:
|
||||
- 10.11.12.2/24
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
IsDisabled:
|
||||
description: IsDisabled is a flag that specifies if the peer is enabled or
|
||||
not. Disabled peers are not able to connect.
|
||||
description: IsDisabled is a flag that specifies if the peer is enabled or not. Disabled peers are not able to connect.
|
||||
example: true
|
||||
type: boolean
|
||||
type: object
|
||||
models.UserMetrics:
|
||||
properties:
|
||||
BytesReceived:
|
||||
description: The total number of bytes received by the user. This is the sum
|
||||
of all bytes received by the peers linked to the user.
|
||||
description: The total number of bytes received by the user. This is the sum of all bytes received by the peers linked to the user.
|
||||
example: 123456789
|
||||
type: integer
|
||||
BytesTransmitted:
|
||||
description: The total number of bytes transmitted by the user. This is the
|
||||
sum of all bytes transmitted by the peers linked to the user.
|
||||
description: The total number of bytes transmitted by the user. This is the sum of all bytes transmitted by the peers linked to the user.
|
||||
example: 123456789
|
||||
type: integer
|
||||
PeerCount:
|
||||
@ -607,8 +552,7 @@ definitions:
|
||||
example: 2
|
||||
type: integer
|
||||
PeerMetrics:
|
||||
description: PeerMetrics represents the metrics of the peers linked to the
|
||||
user.
|
||||
description: PeerMetrics represents the metrics of the peers linked to the user.
|
||||
items:
|
||||
$ref: '#/definitions/models.PeerMetrics'
|
||||
type: array
|
||||
@ -970,8 +914,7 @@ paths:
|
||||
tags:
|
||||
- Peers
|
||||
get:
|
||||
description: Normal users can only access their own records. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own records. Admins can access all records.
|
||||
operationId: peers_handleByIdGet
|
||||
parameters:
|
||||
- description: The peer identifier (public key).
|
||||
@ -1087,8 +1030,7 @@ paths:
|
||||
- Peers
|
||||
/peer/by-user/{id}:
|
||||
get:
|
||||
description: Normal users can only access their own records. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own records. Admins can access all records.
|
||||
operationId: peers_handleAllForUserGet
|
||||
parameters:
|
||||
- description: The user identifier.
|
||||
@ -1163,8 +1105,7 @@ paths:
|
||||
- Peers
|
||||
/provisioning/data/peer-config:
|
||||
get:
|
||||
description: Normal users can only access their own record. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own record. Admins can access all records.
|
||||
operationId: provisioning_handlePeerConfigGet
|
||||
parameters:
|
||||
- description: The peer identifier (public key) that should be queried.
|
||||
@ -1207,8 +1148,7 @@ paths:
|
||||
- Provisioning
|
||||
/provisioning/data/peer-qr:
|
||||
get:
|
||||
description: Normal users can only access their own record. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own record. Admins can access all records.
|
||||
operationId: provisioning_handlePeerQrGet
|
||||
parameters:
|
||||
- description: The peer identifier (public key) that should be queried.
|
||||
@ -1251,17 +1191,14 @@ paths:
|
||||
- Provisioning
|
||||
/provisioning/data/user-info:
|
||||
get:
|
||||
description: Normal users can only access their own record. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own record. Admins can access all records.
|
||||
operationId: provisioning_handleUserInfoGet
|
||||
parameters:
|
||||
- description: The user identifier that should be queried. If not set, the authenticated
|
||||
user is used.
|
||||
- description: The user identifier that should be queried. If not set, the authenticated user is used.
|
||||
in: query
|
||||
name: UserId
|
||||
type: string
|
||||
- description: The email address that should be queried. If UserId is set, this
|
||||
is ignored.
|
||||
- description: The email address that should be queried. If UserId is set, this is ignored.
|
||||
in: query
|
||||
name: Email
|
||||
type: string
|
||||
@ -1299,8 +1236,7 @@ paths:
|
||||
- Provisioning
|
||||
/provisioning/new-peer:
|
||||
post:
|
||||
description: Normal users can only create new peers if self provisioning is
|
||||
allowed. Admins can always add new peers.
|
||||
description: Normal users can only create new peers if self provisioning is allowed. Admins can always add new peers.
|
||||
operationId: provisioning_handleNewPeerPost
|
||||
parameters:
|
||||
- description: Provisioning request model.
|
||||
@ -1406,8 +1342,7 @@ paths:
|
||||
tags:
|
||||
- Users
|
||||
get:
|
||||
description: Normal users can only access their own record. Admins can access
|
||||
all records.
|
||||
description: Normal users can only access their own record. Admins can access all records.
|
||||
operationId: users_handleByIdGet
|
||||
parameters:
|
||||
- description: The user identifier.
|
||||
|
Loading…
x
Reference in New Issue
Block a user