ksvmuralidhar commited on
Commit
667bfc3
1 Parent(s): 72ffb46

Update api.py

Browse files
Files changed (1) hide show
  1. api.py +2 -6
api.py CHANGED
@@ -80,11 +80,7 @@ async def scrape_urls(urls):
80
  return scraped_texts, scrape_errors
81
 
82
 
83
- description = """
84
- API to generate summaries of news articles from their URLs.
85
- """
86
-
87
-
88
  app = FastAPI(title='News Summarizer API',
89
  description=description,
90
  summary="News article summary generator",
@@ -141,7 +137,7 @@ def authenticate_key(api_key: str):
141
  raise NewsSummarizerAPIAuthenticationError("Authentication error: Invalid API key.")
142
 
143
 
144
- @app.post("/generate_summary/", response_model=List[SuccessfulResponse],
145
  responses={
146
  401: {"model": AuthenticationError, "description": "Authentication Error"},
147
  500: {"model": SummaryError, "description": "Summarizer Error"}
 
80
  return scraped_texts, scrape_errors
81
 
82
 
83
+ description = "API to generate summaries of news articles from their URLs."
 
 
 
 
84
  app = FastAPI(title='News Summarizer API',
85
  description=description,
86
  summary="News article summary generator",
 
137
  raise NewsSummarizerAPIAuthenticationError("Authentication error: Invalid API key.")
138
 
139
 
140
+ @app.post("/generate_summary/", tags=None, response_model=List[SuccessfulResponse],
141
  responses={
142
  401: {"model": AuthenticationError, "description": "Authentication Error"},
143
  500: {"model": SummaryError, "description": "Summarizer Error"}