generated from fahricansecer/boilerplate-fe
This commit is contained in:
@@ -58,6 +58,16 @@ export const voiceboxApi = {
|
||||
}
|
||||
},
|
||||
|
||||
deleteHistory: async (id: string) => {
|
||||
try {
|
||||
const response = await clientMap.core.delete(`/voicebox/history/${id}`);
|
||||
return response.data;
|
||||
} catch (error) {
|
||||
console.error(`Error deleting VoiceBox history for ${id}:`, error);
|
||||
throw error;
|
||||
}
|
||||
},
|
||||
|
||||
getAudioUrl: (generationId: string) => {
|
||||
// API endpoint for `<audio src="...">` tag
|
||||
return `${process.env.NEXT_PUBLIC_CORE_API_URL || 'http://localhost:3000/api'}/voicebox/audio/${generationId}`;
|
||||
|
||||
Reference in New Issue
Block a user