From a107406edd5ab413f1264d50db4087f9b92af457 Mon Sep 17 00:00:00 2001 From: Theodlz Date: Wed, 23 Oct 2024 09:48:44 -0700 Subject: [PATCH 1/2] add summary key to the docs, set the list of servers to the correct URLs --- extensions/skyportal/skyportal/handlers/api/alert.py | 7 +++++++ extensions/skyportal/skyportal/handlers/api/archive.py | 4 ++++ extensions/skyportal/skyportal/handlers/api/db_stats.py | 1 + .../skyportal/skyportal/handlers/api/kowalski_filter.py | 4 ++++ fritz.defaults.yaml | 7 +++++++ 5 files changed, 23 insertions(+) diff --git a/extensions/skyportal/skyportal/handlers/api/alert.py b/extensions/skyportal/skyportal/handlers/api/alert.py index eb3392c6..dae5f9a1 100644 --- a/extensions/skyportal/skyportal/handlers/api/alert.py +++ b/extensions/skyportal/skyportal/handlers/api/alert.py @@ -834,6 +834,7 @@ async def get(self, object_id: str = None): """ --- single: + summary: Retrieve an object from Kowalski by objectId description: Retrieve an object from Kowalski by objectId tags: - alerts @@ -873,6 +874,7 @@ async def get(self, object_id: str = None): application/json: schema: Error multiple: + summary: Retrieve objects from Kowalski by objectId and or position description: Retrieve objects from Kowalski by objectId and or position tags: - alerts @@ -1040,6 +1042,7 @@ async def get(self, object_id: str = None): def post(self, objectId): """ --- + summary: Save ZTF objectId from Kowalski as source in SkyPortal description: Save ZTF objectId from Kowalski as source in SkyPortal tags: - alerts @@ -1126,6 +1129,7 @@ def get(self, object_id: str = None): """ --- single: + summary: Retrieve aux data for an objectId from Kowalski description: Retrieve aux data for an objectId from Kowalski tags: - alerts @@ -1400,6 +1404,7 @@ async def get(self, object_id: str = None): """ --- summary: Serve alert cutout as fits or png + description: Serve alert cutout as fits or png tags: - alerts - kowalski @@ -1609,6 +1614,7 @@ async def get(self, object_id: str = None): """ --- summary: Serve alert cutouts as a triplet + description: Serve alert cutouts as a triplet tags: - alerts - kowalski @@ -1767,6 +1773,7 @@ async def get(self, alert_stream="ZTF"): """ --- summary: Get number of alerts in a time range + description: Get number of alerts in a time range tags: - alerts - kowalski diff --git a/extensions/skyportal/skyportal/handlers/api/archive.py b/extensions/skyportal/skyportal/handlers/api/archive.py index d778f742..02fcaa8e 100644 --- a/extensions/skyportal/skyportal/handlers/api/archive.py +++ b/extensions/skyportal/skyportal/handlers/api/archive.py @@ -148,6 +148,7 @@ def get(self): """ --- summary: Retrieve available catalog names from Kowalski/Gloria/Melman + description: Retrieve available catalog names from Kowalski/Gloria/Melman tags: - archive - kowalski @@ -187,6 +188,7 @@ def get(self): """ --- summary: Retrieve data from available catalogs on Kowalski/Gloria/Melman by position + description: Retrieve data from available catalogs on Kowalski/Gloria/Melman by position tags: - archive - kowalski @@ -364,6 +366,7 @@ def post(self): """ --- summary: Retrieve archival SCoPe features from Kowalski/Gloria/Melman by position, post as annotation + description: Retrieve archival SCoPe features from Kowalski/Gloria/Melman by position, post as annotation tags: - features - kowalski @@ -626,6 +629,7 @@ def get(self, lc_id=None): """ --- summary: Retrieve archival light curve data from Kowalski/Gloria by position + description: Retrieve archival light curve data from Kowalski/Gloria by position tags: - archive - kowalski diff --git a/extensions/skyportal/skyportal/handlers/api/db_stats.py b/extensions/skyportal/skyportal/handlers/api/db_stats.py index a5eb0751..ae3a5f3c 100644 --- a/extensions/skyportal/skyportal/handlers/api/db_stats.py +++ b/extensions/skyportal/skyportal/handlers/api/db_stats.py @@ -54,6 +54,7 @@ class StatsHandler(BaseHandler): def get(self): """ --- + summary: Retrieve basic DB statistics description: Retrieve basic DB statistics tags: - system_info diff --git a/extensions/skyportal/skyportal/handlers/api/kowalski_filter.py b/extensions/skyportal/skyportal/handlers/api/kowalski_filter.py index e17eb27a..5eb6c697 100644 --- a/extensions/skyportal/skyportal/handlers/api/kowalski_filter.py +++ b/extensions/skyportal/skyportal/handlers/api/kowalski_filter.py @@ -34,6 +34,7 @@ def get(self, filter_id): """ --- single: + summary: Retrieve a filter as stored on Kowalski description: Retrieve a filter as stored on Kowalski tags: - filters @@ -96,6 +97,7 @@ def get(self, filter_id): def post(self, filter_id): """ --- + summary: POST a new filter version description: POST a new filter version. tags: - filters @@ -176,6 +178,7 @@ def post(self, filter_id): def patch(self, filter_id): """ --- + summary: Update a filter on Kowalski description: Update a filter on Kowalski tags: - filters @@ -411,6 +414,7 @@ def patch(self, filter_id): def delete(self, filter_id): """ --- + summary: Delete a filter on Kowalski description: Delete a filter on Kowalski tags: - filters diff --git a/fritz.defaults.yaml b/fritz.defaults.yaml index 9ab74d09..3c8d6785 100644 --- a/fritz.defaults.yaml +++ b/fritz.defaults.yaml @@ -2011,3 +2011,10 @@ kowalski: pgir: True wntr: True turbo: True + +docs: + servers: + - url: https://fritz.science + description: Production server + - url: https://preview.fritz.science + description: Test server From 0f8c3ddfe71267508f3c72ec1fdc6e190055cf45 Mon Sep 17 00:00:00 2001 From: Theodlz Date: Wed, 23 Oct 2024 09:54:32 -0700 Subject: [PATCH 2/2] shorten some of the summaries --- extensions/skyportal/skyportal/handlers/api/alert.py | 2 +- extensions/skyportal/skyportal/handlers/api/archive.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/extensions/skyportal/skyportal/handlers/api/alert.py b/extensions/skyportal/skyportal/handlers/api/alert.py index dae5f9a1..cbf0876e 100644 --- a/extensions/skyportal/skyportal/handlers/api/alert.py +++ b/extensions/skyportal/skyportal/handlers/api/alert.py @@ -874,7 +874,7 @@ async def get(self, object_id: str = None): application/json: schema: Error multiple: - summary: Retrieve objects from Kowalski by objectId and or position + summary: Retrieve objects from Kowalski by objectId/position description: Retrieve objects from Kowalski by objectId and or position tags: - alerts diff --git a/extensions/skyportal/skyportal/handlers/api/archive.py b/extensions/skyportal/skyportal/handlers/api/archive.py index 02fcaa8e..55d644e3 100644 --- a/extensions/skyportal/skyportal/handlers/api/archive.py +++ b/extensions/skyportal/skyportal/handlers/api/archive.py @@ -147,7 +147,7 @@ class ArchiveCatalogsHandler(BaseHandler): def get(self): """ --- - summary: Retrieve available catalog names from Kowalski/Gloria/Melman + summary: Retrieve available catalog names from Kowalski description: Retrieve available catalog names from Kowalski/Gloria/Melman tags: - archive @@ -187,7 +187,7 @@ class CrossMatchHandler(BaseHandler): def get(self): """ --- - summary: Retrieve data from available catalogs on Kowalski/Gloria/Melman by position + summary: Retrieve data from available catalogs in Kowalski by position description: Retrieve data from available catalogs on Kowalski/Gloria/Melman by position tags: - archive @@ -365,7 +365,7 @@ class ScopeFeaturesHandler(BaseHandler): def post(self): """ --- - summary: Retrieve archival SCoPe features from Kowalski/Gloria/Melman by position, post as annotation + summary: Retrieve archival SCoPe features by position, post as annotation description: Retrieve archival SCoPe features from Kowalski/Gloria/Melman by position, post as annotation tags: - features @@ -628,7 +628,7 @@ class ArchiveHandler(BaseHandler): def get(self, lc_id=None): """ --- - summary: Retrieve archival light curve data from Kowalski/Gloria by position + summary: Retrieve archival light curve data by position description: Retrieve archival light curve data from Kowalski/Gloria by position tags: - archive