feat: Introduce external API endpoints with API key authentication and re-enable Whisper transcription and Ollama summarization.

This commit is contained in:
2026-01-21 16:22:12 -03:00
parent 1c55cc4ae7
commit 00ae5ac16b
7 changed files with 238 additions and 101 deletions
+7
View File
@@ -3,6 +3,7 @@ pub mod exporter;
mod handlers;
mod handlers_branding;
mod webhooks;
mod external_handlers;
use axum::{
Router,
@@ -172,8 +173,14 @@ async fn main() {
common::middleware::org_extractor_middleware,
));
let api_routes = Router::new()
.route("/v1/courses", post(external_handlers::create_course_external))
.route("/v1/courses/{id}", get(external_handlers::get_course_external))
.route("/v1/lessons/{id}/transcribe", post(external_handlers::trigger_transcription_external));
// Rutas públicas que no requieren autenticación
let public_routes = Router::new()
.nest("/api/external", api_routes)
.route("/auth/register", post(handlers::register))
.route("/auth/login", post(handlers::login))
.route("/auth/sso/login/{org_id}", get(handlers::sso_login_init))