@learnorama/mozaik-sdk 0.9.0-staging.35.1 → 0.9.1-staging.36.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/README.md +107 -0
  2. package/dist/api/account.d.ts +3 -1
  3. package/dist/api/account.js +2 -0
  4. package/dist/api/account.js.map +1 -1
  5. package/dist/api/admin-catalogue.js.map +1 -1
  6. package/dist/api/admin-consumption.d.ts +1 -1
  7. package/dist/api/admin-consumption.js.map +1 -1
  8. package/dist/api/admin-desk.d.ts +1 -1
  9. package/dist/api/admin-desk.js.map +1 -1
  10. package/dist/api/admin-licenses.d.ts +1 -1
  11. package/dist/api/admin-licenses.js.map +1 -1
  12. package/dist/api/admin-patrons.js.map +1 -1
  13. package/dist/api/admin-reviews.js.map +1 -1
  14. package/dist/api/admin-roles.d.ts +1 -1
  15. package/dist/api/admin-roles.js.map +1 -1
  16. package/dist/api/admin-support.d.ts +1 -1
  17. package/dist/api/admin-support.js.map +1 -1
  18. package/dist/api/admin-tenants.js.map +1 -1
  19. package/dist/api/admin-tutoring.d.ts +1 -1
  20. package/dist/api/admin-tutoring.js.map +1 -1
  21. package/dist/api/auth.d.ts +1 -1
  22. package/dist/api/auth.js.map +1 -1
  23. package/dist/api/biblio-catalogue.d.ts +11 -1
  24. package/dist/api/biblio-catalogue.js +23 -1
  25. package/dist/api/biblio-catalogue.js.map +1 -1
  26. package/dist/api/biblio-home.d.ts +6 -1
  27. package/dist/api/biblio-home.js +5 -0
  28. package/dist/api/biblio-home.js.map +1 -1
  29. package/dist/api/biblio-library.d.ts +9 -6
  30. package/dist/api/biblio-library.js +22 -9
  31. package/dist/api/biblio-library.js.map +1 -1
  32. package/dist/api/biblio-nextory.d.ts +1 -1
  33. package/dist/api/biblio-nextory.js.map +1 -1
  34. package/dist/api/biblio-press.d.ts +25 -32
  35. package/dist/api/biblio-press.js +45 -52
  36. package/dist/api/biblio-press.js.map +1 -1
  37. package/dist/api/biblio-search.js.map +1 -1
  38. package/dist/api/biblio-telemetry.d.ts +1 -1
  39. package/dist/api/biblio-telemetry.js.map +1 -1
  40. package/dist/api/consumption.d.ts +1 -1
  41. package/dist/api/consumption.js.map +1 -1
  42. package/dist/api/cvs-app.js.map +1 -1
  43. package/dist/api/cvs-documents.d.ts +1 -1
  44. package/dist/api/cvs-documents.js.map +1 -1
  45. package/dist/api/cvs-favorites.d.ts +1 -1
  46. package/dist/api/cvs-favorites.js.map +1 -1
  47. package/dist/api/cvs-ils.d.ts +1 -1
  48. package/dist/api/cvs-ils.js.map +1 -1
  49. package/dist/api/cvs-loans.d.ts +1 -1
  50. package/dist/api/cvs-loans.js.map +1 -1
  51. package/dist/api/cvs-payments.js.map +1 -1
  52. package/dist/api/cvs-streaming.js.map +1 -1
  53. package/dist/api/index.d.ts +3 -3
  54. package/dist/api/index.js +3 -3
  55. package/dist/api/partner-catalogue.d.ts +1 -1
  56. package/dist/api/partner-catalogue.js.map +1 -1
  57. package/dist/api/partner-reader.d.ts +1 -1
  58. package/dist/api/partner-reader.js.map +1 -1
  59. package/dist/api/profiles.d.ts +1 -1
  60. package/dist/api/profiles.js.map +1 -1
  61. package/dist/api/search.d.ts +1 -1
  62. package/dist/api/search.js.map +1 -1
  63. package/dist/api/tutoring-catalogue.d.ts +1 -1
  64. package/dist/api/tutoring-catalogue.js.map +1 -1
  65. package/dist/api/tutoring-chat.d.ts +1 -1
  66. package/dist/api/tutoring-chat.js.map +1 -1
  67. package/dist/api/tutoring-dispatch.js.map +1 -1
  68. package/dist/api/tutoring-practitioner.js.map +1 -1
  69. package/dist/api/tutoring-requests.d.ts +1 -1
  70. package/dist/api/tutoring-requests.js.map +1 -1
  71. package/dist/chunks/client2.d.ts +1 -1
  72. package/dist/chunks/index.d.ts +340 -321
  73. package/dist/index.d.ts +3 -3
  74. package/dist/index.js +3 -3
  75. package/dist/index.js.map +1 -1
  76. package/dist/models.d.ts +2 -2
  77. package/dist/models.js.map +1 -1
  78. package/dist/react/account.d.ts +3 -1
  79. package/dist/react/account.js +3 -1
  80. package/dist/react/account.js.map +1 -1
  81. package/dist/react/admin-catalogue.d.ts +1 -1
  82. package/dist/react/admin-catalogue.js +1 -1
  83. package/dist/react/admin-catalogue.js.map +1 -1
  84. package/dist/react/admin-consumption.d.ts +1 -1
  85. package/dist/react/admin-consumption.js +1 -1
  86. package/dist/react/admin-consumption.js.map +1 -1
  87. package/dist/react/admin-desk.d.ts +1 -1
  88. package/dist/react/admin-desk.js +1 -1
  89. package/dist/react/admin-desk.js.map +1 -1
  90. package/dist/react/admin-licenses.d.ts +1 -1
  91. package/dist/react/admin-licenses.js +1 -1
  92. package/dist/react/admin-licenses.js.map +1 -1
  93. package/dist/react/admin-patrons.d.ts +1 -1
  94. package/dist/react/admin-patrons.js +1 -1
  95. package/dist/react/admin-patrons.js.map +1 -1
  96. package/dist/react/admin-reviews.d.ts +1 -1
  97. package/dist/react/admin-reviews.js +1 -1
  98. package/dist/react/admin-reviews.js.map +1 -1
  99. package/dist/react/admin-roles.d.ts +1 -1
  100. package/dist/react/admin-roles.js +1 -1
  101. package/dist/react/admin-roles.js.map +1 -1
  102. package/dist/react/admin-support.d.ts +1 -1
  103. package/dist/react/admin-support.js +1 -1
  104. package/dist/react/admin-support.js.map +1 -1
  105. package/dist/react/admin-tenants.d.ts +1 -1
  106. package/dist/react/admin-tenants.js +1 -1
  107. package/dist/react/admin-tenants.js.map +1 -1
  108. package/dist/react/admin-tutoring.d.ts +1 -1
  109. package/dist/react/admin-tutoring.js +1 -1
  110. package/dist/react/admin-tutoring.js.map +1 -1
  111. package/dist/react/auth.d.ts +1 -1
  112. package/dist/react/auth.js +1 -1
  113. package/dist/react/auth.js.map +1 -1
  114. package/dist/react/biblio-catalogue.d.ts +38 -1
  115. package/dist/react/biblio-catalogue.js +48 -2
  116. package/dist/react/biblio-catalogue.js.map +1 -1
  117. package/dist/react/biblio-home.d.ts +6 -1
  118. package/dist/react/biblio-home.js +6 -1
  119. package/dist/react/biblio-home.js.map +1 -1
  120. package/dist/react/biblio-library.d.ts +15 -11
  121. package/dist/react/biblio-library.js +32 -19
  122. package/dist/react/biblio-library.js.map +1 -1
  123. package/dist/react/biblio-nextory.d.ts +1 -1
  124. package/dist/react/biblio-nextory.js +1 -1
  125. package/dist/react/biblio-nextory.js.map +1 -1
  126. package/dist/react/biblio-press.d.ts +82 -89
  127. package/dist/react/biblio-press.js +97 -104
  128. package/dist/react/biblio-press.js.map +1 -1
  129. package/dist/react/biblio-search.d.ts +1 -1
  130. package/dist/react/biblio-search.js +1 -1
  131. package/dist/react/biblio-search.js.map +1 -1
  132. package/dist/react/biblio-telemetry.d.ts +1 -1
  133. package/dist/react/biblio-telemetry.js +1 -1
  134. package/dist/react/biblio-telemetry.js.map +1 -1
  135. package/dist/react/consumption.d.ts +1 -1
  136. package/dist/react/consumption.js +1 -1
  137. package/dist/react/consumption.js.map +1 -1
  138. package/dist/react/cvs-app.d.ts +1 -1
  139. package/dist/react/cvs-app.js +1 -1
  140. package/dist/react/cvs-app.js.map +1 -1
  141. package/dist/react/cvs-documents.d.ts +1 -1
  142. package/dist/react/cvs-documents.js +1 -1
  143. package/dist/react/cvs-documents.js.map +1 -1
  144. package/dist/react/cvs-favorites.d.ts +1 -1
  145. package/dist/react/cvs-favorites.js +1 -1
  146. package/dist/react/cvs-favorites.js.map +1 -1
  147. package/dist/react/cvs-ils.d.ts +1 -1
  148. package/dist/react/cvs-ils.js +1 -1
  149. package/dist/react/cvs-ils.js.map +1 -1
  150. package/dist/react/cvs-loans.d.ts +1 -1
  151. package/dist/react/cvs-loans.js +1 -1
  152. package/dist/react/cvs-loans.js.map +1 -1
  153. package/dist/react/cvs-payments.d.ts +1 -1
  154. package/dist/react/cvs-payments.js +1 -1
  155. package/dist/react/cvs-payments.js.map +1 -1
  156. package/dist/react/cvs-streaming.d.ts +1 -1
  157. package/dist/react/cvs-streaming.js +1 -1
  158. package/dist/react/cvs-streaming.js.map +1 -1
  159. package/dist/react/index.d.ts +3 -3
  160. package/dist/react/index.js +3 -3
  161. package/dist/react/partner-catalogue.d.ts +1 -1
  162. package/dist/react/partner-catalogue.js +1 -1
  163. package/dist/react/partner-catalogue.js.map +1 -1
  164. package/dist/react/partner-reader.d.ts +1 -1
  165. package/dist/react/partner-reader.js +1 -1
  166. package/dist/react/partner-reader.js.map +1 -1
  167. package/dist/react/profiles.d.ts +1 -1
  168. package/dist/react/profiles.js +1 -1
  169. package/dist/react/profiles.js.map +1 -1
  170. package/dist/react/search.d.ts +1 -1
  171. package/dist/react/search.js +1 -1
  172. package/dist/react/search.js.map +1 -1
  173. package/dist/react/tutoring-catalogue.d.ts +1 -1
  174. package/dist/react/tutoring-catalogue.js +1 -1
  175. package/dist/react/tutoring-catalogue.js.map +1 -1
  176. package/dist/react/tutoring-chat.d.ts +1 -1
  177. package/dist/react/tutoring-chat.js +1 -1
  178. package/dist/react/tutoring-chat.js.map +1 -1
  179. package/dist/react/tutoring-dispatch.d.ts +1 -1
  180. package/dist/react/tutoring-dispatch.js +1 -1
  181. package/dist/react/tutoring-dispatch.js.map +1 -1
  182. package/dist/react/tutoring-practitioner.d.ts +1 -1
  183. package/dist/react/tutoring-practitioner.js +1 -1
  184. package/dist/react/tutoring-practitioner.js.map +1 -1
  185. package/dist/react/tutoring-requests.d.ts +1 -1
  186. package/dist/react/tutoring-requests.js +1 -1
  187. package/dist/react/tutoring-requests.js.map +1 -1
  188. package/package.json +7 -7
