Skip to content

Commit

Permalink
EKIRJASTO-131 Add link to auth doc
Browse files Browse the repository at this point in the history
  • Loading branch information
natlibfi-kaisa committed Dec 19, 2024
1 parent 87490e0 commit 775ccac
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions api/authenticator.py
Original file line number Diff line number Diff line change
Expand Up @@ -697,6 +697,9 @@ def create_authentication_document(self) -> str:
loans_url = url_for(
"active_loans", _external=True, library_short_name=self.library_short_name
)
selected_books_url = url_for(
"selected_books", _external=True, library_short_name=self.library_short_name
)
profile_url = url_for(
"patron_profile", _external=True, library_short_name=self.library_short_name
)
Expand All @@ -711,6 +714,13 @@ def create_authentication_document(self) -> str:
type=OPDSFeed.ACQUISITION_FEED_TYPE,
)
)
links.append(
dict(
rel="http://opds-spec.org/shelf",
href=selected_books_url,
type=OPDSFeed.ACQUISITION_FEED_TYPE,
)
)
links.append(
dict(
rel=ProfileController.LINK_RELATION,
Expand Down

0 comments on commit 775ccac

Please sign in to comment.