---
title: "Create WireGuard peer"
method: POST
path: "/v1/network/{network_id}/wg-peer"
tags: ["Networks"]
---

# Create WireGuard peer

`POST /v1/network/{network_id}/wg-peer`

## Path parameters

- `network_id` string, required — ID of an network

## Request body

- object
  - `peer_name` string, required — Name of the WireGuard client
  - `remote_networks` string[] — List of remote networks

## Response `201`

Created

- NetworkWGPeer — NetworkWGPeer object that represents a WireGuard client.
  - `peer_name` string, required — Name of the WireGuard client
  - `remote_networks` string[], required — List of remote networks
  - `wg_address` string, required — WireGuard address of this peer, part of the network defined in wg_prefix
  - `wg_endpoint` string, required — Address of the WireGuard endpoint that this peer connects to
  - `wg_peer_id` string, required — ID of a WireGuard peer
  - `wg_private_key` string, required — WireGuard private key of this peer
  - `wg_public_key` string, required — WireGuard public key of this peer

## Other responses

- `400` — Bad request
- `401` — Unauthorized
- `404` — Not found
- `500` — Internal server error

---

[API](https://skmtc.net/slide/apis/slide-api.md) · [All operations](https://skmtc.net/slide/apis/slide-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/slide/slide-api/revisions/c63e4b604dd1/schema)
