From 961d2db13b8c36a5d357a58258f7fe58201a0d48 Mon Sep 17 00:00:00 2001 From: Paige Gulley Date: Tue, 31 Oct 2023 12:34:29 -0400 Subject: [PATCH] First commit --- README.md | 2 +- {waybacknews => mcnews}/__init__.py | 0 {waybacknews => mcnews}/searchapi.py | 3 ++- {waybacknews => mcnews}/tests/__init__.py | 0 {waybacknews => mcnews}/tests/test_util.py | 0 {waybacknews => mcnews}/tests/test_waybacknews.py | 0 {waybacknews => mcnews}/util.py | 0 7 files changed, 3 insertions(+), 2 deletions(-) rename {waybacknews => mcnews}/__init__.py (100%) rename {waybacknews => mcnews}/searchapi.py (98%) rename {waybacknews => mcnews}/tests/__init__.py (100%) rename {waybacknews => mcnews}/tests/test_util.py (100%) rename {waybacknews => mcnews}/tests/test_waybacknews.py (100%) rename {waybacknews => mcnews}/util.py (100%) diff --git a/README.md b/README.md index df891f6..03a31c5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -Wayback Machine News Archive Client +Mediacloud News Archive Client =================================== 🚧 _under construction_ 🚧 diff --git a/waybacknews/__init__.py b/mcnews/__init__.py similarity index 100% rename from waybacknews/__init__.py rename to mcnews/__init__.py diff --git a/waybacknews/searchapi.py b/mcnews/searchapi.py similarity index 98% rename from waybacknews/searchapi.py rename to mcnews/searchapi.py index 0ad22c1..e203fb9 100644 --- a/waybacknews/searchapi.py +++ b/mcnews/searchapi.py @@ -8,9 +8,10 @@ VERSION = "v1" # the API access URL is versioned for future compatability and maintenance + class SearchApiClient: - API_BASE_URL = "https://wayback-api.archive.org/colsearch/{}/".format(VERSION) + API_BASE_URL = "https://news-search-api.tarbell.mediacloud.org/{}/".format(VERSION) TIMEOUT_SECS = 30 # constants used when requesting top terms diff --git a/waybacknews/tests/__init__.py b/mcnews/tests/__init__.py similarity index 100% rename from waybacknews/tests/__init__.py rename to mcnews/tests/__init__.py diff --git a/waybacknews/tests/test_util.py b/mcnews/tests/test_util.py similarity index 100% rename from waybacknews/tests/test_util.py rename to mcnews/tests/test_util.py diff --git a/waybacknews/tests/test_waybacknews.py b/mcnews/tests/test_waybacknews.py similarity index 100% rename from waybacknews/tests/test_waybacknews.py rename to mcnews/tests/test_waybacknews.py diff --git a/waybacknews/util.py b/mcnews/util.py similarity index 100% rename from waybacknews/util.py rename to mcnews/util.py