MCPcopy Index your code
hub / github.com/fastapi/fastapi / read_own_items

Function read_own_items

docs_src/security/tutorial005_an_py310.py:174–177  ·  view source on GitHub ↗
(
    current_user: Annotated[User, Security(get_current_active_user, scopes=["items"])],
)

Source from the content-addressed store, hash-verified

172
173@app.get("/users/me/items/")
174async def read_own_items(
175 current_user: Annotated[User, Security(get_current_active_user, scopes=["items"])],
176):
177 return [{"item_id": "Foo", "owner": current_user.username}]
178
179
180@app.get("/status/")

Callers

nothing calls this directly

Calls 1

SecurityClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…