dify/api/controllers/web/__init__.py

37 lines
738 B
Python
Raw Normal View History

2023-05-15 08:51:32 +08:00
from flask import Blueprint
from flask_restx import Namespace
2023-05-15 08:51:32 +08:00
from libs.external_api import ExternalApi
bp = Blueprint("web", __name__, url_prefix="/api")
2023-05-15 08:51:32 +08:00
api = ExternalApi(
bp,
version="1.0",
title="Web API",
description="Public APIs for web applications including file uploads, chat interactions, and app management",
doc="/docs", # Enable Swagger UI at /api/docs
)
# Create namespace
web_ns = Namespace("web", description="Web application API operations", path="/")
2023-05-15 08:51:32 +08:00
2025-06-09 17:19:53 +09:00
from . import (
app,
audio,
completion,
conversation,
feature,
files,
2025-06-09 17:19:53 +09:00
forgot_password,
login,
message,
passport,
remote_files,
2025-06-09 17:19:53 +09:00
saved_message,
site,
workflow,
)
api.add_namespace(web_ns)