@@ -1,8 +1,13 @@
1
1
 
2
2
  import { r as request } from "../chunks/client.js";
3
3
  //#region src/api/biblio-library/biblio-library.ts
4
- const getListBiblioCategoriesUrl = () => {
5
- return `/biblio/me/categories`;
4
+ const getListBiblioCategoriesUrl = (params) => {
5
+ const normalizedParams = new URLSearchParams();
6
+ Object.entries(params || {}).forEach(([key, value]) => {
7
+ if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
8
+ });
9
+ const stringifiedParams = normalizedParams.toString();
10
+ return stringifiedParams.length > 0 ? `/biblio/me/categories?${stringifiedParams}` : `/biblio/me/categories`;
6
11
  };
7
12
  /**
8
13
  * The categories this account can reach (E26).
@@ -14,8 +19,8 @@ const getListBiblioCategoriesUrl = () => {
14
19
  * other.
15
20
  * @summary List Biblio Categories
16
21
  */
17
- const listBiblioCategories = async (options) => {
18
- return request(getListBiblioCategoriesUrl(), {
22
+ const listBiblioCategories = async (params, options) => {
23
+ return request(getListBiblioCategoriesUrl(params), {
19
24
  ...options,
20
25
  method: "GET"
21
26
  });
@@ -38,15 +43,23 @@ const listBiblioFavorites = async (params, options) => {
38
43
  method: "GET"
39
44
  });
40
45
  };
41
- const getRemoveBiblioFavoriteUrl = (contentId) => {
42
- return `/biblio/me/favorites/${contentId}`;
46
+ const getRemoveBiblioFavoriteUrl = (contentId, params) => {
47
+ const normalizedParams = new URLSearchParams();
48
+ Object.entries(params || {}).forEach(([key, value]) => {
49
+ if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
50
+ });
51
+ const stringifiedParams = normalizedParams.toString();
52
+ return stringifiedParams.length > 0 ? `/biblio/me/favorites/${contentId}?${stringifiedParams}` : `/biblio/me/favorites/${contentId}`;
43
53
  };
44
54
  /**
45
- * Remove a favourite (E32). Idempotent — absent is already the desired state.
55
+ * Remove one mode only; a press selection includes its publication variants.
56
+ *
57
+ * Omitted mode means content. Use ?mode=press_title to unselect a publication.
58
+ * No longer removes both modes sharing an ID. Absent is already the desired state.
46
59
  * @summary Remove Biblio Favorite
47
60
  */
48
- const removeBiblioFavorite = async (contentId, options) => {
49
- return request(getRemoveBiblioFavoriteUrl(contentId), {
61
+ const removeBiblioFavorite = async (contentId, params, options) => {
62
+ return request(getRemoveBiblioFavoriteUrl(contentId, params), {
50
63
  ...options,
51
64
  method: "DELETE"
52
65
  });
@@ -1 +1 @@
1
- {"version":3,"file":"biblio-library.js","names":[],"sources":["../../src/api/biblio-library/biblio-library.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n CategoryListRead,\n CategoryPreferencesWrite,\n FavoriteAddWrite,\n FavoritePage,\n HistoryPage,\n ListBiblioFavoritesParams,\n ListHistoryParams,\n PackListRead,\n PreferencesRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getListBiblioCategoriesUrl = () => {\n\n\n\n\n return `/biblio/me/categories`\n}\n\n/**\n * The categories this account can reach (E26).\n *\n * Two independent gates, and both have to pass. Entitlement answers \"did the\n * company buy this\"; ``access_level`` answers \"is this person allowed it\" — an\n * ordinal on the account compared against one on the category, which is how a\n * child profile is kept out of the adult catalogue. Neither substitutes for the\n * other.\n * @summary List Biblio Categories\n */\nexport const listBiblioCategories = async ( options?: Parameters<typeof request>[1]): Promise<CategoryListRead> => {\n\n return request<CategoryListRead>(getListBiblioCategoriesUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getListBiblioFavoritesUrl = (params?: ListBiblioFavoritesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/favorites?${stringifiedParams}` : `/biblio/me/favorites`\n}\n\n/**\n * The caller's favourites (E30), newest first.\n * @summary List Biblio Favorites\n */\nexport const listBiblioFavorites = async (params?: ListBiblioFavoritesParams, options?: Parameters<typeof request>[1]): Promise<FavoritePage> => {\n\n return request<FavoritePage>(getListBiblioFavoritesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getRemoveBiblioFavoriteUrl = (contentId: number,) => {\n\n\n\n\n return `/biblio/me/favorites/${contentId}`\n}\n\n/**\n * Remove a favourite (E32). Idempotent — absent is already the desired state.\n * @summary Remove Biblio Favorite\n */\nexport const removeBiblioFavorite = async (contentId: number, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getRemoveBiblioFavoriteUrl(contentId),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getAddBiblioFavoriteUrl = (contentId: number,) => {\n\n\n\n\n return `/biblio/me/favorites/${contentId}`\n}\n\n/**\n * Mark content as a favourite (E31). Idempotent.\n *\n * ``PUT`` and :func:`remove_favorite`'s ``DELETE`` replace one\n * ``POST /favorites`` carrying an ``enabled`` boolean — the verb encoded as\n * data. A retry after a timeout reversed the user's intent; a repeated ``PUT``\n * cannot (§4, consequence 3).\n *\n * Favouriting is not consumption, so it is not entitlement-gated: a member may\n * bookmark something their library has not licensed *yet*. Reaching the content\n * is gated, at the point of reaching it.\n * @summary Add Biblio Favorite\n */\nexport const addBiblioFavorite = async (contentId: number,\n favoriteAddWrite: FavoriteAddWrite, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<void>(getAddBiblioFavoriteUrl(contentId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(favoriteAddWrite)\n }\n);}\n\n\nexport const getListHistoryUrl = (params?: ListHistoryParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/history?${stringifiedParams}` : `/biblio/me/history`\n}\n\n/**\n * What this account has consumed, most recent first (E33).\n *\n * One row per content item, not one per view: the caller wants \"what have I\n * been reading\", and ``consumption_event`` is append-only with a row per act.\n * The last access is therefore a MAX, and progress comes from\n * ``content_progress``, which is LEFT JOINed because an absent row means \"not\n * started\" rather than zero.\n * @summary List History\n */\nexport const listHistory = async (params?: ListHistoryParams, options?: Parameters<typeof request>[1]): Promise<HistoryPage> => {\n\n return request<HistoryPage>(getListHistoryUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getListPacksUrl = () => {\n\n\n\n\n return `/biblio/me/packs`\n}\n\n/**\n * The content packs this account can navigate (E25).\n *\n * A pack is a :class:`~app.models.biblio.catalogue.CatalogSection`, and one is\n * reachable when the contract reaches at least one category inside it. Deriving\n * it that way rather than granting packs directly means a pack cannot advertise\n * itself while every category under it is out of contract.\n *\n * Empty is a correct answer, not a broken one: an account whose contract has\n * lapsed reaches nothing.\n * @summary List Packs\n */\nexport const listPacks = async ( options?: Parameters<typeof request>[1]): Promise<PackListRead> => {\n\n return request<PackListRead>(getListPacksUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadPreferencesUrl = () => {\n\n\n\n\n return `/biblio/me/preferences`\n}\n\n/**\n * The caller's own preferences (E28).\n *\n * An object with one key rather than a bare array, so a second preference can\n * be added later without breaking every client.\n * @summary Read Preferences\n */\nexport const readPreferences = async ( options?: Parameters<typeof request>[1]): Promise<PreferencesRead> => {\n\n return request<PreferencesRead>(getReadPreferencesUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReplaceCategoryPreferencesUrl = () => {\n\n\n\n\n return `/biblio/me/preferences/categories`\n}\n\n/**\n * Replace the favourite-category set wholesale (E29).\n *\n * ``PUT`` because the legacy handler already replaced the whole set; the verb\n * now says so. An empty array clears the set and is valid input — the legacy\n * left that path uncaught and returned ``500``.\n *\n * A category the account cannot reach is ``422``, listing the offending ids.\n * Silently dropping them would leave the client believing it had saved\n * something it had not.\n * @summary Replace Category Preferences\n */\nexport const replaceCategoryPreferences = async (categoryPreferencesWrite: CategoryPreferencesWrite, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<void>(getReplaceCategoryPreferencesUrl(),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(categoryPreferencesWrite)\n }\n);}\n\n\n"],"mappings":";;;AAqBA,MAAa,mCAAmC;CAK9C,OAAO;AACT;;;;;;;;;;;AAYA,MAAa,uBAAuB,OAAQ,YAAuE;CAEjH,OAAO,QAA0B,2BAA2B,GAC5D;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,6BAA6B,WAAwC;CAChF,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,wBAAwB,sBAAsB;AACtF;;;;;AAMA,MAAa,sBAAsB,OAAO,QAAoC,YAAmE;CAE/I,OA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,sBAAsB;AACpF;;;;;;;;;;;AAYA,MAAa,cAAc,OAAO,QAA4B,YAAkE;CAE9H,OAAO,QAAqB,kBAAkB,MAAM,GACpD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,wBAAwB;CAKnC,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,YAAY,OAAQ,YAAmE;CAElG,OAAO,QAAsB,gBAAgB,GAC7C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,8BAA8B;CAKzC,OAAO;AACT;;;;;;;;AASA,MAAa,kBAAkB,OAAQ,YAAsE;CAE3G,OAAO,QAAyB,sBAAsB,GACtD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,yCAAyC;CAKpD,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,6BAA6B,OAAO,0BAAoD,YAA2D;CAE5J,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAAc,iCAAiC,GACpD;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,wBAAwB;CAC/C,CACF;AAAE"}
1
+ {"version":3,"file":"biblio-library.js","names":[],"sources":["../../src/api/biblio-library/biblio-library.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n CategoryListRead,\n CategoryPreferencesWrite,\n FavoriteAddWrite,\n FavoritePage,\n HistoryPage,\n ListBiblioCategoriesParams,\n ListBiblioFavoritesParams,\n ListHistoryParams,\n PackListRead,\n PreferencesRead,\n RemoveBiblioFavoriteParams\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getListBiblioCategoriesUrl = (params?: ListBiblioCategoriesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/categories?${stringifiedParams}` : `/biblio/me/categories`\n}\n\n/**\n * The categories this account can reach (E26).\n *\n * Two independent gates, and both have to pass. Entitlement answers \"did the\n * company buy this\"; ``access_level`` answers \"is this person allowed it\" — an\n * ordinal on the account compared against one on the category, which is how a\n * child profile is kept out of the adult catalogue. Neither substitutes for the\n * other.\n * @summary List Biblio Categories\n */\nexport const listBiblioCategories = async (params?: ListBiblioCategoriesParams, options?: Parameters<typeof request>[1]): Promise<CategoryListRead> => {\n\n return request<CategoryListRead>(getListBiblioCategoriesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getListBiblioFavoritesUrl = (params?: ListBiblioFavoritesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/favorites?${stringifiedParams}` : `/biblio/me/favorites`\n}\n\n/**\n * The caller's favourites (E30), newest first.\n * @summary List Biblio Favorites\n */\nexport const listBiblioFavorites = async (params?: ListBiblioFavoritesParams, options?: Parameters<typeof request>[1]): Promise<FavoritePage> => {\n\n return request<FavoritePage>(getListBiblioFavoritesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getRemoveBiblioFavoriteUrl = (contentId: number,\n params?: RemoveBiblioFavoriteParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/favorites/${contentId}?${stringifiedParams}` : `/biblio/me/favorites/${contentId}`\n}\n\n/**\n * Remove one mode only; a press selection includes its publication variants.\n *\n * Omitted mode means content. Use ?mode=press_title to unselect a publication.\n * No longer removes both modes sharing an ID. Absent is already the desired state.\n * @summary Remove Biblio Favorite\n */\nexport const removeBiblioFavorite = async (contentId: number,\n params?: RemoveBiblioFavoriteParams, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getRemoveBiblioFavoriteUrl(contentId,params),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getAddBiblioFavoriteUrl = (contentId: number,) => {\n\n\n\n\n return `/biblio/me/favorites/${contentId}`\n}\n\n/**\n * Mark content as a favourite (E31). Idempotent.\n *\n * ``PUT`` and :func:`remove_favorite`'s ``DELETE`` replace one\n * ``POST /favorites`` carrying an ``enabled`` boolean — the verb encoded as\n * data. A retry after a timeout reversed the user's intent; a repeated ``PUT``\n * cannot (§4, consequence 3).\n *\n * Favouriting is not consumption, so it is not entitlement-gated: a member may\n * bookmark something their library has not licensed *yet*. Reaching the content\n * is gated, at the point of reaching it.\n * @summary Add Biblio Favorite\n */\nexport const addBiblioFavorite = async (contentId: number,\n favoriteAddWrite: FavoriteAddWrite, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<void>(getAddBiblioFavoriteUrl(contentId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(favoriteAddWrite)\n }\n);}\n\n\nexport const getListHistoryUrl = (params?: ListHistoryParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/me/history?${stringifiedParams}` : `/biblio/me/history`\n}\n\n/**\n * What this account has consumed, most recent first (E33).\n *\n * One row per content item, not one per view: the caller wants \"what have I\n * been reading\", and ``consumption_event`` is append-only with a row per act.\n * The last access is therefore a MAX, and progress comes from\n * ``content_progress``, which is LEFT JOINed because an absent row means \"not\n * started\" rather than zero.\n * @summary List History\n */\nexport const listHistory = async (params?: ListHistoryParams, options?: Parameters<typeof request>[1]): Promise<HistoryPage> => {\n\n return request<HistoryPage>(getListHistoryUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getListPacksUrl = () => {\n\n\n\n\n return `/biblio/me/packs`\n}\n\n/**\n * The content packs this account can navigate (E25).\n *\n * A pack is a :class:`~app.models.biblio.catalogue.CatalogSection`, and one is\n * reachable when the contract reaches at least one category inside it. Deriving\n * it that way rather than granting packs directly means a pack cannot advertise\n * itself while every category under it is out of contract.\n *\n * Empty is a correct answer, not a broken one: an account whose contract has\n * lapsed reaches nothing.\n * @summary List Packs\n */\nexport const listPacks = async ( options?: Parameters<typeof request>[1]): Promise<PackListRead> => {\n\n return request<PackListRead>(getListPacksUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadPreferencesUrl = () => {\n\n\n\n\n return `/biblio/me/preferences`\n}\n\n/**\n * The caller's own preferences (E28).\n *\n * An object with one key rather than a bare array, so a second preference can\n * be added later without breaking every client.\n * @summary Read Preferences\n */\nexport const readPreferences = async ( options?: Parameters<typeof request>[1]): Promise<PreferencesRead> => {\n\n return request<PreferencesRead>(getReadPreferencesUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReplaceCategoryPreferencesUrl = () => {\n\n\n\n\n return `/biblio/me/preferences/categories`\n}\n\n/**\n * Replace the favourite-category set wholesale (E29).\n *\n * ``PUT`` because the legacy handler already replaced the whole set; the verb\n * now says so. An empty array clears the set and is valid input — the legacy\n * left that path uncaught and returned ``500``.\n *\n * A category the account cannot reach is ``422``, listing the offending ids.\n * Silently dropping them would leave the client believing it had saved\n * something it had not.\n * @summary Replace Category Preferences\n */\nexport const replaceCategoryPreferences = async (categoryPreferencesWrite: CategoryPreferencesWrite, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<void>(getReplaceCategoryPreferencesUrl(),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(categoryPreferencesWrite)\n }\n);}\n\n\n"],"mappings":";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AAO,QAAqB,kBAAkB,MAAM,GACpD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,wBAAwB;CAKnC,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,YAAY,OAAQ,YAAmE;CAElG,OAAO,QAAsB,gBAAgB,GAC7C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,8BAA8B;CAKzC,OAAO;AACT;;;;;;;;AASA,MAAa,kBAAkB,OAAQ,YAAsE;CAE3G,OAAO,QAAyB,sBAAsB,GACtD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,yCAAyC;CAKpD,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,6BAA6B,OAAO,0BAAoD,YAA2D;CAE5J,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAAc,iCAAiC,GACpD;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,wBAAwB;CAC/C,CACF;AAAE"}
@@ -1,5 +1,5 @@
1
1
 
2
- import { yr as LicenseRead } from "../chunks/index.js";
2
+ import { xr as LicenseRead } from "../chunks/index.js";
3
3
  import { c as request } from "../chunks/client.js";
4
4
  //#region src/api/biblio-nextory/biblio-nextory.d.ts
5
5
  export declare const getDeleteLicenseUrl: () => string;
@@ -1 +1 @@
1
- {"version":3,"file":"biblio-nextory.js","names":[],"sources":["../../src/api/biblio-nextory/biblio-nextory.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n LicenseRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getDeleteLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * Release this member's seat back to the household pool.\n *\n * Not in the legacy's member surface — releasing was staff-only, so a household\n * at its cap had to call support. The seat stays claimed by this member rather\n * than orphaned, so their next allocation gets the same number back and their\n * reading positions with it.\n *\n * ``204`` whether or not a licence was held: the desired end state is \"no\n * seat\", and reporting ``404`` would only tell a caller something they cannot\n * act on.\n * @summary Delete License\n */\nexport const deleteLicense = async ( options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getDeleteLicenseUrl(),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getReadLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * The seat this member holds (E49). ``404`` when they hold none.\n *\n * Safe, and that is the entire point of the endpoint existing separately.\n * @summary Read License\n */\nexport const readLicense = async ( options?: Parameters<typeof request>[1]): Promise<LicenseRead> => {\n\n return request<LicenseRead>(getReadLicenseUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getCreateLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * Allocate or reactivate this member's seat (E50).\n *\n * Idempotent: a member who already holds one gets it back with ``200``, and the\n * call doubles as a repair — a subscription that lapsed at the partner is\n * reopened against the same number, so reading positions survive.\n *\n * Medium assurance: this creates an account for the member at a third party\n * under their identity, which is not something a session established by a\n * partner handing over a static URL key should be able to do.\n * @summary Create License\n */\nexport const createLicense = async ( options?: Parameters<typeof request>[1]): Promise<LicenseRead> => {\n\n return request<LicenseRead>(getCreateLicenseUrl(),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAaA,MAAa,4BAA4B;CAKvC,OAAO;AACT;;;;;;;;;;;;;;AAeA,MAAa,gBAAgB,OAAQ,YAA2D;CAE9F,OAAO,QAAc,oBAAoB,GACzC;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,0BAA0B;CAKrC,OAAO;AACT;;;;;;;AAQA,MAAa,cAAc,OAAQ,YAAkE;CAEnG,OAAO,QAAqB,kBAAkB,GAC9C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,4BAA4B;CAKvC,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,gBAAgB,OAAQ,YAAkE;CAErG,OAAO,QAAqB,oBAAoB,GAChD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
1
+ {"version":3,"file":"biblio-nextory.js","names":[],"sources":["../../src/api/biblio-nextory/biblio-nextory.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n LicenseRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getDeleteLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * Release this member's seat back to the household pool.\n *\n * Not in the legacy's member surface — releasing was staff-only, so a household\n * at its cap had to call support. The seat stays claimed by this member rather\n * than orphaned, so their next allocation gets the same number back and their\n * reading positions with it.\n *\n * ``204`` whether or not a licence was held: the desired end state is \"no\n * seat\", and reporting ``404`` would only tell a caller something they cannot\n * act on.\n * @summary Delete License\n */\nexport const deleteLicense = async ( options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getDeleteLicenseUrl(),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getReadLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * The seat this member holds (E49). ``404`` when they hold none.\n *\n * Safe, and that is the entire point of the endpoint existing separately.\n * @summary Read License\n */\nexport const readLicense = async ( options?: Parameters<typeof request>[1]): Promise<LicenseRead> => {\n\n return request<LicenseRead>(getReadLicenseUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getCreateLicenseUrl = () => {\n\n\n\n\n return `/biblio/me/nextory/license`\n}\n\n/**\n * Allocate or reactivate this member's seat (E50).\n *\n * Idempotent: a member who already holds one gets it back with ``200``, and the\n * call doubles as a repair — a subscription that lapsed at the partner is\n * reopened against the same number, so reading positions survive.\n *\n * Medium assurance: this creates an account for the member at a third party\n * under their identity, which is not something a session established by a\n * partner handing over a static URL key should be able to do.\n * @summary Create License\n */\nexport const createLicense = async ( options?: Parameters<typeof request>[1]): Promise<LicenseRead> => {\n\n return request<LicenseRead>(getCreateLicenseUrl(),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAaA,MAAa,4BAA4B;CAKvC,OAAO;AACT;;;;;;;;;;;;;;AAeA,MAAa,gBAAgB,OAAQ,YAA2D;CAE9F,OAAO,QAAc,oBAAoB,GACzC;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,0BAA0B;CAKrC,OAAO;AACT;;;;;;;AAQA,MAAa,cAAc,OAAQ,YAAkE;CAEnG,OAAO,QAAqB,kBAAkB,GAC9C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,4BAA4B;CAKvC,OAAO;AACT;;;;;;;;;;;;;AAcA,MAAa,gBAAgB,OAAQ,YAAkE;CAErG,OAAO,QAAqB,oBAAoB,GAChD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
@@ -1,30 +1,39 @@
1
1
 
2
- import { Ht as PressReaderAccessWrite, Kt as PressArticleRead, Ut as PressReaderAccessRead, Wt as PressIssuePage, gt as ReadIssuesParams, li as PressReviewRead, qt as PressArticleListRead, tr as ListPressArticlesParams, ut as ReadPressReviewParams } from "../chunks/index.js";
2
+ import { Gt as PressReaderAccessWrite, Kt as PressReaderAccessRead, Ut as PressTitleRead, Wt as PressTitlePage, _t as ReadIssuesParams, di as PressFeedRead, dt as ReadPressFeedParams, qt as PressIssuePage, tr as ListPressTitlesParams } from "../chunks/index.js";
3
3
  import { c as request } from "../chunks/client.js";
4
4
  //#region src/api/biblio-press/biblio-press.d.ts
5
- export declare const getListPressArticlesUrl: (params?: ListPressArticlesParams) => string;
5
+ export declare const getReadPressFeedUrl: (params?: ReadPressFeedParams) => string;
6
6
  /**
7
- * Press articles, filtered (E41).
7
+ * Saved accessible publications first, then discovery by theme.
8
8
  *
9
- * ``theme_id`` unifies the legacy's two separate parameters ``themeId`` and
10
- * ``themePk``, which named the same thing. ``order`` is resolved against a
11
- * whitelist; anything else is ``422`` rather than a surprise ordering.
12
- * @summary List Press Articles
9
+ * Each section carries its first page, pagination metadata and a titlesUrl
10
+ * using the same filters. Unavailable titles never reappear through favourites.
11
+ * @summary Read Press Feed
13
12
  */
14
- export declare const listPressArticles: (params?: ListPressArticlesParams, options?: Parameters<typeof request>[1]) => Promise<PressArticleListRead>;
15
- export declare const getReadPressArticleUrl: (articleId: number) => string;
13
+ export declare const readPressFeed: (params?: ReadPressFeedParams, options?: Parameters<typeof request>[1]) => Promise<PressFeedRead>;
14
+ export declare const getListPressTitlesUrl: (params?: ListPressTitlesParams) => string;
16
15
  /**
17
- * One press article (E42). ``404`` when unknown *or* not entitled.
18
- * @summary Read Press Article
16
+ * One accessible catalogue entry per publication, with profile selection.
17
+ *
18
+ * contentId is the key for favourites, details and /issues. publicationId is
19
+ * the separate provider identifier. Search is a case-insensitive literal title
20
+ * substring. Ordering is alphabetical with a contentId tie-break.
21
+ * @summary List Press Titles
22
+ */
23
+ export declare const listPressTitles: (params?: ListPressTitlesParams, options?: Parameters<typeof request>[1]) => Promise<PressTitlePage>;
24
+ export declare const getReadPressTitleUrl: (contentId: number) => string;
25
+ /**
26
+ * Publication metadata; an unavailable or unknown title returns 404.
27
+ * @summary Read Press Title
19
28
  */
20
- export declare const readPressArticle: (articleId: number, options?: Parameters<typeof request>[1]) => Promise<PressArticleRead>;
21
- export declare const getReadIssuesUrl: (articleId: number, params?: ReadIssuesParams) => string;
29
+ export declare const readPressTitle: (contentId: number, options?: Parameters<typeof request>[1]) => Promise<PressTitleRead>;
30
+ export declare const getReadIssuesUrl: (contentId: number, params?: ReadIssuesParams) => string;
22
31
  /**
23
32
  * Entitled publication editions and covers. Never creates reader access.
24
33
  * @summary Read Issues
25
34
  */
26
- export declare const readIssues: (articleId: number, params?: ReadIssuesParams, options?: Parameters<typeof request>[1]) => Promise<PressIssuePage>;
27
- export declare const getOpenReaderUrl: (articleId: number) => string;
35
+ export declare const readIssues: (contentId: number, params?: ReadIssuesParams, options?: Parameters<typeof request>[1]) => Promise<PressIssuePage>;
36
+ export declare const getOpenReaderUrl: (contentId: number) => string;
28
37
  /**
29
38
  * Open a PressReader edition under this profile's current content grant.
30
39
  *
@@ -33,22 +42,6 @@ export declare const getOpenReaderUrl: (articleId: number) => string;
33
42
  * The date selects an edition; a missing edition is reported by PressReader.
34
43
  * @summary Open Reader
35
44
  */
36
- export declare const openReader: (articleId: number, pressReaderAccessWrite: PressReaderAccessWrite, options?: Parameters<typeof request>[1]) => Promise<PressReaderAccessRead>;
37
- export declare const getReadPressReviewUrl: (params?: ReadPressReviewParams) => string;
38
- /**
39
- * The curated press review (E43). An explicit aggregate (§5.2).
40
- *
41
- * New as an endpoint; the legacy composed it into two pages and never exposed
42
- * it. There is no curation table, so a section is a theme and its members are
43
- * that theme's most recent entitled articles — which is what the rendered page
44
- * amounted to. When a real curation model appears this is the one place that has
45
- * to change.
46
- *
47
- * A theme with nothing the caller may read is omitted rather than returned
48
- * empty: an empty section is a hole in a page, and the client cannot tell
49
- * "nothing new" from "not licensed".
50
- * @summary Read Press Review
51
- */
52
- export declare const readPressReview: (params?: ReadPressReviewParams, options?: Parameters<typeof request>[1]) => Promise<PressReviewRead>;
45
+ export declare const openReader: (contentId: number, pressReaderAccessWrite: PressReaderAccessWrite, options?: Parameters<typeof request>[1]) => Promise<PressReaderAccessRead>;
53
46
  //#endregion
54
47
  //# sourceMappingURL=biblio-press.d.ts.map
@@ -1,61 +1,82 @@
1
1
 
2
2
  import { r as request } from "../chunks/client.js";
3
3
  //#region src/api/biblio-press/biblio-press.ts
4
- const getListPressArticlesUrl = (params) => {
4
+ const getReadPressFeedUrl = (params) => {
5
5
  const normalizedParams = new URLSearchParams();
6
6
  Object.entries(params || {}).forEach(([key, value]) => {
7
7
  if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
8
8
  });
9
9
  const stringifiedParams = normalizedParams.toString();
10
- return stringifiedParams.length > 0 ? `/biblio/press-articles?${stringifiedParams}` : `/biblio/press-articles`;
10
+ return stringifiedParams.length > 0 ? `/biblio/press-feed?${stringifiedParams}` : `/biblio/press-feed`;
11
11
  };
12
12
  /**
13
- * Press articles, filtered (E41).
13
+ * Saved accessible publications first, then discovery by theme.
14
14
  *
15
- * ``theme_id`` unifies the legacy's two separate parameters ``themeId`` and
16
- * ``themePk``, which named the same thing. ``order`` is resolved against a
17
- * whitelist; anything else is ``422`` rather than a surprise ordering.
18
- * @summary List Press Articles
15
+ * Each section carries its first page, pagination metadata and a titlesUrl
16
+ * using the same filters. Unavailable titles never reappear through favourites.
17
+ * @summary Read Press Feed
19
18
  */
20
- const listPressArticles = async (params, options) => {
21
- return request(getListPressArticlesUrl(params), {
19
+ const readPressFeed = async (params, options) => {
20
+ return request(getReadPressFeedUrl(params), {
22
21
  ...options,
23
22
  method: "GET"
24
23
  });
25
24
  };
26
- const getReadPressArticleUrl = (articleId) => {
27
- return `/biblio/press-articles/${articleId}`;
25
+ const getListPressTitlesUrl = (params) => {
26
+ const normalizedParams = new URLSearchParams();
27
+ Object.entries(params || {}).forEach(([key, value]) => {
28
+ if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
29
+ });
30
+ const stringifiedParams = normalizedParams.toString();
31
+ return stringifiedParams.length > 0 ? `/biblio/press-titles?${stringifiedParams}` : `/biblio/press-titles`;
32
+ };
33
+ /**
34
+ * One accessible catalogue entry per publication, with profile selection.
35
+ *
36
+ * contentId is the key for favourites, details and /issues. publicationId is
37
+ * the separate provider identifier. Search is a case-insensitive literal title
38
+ * substring. Ordering is alphabetical with a contentId tie-break.
39
+ * @summary List Press Titles
40
+ */
41
+ const listPressTitles = async (params, options) => {
42
+ return request(getListPressTitlesUrl(params), {
43
+ ...options,
44
+ method: "GET"
45
+ });
46
+ };
47
+ const getReadPressTitleUrl = (contentId) => {
48
+ return `/biblio/press-titles/${contentId}`;
28
49
  };
29
50
  /**
30
- * One press article (E42). ``404`` when unknown *or* not entitled.
31
- * @summary Read Press Article
51
+ * Publication metadata; an unavailable or unknown title returns 404.
52
+ * @summary Read Press Title
32
53
  */
33
- const readPressArticle = async (articleId, options) => {
34
- return request(getReadPressArticleUrl(articleId), {
54
+ const readPressTitle = async (contentId, options) => {
55
+ return request(getReadPressTitleUrl(contentId), {
35
56
  ...options,
36
57
  method: "GET"
37
58
  });
38
59
  };
39
- const getReadIssuesUrl = (articleId, params) => {
60
+ const getReadIssuesUrl = (contentId, params) => {
40
61
  const normalizedParams = new URLSearchParams();
41
62
  Object.entries(params || {}).forEach(([key, value]) => {
42
63
  if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
43
64
  });
44
65
  const stringifiedParams = normalizedParams.toString();
45
- return stringifiedParams.length > 0 ? `/biblio/press-articles/${articleId}/issues?${stringifiedParams}` : `/biblio/press-articles/${articleId}/issues`;
66
+ return stringifiedParams.length > 0 ? `/biblio/press-titles/${contentId}/issues?${stringifiedParams}` : `/biblio/press-titles/${contentId}/issues`;
46
67
  };
47
68
  /**
48
69
  * Entitled publication editions and covers. Never creates reader access.
49
70
  * @summary Read Issues
50
71
  */
51
- const readIssues = async (articleId, params, options) => {
52
- return request(getReadIssuesUrl(articleId, params), {
72
+ const readIssues = async (contentId, params, options) => {
73
+ return request(getReadIssuesUrl(contentId, params), {
53
74
  ...options,
54
75
  method: "GET"
55
76
  });
56
77
  };
57
- const getOpenReaderUrl = (articleId) => {
58
- return `/biblio/press-articles/${articleId}/reader-access`;
78
+ const getOpenReaderUrl = (contentId) => {
79
+ return `/biblio/press-titles/${contentId}/reader-access`;
59
80
  };
60
81
  /**
61
82
  * Open a PressReader edition under this profile's current content grant.
@@ -65,7 +86,7 @@ const getOpenReaderUrl = (articleId) => {
65
86
  * The date selects an edition; a missing edition is reported by PressReader.
66
87
  * @summary Open Reader
67
88
  */
68
- const openReader = async (articleId, pressReaderAccessWrite, options) => {
89
+ const openReader = async (contentId, pressReaderAccessWrite, options) => {
69
90
  const getHeaders = (h) => {
70
91
  if (!h) return {};
71
92
  if (h instanceof Headers) return Object.fromEntries(h.entries());
@@ -74,7 +95,7 @@ const openReader = async (articleId, pressReaderAccessWrite, options) => {
74
95
  for (const [name, value] of Object.entries(h)) if (value !== void 0) headers[name] = value;
75
96
  return headers;
76
97
  };
77
- return request(getOpenReaderUrl(articleId), {
98
+ return request(getOpenReaderUrl(contentId), {
78
99
  ...options,
79
100
  method: "POST",
80
101
  headers: {
@@ -84,35 +105,7 @@ const openReader = async (articleId, pressReaderAccessWrite, options) => {
84
105
  body: JSON.stringify(pressReaderAccessWrite)
85
106
  });
86
107
  };
87
- const getReadPressReviewUrl = (params) => {
88
- const normalizedParams = new URLSearchParams();
89
- Object.entries(params || {}).forEach(([key, value]) => {
90
- if (value !== void 0) normalizedParams.append(key, value === null ? "null" : String(value));
91
- });
92
- const stringifiedParams = normalizedParams.toString();
93
- return stringifiedParams.length > 0 ? `/biblio/press-review?${stringifiedParams}` : `/biblio/press-review`;
94
- };
95
- /**
96
- * The curated press review (E43). An explicit aggregate (§5.2).
97
- *
98
- * New as an endpoint; the legacy composed it into two pages and never exposed
99
- * it. There is no curation table, so a section is a theme and its members are
100
- * that theme's most recent entitled articles — which is what the rendered page
101
- * amounted to. When a real curation model appears this is the one place that has
102
- * to change.
103
- *
104
- * A theme with nothing the caller may read is omitted rather than returned
105
- * empty: an empty section is a hole in a page, and the client cannot tell
106
- * "nothing new" from "not licensed".
107
- * @summary Read Press Review
108
- */
109
- const readPressReview = async (params, options) => {
110
- return request(getReadPressReviewUrl(params), {
111
- ...options,
112
- method: "GET"
113
- });
114
- };
115
108
  //#endregion
116
- export { getListPressArticlesUrl, getOpenReaderUrl, getReadIssuesUrl, getReadPressArticleUrl, getReadPressReviewUrl, listPressArticles, openReader, readIssues, readPressArticle, readPressReview };
109
+ export { getListPressTitlesUrl, getOpenReaderUrl, getReadIssuesUrl, getReadPressFeedUrl, getReadPressTitleUrl, listPressTitles, openReader, readIssues, readPressFeed, readPressTitle };
117
110
 
118
111
  //# sourceMappingURL=biblio-press.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"biblio-press.js","names":[],"sources":["../../src/api/biblio-press/biblio-press.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n ListPressArticlesParams,\n PressArticleListRead,\n PressArticleRead,\n PressIssuePage,\n PressReaderAccessRead,\n PressReaderAccessWrite,\n PressReviewRead,\n ReadIssuesParams,\n ReadPressReviewParams\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getListPressArticlesUrl = (params?: ListPressArticlesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-articles?${stringifiedParams}` : `/biblio/press-articles`\n}\n\n/**\n * Press articles, filtered (E41).\n *\n * ``theme_id`` unifies the legacy's two separate parameters ``themeId`` and\n * ``themePk``, which named the same thing. ``order`` is resolved against a\n * whitelist; anything else is ``422`` rather than a surprise ordering.\n * @summary List Press Articles\n */\nexport const listPressArticles = async (params?: ListPressArticlesParams, options?: Parameters<typeof request>[1]): Promise<PressArticleListRead> => {\n\n return request<PressArticleListRead>(getListPressArticlesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadPressArticleUrl = (articleId: number,) => {\n\n\n\n\n return `/biblio/press-articles/${articleId}`\n}\n\n/**\n * One press article (E42). ``404`` when unknown *or* not entitled.\n * @summary Read Press Article\n */\nexport const readPressArticle = async (articleId: number, options?: Parameters<typeof request>[1]): Promise<PressArticleRead> => {\n\n return request<PressArticleRead>(getReadPressArticleUrl(articleId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadIssuesUrl = (articleId: number,\n params?: ReadIssuesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-articles/${articleId}/issues?${stringifiedParams}` : `/biblio/press-articles/${articleId}/issues`\n}\n\n/**\n * Entitled publication editions and covers. Never creates reader access.\n * @summary Read Issues\n */\nexport const readIssues = async (articleId: number,\n params?: ReadIssuesParams, options?: Parameters<typeof request>[1]): Promise<PressIssuePage> => {\n\n return request<PressIssuePage>(getReadIssuesUrl(articleId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getOpenReaderUrl = (articleId: number,) => {\n\n\n\n\n return `/biblio/press-articles/${articleId}/reader-access`\n}\n\n/**\n * Open a PressReader edition under this profile's current content grant.\n *\n * URL and token authorize gifted access, not the deployment catalogue API.\n * Keep lease.eventId alive with PUT /consumption/{id}; close with DELETE.\n * The date selects an edition; a missing edition is reported by PressReader.\n * @summary Open Reader\n */\nexport const openReader = async (articleId: number,\n pressReaderAccessWrite: PressReaderAccessWrite, options?: Parameters<typeof request>[1]): Promise<PressReaderAccessRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<PressReaderAccessRead>(getOpenReaderUrl(articleId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(pressReaderAccessWrite)\n }\n);}\n\n\nexport const getReadPressReviewUrl = (params?: ReadPressReviewParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-review?${stringifiedParams}` : `/biblio/press-review`\n}\n\n/**\n * The curated press review (E43). An explicit aggregate (§5.2).\n *\n * New as an endpoint; the legacy composed it into two pages and never exposed\n * it. There is no curation table, so a section is a theme and its members are\n * that theme's most recent entitled articles — which is what the rendered page\n * amounted to. When a real curation model appears this is the one place that has\n * to change.\n *\n * A theme with nothing the caller may read is omitted rather than returned\n * empty: an empty section is a hole in a page, and the client cannot tell\n * \"nothing new\" from \"not licensed\".\n * @summary Read Press Review\n */\nexport const readPressReview = async (params?: ReadPressReviewParams, options?: Parameters<typeof request>[1]): Promise<PressReviewRead> => {\n\n return request<PressReviewRead>(getReadPressReviewUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAqBA,MAAa,2BAA2B,WAAsC;CAC5E,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,0BAA0B,sBAAsB;AACxF;;;;;;;;;AAUA,MAAa,oBAAoB,OAAO,QAAkC,YAA2E;CAEnJ,OAAO,QAA8B,wBAAwB,MAAM,GACnE;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,0BAA0B,cAAuB;CAK5D,OAAO,0BAA0B;AACnC;;;;;AAMA,MAAa,mBAAmB,OAAO,WAAmB,YAAuE;CAE/H,OAAO,QAA0B,uBAAuB,SAAS,GACjE;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,oBAAoB,WAC7B,WAA+B;CACjC,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,0BAA0B,UAAU,UAAU,sBAAsB,0BAA0B,UAAU;AAChJ;;;;;AAMA,MAAa,aAA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AAQ;CAGV,CACF;AAAE"}
1
+ {"version":3,"file":"biblio-press.js","names":[],"sources":["../../src/api/biblio-press/biblio-press.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n ListPressTitlesParams,\n PressFeedRead,\n PressIssuePage,\n PressReaderAccessRead,\n PressReaderAccessWrite,\n PressTitlePage,\n PressTitleRead,\n ReadIssuesParams,\n ReadPressFeedParams\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getReadPressFeedUrl = (params?: ReadPressFeedParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-feed?${stringifiedParams}` : `/biblio/press-feed`\n}\n\n/**\n * Saved accessible publications first, then discovery by theme.\n *\n * Each section carries its first page, pagination metadata and a titlesUrl\n * using the same filters. Unavailable titles never reappear through favourites.\n * @summary Read Press Feed\n */\nexport const readPressFeed = async (params?: ReadPressFeedParams, options?: Parameters<typeof request>[1]): Promise<PressFeedRead> => {\n\n return request<PressFeedRead>(getReadPressFeedUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getListPressTitlesUrl = (params?: ListPressTitlesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-titles?${stringifiedParams}` : `/biblio/press-titles`\n}\n\n/**\n * One accessible catalogue entry per publication, with profile selection.\n *\n * contentId is the key for favourites, details and /issues. publicationId is\n * the separate provider identifier. Search is a case-insensitive literal title\n * substring. Ordering is alphabetical with a contentId tie-break.\n * @summary List Press Titles\n */\nexport const listPressTitles = async (params?: ListPressTitlesParams, options?: Parameters<typeof request>[1]): Promise<PressTitlePage> => {\n\n return request<PressTitlePage>(getListPressTitlesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadPressTitleUrl = (contentId: number,) => {\n\n\n\n\n return `/biblio/press-titles/${contentId}`\n}\n\n/**\n * Publication metadata; an unavailable or unknown title returns 404.\n * @summary Read Press Title\n */\nexport const readPressTitle = async (contentId: number, options?: Parameters<typeof request>[1]): Promise<PressTitleRead> => {\n\n return request<PressTitleRead>(getReadPressTitleUrl(contentId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getReadIssuesUrl = (contentId: number,\n params?: ReadIssuesParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/press-titles/${contentId}/issues?${stringifiedParams}` : `/biblio/press-titles/${contentId}/issues`\n}\n\n/**\n * Entitled publication editions and covers. Never creates reader access.\n * @summary Read Issues\n */\nexport const readIssues = async (contentId: number,\n params?: ReadIssuesParams, options?: Parameters<typeof request>[1]): Promise<PressIssuePage> => {\n\n return request<PressIssuePage>(getReadIssuesUrl(contentId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getOpenReaderUrl = (contentId: number,) => {\n\n\n\n\n return `/biblio/press-titles/${contentId}/reader-access`\n}\n\n/**\n * Open a PressReader edition under this profile's current content grant.\n *\n * URL and token authorize gifted access, not the deployment catalogue API.\n * Keep lease.eventId alive with PUT /consumption/{id}; close with DELETE.\n * The date selects an edition; a missing edition is reported by PressReader.\n * @summary Open Reader\n */\nexport const openReader = async (contentId: number,\n pressReaderAccessWrite: PressReaderAccessWrite, options?: Parameters<typeof request>[1]): Promise<PressReaderAccessRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<PressReaderAccessRead>(getOpenReaderUrl(contentId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(pressReaderAccessWrite)\n }\n);}\n\n\n"],"mappings":";;;AAqBA,MAAa,uBAAuB,WAAkC;CACpE,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,sBAAsB,sBAAsB;AACpF;;;;;;;;AASA,MAAa,gBAAgB,OAAO,QAA8B,YAAoE;CAEpI,OAAO,QAAuB,oBAAoB,MAAM,GACxD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,yBAAyB,WAAoC;CACxE,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,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MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA+B,iBAAiB,SAAS,GAC9D;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,sBAAsB;CAC7C,CACF;AAAE"}
@@ -1 +1 @@
1
- {"version":3,"file":"biblio-search.js","names":[],"sources":["../../src/api/biblio-search/biblio-search.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n SearchParams,\n SearchResultsRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getSearchUrl = (params?: SearchParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/search?${stringifiedParams}` : `/biblio/search`\n}\n\n/**\n * Search the catalogue (E46).\n *\n * An empty ``q`` returns an empty ``data`` with ``200``. It is not an error: a\n * client clearing its search box should get an empty result, not a failure.\n *\n * An unrecognised ``type`` is ``422``, naming the families that exist.\n * @summary Search\n */\nexport const search = async (params?: SearchParams, options?: Parameters<typeof request>[1]): Promise<SearchResultsRead> => {\n\n return request<SearchResultsRead>(getSearchUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAcA,MAAa,gBAAgB,WAA2B;CACtD,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,kBAAkB,sBAAsB;AAChF;;;;;;;;;;AAWA,MAAa,SAAS,OAAO,QAAuB,YAAwE;CAE1H,OAAO,QAA2B,aAAa,MAAM,GACrD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
1
+ {"version":3,"file":"biblio-search.js","names":[],"sources":["../../src/api/biblio-search/biblio-search.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n SearchParams,\n SearchResultsRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getSearchUrl = (params?: SearchParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/biblio/search?${stringifiedParams}` : `/biblio/search`\n}\n\n/**\n * Search the catalogue (E46).\n *\n * An empty ``q`` returns an empty ``data`` with ``200``. It is not an error: a\n * client clearing its search box should get an empty result, not a failure.\n *\n * An unrecognised ``type`` is ``422``, naming the families that exist.\n * @summary Search\n */\nexport const search = async (params?: SearchParams, options?: Parameters<typeof request>[1]): Promise<SearchResultsRead> => {\n\n return request<SearchResultsRead>(getSearchUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAcA,MAAa,gBAAgB,WAA2B;CACtD,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,kBAAkB,sBAAsB;AAChF;;;;;;;;;;AAWA,MAAa,SAAS,OAAO,QAAuB,YAAwE;CAE1H,OAAO,QAA2B,aAAa,MAAM,GACrD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
@@ -1,5 +1,5 @@
1
1
 
2
- import { _t as ReadingSessionWrite, vt as ReadingSessionRead } from "../chunks/index.js";
2
+ import { vt as ReadingSessionWrite, yt as ReadingSessionRead } from "../chunks/index.js";
3
3
  import { c as request } from "../chunks/client.js";
4
4
  //#region src/api/biblio-telemetry/biblio-telemetry.d.ts
5
5
  export declare const getRecordReadingSessionUrl: (sessionTag: string) => string;
@@ -1 +1 @@
1
- {"version":3,"file":"biblio-telemetry.js","names":[],"sources":["../../src/api/biblio-telemetry/biblio-telemetry.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n ReadingSessionRead,\n ReadingSessionWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getRecordReadingSessionUrl = (sessionTag: string,) => {\n\n\n\n\n return `/biblio/reading-sessions/${sessionTag}`\n}\n\n/**\n * Record one content-consumption session (E54). Idempotent on ``session_tag``.\n *\n * **There is no ``user_id`` and no ``client_id`` in the body, and there must\n * never be.** The legacy endpoint was unauthenticated and took both from the\n * request without checking either against a credential, so consumption records\n * — which is to say the billing record — were forgeable for any account\n * (defect D3). Both come from the token here.\n *\n * ``PUT`` because the legacy handler already checked whether the tag existed and\n * returned success rather than duplicating: that is an upsert keyed by a\n * client-supplied identifier, and the verb now says so. The tag becomes\n * ``ConsumptionEvent.request_key``, so a retried request after a timeout costs\n * one unit rather than two — enforced by a partial unique index, not by\n * checking first and hoping.\n *\n * ``201`` on the first write for a tag, ``200`` when it already existed. Never\n * an error for a repeat: that is what idempotent means (§2.6).\n * @summary Record Reading Session\n */\nexport const recordReadingSession = async (sessionTag: string,\n readingSessionWrite: ReadingSessionWrite, options?: Parameters<typeof request>[1]): Promise<ReadingSessionRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<ReadingSessionRead>(getRecordReadingSessionUrl(sessionTag),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(readingSessionWrite)\n }\n);}\n\n\n"],"mappings":";;;AAcA,MAAa,8BAA8B,eAAwB;CAKjE,OAAO,4BAA4B;AACrC;;;;;;;;;;;;;;;;;;;;;AAsBA,MAAa,uBAAuB,OAAO,YACvC,qBAA0C,YAAyE;CAEnH,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA4B,2BAA2B,UAAU,GACtE;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,mBAAmB;CAC1C,CACF;AAAE"}
1
+ {"version":3,"file":"biblio-telemetry.js","names":[],"sources":["../../src/api/biblio-telemetry/biblio-telemetry.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n ReadingSessionRead,\n ReadingSessionWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getRecordReadingSessionUrl = (sessionTag: string,) => {\n\n\n\n\n return `/biblio/reading-sessions/${sessionTag}`\n}\n\n/**\n * Record one content-consumption session (E54). Idempotent on ``session_tag``.\n *\n * **There is no ``user_id`` and no ``client_id`` in the body, and there must\n * never be.** The legacy endpoint was unauthenticated and took both from the\n * request without checking either against a credential, so consumption records\n * — which is to say the billing record — were forgeable for any account\n * (defect D3). Both come from the token here.\n *\n * ``PUT`` because the legacy handler already checked whether the tag existed and\n * returned success rather than duplicating: that is an upsert keyed by a\n * client-supplied identifier, and the verb now says so. The tag becomes\n * ``ConsumptionEvent.request_key``, so a retried request after a timeout costs\n * one unit rather than two — enforced by a partial unique index, not by\n * checking first and hoping.\n *\n * ``201`` on the first write for a tag, ``200`` when it already existed. Never\n * an error for a repeat: that is what idempotent means (§2.6).\n * @summary Record Reading Session\n */\nexport const recordReadingSession = async (sessionTag: string,\n readingSessionWrite: ReadingSessionWrite, options?: Parameters<typeof request>[1]): Promise<ReadingSessionRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<ReadingSessionRead>(getRecordReadingSessionUrl(sessionTag),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(readingSessionWrite)\n }\n);}\n\n\n"],"mappings":";;;AAcA,MAAa,8BAA8B,eAAwB;CAKjE,OAAO,4BAA4B;AACrC;;;;;;;;;;;;;;;;;;;;;AAsBA,MAAa,uBAAuB,OAAO,YACvC,qBAA0C,YAAyE;CAEnH,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA4B,2BAA2B,UAAU,GACtE;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,mBAAmB;CAC1C,CACF;AAAE"}
@@ -1,5 +1,5 @@
1
1
 
2
- import { wr as LeaseRead } from "../chunks/index.js";
2
+ import { Er as LeaseRead } from "../chunks/index.js";
3
3
  import { c as request } from "../chunks/client.js";
4
4
  //#region src/api/consumption/consumption.d.ts
5
5
  export declare const getCloseLeaseUrl: (eventId: number) => string;
@@ -1 +1 @@
1
- {"version":3,"file":"consumption.js","names":[],"sources":["../../src/api/consumption/consumption.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n LeaseRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getCloseLeaseUrl = (eventId: number,) => {\n\n\n\n\n return `/consumption/${eventId}`\n}\n\n/**\n * Finish reading. Returns the seat immediately rather than at lapse.\n *\n * ``204`` whether or not the lease was still open: the desired end state is\n * \"closed\", and a client that lost its connection and retried should not get an\n * error for succeeding twice.\n * @summary Close Lease\n */\nexport const closeLease = async (eventId: number, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getCloseLeaseUrl(eventId),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getRenewLeaseUrl = (eventId: number,) => {\n\n\n\n\n return `/consumption/${eventId}`\n}\n\n/**\n * Heartbeat. Push the lease out; the client repeats before it lapses.\n *\n * ``404`` when the lease is closed, reaped, or somebody else's — the three are\n * deliberately indistinguishable, because a lease id is a bare integer and\n * guessing one must not reveal whether it exists.\n *\n * This does not write the ledger. A reader refreshing every thirty seconds for\n * an hour would be 120 UPDATEs on the table we bill from, for a value that only\n * matters while it is current; the durable extent is settled once, at close.\n * @summary Renew Lease\n */\nexport const renewLease = async (eventId: number, options?: Parameters<typeof request>[1]): Promise<LeaseRead> => {\n\n return request<LeaseRead>(getRenewLeaseUrl(eventId),\n {\n ...options,\n method: 'PUT'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAaA,MAAa,oBAAoB,YAAqB;CAKpD,OAAO,gBAAgB;AACzB;;;;;;;;;AAUA,MAAa,aAAa,OAAO,SAAiB,YAA2D;CAE3G,OAAO,QAAc,iBAAiB,OAAO,GAC7C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,oBAAoB,YAAqB;CAKpD,OAAO,gBAAgB;AACzB;;;;;;;;;;;;;AAcA,MAAa,aAAa,OAAO,SAAiB,YAAgE;CAEhH,OAAO,QAAmB,iBAAiB,OAAO,GAClD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
1
+ {"version":3,"file":"consumption.js","names":[],"sources":["../../src/api/consumption/consumption.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n LeaseRead\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getCloseLeaseUrl = (eventId: number,) => {\n\n\n\n\n return `/consumption/${eventId}`\n}\n\n/**\n * Finish reading. Returns the seat immediately rather than at lapse.\n *\n * ``204`` whether or not the lease was still open: the desired end state is\n * \"closed\", and a client that lost its connection and retried should not get an\n * error for succeeding twice.\n * @summary Close Lease\n */\nexport const closeLease = async (eventId: number, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getCloseLeaseUrl(eventId),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\nexport const getRenewLeaseUrl = (eventId: number,) => {\n\n\n\n\n return `/consumption/${eventId}`\n}\n\n/**\n * Heartbeat. Push the lease out; the client repeats before it lapses.\n *\n * ``404`` when the lease is closed, reaped, or somebody else's — the three are\n * deliberately indistinguishable, because a lease id is a bare integer and\n * guessing one must not reveal whether it exists.\n *\n * This does not write the ledger. A reader refreshing every thirty seconds for\n * an hour would be 120 UPDATEs on the table we bill from, for a value that only\n * matters while it is current; the durable extent is settled once, at close.\n * @summary Renew Lease\n */\nexport const renewLease = async (eventId: number, options?: Parameters<typeof request>[1]): Promise<LeaseRead> => {\n\n return request<LeaseRead>(getRenewLeaseUrl(eventId),\n {\n ...options,\n method: 'PUT'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAaA,MAAa,oBAAoB,YAAqB;CAKpD,OAAO,gBAAgB;AACzB;;;;;;;;;AAUA,MAAa,aAAa,OAAO,SAAiB,YAA2D;CAE3G,OAAO,QAAc,iBAAiB,OAAO,GAC7C;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,oBAAoB,YAAqB;CAKpD,OAAO,gBAAgB;AACzB;;;;;;;;;;;;;AAcA,MAAa,aAAa,OAAO,SAAiB,YAAgE;CAEhH,OAAO,QAAmB,iBAAiB,OAAO,GAClD;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
@@ -1 +1 @@
1
- {"version":3,"file":"cvs-app.js","names":[],"sources":["../../src/api/cvs-app/cvs-app.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.0\n */\nimport type {\n ListNotificationsParams,\n NotificationListRead,\n PlaybackReportRead,\n PlaybackReportWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getListNotificationsUrl = (params?: ListNotificationsParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/cvs/notifications?${stringifiedParams}` : `/cvs/notifications`\n}\n\n/**\n * Notifications published to this caller's library.\n *\n * **These are tenant broadcasts, not a per-user inbox.** ``app_notification``\n * has no user column and no read state — ``app_notification_bm`` links a\n * notification to a library and that is the whole model. So ``unread_count`` is\n * always ``0`` here and every notification is returned every time.\n *\n * Giving each member their own read state is a schema change (a\n * ``notification_read`` row per user and notification), not a query change. It\n * is worth doing — a broadcast list that never shrinks is one people stop\n * opening — but it is a decision rather than a port, so it is not made here.\n * @summary List Notifications\n */\nexport const listNotifications = async (params?: ListNotificationsParams, options?: Parameters<typeof request>[1]): Promise<NotificationListRead> => {\n\n return request<NotificationListRead>(getListNotificationsUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getCreateReportUrl = () => {\n\n\n\n\n return `/cvs/reports`\n}\n\n/**\n * Report a playback problem.\n *\n * The identifying fields are taken from the credential, not the body. The\n * legacy took ``adhId``, ``bmId`` and ``bmBibLocaleId`` from the query string\n * and declared no ``Authorization`` at all, so anyone holding the shared\n * ``api_key`` — which every deployed app binary contains — could file a report\n * in any patron's name, at any library. The DTO still carries those three\n * fields, marked transition-only, and this handler ignores every one of them.\n *\n * ``email`` is free text that ends up in a message. Authenticated and\n * rate-limited it is a support channel; unauthenticated it is a spam relay with\n * the library's return address on it.\n * @summary Create Report\n */\nexport const createReport = async (playbackReportWrite: PlaybackReportWrite, options?: Parameters<typeof request>[1]): Promise<PlaybackReportRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<PlaybackReportRead>(getCreateReportUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(playbackReportWrite)\n }\n);}\n\n\n"],"mappings":";;;AAgBA,MAAa,2BAA2B,WAAsC;CAC5E,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,sBAAsB,sBAAsB;AACpF;;;;;;;;;;;;;;;AAgBA,MAAa,oBAAoB,OAAO,QAAkC,YAA2E;CAEnJ,OAAO,QAA8B,wBAAwB,MAAM,GACnE;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,2BAA2B;CAKtC,OAAO;AACT;;;;;;;;;;;;;;;;AAiBA,MAAa,eAAe,OAAO,qBAA0C,YAAyE;CAElJ,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA4B,mBAAmB,GACpD;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,mBAAmB;CAC1C,CACF;AAAE"}
1
+ {"version":3,"file":"cvs-app.js","names":[],"sources":["../../src/api/cvs-app/cvs-app.ts"],"sourcesContent":["/**\n * Generated by orval 🍺\n * Do not edit manually.\n * Mozaik backend\n * Four products behind one API — Biblio, Médiathèques, the partner catalogues (Nextory and YouScribe) and Prof Express. Authentication is Keycloak SSO only, once, for all of them: see the **auth** section below for the browser flow and the three failure modes.\n * OpenAPI spec version: 0.9.1\n */\nimport type {\n ListNotificationsParams,\n NotificationListRead,\n PlaybackReportRead,\n PlaybackReportWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getListNotificationsUrl = (params?: ListNotificationsParams,) => {\n const normalizedParams = new URLSearchParams();\n\n Object.entries(params || {}).forEach(([key, value]) => {\n\n if (value !== undefined) {\n normalizedParams.append(key, value === null ? 'null' : String(value))\n }\n });\n\n const stringifiedParams = normalizedParams.toString();\n\n return stringifiedParams.length > 0 ? `/cvs/notifications?${stringifiedParams}` : `/cvs/notifications`\n}\n\n/**\n * Notifications published to this caller's library.\n *\n * **These are tenant broadcasts, not a per-user inbox.** ``app_notification``\n * has no user column and no read state — ``app_notification_bm`` links a\n * notification to a library and that is the whole model. So ``unread_count`` is\n * always ``0`` here and every notification is returned every time.\n *\n * Giving each member their own read state is a schema change (a\n * ``notification_read`` row per user and notification), not a query change. It\n * is worth doing — a broadcast list that never shrinks is one people stop\n * opening — but it is a decision rather than a port, so it is not made here.\n * @summary List Notifications\n */\nexport const listNotifications = async (params?: ListNotificationsParams, options?: Parameters<typeof request>[1]): Promise<NotificationListRead> => {\n\n return request<NotificationListRead>(getListNotificationsUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getCreateReportUrl = () => {\n\n\n\n\n return `/cvs/reports`\n}\n\n/**\n * Report a playback problem.\n *\n * The identifying fields are taken from the credential, not the body. The\n * legacy took ``adhId``, ``bmId`` and ``bmBibLocaleId`` from the query string\n * and declared no ``Authorization`` at all, so anyone holding the shared\n * ``api_key`` — which every deployed app binary contains — could file a report\n * in any patron's name, at any library. The DTO still carries those three\n * fields, marked transition-only, and this handler ignores every one of them.\n *\n * ``email`` is free text that ends up in a message. Authenticated and\n * rate-limited it is a support channel; unauthenticated it is a spam relay with\n * the library's return address on it.\n * @summary Create Report\n */\nexport const createReport = async (playbackReportWrite: PlaybackReportWrite, options?: Parameters<typeof request>[1]): Promise<PlaybackReportRead> => {\n\n const getHeaders = (h?: NonNullable<RequestInit['headers']>): Record<string, string | readonly string[]> => {\n if (!h) return {};\n if (h instanceof Headers) return Object.fromEntries(h.entries());\n if (Symbol.iterator in h) {\n return Object.fromEntries(\n Array.from(h as Iterable<Iterable<string>>, (entry) => Array.from(entry) as [string, string]),\n );\n }\n const headers: Record<string, string | readonly string[]> = {};\n for (const [name, value] of Object.entries<string | readonly string[] | undefined>(h)) {\n if (value !== undefined) headers[name] = value;\n }\n return headers;\n };\nreturn request<PlaybackReportRead>(getCreateReportUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(playbackReportWrite)\n }\n);}\n\n\n"],"mappings":";;;AAgBA,MAAa,2BAA2B,WAAsC;CAC5E,MAAM,mBAAmB,IAAI,gBAAgB;CAE7C,OAAO,QAAQ,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,WAAW;EAErD,IAAI,UAAU,KAAA,GACZ,iBAAiB,OAAO,KAAK,UAAU,OAAO,SAAS,OAAO,KAAK,CAAC;CAExE,CAAC;CAED,MAAM,oBAAoB,iBAAiB,SAAS;CAEpD,OAAO,kBAAkB,SAAS,IAAI,sBAAsB,sBAAsB;AACpF;;;;;;;;;;;;;;;AAgBA,MAAa,oBAAoB,OAAO,QAAkC,YAA2E;CAEnJ,OAAO,QAA8B,wBAAwB,MAAM,GACnE;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,2BAA2B;CAKtC,OAAO;AACT;;;;;;;;;;;;;;;;AAiBA,MAAa,eAAe,OAAO,qBAA0C,YAAyE;CAElJ,MAAM,cAAc,MAAwF;EAC5G,IAAI,CAAC,GAAG,OAAO,CAAC;EAChB,IAAI,aAAa,SAAS,OAAO,OAAO,YAAY,EAAE,QAAQ,CAAC;EAC/D,IAAI,OAAO,YAAY,GACrB,OAAO,OAAO,YACZ,MAAM,KAAK,IAAkC,UAAU,MAAM,KAAK,KAAK,CAAqB,CAC9F;EAEF,MAAM,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA4B,mBAAmB,GACpD;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,mBAAmB;CAC1C,CACF;AAAE"}
@@ -1,5 +1,5 @@
1
1
 
2
- import { Fn as OpenAtSupplierParams, H as SupplierGrantRead, Hi as DocumentPage, Ot as RatingUpdateWrite, Ri as DocumentSearchWrite, it as ReviewRead, kr as LastPositionWrite, rt as ReviewUpdateWrite, zi as DocumentRead } from "../chunks/index.js";
2
+ import { Bi as DocumentSearchWrite, Fn as OpenAtSupplierParams, H as SupplierGrantRead, Vi as DocumentRead, Wi as DocumentPage, it as ReviewRead, jr as LastPositionWrite, kt as RatingUpdateWrite, rt as ReviewUpdateWrite } from "../chunks/index.js";
3
3
  import { c as request } from "../chunks/client.js";
4
4
  //#region src/api/cvs-documents/cvs-documents.d.ts
5
5
  export declare const getSearchDocumentsUrl: () => string;