handlers

package
v0.0.0-...-1b12299 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 30, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateMeditation

func CreateMeditation(w http.ResponseWriter, r *http.Request)

Handler for creating a new meditation

func DeleteMeditation

func DeleteMeditation(w http.ResponseWriter, r *http.Request)

Handler for deleting a meditation by ID

func GetMeditationByID

func GetMeditationByID(w http.ResponseWriter, r *http.Request)

Handler for getting a specific meditation by ID

func GetMeditations

func GetMeditations(w http.ResponseWriter, r *http.Request)

Handler for getting all meditations

func UpdateMeditation

func UpdateMeditation(w http.ResponseWriter, r *http.Request)

Handler for updating an existing meditation

Types

type Meditation

type Meditation struct {
	ID      string `json:"id"`
	Title   string `json:"title"`
	Content string `json:"content"`
}

Sample data structure for a meditation

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL