diff --git a/src/pydiscourse/client.py b/src/pydiscourse/client.py index c31e34a..69e4a61 100644 --- a/src/pydiscourse/client.py +++ b/src/pydiscourse/client.py @@ -1500,6 +1500,12 @@ def notifications(self, category_id, **kwargs): """ return self._post(f"/category/{category_id}/notifications", **kwargs) + def about(self): + """ + Get site info + """ + return self._get("/about.json") + def _get(self, path, override_request_kwargs=None, **kwargs): """ diff --git a/tests/test_client.py b/tests/test_client.py index 08f7df7..530aa09 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -205,3 +205,10 @@ def test_grant_badge_to(self, discourse_client, discourse_request): assert request_payload["username"] == ["username"] assert request_payload["badge_id"] == ["1"] + + +class TestAbout: + def test_about(self, discourse_client, discourse_request): + request = discourse_request("get", "/about.json") + discourse_client.about() + assert request.called_once