Hayden Hargreaves b8c9fc469e (FEAT): Deletion is implemented!
This should be a nice test! Hopefully other users cannot delete my
recipes. Though they're setup to soft delete.
2026-01-30 23:44:21 -07:00

19 lines
636 B
Go

package domain
import (
"github.com/gin-gonic/gin"
)
type RecipeService interface {
CreateRecipe(ctx *gin.Context) (*Recipe, error)
DeleteRecipe(userId, recipeId int) error
GetRecipe(id int, userId *int) (*Recipe, error)
SearchRecipes(filters SearchFilters, userId *int, favorites bool) ([]Recipe, error)
GetUserRecipes(userId int) ([]Recipe, error)
GetUserFavoriteRecipes(userId int) ([]Recipe, error)
GetUserViewedRecipes(userId, limit int) ([]Recipe, error)
GetUserMadeRecipes(userId, limit int) ([]Recipe, error)
GetRecipeOfTheWeek(userId *int) (*Recipe, error)
IsRecipeOwner(userId *int, recipeId int) (bool, error)
}