fix: Move music vibe from tags to prompt for Sonauto API

Sonauto only accepts specific predefined tags. The custom frontend
music vibes (Hip-Hop, Boy Band, etc.) were being rejected with 422.

Now using fixed tags ["love song", "valentine"] and including the
music vibe in the prompt text instead.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
michael 2026-02-02 08:43:10 -06:00
parent a570ac657f
commit 56bc3d6059

View file

@ -227,11 +227,12 @@ def send_to_sonauto(self, session_id: str):
return {"error": "not_found"}
payload = {
"tags": [submission.music_vibe],
"tags": ["love song", "valentine"],
"prompt": (
f"Create a heartfelt Valentine's Day love song celebrating the special bond "
f"between {submission.owner_name} and their beloved {submission.pet_type} "
f"{submission.pet_name}. Make it warm, genuine, and mention both names in the lyrics."
f"Create a heartfelt Valentine's Day love song in a {submission.music_vibe} style "
f"celebrating the special bond between {submission.owner_name} and their beloved "
f"{submission.pet_type} {submission.pet_name}. Make it warm, genuine, and mention "
f"both names in the lyrics."
),
"instrumental": False,
"output_format": "mp3",