bounswe / bounswe2020group9

0 stars 4 forks source link

News API implementation #48

Closed ibrahimorhan closed 4 years ago

ibrahimorhan commented 4 years ago

Implementation of News API until 27.05.2020, 23.00

ocebenzer commented 4 years ago

New branch: API_Development_Favorites Added 3 routes: "/api", "/api/add", "/api/remove" These routes can view, add or remove a custom json file They can handle in order: GET, POST, DELETE requests Is there a way to combine them into one route: "/api" without causing a problem? Maybe something like if (request == "GET") elif (request =="POST") etc..

ibrahimorhan commented 4 years ago

New branch "newsAPI" is created

firatbulut19 commented 4 years ago

Added 2 routes: "/news", "/newsNasa". Both handle GET requests. "/news" returns a json file containing the most popular news articles about a certain topic. Topic and origin country are specified by the user. "/newsNasa" returns a json file containing the most popular news articles that contain the keyword [owner of today's Astronomy picture from NASA API]

ibrahimorhan commented 4 years ago

I have carried class that Ömer implemented to "newsAPI" branch. Also added getMaxDate function and carried "newsNasa" on the new commit. However app.py and bazaar.py should be updated

ibrahimorhan commented 4 years ago

"Dandelion API" added for the entity extraction of apod explanation. Also "sortByConfidence method added to utils.py

ibrahimorhan commented 4 years ago

"/api/news/nasa" route added. "get_news" call separated and "get_nasa_news" added. Case of no article should be handled.

ibrahimorhan commented 4 years ago

"newsAPI" branch is merged with "API_Development" branch pull request

firatbulut19 commented 4 years ago

New branch news_unit_test is opened. All test cases for News API will be written here.

ibrahimorhan commented 4 years ago

test_early_date_nasa test_early_date_news test_input_format_nasa test_input_format_news test_output_format_nasa test_output_format_news Tests are added. also checkInputFormat added to utils.py to " news_unit_test" branch

firatbulut19 commented 4 years ago

Added test cases: test_recent_date_news test_recent_date_nasa test_forward_date_news test_forward_date_nasa Also made some minor adjustments on utils.py and api_calls.py.

ibrahimorhan commented 4 years ago

I have solved the problem which api call returns null urlToImage.

sadiuysal commented 4 years ago

Implementation of News API is done.