diff --git a/API/Controllers/NotificationConnectorController.cs b/API/Controllers/NotificationConnectorController.cs index a242e68..c0100e0 100644 --- a/API/Controllers/NotificationConnectorController.cs +++ b/API/Controllers/NotificationConnectorController.cs @@ -134,32 +134,6 @@ public class NotificationConnectorController(NotificationsContext context, ILog return CreateConnector(ntfyConnector); } - /// - /// Creates a new Lunasea-Notification-Connector - /// - /// https://docs.lunasea.app/lunasea/notifications/custom-notifications for id. Either device/:device_id or user/:user_id - /// ID of new connector - /// - /// A NotificationConnector with name already exists - /// Error during Database Operation - [HttpPut("Lunasea")] - [ProducesResponseType(Status201Created, "application/json")] - [ProducesResponseType(Status400BadRequest)] - [ProducesResponseType(Status409Conflict)] - [ProducesResponseType(Status500InternalServerError, "text/plain")] - public IActionResult CreateLunaseaConnector([FromBody]LunaseaRecord lunaseaRecord) - { - if(!lunaseaRecord.Validate()) - return BadRequest(); - - NotificationConnector lunaseaConnector = new (TokenGen.CreateToken("Lunasea"), - $"https://notify.lunasea.app/v1/custom/{lunaseaRecord.id}", - new Dictionary(), - "POST", - "{\"title\": \"%title\", \"body\": \"%text\"}"); - return CreateConnector(lunaseaConnector); - } - /// /// Creates a new Pushover-Notification-Connector ///