Skip to content

Commit

Permalink
use the correct endpoint for urgency detect
Browse files Browse the repository at this point in the history
  • Loading branch information
Hlamallama committed Sep 5, 2024
1 parent 2bc4c18 commit f20b6f4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions aaq/tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def test_search_function(self):
fakeAaqUdV2Api = FakeAaqUdV2Api()
responses.add_callback(
responses.POST,
"http://aaq_v2/api/check-urgency",
"http://aaq_v2/api/urgency-detect",
callback=fakeAaqUdV2Api.post_urgency_detect_return_true,
content_type="application/json",
)
Expand Down Expand Up @@ -80,7 +80,7 @@ def test_urgency_check(self):
fakeAaqUdV2Api = FakeAaqUdV2Api()
responses.add_callback(
responses.POST,
"http://aaq_v2/api/check-urgency",
"http://aaq_v2/api/urgency-detect",
callback=fakeAaqUdV2Api.post_urgency_detect_return_true,
content_type="application/json",
)
Expand Down
4 changes: 2 additions & 2 deletions aaq/tests/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def test_search(self):
fakeAaqUdV2Api = FakeAaqUdV2Api()
responses.add_callback(
responses.POST,
"http://aaq_v2/api/check-urgency",
"http://aaq_v2/api/urgency-detect",
callback=fakeAaqUdV2Api.post_urgency_detect_return_true,
content_type="application/json",
)
Expand Down Expand Up @@ -446,7 +446,7 @@ def test_request(self):
fakeAaqUdV2Api = FakeAaqUdV2Api()
responses.add_callback(
responses.POST,
"http://aaq_v2/check-urgency",
"http://aaq_v2/urgency-detect",
callback=fakeAaqUdV2Api.post_urgency_detect_return_true,
content_type="application/json",
)
Expand Down
2 changes: 1 addition & 1 deletion aaq/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@


def check_urgency_v2(message_text):
url = urllib.parse.urljoin(settings.AAQ_V2_API_URL, "api/check-urgency")
url = urllib.parse.urljoin(settings.AAQ_V2_API_URL, "api/urgency-detect")
headers = {
"Authorization": f"Bearer {settings.AAQ_V2_AUTH}",
"Content-Type": "application/json",
Expand Down

0 comments on commit f20b6f4

Please sign in to comment.