Skip to content

Commit

Permalink
Fixup swagger docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ross-spencer committed Nov 19, 2024
1 parent 165170f commit 839336a
Showing 1 changed file with 3 additions and 15 deletions.
18 changes: 3 additions & 15 deletions src/itn_api/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,33 +192,21 @@ async def get_itn_aliases_and_staking(
async def get_itn_aliases_and_staking_csv(
min_stake: int = 500000, sort: str = "stake"
) -> str:
"""Return ITN aliases and stake values.
Optionally: enter a license number, e.g. `#001` to see the details
of a specific license.
"""
"""Return ITN aliases and stake values."""
return reports.get_all_license_holders_csv(app, min_stake, sort)


@app.get("/participants", tags=[TAG_HTMX], response_class=HTMLResponse)
async def get_itn_participants() -> str:
"""Return ITN aliases and stake values.
Optionally: enter a license number, e.g. `#001` to see the details
of a specific license.
"""
"""Return ITN aliases and licenses."""
all_holders = reports.get_all_license_holders(app, 0, None)
htmx = htm_helpers.aliases_to_html(all_holders)
return htmx.strip()


@app.get("/online_collectors", tags=[TAG_HTMX], response_class=HTMLResponse)
async def get_online_collectors() -> str:
"""Return ITN aliases and stake values.
Optionally: enter a license number, e.g. `#001` to see the details
of a specific license.
"""
"""Return ITN aliases and collector counts."""
participants_count_total = app.state.connection.execute(
"select address, count(*) as count from data_points group by address order by count desc;"
)
Expand Down

0 comments on commit 839336a

Please sign in to comment.