SiteKaraokeController
struct SiteKaraokeController : SiteControllerUtilsPages for displaying info on Karaoke Songs. This is all based on 2 kinds of data on the API:
- KaraokeSongs, a static list of all ~25000 songs in the jukebox.
- Performances. Authorized users can create log entries noting that one or more performers sang a KaraokeSong.
- 
                  
                  DeclarationSwift func registerRoutes(_ app: Application) throws
- 
                  karaokePageHandler(_:Asynchronous) GET /karaoke URL Query Parameters - ?search=STRING- returns song library results where the artist OR song title matches the given string. If a single letter or %23 is sent, it will return songs where the artist matches the letter, or starts with a number.
- ?favorite=TRUE- Only return songs that have been favorited by current user.
- ?start=INT- Offset from start of results set
- ?limit=INT- the maximum number of songs to retrieve: 1-200, default is 50.
 With no search query, returns a page with a search form and a list of the 10 most recently performed songs. With a search parameter, returns a list of matching songs from the catalog. The underlying idea is that it’s not helpful to let the user browse all 25000+ songs. DeclarationSwift func karaokePageHandler(_ req: Request) async throws -> View
- 
                  addFavoriteSong(_:Asynchronous) DeclarationSwift func addFavoriteSong(_ req: Request) async throws -> HTTPStatus
- 
                  removeFavoriteSong(_:Asynchronous) DeclarationSwift func removeFavoriteSong(_ req: Request) async throws -> HTTPStatus
- 
                  songPerformanceLogEntryPageHandler(_:Asynchronous) DeclarationSwift func songPerformanceLogEntryPageHandler(_ req: Request) async throws -> View
- 
                  songPerformanceLogEntryPostHandler(_:Asynchronous) DeclarationSwift func songPerformanceLogEntryPostHandler(_ req: Request) async throws -> HTTPStatus
 View on GitHub
            View on GitHub
           SiteKaraokeController Structure Reference
      SiteKaraokeController Structure Reference