package org.wfc.omada.api.sitesetting;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import io.swagger.annotations.ApiResponse;
import io.swagger.annotations.ApiResponses;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.ResponseEntity;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.wfc.omada.config.FeignConfig;
import org.wfc.omada.api.sitesetting.model.OperationResponseGridVoWireguardDetailOpenApiVo;
import org.wfc.omada.api.sitesetting.model.OperationResponseGridVoWireguardPeerDetailOpenApiVo;
import org.wfc.omada.api.sitesetting.model.OperationResponseResponseDataVoWireguardSummaryOpenApiVo;
import org.wfc.omada.api.sitesetting.model.OperationResponseResponseIdVo;
import org.wfc.omada.api.sitesetting.model.OperationResponseWireguardKeyOpenApiVo;
import org.wfc.omada.api.sitesetting.model.OperationResponseWithoutResult;
import org.wfc.omada.api.sitesetting.model.WireguardOpenApiVo;
import org.wfc.omada.api.sitesetting.model.WireguardPeerOpenApiVo;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-12-04T11:31:51.978+08:00[Asia/Shanghai]")

@Validated
@Api(value = "OmadaWireguardVpn", description = "the OmadaWireguardVpn API")
@FeignClient(name="OmadaWireguardVpnApi", url = "${omada.omada-url}", configuration = FeignConfig.class)
public interface OmadaWireguardVpnApi {

