Skip to content

Commit cd21570

Browse files
committed
added route for selecting style preset
1 parent e97fd85 commit cd21570

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

invokeai/app/api/routers/style_presets.py

+14
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,20 @@ async def get_style_preset(
5353
return StylePresetRecordWithImage(image=image, **style_preset.model_dump())
5454
except StylePresetNotFoundError:
5555
raise HTTPException(status_code=404, detail="Style preset not found")
56+
57+
@style_presets_router.post(
58+
"/i/{style_preset_id}",
59+
operation_id="set_style_preset",
60+
responses={
61+
200: {"model": StylePresetRecordWithImage},
62+
},
63+
)
64+
async def select_style_preset(
65+
style_preset_id: str = Path(description="The style preset to select"),
66+
) -> None:
67+
"""Selects a style preset, this will be used for saving recently used style presets"""
68+
69+
return
5670

5771

5872
@style_presets_router.patch(

0 commit comments

Comments
 (0)