    /**
     * POST /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers : Create new wireguard peer
     * Create new wireguard peer.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify&lt;br/&gt;&lt;br/&gt;The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): &lt;br/&gt;-33006  -  This name already exists in this site.&lt;br/&gt;-43202  -  The number of WireGuard peers has reached the limit.&lt;br/&gt;-43205  -  The public key of the WireGuard peer for the same interface already exists.&lt;br/&gt;-43207  -  Endpoint and Endpoint Port need to be filled in at the same time or both left blank.
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param wireguardPeerOpenApiVo  (optional)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Create new wireguard peer", nickname = "createPeer", notes = "Create new wireguard peer.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify<br/><br/>The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): <br/>-33006  -  This name already exists in this site.<br/>-43202  -  The number of WireGuard peers has reached the limit.<br/>-43205  -  The public key of the WireGuard peer for the same interface already exists.<br/>-43207  -  Endpoint and Endpoint Port need to be filled in at the same time or both left blank.", response = OperationResponseResponseIdVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseResponseIdVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-peers",
        produces = "*/*", 
        consumes = "application/json",
        method = RequestMethod.POST)
    ResponseEntity<OperationResponseResponseIdVo> createPeer(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = ""  )  @Valid @RequestBody(required = false) WireguardPeerOpenApiVo wireguardPeerOpenApiVo);


    /**
     * POST /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards : Create new wireguard
     * Create new wireguard.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify&lt;br/&gt;&lt;br/&gt;The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): &lt;br/&gt;-33006  -  This name already exists in this site.&lt;br/&gt;-43200  -  The number of WireGuard entries has reached the limit.&lt;br/&gt;-43204  -  The port has been used.
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param wireguardOpenApiVo  (optional)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Create new wireguard", nickname = "createWireguard", notes = "Create new wireguard.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify<br/><br/>The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): <br/>-33006  -  This name already exists in this site.<br/>-43200  -  The number of WireGuard entries has reached the limit.<br/>-43204  -  The port has been used.", response = OperationResponseResponseIdVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseResponseIdVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguards",
        produces = "*/*", 
        consumes = "application/json",
        method = RequestMethod.POST)
    ResponseEntity<OperationResponseResponseIdVo> createWireguard(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = ""  )  @Valid @RequestBody(required = false) WireguardOpenApiVo wireguardOpenApiVo);


    /**
     * DELETE /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers/{id} : Delete an existing wireguard peer
     * Delete an existing wireguard peer.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param id Peer ID (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Delete an existing wireguard peer", nickname = "deletePeer", notes = "Delete an existing wireguard peer.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify", response = OperationResponseWithoutResult.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseWithoutResult.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-peers/{id}",
        produces = "*/*", 
        method = RequestMethod.DELETE)
    ResponseEntity<OperationResponseWithoutResult> deletePeer(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = "Peer ID",required=true) @PathVariable("id") String id);


    /**
     * DELETE /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards/{id} : Delete an existing wireguard
     * Delete an existing wireguard.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param id WireGuard VPN ID (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Delete an existing wireguard", nickname = "deleteWireguard", notes = "Delete an existing wireguard.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify", response = OperationResponseWithoutResult.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseWithoutResult.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguards/{id}",
        produces = "*/*", 
        method = RequestMethod.DELETE)
    ResponseEntity<OperationResponseWithoutResult> deleteWireguard(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = "WireGuard VPN ID",required=true) @PathVariable("id") String id);


    /**
     * GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-key : Get new private key and public key
     * Get new private key and public key.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager View Only&lt;br/&gt;&lt;br/&gt;The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): &lt;br/&gt;-1001  -  Invalid request parameters.
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Get new private key and public key", nickname = "getWireguardKey", notes = "Get new private key and public key.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager View Only<br/><br/>The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): <br/>-1001  -  Invalid request parameters.", response = OperationResponseWireguardKeyOpenApiVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseWireguardKeyOpenApiVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-key",
        produces = "*/*", 
        method = RequestMethod.GET)
    ResponseEntity<OperationResponseWireguardKeyOpenApiVo> getWireguardKey(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId);


    /**
     * GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-summarys : Get all wireguard&#39;s id and name info
     * Get all wireguard&#39;s id and name info.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager View Only
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Get all wireguard's id and name info", nickname = "getWireguardSummary", notes = "Get all wireguard's id and name info.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager View Only", response = OperationResponseResponseDataVoWireguardSummaryOpenApiVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseResponseDataVoWireguardSummaryOpenApiVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-summarys",
        produces = "*/*", 
        method = RequestMethod.GET)
    ResponseEntity<OperationResponseResponseDataVoWireguardSummaryOpenApiVo> getWireguardSummary(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId);


    /**
     * GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers : Get wireguard peer list
     * Get wireguard peer list.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager View Only
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param page Start page number. Start from 1. (required)
     * @param pageSize Number of entries per page. It should be within the range of 1–1000. (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Get wireguard peer list", nickname = "listPeer", notes = "Get wireguard peer list.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager View Only", response = OperationResponseGridVoWireguardPeerDetailOpenApiVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseGridVoWireguardPeerDetailOpenApiVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-peers",
        produces = "*/*", 
        method = RequestMethod.GET)
    ResponseEntity<OperationResponseGridVoWireguardPeerDetailOpenApiVo> listPeer(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@NotNull @ApiParam(value = "Start page number. Start from 1.", required = true) @Valid @RequestParam(value = "page", required = true) Integer page,@NotNull @ApiParam(value = "Number of entries per page. It should be within the range of 1–1000.", required = true) @Valid @RequestParam(value = "pageSize", required = true) Integer pageSize);


    /**
     * GET /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards : Get wireguard list
     * Get wireguard list.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager View Only
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param page Start page number. Start from 1. (required)
     * @param pageSize Number of entries per page. It should be within the range of 1–1000. (required)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Get wireguard list", nickname = "listWireguard", notes = "Get wireguard list.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager View Only", response = OperationResponseGridVoWireguardDetailOpenApiVo.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseGridVoWireguardDetailOpenApiVo.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguards",
        produces = "*/*", 
        method = RequestMethod.GET)
    ResponseEntity<OperationResponseGridVoWireguardDetailOpenApiVo> listWireguard(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@NotNull @ApiParam(value = "Start page number. Start from 1.", required = true) @Valid @RequestParam(value = "page", required = true) Integer page,@NotNull @ApiParam(value = "Number of entries per page. It should be within the range of 1–1000.", required = true) @Valid @RequestParam(value = "pageSize", required = true) Integer pageSize);


    /**
     * PUT /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguard-peers/{id} : Modify an existing wireguard peer
     * Modify an existing wireguard peer.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify&lt;br/&gt;&lt;br/&gt;The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): &lt;br/&gt;-33006  -  This name already exists in this site.&lt;br/&gt;-43202  -  The number of WireGuard peers has reached the limit.&lt;br/&gt;-43203  -  The WireGuard peer does not exist.&lt;br/&gt;-43205  -  The public key of the WireGuard peer for the same interface already exists.&lt;br/&gt;-43207  -  Endpoint and Endpoint Port need to be filled in at the same time or both left blank.
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param id Peer ID (required)
     * @param wireguardPeerOpenApiVo  (optional)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Modify an existing wireguard peer", nickname = "modifyPeer", notes = "Modify an existing wireguard peer.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify<br/><br/>The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): <br/>-33006  -  This name already exists in this site.<br/>-43202  -  The number of WireGuard peers has reached the limit.<br/>-43203  -  The WireGuard peer does not exist.<br/>-43205  -  The public key of the WireGuard peer for the same interface already exists.<br/>-43207  -  Endpoint and Endpoint Port need to be filled in at the same time or both left blank.", response = OperationResponseWithoutResult.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseWithoutResult.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguard-peers/{id}",
        produces = "*/*", 
        consumes = "application/json",
        method = RequestMethod.PUT)
    ResponseEntity<OperationResponseWithoutResult> modifyPeer(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = "Peer ID",required=true) @PathVariable("id") String id,@ApiParam(value = ""  )  @Valid @RequestBody(required = false) WireguardPeerOpenApiVo wireguardPeerOpenApiVo);


    /**
     * PUT /openapi/v1/{omadacId}/sites/{siteId}/vpn/wireguards/{id} : Modify an existing wireguard
     * Modify an existing wireguard.&lt;br/&gt;&lt;br/&gt;The interface requires one of the permissions: &lt;br/&gt;Site Settings Manager Modify&lt;br/&gt;&lt;br/&gt;The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): &lt;br/&gt;-33006  -  This name already exists in this site.&lt;br/&gt;-43201  -  The WireGuard entry does not exist.&lt;br/&gt;-43204  -  The port has been used.
     *
     * @param omadacId Omada ID (required)
     * @param siteId Site ID (required)
     * @param id Wireguard ID (required)
     * @param wireguardOpenApiVo  (optional)
     * @return OK (status code 200)
     */
    @ApiOperation(value = "Modify an existing wireguard", nickname = "modifyWireguard", notes = "Modify an existing wireguard.<br/><br/>The interface requires one of the permissions: <br/>Site Settings Manager Modify<br/><br/>The possible error code for the interface in the returned body is one of the following error codes (non generic error codes): <br/>-33006  -  This name already exists in this site.<br/>-43201  -  The WireGuard entry does not exist.<br/>-43204  -  The port has been used.", response = OperationResponseWithoutResult.class, tags={ "Omada/Wireguard VPN","Wireguard VPN", })
    @ApiResponses(value = { 
        @ApiResponse(code = 200, message = "OK", response = OperationResponseWithoutResult.class) })
    @RequestMapping(value = "/openapi/v1/${omada.omadac-id}/sites/{siteId}/vpn/wireguards/{id}",
        produces = "*/*", 
        consumes = "application/json",
        method = RequestMethod.PUT)
    ResponseEntity<OperationResponseWithoutResult> modifyWireguard(@ApiParam(value = "Site ID",required=true) @PathVariable("siteId") String siteId,@ApiParam(value = "Wireguard ID",required=true) @PathVariable("id") String id,@ApiParam(value = ""  )  @Valid @RequestBody(required = false) WireguardOpenApiVo wireguardOpenApiVo);

}
