@learnorama/mozaik-sdk 0.20.0-staging.61.1 → 0.20.2-staging.63.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.
- package/COURSES.md +18 -1
- package/CVS-PLAYBACK.md +9 -1
- package/OFFLINE.md +14 -2
- package/dist/api/account.d.ts +1 -1
- package/dist/api/account.js.map +1 -1
- package/dist/api/admin-catalogue.d.ts +1 -1
- package/dist/api/admin-catalogue.js.map +1 -1
- package/dist/api/admin-consumption.d.ts +1 -1
- package/dist/api/admin-consumption.js.map +1 -1
- package/dist/api/admin-contracts.d.ts +1 -1
- package/dist/api/admin-contracts.js.map +1 -1
- package/dist/api/admin-customer.d.ts +1 -1
- package/dist/api/admin-customer.js.map +1 -1
- package/dist/api/admin-desk.d.ts +1 -1
- package/dist/api/admin-desk.js.map +1 -1
- package/dist/api/admin-licenses.d.ts +1 -1
- package/dist/api/admin-licenses.js.map +1 -1
- package/dist/api/admin-partner-selections.d.ts +1 -1
- package/dist/api/admin-partner-selections.js.map +1 -1
- package/dist/api/admin-patrons.d.ts +1 -1
- package/dist/api/admin-patrons.js.map +1 -1
- package/dist/api/admin-reviews.d.ts +1 -1
- package/dist/api/admin-reviews.js.map +1 -1
- package/dist/api/admin-roles.d.ts +1 -1
- package/dist/api/admin-roles.js.map +1 -1
- package/dist/api/admin-support.d.ts +1 -1
- package/dist/api/admin-support.js.map +1 -1
- package/dist/api/admin-tenants.d.ts +1 -1
- package/dist/api/admin-tenants.js.map +1 -1
- package/dist/api/admin-tutoring.d.ts +1 -1
- package/dist/api/admin-tutoring.js.map +1 -1
- package/dist/api/admin-vod.d.ts +1 -1
- package/dist/api/admin-vod.js.map +1 -1
- package/dist/api/auth-device.d.ts +1 -1
- package/dist/api/auth-device.js.map +1 -1
- package/dist/api/auth.d.ts +1 -1
- package/dist/api/auth.js.map +1 -1
- package/dist/api/biblio-billing-webhooks.d.ts +1 -1
- package/dist/api/biblio-billing-webhooks.js.map +1 -1
- package/dist/api/biblio-billing.d.ts +1 -1
- package/dist/api/biblio-billing.js.map +1 -1
- package/dist/api/biblio-catalogue.d.ts +7 -1
- package/dist/api/biblio-catalogue.js +14 -1
- package/dist/api/biblio-catalogue.js.map +1 -1
- package/dist/api/biblio-home.d.ts +1 -1
- package/dist/api/biblio-home.js.map +1 -1
- package/dist/api/biblio-learning-author-profiles.d.ts +1 -1
- package/dist/api/biblio-learning-author-profiles.js.map +1 -1
- package/dist/api/biblio-learning-authoring.d.ts +1 -1
- package/dist/api/biblio-learning-authoring.js.map +1 -1
- package/dist/api/biblio-learning-editorial.d.ts +1 -1
- package/dist/api/biblio-learning-editorial.js.map +1 -1
- package/dist/api/biblio-learning-feedback.d.ts +1 -1
- package/dist/api/biblio-learning-feedback.js.map +1 -1
- package/dist/api/biblio-learning-finance.d.ts +1 -1
- package/dist/api/biblio-learning-finance.js.map +1 -1
- package/dist/api/biblio-learning-integrations.d.ts +1 -1
- package/dist/api/biblio-learning-integrations.js.map +1 -1
- package/dist/api/biblio-learning-membership.d.ts +1 -1
- package/dist/api/biblio-learning-membership.js.map +1 -1
- package/dist/api/biblio-learning.d.ts +1 -1
- package/dist/api/biblio-learning.js.map +1 -1
- package/dist/api/biblio-library.d.ts +1 -1
- package/dist/api/biblio-library.js.map +1 -1
- package/dist/api/biblio-nextory.d.ts +1 -1
- package/dist/api/biblio-nextory.js.map +1 -1
- package/dist/api/biblio-press.d.ts +19 -1
- package/dist/api/biblio-press.js +40 -1
- package/dist/api/biblio-press.js.map +1 -1
- package/dist/api/biblio-search.d.ts +1 -1
- package/dist/api/biblio-search.js.map +1 -1
- package/dist/api/biblio-telemetry.d.ts +1 -1
- package/dist/api/biblio-telemetry.js.map +1 -1
- package/dist/api/biblio-youscribe.js.map +1 -1
- package/dist/api/consumption.d.ts +2 -2
- package/dist/api/consumption.js.map +1 -1
- package/dist/api/cvs-app.d.ts +1 -1
- package/dist/api/cvs-app.js.map +1 -1
- package/dist/api/cvs-documents.d.ts +1 -1
- package/dist/api/cvs-documents.js.map +1 -1
- package/dist/api/cvs-favorites.d.ts +1 -1
- package/dist/api/cvs-favorites.js.map +1 -1
- package/dist/api/cvs-ils.d.ts +1 -1
- package/dist/api/cvs-ils.js.map +1 -1
- package/dist/api/cvs-loans.d.ts +1 -1
- package/dist/api/cvs-loans.js.map +1 -1
- package/dist/api/cvs-payments.d.ts +1 -1
- package/dist/api/cvs-payments.js.map +1 -1
- package/dist/api/cvs-streaming.d.ts +1 -1
- package/dist/api/cvs-streaming.js.map +1 -1
- package/dist/api/index.d.ts +3 -3
- package/dist/api/index.js +3 -3
- package/dist/api/partner-catalogue.d.ts +1 -1
- package/dist/api/partner-catalogue.js.map +1 -1
- package/dist/api/partner-reader-nextory.d.ts +1 -1
- package/dist/api/partner-reader-nextory.js.map +1 -1
- package/dist/api/partner-reader-youscribe.d.ts +1 -1
- package/dist/api/partner-reader-youscribe.js.map +1 -1
- package/dist/api/partner-reading.d.ts +1 -1
- package/dist/api/partner-reading.js.map +1 -1
- package/dist/api/profiles.d.ts +1 -1
- package/dist/api/profiles.js.map +1 -1
- package/dist/api/search.d.ts +1 -1
- package/dist/api/search.js.map +1 -1
- package/dist/api/tutoring-catalogue.d.ts +1 -1
- package/dist/api/tutoring-catalogue.js.map +1 -1
- package/dist/api/tutoring-chat.d.ts +1 -1
- package/dist/api/tutoring-chat.js.map +1 -1
- package/dist/api/tutoring-dispatch.d.ts +1 -1
- package/dist/api/tutoring-dispatch.js.map +1 -1
- package/dist/api/tutoring-practitioner.d.ts +1 -1
- package/dist/api/tutoring-practitioner.js.map +1 -1
- package/dist/api/tutoring-requests.d.ts +1 -1
- package/dist/api/tutoring-requests.js.map +1 -1
- package/dist/chunks/client2.d.ts +1 -1
- package/dist/chunks/connection.d.ts +1 -1
- package/dist/chunks/index.d.ts +768 -645
- package/dist/chunks/index2.d.ts +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/models.d.ts +2 -2
- package/dist/models.js +23 -3
- package/dist/models.js.map +1 -1
- package/dist/react/account.d.ts +1 -1
- package/dist/react/account.js +1 -1
- package/dist/react/account.js.map +1 -1
- package/dist/react/admin-catalogue.d.ts +1 -1
- package/dist/react/admin-catalogue.js +1 -1
- package/dist/react/admin-catalogue.js.map +1 -1
- package/dist/react/admin-consumption.d.ts +1 -1
- package/dist/react/admin-consumption.js +1 -1
- package/dist/react/admin-consumption.js.map +1 -1
- package/dist/react/admin-contracts.d.ts +1 -1
- package/dist/react/admin-contracts.js +1 -1
- package/dist/react/admin-contracts.js.map +1 -1
- package/dist/react/admin-customer.d.ts +1 -1
- package/dist/react/admin-customer.js +1 -1
- package/dist/react/admin-customer.js.map +1 -1
- package/dist/react/admin-desk.d.ts +1 -1
- package/dist/react/admin-desk.js +1 -1
- package/dist/react/admin-desk.js.map +1 -1
- package/dist/react/admin-licenses.d.ts +1 -1
- package/dist/react/admin-licenses.js +1 -1
- package/dist/react/admin-licenses.js.map +1 -1
- package/dist/react/admin-partner-selections.d.ts +1 -1
- package/dist/react/admin-partner-selections.js +1 -1
- package/dist/react/admin-partner-selections.js.map +1 -1
- package/dist/react/admin-patrons.d.ts +1 -1
- package/dist/react/admin-patrons.js +1 -1
- package/dist/react/admin-patrons.js.map +1 -1
- package/dist/react/admin-reviews.d.ts +1 -1
- package/dist/react/admin-reviews.js +1 -1
- package/dist/react/admin-reviews.js.map +1 -1
- package/dist/react/admin-roles.d.ts +1 -1
- package/dist/react/admin-roles.js +1 -1
- package/dist/react/admin-roles.js.map +1 -1
- package/dist/react/admin-support.d.ts +1 -1
- package/dist/react/admin-support.js +1 -1
- package/dist/react/admin-support.js.map +1 -1
- package/dist/react/admin-tenants.d.ts +1 -1
- package/dist/react/admin-tenants.js +1 -1
- package/dist/react/admin-tenants.js.map +1 -1
- package/dist/react/admin-tutoring.d.ts +1 -1
- package/dist/react/admin-tutoring.js +1 -1
- package/dist/react/admin-tutoring.js.map +1 -1
- package/dist/react/admin-vod.d.ts +1 -1
- package/dist/react/admin-vod.js +1 -1
- package/dist/react/admin-vod.js.map +1 -1
- package/dist/react/auth-device.d.ts +1 -1
- package/dist/react/auth-device.js +1 -1
- package/dist/react/auth-device.js.map +1 -1
- package/dist/react/auth.d.ts +1 -1
- package/dist/react/auth.js +1 -1
- package/dist/react/auth.js.map +1 -1
- package/dist/react/biblio-billing-webhooks.d.ts +1 -1
- package/dist/react/biblio-billing-webhooks.js +1 -1
- package/dist/react/biblio-billing-webhooks.js.map +1 -1
- package/dist/react/biblio-billing.d.ts +1 -1
- package/dist/react/biblio-billing.js +1 -1
- package/dist/react/biblio-billing.js.map +1 -1
- package/dist/react/biblio-catalogue.d.ts +24 -1
- package/dist/react/biblio-catalogue.js +43 -2
- package/dist/react/biblio-catalogue.js.map +1 -1
- package/dist/react/biblio-home.d.ts +1 -1
- package/dist/react/biblio-home.js +1 -1
- package/dist/react/biblio-home.js.map +1 -1
- package/dist/react/biblio-learning-author-profiles.d.ts +1 -1
- package/dist/react/biblio-learning-author-profiles.js +1 -1
- package/dist/react/biblio-learning-author-profiles.js.map +1 -1
- package/dist/react/biblio-learning-authoring.d.ts +1 -1
- package/dist/react/biblio-learning-authoring.js +1 -1
- package/dist/react/biblio-learning-authoring.js.map +1 -1
- package/dist/react/biblio-learning-editorial.d.ts +1 -1
- package/dist/react/biblio-learning-editorial.js +1 -1
- package/dist/react/biblio-learning-editorial.js.map +1 -1
- package/dist/react/biblio-learning-feedback.d.ts +1 -1
- package/dist/react/biblio-learning-feedback.js +1 -1
- package/dist/react/biblio-learning-feedback.js.map +1 -1
- package/dist/react/biblio-learning-finance.d.ts +1 -1
- package/dist/react/biblio-learning-finance.js +1 -1
- package/dist/react/biblio-learning-finance.js.map +1 -1
- package/dist/react/biblio-learning-integrations.d.ts +1 -1
- package/dist/react/biblio-learning-integrations.js +1 -1
- package/dist/react/biblio-learning-integrations.js.map +1 -1
- package/dist/react/biblio-learning-membership.d.ts +1 -1
- package/dist/react/biblio-learning-membership.js +1 -1
- package/dist/react/biblio-learning-membership.js.map +1 -1
- package/dist/react/biblio-learning.d.ts +1 -1
- package/dist/react/biblio-learning.js +1 -1
- package/dist/react/biblio-learning.js.map +1 -1
- package/dist/react/biblio-library.d.ts +1 -1
- package/dist/react/biblio-library.js +1 -1
- package/dist/react/biblio-library.js.map +1 -1
- package/dist/react/biblio-nextory.d.ts +1 -1
- package/dist/react/biblio-nextory.js +1 -1
- package/dist/react/biblio-nextory.js.map +1 -1
- package/dist/react/biblio-press.d.ts +91 -1
- package/dist/react/biblio-press.js +118 -2
- package/dist/react/biblio-press.js.map +1 -1
- package/dist/react/biblio-search.d.ts +1 -1
- package/dist/react/biblio-search.js +1 -1
- package/dist/react/biblio-search.js.map +1 -1
- package/dist/react/biblio-telemetry.d.ts +1 -1
- package/dist/react/biblio-telemetry.js +1 -1
- package/dist/react/biblio-telemetry.js.map +1 -1
- package/dist/react/biblio-youscribe.d.ts +1 -1
- package/dist/react/biblio-youscribe.js +1 -1
- package/dist/react/biblio-youscribe.js.map +1 -1
- package/dist/react/chat.d.ts +1 -1
- package/dist/react/consumption.d.ts +2 -2
- package/dist/react/consumption.js +1 -1
- package/dist/react/consumption.js.map +1 -1
- package/dist/react/cvs-app.d.ts +1 -1
- package/dist/react/cvs-app.js +1 -1
- package/dist/react/cvs-app.js.map +1 -1
- package/dist/react/cvs-documents.d.ts +1 -1
- package/dist/react/cvs-documents.js +1 -1
- package/dist/react/cvs-documents.js.map +1 -1
- package/dist/react/cvs-favorites.d.ts +1 -1
- package/dist/react/cvs-favorites.js +1 -1
- package/dist/react/cvs-favorites.js.map +1 -1
- package/dist/react/cvs-ils.d.ts +1 -1
- package/dist/react/cvs-ils.js +1 -1
- package/dist/react/cvs-ils.js.map +1 -1
- package/dist/react/cvs-loans.d.ts +1 -1
- package/dist/react/cvs-loans.js +1 -1
- package/dist/react/cvs-loans.js.map +1 -1
- package/dist/react/cvs-payments.d.ts +1 -1
- package/dist/react/cvs-payments.js +1 -1
- package/dist/react/cvs-payments.js.map +1 -1
- package/dist/react/cvs-streaming.d.ts +1 -1
- package/dist/react/cvs-streaming.js +1 -1
- package/dist/react/cvs-streaming.js.map +1 -1
- package/dist/react/index.d.ts +3 -3
- package/dist/react/index.js +3 -3
- package/dist/react/partner-catalogue.d.ts +1 -1
- package/dist/react/partner-catalogue.js +1 -1
- package/dist/react/partner-catalogue.js.map +1 -1
- package/dist/react/partner-reader-nextory.d.ts +1 -1
- package/dist/react/partner-reader-nextory.js +1 -1
- package/dist/react/partner-reader-nextory.js.map +1 -1
- package/dist/react/partner-reader-youscribe.d.ts +1 -1
- package/dist/react/partner-reader-youscribe.js +1 -1
- package/dist/react/partner-reader-youscribe.js.map +1 -1
- package/dist/react/partner-reading.d.ts +1 -1
- package/dist/react/partner-reading.js +1 -1
- package/dist/react/partner-reading.js.map +1 -1
- package/dist/react/profiles.d.ts +1 -1
- package/dist/react/profiles.js +1 -1
- package/dist/react/profiles.js.map +1 -1
- package/dist/react/search.d.ts +1 -1
- package/dist/react/search.js +1 -1
- package/dist/react/search.js.map +1 -1
- package/dist/react/tutoring-catalogue.d.ts +1 -1
- package/dist/react/tutoring-catalogue.js +1 -1
- package/dist/react/tutoring-catalogue.js.map +1 -1
- package/dist/react/tutoring-chat.d.ts +1 -1
- package/dist/react/tutoring-chat.js +1 -1
- package/dist/react/tutoring-chat.js.map +1 -1
- package/dist/react/tutoring-dispatch.d.ts +1 -1
- package/dist/react/tutoring-dispatch.js +1 -1
- package/dist/react/tutoring-dispatch.js.map +1 -1
- package/dist/react/tutoring-practitioner.d.ts +1 -1
- package/dist/react/tutoring-practitioner.js +1 -1
- package/dist/react/tutoring-practitioner.js.map +1 -1
- package/dist/react/tutoring-requests.d.ts +1 -1
- package/dist/react/tutoring-requests.js +1 -1
- package/dist/react/tutoring-requests.js.map +1 -1
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"biblio-learning-author-profiles.js","names":[],"sources":["../../src/api/biblio-learning-author-profiles/biblio-learning-author-profiles.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.20.0\n */\nimport type {\n CourseReviewWrite,\n LearningAssetRead,\n LearningAuthorDefinitionWrite,\n LearningAuthorFragmentsParams,\n LearningAuthorMessageWrite,\n LearningAuthorMessagesParams,\n LearningAuthorProfileAdminPage,\n LearningAuthorProfileAdminRead,\n LearningAuthorProfileCreateWrite,\n LearningAuthorProfilePage,\n LearningAuthorProfileRead,\n LearningAuthorRevisionPage,\n LearningAuthorRevisionRead,\n LearningAuthorRevisionUpdateWrite,\n LearningAuthorRevisionsParams,\n LearningEditorialFragmentDetailRead,\n LearningEditorialFragmentPage,\n LearningEditorialMessagePage,\n LearningEditorialMessageRead,\n LearningOwnAuthorProfilesParams,\n LearningPublicAuthorProfilesParams,\n LearningUploadRead,\n LearningUploadWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningOwnAuthorProfilesUrl = (params?: LearningOwnAuthorProfilesParams,) => {\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 ? `/learning/author/profiles?${stringifiedParams}` : `/learning/author/profiles`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Includes inactive drafts and active public profiles, ordered by author ID. An imported active public snapshot may have no native publishedRevisionId; this does not imply that a publication date is known.\n * @summary List author profiles I can manage\n */\nexport const learningOwnAuthorProfiles = async (params?: LearningOwnAuthorProfilesParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminPage> => {\n\n return request<LearningAuthorProfileAdminPage>(getLearningOwnAuthorProfilesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateAuthorProfileUrl = () => {\n\n\n\n\n return `/learning/author/profiles`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Creates an inactive teaching profile and its initial editable revision. The definition is not public until approved. Omitting authorId creates a new public author identity; binding an existing authorId or another ownerUserId requires global authority. Portrait assets must be eligible images in the chosen catalogue.\n * @summary Create an author profile and its first draft\n */\nexport const learningCreateAuthorProfile = async (learningAuthorProfileCreateWrite: LearningAuthorProfileCreateWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminRead> => {\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<LearningAuthorProfileAdminRead>(getLearningCreateAuthorProfileUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorProfileCreateWrite)\n }\n);}\n\n\nexport const getLearningAuthorProfileAdminUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Returns ownership and the native published revision pointer without exposing raw provider metadata. authorId is the existing public author identity. A null publishedRevisionId can describe a newly created profile or an imported public snapshot; use isActive and revision history for context.\n * @summary Read an author's private profile metadata\n */\nexport const learningAuthorProfileAdmin = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminRead> => {\n\n return request<LearningAuthorProfileAdminRead>(getLearningAuthorProfileAdminUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorMessagesUrl = (authorId: number,\n params?: LearningAuthorMessagesParams,) => {\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 ? `/learning/author/profiles/${authorId}/messages?${stringifiedParams}` : `/learning/author/profiles/${authorId}/messages`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID. Includes native profile discussion and matching imported source messages when available. Author messages do not carry courseId or course revisionId. Historical messages can have unknown author attribution or creation date.\n * @summary List private editorial messages for an author\n */\nexport const learningAuthorMessages = async (authorId: number,\n params?: LearningAuthorMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningAuthorMessagesUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAddAuthorMessageUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/messages`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Appends a message to the profile's editorial discussion, attributed to the effective profile. The source object fields identify the native LearningAuthorProfile subject; they are not a course revision reference. Messages do not change publication status.\n * @summary Add a private author profile message\n */\nexport const learningAddAuthorMessage = async (authorId: number,\n learningAuthorMessageWrite: LearningAuthorMessageWrite, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessageRead> => {\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<LearningEditorialMessageRead>(getLearningAddAuthorMessageUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorMessageWrite)\n }\n);}\n\n\nexport const getLearningPreviewAuthorPortraitUrl = (authorId: number,\n assetId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/portraits/${assetId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Returns a delivery descriptor for a candidate image that the caller may use in this profile's catalogue. assetId may refer to a completed private portrait upload or eligible teaching image. Previewing does not publish it; the public portrait remains tied to the current public profile.\n * @summary Preview an eligible private author portrait\n */\nexport const learningPreviewAuthorPortrait = async (authorId: number,\n assetId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningPreviewAuthorPortraitUrl(authorId,assetId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorFragmentsUrl = (authorId: number,\n params?: LearningAuthorFragmentsParams,) => {\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 ? `/learning/author/profiles/${authorId}/revision-fragments?${stringifiedParams}` : `/learning/author/profiles/${authorId}/revision-fragments`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Returns summaries for the profile's matched source identity, ordered by fragment ID. No source identity match produces an empty collection. Payload bytes are available from the scoped detail endpoint.\n * @summary List an author's imported revision fragments\n */\nexport const learningAuthorFragments = async (authorId: number,\n params?: LearningAuthorFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningAuthorFragmentsUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorFragmentUrl = (authorId: number,\n fragmentId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revision-fragments/${fragmentId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. fragmentId must match the selected author's source identity and catalogue. sourcePayload contains opaque base64-encoded source bytes when retained; inspect them as evidence, never execute or deserialize them as trusted application objects.\n * @summary Read an author's imported revision fragment\n */\nexport const learningAuthorFragment = async (authorId: number,\n fragmentId: number, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentDetailRead> => {\n\n return request<LearningEditorialFragmentDetailRead>(getLearningAuthorFragmentUrl(authorId,fragmentId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorRevisionsUrl = (authorId: number,\n params?: LearningAuthorRevisionsParams,) => {\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 ? `/learning/author/profiles/${authorId}/revisions?${stringifiedParams}` : `/learning/author/profiles/${authorId}/revisions`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by revision ID descending. These are complete native definitions. Partial imported revisions are available separately from revision-fragments and are not promoted into this history. version counts revisions; editVersion counts replacements within a draft.\n * @summary List an author's native editorial revisions\n */\nexport const learningAuthorRevisions = async (authorId: number,\n params?: LearningAuthorRevisionsParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionPage> => {\n\n return request<LearningAuthorRevisionPage>(getLearningAuthorRevisionsUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningDraftAuthorRevisionUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Creates the next numbered revision from the supplied full definition. No existing draft or submitted revision may be present. Rejected or published definitions remain in history. The public profile stays unchanged until this draft is submitted and approved.\n * @summary Create the next author profile draft\n */\nexport const learningDraftAuthorRevision = async (authorId: number,\n learningAuthorDefinitionWrite: LearningAuthorDefinitionWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningDraftAuthorRevisionUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorDefinitionWrite)\n }\n);}\n\n\nexport const getLearningEditAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Replaces the full draft definition and increments editVersion. expectedEditVersion must match the latest response. Only draft status is editable; a rejected profile revision needs a new successor. Neither this edit nor a private portrait preview changes the public profile.\n * @summary Replace an editable author profile draft\n */\nexport const learningEditAuthorRevision = async (authorId: number,\n revisionId: number,\n learningAuthorRevisionUpdateWrite: LearningAuthorRevisionUpdateWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningEditAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorRevisionUpdateWrite)\n }\n);}\n\n\nexport const getLearningReviewAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}/review`\n}\n\n/**\n * Requires review authority for the author's active catalogue or global authority; ownership alone is insufficient. Only submitted revisions can be reviewed. Approval atomically updates the public identity, biography, portrait and activity flag, and supersedes the previous published revision. Rejection retains the current public profile and stores the review note.\n * @summary Approve or reject an author profile revision\n */\nexport const learningReviewAuthorRevision = async (authorId: number,\n revisionId: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningReviewAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}/submit`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Only a draft may be submitted. Revalidates the portrait, records submittedAt and freezes editing while awaiting review. The currently public biography and portrait remain in place until approval.\n * @summary Submit an author profile draft for review\n */\nexport const learningSubmitAuthorRevision = async (authorId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\n\n return request<LearningAuthorRevisionRead>(getLearningSubmitAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningReserveAuthorPortraitUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/uploads`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Reserves a PNG or JPEG of at most 10 MiB. Send exactly sizeBytes raw bytes with the declared Content-Type to uploadUrl using method before expiresAt. Reservation alone creates no usable portrait; reference the asset returned after upload completion in an author revision, then submit and approve it to make it public.\n * @summary Reserve a private author portrait upload\n */\nexport const learningReserveAuthorPortrait = async (authorId: number,\n learningUploadWrite: LearningUploadWrite, options?: Parameters<typeof request>[1]): Promise<LearningUploadRead> => {\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<LearningUploadRead>(getLearningReserveAuthorPortraitUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningUploadWrite)\n }\n);}\n\n\nexport const getLearningPublicAuthorProfilesUrl = (params?: LearningPublicAuthorProfilesParams,) => {\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 ? `/learning/authors?${stringifiedParams}` : `/learning/authors`\n}\n\n/**\n * Requires an authenticated effective profile in the learning context. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Lists active profiles in active catalogues, ordered by author ID. Returns the current public projection, including imported public snapshots, with no private ownership, draft or review metadata. portraitUrl is the API locator for a separate media delivery request.\n * @summary List published teaching author profiles\n */\nexport const learningPublicAuthorProfiles = async (params?: LearningPublicAuthorProfilesParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfilePage> => {\n\n return request<LearningAuthorProfilePage>(getLearningPublicAuthorProfilesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningPublicAuthorProfileUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/authors/${authorId}`\n}\n\n/**\n * Returns the current public profile to an authenticated effective profile in the learning context. Both the profile and its catalogue must be active. Pending drafts and review notes are private. Follow portraitUrl through the portrait endpoint to obtain a delivery descriptor.\n * @summary Read a published teaching author profile\n */\nexport const learningPublicAuthorProfile = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileRead> => {\n\n return request<LearningAuthorProfileRead>(getLearningPublicAuthorProfileUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorPortraitUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/authors/${authorId}/portrait`\n}\n\n/**\n * Requires an active public author in an active catalogue. Returns a media delivery descriptor for the approved or imported public portrait, not image bytes. Draft portrait assets are accessible only through the private preview endpoint. Delivery URLs may expire and do not disclose storage keys or provider metadata.\n * @summary Get the currently public author portrait\n */\nexport const learningAuthorPortrait = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningAuthorPortraitUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAmCA,MAAa,mCAAmC,WAA8C;CAC5F,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,6BAA6B,sBAAsB;AAC3F;;;;;AAMA,MAAa,4BAA4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,UAAsD,CAAC;EAC7D,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAA4B,oCAAoC,QAAQ,GAC7E;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,mBAAmB;CAC1C,CACF;AAAE;AAGF,MAAa,sCAAsC,WAAiD;CAClG,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,qBAAqB,sBAAsB;AACnF;;;;;AAMA,MAAa,+BAA+B,OAAO,QAA6C,YAAgF;CAE9K,OAAO,QAAmC,mCAAmC,MAAM,GACnF;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,qCAAqC,aAAsB;CAKtE,OAAO,qBAAqB;AAC9B;;;;;AAMA,MAAa,8BAA8B,OAAO,UAAkB,YAAgF;CAElJ,OAAO,QAAmC,kCAAkC,QAAQ,GACpF;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,gCAAgC,aAAsB;CAKjE,OAAO,qBAAqB,SAAS;AACvC;;;;;AAMA,MAAa,yBAAyB,OAAO,UAAkB,YAAwE;CAErI,OAAO,QAA2B,6BAA6B,QAAQ,GACvE;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
|
|
1
|
+
{"version":3,"file":"biblio-learning-author-profiles.js","names":[],"sources":["../../src/api/biblio-learning-author-profiles/biblio-learning-author-profiles.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.20.2\n */\nimport type {\n CourseReviewWrite,\n LearningAssetRead,\n LearningAuthorDefinitionWrite,\n LearningAuthorFragmentsParams,\n LearningAuthorMessageWrite,\n LearningAuthorMessagesParams,\n LearningAuthorProfileAdminPage,\n LearningAuthorProfileAdminRead,\n LearningAuthorProfileCreateWrite,\n LearningAuthorProfilePage,\n LearningAuthorProfileRead,\n LearningAuthorRevisionPage,\n LearningAuthorRevisionRead,\n LearningAuthorRevisionUpdateWrite,\n LearningAuthorRevisionsParams,\n LearningEditorialFragmentDetailRead,\n LearningEditorialFragmentPage,\n LearningEditorialMessagePage,\n LearningEditorialMessageRead,\n LearningOwnAuthorProfilesParams,\n LearningPublicAuthorProfilesParams,\n LearningUploadRead,\n LearningUploadWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningOwnAuthorProfilesUrl = (params?: LearningOwnAuthorProfilesParams,) => {\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 ? `/learning/author/profiles?${stringifiedParams}` : `/learning/author/profiles`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Includes inactive drafts and active public profiles, ordered by author ID. An imported active public snapshot may have no native publishedRevisionId; this does not imply that a publication date is known.\n * @summary List author profiles I can manage\n */\nexport const learningOwnAuthorProfiles = async (params?: LearningOwnAuthorProfilesParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminPage> => {\n\n return request<LearningAuthorProfileAdminPage>(getLearningOwnAuthorProfilesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateAuthorProfileUrl = () => {\n\n\n\n\n return `/learning/author/profiles`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Creates an inactive teaching profile and its initial editable revision. The definition is not public until approved. Omitting authorId creates a new public author identity; binding an existing authorId or another ownerUserId requires global authority. Portrait assets must be eligible images in the chosen catalogue.\n * @summary Create an author profile and its first draft\n */\nexport const learningCreateAuthorProfile = async (learningAuthorProfileCreateWrite: LearningAuthorProfileCreateWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminRead> => {\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<LearningAuthorProfileAdminRead>(getLearningCreateAuthorProfileUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorProfileCreateWrite)\n }\n);}\n\n\nexport const getLearningAuthorProfileAdminUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Returns ownership and the native published revision pointer without exposing raw provider metadata. authorId is the existing public author identity. A null publishedRevisionId can describe a newly created profile or an imported public snapshot; use isActive and revision history for context.\n * @summary Read an author's private profile metadata\n */\nexport const learningAuthorProfileAdmin = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileAdminRead> => {\n\n return request<LearningAuthorProfileAdminRead>(getLearningAuthorProfileAdminUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorMessagesUrl = (authorId: number,\n params?: LearningAuthorMessagesParams,) => {\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 ? `/learning/author/profiles/${authorId}/messages?${stringifiedParams}` : `/learning/author/profiles/${authorId}/messages`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID. Includes native profile discussion and matching imported source messages when available. Author messages do not carry courseId or course revisionId. Historical messages can have unknown author attribution or creation date.\n * @summary List private editorial messages for an author\n */\nexport const learningAuthorMessages = async (authorId: number,\n params?: LearningAuthorMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningAuthorMessagesUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAddAuthorMessageUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/messages`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Appends a message to the profile's editorial discussion, attributed to the effective profile. The source object fields identify the native LearningAuthorProfile subject; they are not a course revision reference. Messages do not change publication status.\n * @summary Add a private author profile message\n */\nexport const learningAddAuthorMessage = async (authorId: number,\n learningAuthorMessageWrite: LearningAuthorMessageWrite, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessageRead> => {\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<LearningEditorialMessageRead>(getLearningAddAuthorMessageUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorMessageWrite)\n }\n);}\n\n\nexport const getLearningPreviewAuthorPortraitUrl = (authorId: number,\n assetId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/portraits/${assetId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Returns a delivery descriptor for a candidate image that the caller may use in this profile's catalogue. assetId may refer to a completed private portrait upload or eligible teaching image. Previewing does not publish it; the public portrait remains tied to the current public profile.\n * @summary Preview an eligible private author portrait\n */\nexport const learningPreviewAuthorPortrait = async (authorId: number,\n assetId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningPreviewAuthorPortraitUrl(authorId,assetId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorFragmentsUrl = (authorId: number,\n params?: LearningAuthorFragmentsParams,) => {\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 ? `/learning/author/profiles/${authorId}/revision-fragments?${stringifiedParams}` : `/learning/author/profiles/${authorId}/revision-fragments`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Returns summaries for the profile's matched source identity, ordered by fragment ID. No source identity match produces an empty collection. Payload bytes are available from the scoped detail endpoint.\n * @summary List an author's imported revision fragments\n */\nexport const learningAuthorFragments = async (authorId: number,\n params?: LearningAuthorFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningAuthorFragmentsUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorFragmentUrl = (authorId: number,\n fragmentId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revision-fragments/${fragmentId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. fragmentId must match the selected author's source identity and catalogue. sourcePayload contains opaque base64-encoded source bytes when retained; inspect them as evidence, never execute or deserialize them as trusted application objects.\n * @summary Read an author's imported revision fragment\n */\nexport const learningAuthorFragment = async (authorId: number,\n fragmentId: number, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentDetailRead> => {\n\n return request<LearningEditorialFragmentDetailRead>(getLearningAuthorFragmentUrl(authorId,fragmentId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorRevisionsUrl = (authorId: number,\n params?: LearningAuthorRevisionsParams,) => {\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 ? `/learning/author/profiles/${authorId}/revisions?${stringifiedParams}` : `/learning/author/profiles/${authorId}/revisions`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by revision ID descending. These are complete native definitions. Partial imported revisions are available separately from revision-fragments and are not promoted into this history. version counts revisions; editVersion counts replacements within a draft.\n * @summary List an author's native editorial revisions\n */\nexport const learningAuthorRevisions = async (authorId: number,\n params?: LearningAuthorRevisionsParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionPage> => {\n\n return request<LearningAuthorRevisionPage>(getLearningAuthorRevisionsUrl(authorId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningDraftAuthorRevisionUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Creates the next numbered revision from the supplied full definition. No existing draft or submitted revision may be present. Rejected or published definitions remain in history. The public profile stays unchanged until this draft is submitted and approved.\n * @summary Create the next author profile draft\n */\nexport const learningDraftAuthorRevision = async (authorId: number,\n learningAuthorDefinitionWrite: LearningAuthorDefinitionWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningDraftAuthorRevisionUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorDefinitionWrite)\n }\n);}\n\n\nexport const getLearningEditAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Replaces the full draft definition and increments editVersion. expectedEditVersion must match the latest response. Only draft status is editable; a rejected profile revision needs a new successor. Neither this edit nor a private portrait preview changes the public profile.\n * @summary Replace an editable author profile draft\n */\nexport const learningEditAuthorRevision = async (authorId: number,\n revisionId: number,\n learningAuthorRevisionUpdateWrite: LearningAuthorRevisionUpdateWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningEditAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAuthorRevisionUpdateWrite)\n }\n);}\n\n\nexport const getLearningReviewAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}/review`\n}\n\n/**\n * Requires review authority for the author's active catalogue or global authority; ownership alone is insufficient. Only submitted revisions can be reviewed. Approval atomically updates the public identity, biography, portrait and activity flag, and supersedes the previous published revision. Rejection retains the current public profile and stores the review note.\n * @summary Approve or reject an author profile revision\n */\nexport const learningReviewAuthorRevision = async (authorId: number,\n revisionId: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\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<LearningAuthorRevisionRead>(getLearningReviewAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitAuthorRevisionUrl = (authorId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/revisions/${revisionId}/submit`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Only a draft may be submitted. Revalidates the portrait, records submittedAt and freezes editing while awaiting review. The currently public biography and portrait remain in place until approval.\n * @summary Submit an author profile draft for review\n */\nexport const learningSubmitAuthorRevision = async (authorId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorRevisionRead> => {\n\n return request<LearningAuthorRevisionRead>(getLearningSubmitAuthorRevisionUrl(authorId,revisionId),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningReserveAuthorPortraitUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/author/profiles/${authorId}/uploads`\n}\n\n/**\n * Visible only to the profile owner, a reviewer of its active catalogue, or a global operator. Support impersonation and dependent profiles are rejected. Reserves a PNG or JPEG of at most 10 MiB. Send exactly sizeBytes raw bytes with the declared Content-Type to uploadUrl using method before expiresAt. Reservation alone creates no usable portrait; reference the asset returned after upload completion in an author revision, then submit and approve it to make it public.\n * @summary Reserve a private author portrait upload\n */\nexport const learningReserveAuthorPortrait = async (authorId: number,\n learningUploadWrite: LearningUploadWrite, options?: Parameters<typeof request>[1]): Promise<LearningUploadRead> => {\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<LearningUploadRead>(getLearningReserveAuthorPortraitUrl(authorId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningUploadWrite)\n }\n);}\n\n\nexport const getLearningPublicAuthorProfilesUrl = (params?: LearningPublicAuthorProfilesParams,) => {\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 ? `/learning/authors?${stringifiedParams}` : `/learning/authors`\n}\n\n/**\n * Requires an authenticated effective profile in the learning context. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Lists active profiles in active catalogues, ordered by author ID. Returns the current public projection, including imported public snapshots, with no private ownership, draft or review metadata. portraitUrl is the API locator for a separate media delivery request.\n * @summary List published teaching author profiles\n */\nexport const learningPublicAuthorProfiles = async (params?: LearningPublicAuthorProfilesParams, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfilePage> => {\n\n return request<LearningAuthorProfilePage>(getLearningPublicAuthorProfilesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningPublicAuthorProfileUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/authors/${authorId}`\n}\n\n/**\n * Returns the current public profile to an authenticated effective profile in the learning context. Both the profile and its catalogue must be active. Pending drafts and review notes are private. Follow portraitUrl through the portrait endpoint to obtain a delivery descriptor.\n * @summary Read a published teaching author profile\n */\nexport const learningPublicAuthorProfile = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAuthorProfileRead> => {\n\n return request<LearningAuthorProfileRead>(getLearningPublicAuthorProfileUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAuthorPortraitUrl = (authorId: number,) => {\n\n\n\n\n return `/learning/authors/${authorId}/portrait`\n}\n\n/**\n * Requires an active public author in an active catalogue. Returns a media delivery descriptor for the approved or imported public portrait, not image bytes. Draft portrait assets are accessible only through the private preview endpoint. Delivery URLs may expire and do not disclose storage keys or provider metadata.\n * @summary Get the currently public author portrait\n */\nexport const learningAuthorPortrait = async (authorId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningAuthorPortraitUrl(authorId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAmCA,MAAa,mCAAmC,WAA8C;CAC5F,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,6BAA6B,sBAAsB;AAC3F;;;;;AAMA,MAAa,4BAA4B,OAAO,QAA0C,YAAqF;CAE7K,OAAO,QAAwC,gCAAgC,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rite, Gc as LearningLibraryPage, Gl as LearningCaptionWrite, Hc as LearningLibraryWrite, Hl as LearningCatalogueRead, Jc as LearningLibraryDocumentRead, Kc as LearningLibraryRead, Ol as LearningCourseAdminPage, Pc as LearningListRevisionsParams, Rc as LearningListLibraryVersionsParams, Rl as LearningCatalogueWrite, Uc as LearningLibraryVersionWrite, Ul as LearningCatalogueGrantWrite, Vl as LearningCatalogueListRead, Wc as LearningLibraryVersionPage, Xc as LearningLibraryVersionRead, Xv as CourseRevisionRead, dc as LearningPathAdminRead, fc as LearningPathWrite, kl as LearningCourseAdminRead, nv as CourseRevisionPage, rv as CourseReviewWrite, tv as CourseRevisionWriteInput, uc as LearningPathAssessmentRead, uv as LearningAssessmentWriteInput, xu as LearningAssetWrite, xv as CourseAuthorRevisionRead, zc as LearningListLibrariesParams } from "../chunks/index.js";
|
|
3
3
|
import { c as request } from "../chunks/client.js";
|
|
4
4
|
//#region src/api/biblio-learning-authoring/biblio-learning-authoring.d.ts
|
|
5
5
|
export declare const getLearningListAuthorCataloguesUrl: () => string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"biblio-learning-authoring.js","names":[],"sources":["../../src/api/biblio-learning-authoring/biblio-learning-authoring.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.20.0\n */\nimport type {\n CourseAuthorRevisionRead,\n CourseReviewWrite,\n CourseRevisionPage,\n CourseRevisionRead,\n CourseRevisionWriteInput,\n LearningAssessmentWriteInput,\n LearningAssetRead,\n LearningAssetWrite,\n LearningCaptionWrite,\n LearningCatalogueGrantWrite,\n LearningCatalogueListRead,\n LearningCatalogueRead,\n LearningCatalogueWrite,\n LearningCourseAdminPage,\n LearningCourseAdminRead,\n LearningCourseCreateWrite,\n LearningCourseSettingsWrite,\n LearningLibraryDocumentRead,\n LearningLibraryPage,\n LearningLibraryRead,\n LearningLibraryVersionPage,\n LearningLibraryVersionRead,\n LearningLibraryVersionWrite,\n LearningLibraryWrite,\n LearningListAuthorCoursesParams,\n LearningListLibrariesParams,\n LearningListLibraryVersionsParams,\n LearningListRevisionsParams,\n LearningPathAdminRead,\n LearningPathAssessmentRead,\n LearningPathWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningListAuthorCataloguesUrl = () => {\n\n\n\n\n return `/learning/author/catalogues`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Lists active catalogues with creation, review or finance authority. Review permission also enables creation; finance permission alone does not. The collection is ordered by catalogue ID and is not paginated.\n * @summary List my authoring catalogues\n */\nexport const learningListAuthorCatalogues = async ( options?: Parameters<typeof request>[1]): Promise<LearningCatalogueListRead> => {\n\n return request<LearningCatalogueListRead>(getLearningListAuthorCataloguesUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateAuthorCatalogueUrl = () => {\n\n\n\n\n return `/learning/author/catalogues`\n}\n\n/**\n * Requires global catalogue write authority and rejects support impersonation. Creates an active authoring catalogue; the returned capability flags describe the operator making this request.\n * @summary Create a learning catalogue\n */\nexport const learningCreateAuthorCatalogue = async (learningCatalogueWrite: LearningCatalogueWrite, options?: Parameters<typeof request>[1]): Promise<LearningCatalogueRead> => {\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<LearningCatalogueRead>(getLearningCreateAuthorCatalogueUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCatalogueWrite)\n }\n);}\n\n\nexport const getLearningSetCatalogueAuthorityUrl = (catalogueId: number,) => {\n\n\n\n\n return `/learning/author/catalogues/${catalogueId}/authority`\n}\n\n/**\n * Requires global catalogue write authority. Replaces all three grants for the selected active independent account, including revocation when all flags are false. The reason is recorded for audit. Successful updates return 204 with no response body.\n * @summary Replace an author's catalogue permissions\n */\nexport const learningSetCatalogueAuthority = async (catalogueId: number,\n learningCatalogueGrantWrite: LearningCatalogueGrantWrite, 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>(getLearningSetCatalogueAuthorityUrl(catalogueId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCatalogueGrantWrite)\n }\n);}\n\n\nexport const getLearningListAuthorCoursesUrl = (params?: LearningListAuthorCoursesParams,) => {\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 ? `/learning/author/courses?${stringifiedParams}` : `/learning/author/courses`\n}\n\n/**\n * Returns courses assigned to the effective author and courses in active catalogues they may review. Global administrators and support readers can see all courses. Dependent profiles and support impersonation are refused. Pagination counts this authorized scope and sorts by course ID ascending; draft courses are included.\n * @summary List courses available to the author\n */\nexport const learningListAuthorCourses = async (params?: LearningListAuthorCoursesParams, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminPage> => {\n\n return request<LearningCourseAdminPage>(getLearningListAuthorCoursesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateCourseUrl = () => {\n\n\n\n\n return `/learning/author/courses`\n}\n\n/**\n * Create an inactive course from a title in an authorized catalogue, then register media and create an edition. Binding an existing catalogue contentId, or creating without catalogueId, requires global administration. Assigning other authors requires curator authority. Publication activates a new course; this request alone does not make it readable.\n * @summary Create a native course shell\n */\nexport const learningCreateCourse = async (learningCourseCreateWrite: LearningCourseCreateWrite, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminRead> => {\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<LearningCourseAdminRead>(getLearningCreateCourseUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCourseCreateWrite)\n }\n);}\n\n\nexport const getLearningUpdateCourseSettingsUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}`\n}\n\n/**\n * Requires course curator or global administrator authority and an audit reason. Non-null scalar fields replace their current values; null or omitted values leave them unchanged. authorIds replaces the complete author set, including clearing it with an empty list. A course must have a published edition before isActive can be true.\n * @summary Update publication and author settings\n */\nexport const learningUpdateCourseSettings = async (courseId: number,\n learningCourseSettingsWrite: LearningCourseSettingsWrite, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminRead> => {\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<LearningCourseAdminRead>(getLearningUpdateCourseSettingsUrl(courseId),\n {\n ...options,\n method: 'PATCH',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCourseSettingsWrite)\n }\n);}\n\n\nexport const getLearningRegisterAssetUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/assets`\n}\n\n/**\n * Requires edit authority on the course. Registers an immutable media reference for use in edition definitions. Vimeo requires a numeric video ID; external resources require HTTPS without credentials; HTML is sanitized; storage keys must identify an existing object under this author's learning prefix. The response identifies the asset and does not issue a playback URL. For new file bytes use the upload reservation workflow.\n * @summary Register a course media resource\n */\nexport const learningRegisterAsset = async (courseId: number,\n learningAssetWrite: LearningAssetWrite, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\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<LearningAssetRead>(getLearningRegisterAssetUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAssetWrite)\n }\n);}\n\n\nexport const getLearningAttachCaptionsUrl = (courseId: number,\n assetId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/assets/${assetId}/captions`\n}\n\n/**\n * Requires course edit authority. First upload validated UTF-8 WebVTT to the same course, then reference its asset ID here. Returns a new immutable media variant; existing editions keep their original asset. Repeating the original asset, caption asset and language returns the existing variant. Put the returned assetId into a draft edition to publish the captions.\n * @summary Create a captioned variant of course audio or video\n */\nexport const learningAttachCaptions = async (courseId: number,\n assetId: number,\n learningCaptionWrite: LearningCaptionWrite, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\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<LearningAssetRead>(getLearningAttachCaptionsUrl(courseId,assetId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCaptionWrite)\n }\n);}\n\n\nexport const getLearningListRevisionsUrl = (courseId: number,\n params?: LearningListRevisionsParams,) => {\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 ? `/learning/author/courses/${courseId}/revisions?${stringifiedParams}` : `/learning/author/courses/${courseId}/revisions`\n}\n\n/**\n * Requires read authority on this course. Returns draft, submitted, published, rejected and superseded editions, newest version first. version identifies the course edition; editVersion is the optimistic concurrency counter within a working edition.\n * @summary List the course's edition history\n */\nexport const learningListRevisions = async (courseId: number,\n params?: LearningListRevisionsParams, options?: Parameters<typeof request>[1]): Promise<CourseRevisionPage> => {\n\n return request<CourseRevisionPage>(getLearningListRevisionsUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateRevisionUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions`\n}\n\n/**\n * Requires course edit authority. Creates a complete edition with the next version number; only one draft or submitted edition may exist for a course. Asset and library references must be available to this course. Chapters contain 1–2000 lessons with unique keys across the edition; the serialized authoring definition is limited to 2,000,000 bytes. Published editions and existing enrollments remain pinned to their definitions.\n * @summary Create the next draft edition\n */\nexport const learningCreateRevision = async (courseId: number,\n courseRevisionWriteInput: CourseRevisionWriteInput, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningCreateRevisionUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseRevisionWriteInput)\n }\n);}\n\n\nexport const getLearningReadAuthorRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}`\n}\n\n/**\n * Requires authoring read authority and checks that revisionId belongs to courseId. Returns editorial content, lessons, resources, vocabularies and private assessment solutions. Read revision.editVersion before replacing a changed definition. This author-only representation includes grading keys that are deliberately absent from reader questions.\n * @summary Read a complete editable edition definition\n */\nexport const learningReadAuthorRevision = async (courseId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<CourseAuthorRevisionRead> => {\n\n return request<CourseAuthorRevisionRead>(getLearningReadAuthorRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningReplaceRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}`\n}\n\n/**\n * Replaces the entire editorial and lesson graph of a draft or rejected edition. Send the editVersion last read as expectedEditVersion. An identical definition is an idempotent replay; a changed definition requires a matching version and increments editVersion. A changed rejected edition returns to draft and clears its review note and submission date. Published and submitted editions cannot be edited.\n * @summary Replace a draft edition with concurrency protection\n */\nexport const learningReplaceRevision = async (courseId: number,\n revisionId: number,\n courseRevisionWriteInput: CourseRevisionWriteInput, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningReplaceRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseRevisionWriteInput)\n }\n);}\n\n\nexport const getLearningReviewRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}/review`\n}\n\n/**\n * Requires course curator or global administrator authority. Approval revalidates materials, publishes this edition, supersedes its published predecessor, updates catalogue editorial fields and activates the course. Existing readers retain their selected edition until they explicitly upgrade. Rejection returns the edition for editing. Every decision requires a review note; repeated decisions return 409 once the edition leaves submitted.\n * @summary Publish or reject a submitted edition\n */\nexport const learningReviewRevision = async (courseId: number,\n revisionId: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningReviewRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}/submit`\n}\n\n/**\n * Requires course edit authority. Moves draft to submitted and records submittedAt; reviewers can then approve or reject it. Submission locks the definition against editing. This transition is not replay-idempotent: submitting an already submitted edition returns 409.\n * @summary Submit a draft edition for review\n */\nexport const learningSubmitRevision = async (courseId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\n\n return request<CourseRevisionRead>(getLearningSubmitRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningListLibrariesUrl = (params?: LearningListLibrariesParams,) => {\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 ? `/learning/author/libraries?${stringifiedParams}` : `/learning/author/libraries`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Lists owned or shared libraries for creators, all libraries in reviewable active catalogues for reviewers, and all libraries for global operators. Ordered by library ID. publishedVersion=0 means no native published version is selected.\n * @summary List reusable teaching libraries\n */\nexport const learningListLibraries = async (params?: LearningListLibrariesParams, options?: Parameters<typeof request>[1]): Promise<LearningLibraryPage> => {\n\n return request<LearningLibraryPage>(getLearningListLibrariesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateLibraryUrl = () => {\n\n\n\n\n return `/learning/author/libraries`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Creates an empty assessment or vocabulary container owned by the caller. A null catalogueId requires global authority. shared allows catalogue peers to reuse published material; it does not grant them editing rights. Create a version separately.\n * @summary Create a reusable teaching library\n */\nexport const learningCreateLibrary = async (learningLibraryWrite: LearningLibraryWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryRead> => {\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<LearningLibraryRead>(getLearningCreateLibraryUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryWrite)\n }\n);}\n\n\nexport const getLearningListLibraryVersionsUrl = (libraryId: number,\n params?: LearningListLibraryVersionsParams,) => {\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 ? `/learning/author/libraries/${libraryId}/versions?${stringifiedParams}` : `/learning/author/libraries/${libraryId}/versions`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by version descending. Owners, reviewers and global operators can read drafts; other eligible users see published and superseded versions only. sealed is authoritative for editing: imported or referenced material can be sealed even with a draft status.\n * @summary List versions of a teaching library\n */\nexport const learningListLibraryVersions = async (libraryId: number,\n params?: LearningListLibraryVersionsParams, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionPage> => {\n\n return request<LearningLibraryVersionPage>(getLearningListLibraryVersionsUrl(libraryId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateLibraryVersionUrl = (libraryId: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Creates the next numbered draft without changing any previous definition. Supply exactly one assessment or vocabulary matching the library kind. There must be no submitted version or unsealed working draft. Sealed source drafts do not block a successor. Referenced questions must be published and accessible; sourceLessonKeys are not accepted for libraries.\n * @summary Create a successor library version\n */\nexport const learningCreateLibraryVersion = async (libraryId: number,\n learningLibraryVersionWrite: LearningLibraryVersionWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningCreateLibraryVersionUrl(libraryId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryVersionWrite)\n }\n);}\n\n\nexport const getLearningReadLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Returns the full authoring definition and stable question references. version is the library's sequential version number, not materialId. Draft visibility is restricted to owner/reviewer/global operator. Answer keys are part of this private authoring contract. A sealed source snapshot must be copied into a successor to change it.\n * @summary Read a teaching library version\n */\nexport const learningReadLibraryVersion = async (libraryId: number,\n version: number, options?: Parameters<typeof request>[1]): Promise<LearningLibraryDocumentRead> => {\n\n return request<LearningLibraryDocumentRead>(getLearningReadLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningReplaceLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Replaces an unsealed draft or rejected version. Supply the current expectedEditVersion when changing the definition; a semantic no-op returns the same version. Submitted, published, superseded, imported and referenced definitions are immutable. Create a successor for sealed material instead. Exactly one matching assessment or vocabulary is required.\n * @summary Replace an editable library definition\n */\nexport const learningReplaceLibraryVersion = async (libraryId: number,\n version: number,\n learningLibraryVersionWrite: LearningLibraryVersionWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningReplaceLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryVersionWrite)\n }\n);}\n\n\nexport const getLearningReviewLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}/review`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review or global authority. Approval revalidates resources, publishes this version and supersedes the previously published version. Rejection records the decision and makes an unpinned definition editable again. The supplied note is audited; it is not a field of the returned version summary.\n * @summary Approve or reject a submitted library version\n */\nexport const learningReviewLibraryVersion = async (libraryId: number,\n version: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningReviewLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}/submit`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Only an unsealed draft can be submitted. Submission locks its definition pending review; it does not publish the material. Source snapshots and referenced drafts require a successor before submission.\n * @summary Submit a library draft for review\n */\nexport const learningSubmitLibraryVersion = async (libraryId: number,\n version: number, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\n\n return request<LearningLibraryVersionRead>(getLearningSubmitLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningCreatePathUrl = () => {\n\n\n\n\n return `/learning/author/paths`\n}\n\n/**\n * Requires review authority for the chosen catalogue, or global authority for a null catalogueId. Creates a path with ordered, unique content IDs; these are catalogue content identities, not revision IDs. Creators without review permission cannot curate paths. Active publication requires active content and eligible catalogue resources.\n * @summary Create a curated learning path\n */\nexport const learningCreatePath = async (learningPathWrite: LearningPathWrite, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\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<LearningPathAdminRead>(getLearningCreatePathUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningPathWrite)\n }\n);}\n\n\nexport const getLearningReadAuthorPathUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}`\n}\n\n/**\n * Requires review authority for the path's original catalogue or global authority. Returns the complete ordered definition and its current editVersion; use that counter in the next replacement request.\n * @summary Read a path's authoring definition\n */\nexport const learningReadAuthorPath = async (pathId: number, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\n\n return request<LearningPathAdminRead>(getLearningReadAuthorPathUrl(pathId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningUpdatePathUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}`\n}\n\n/**\n * Requires review authority for the original catalogue or global authority. Replaces the entire definition and step ordering, increments editVersion, and requires expectedEditVersion to match. The catalogue cannot change. Setting isActive=true requires all referenced content to be active; step visibility for readers still follows their existing access grants.\n * @summary Replace and optionally publish a learning path\n */\nexport const learningUpdatePath = async (pathId: number,\n learningPathWrite: LearningPathWrite, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\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<LearningPathAdminRead>(getLearningUpdatePathUrl(pathId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningPathWrite)\n }\n);}\n\n\nexport const getLearningCreatePathAssessmentUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}/assessments`\n}\n\n/**\n * Requires path catalogue review authority or global authority. Creates a new assessment with kind=final and explicit questions or published questionRefs; sourceLessonKeys are not accepted. References must come from courses in this path. Existing assessments are immutable; withdraw one and create another when replacing it.\n * @summary Add a final assessment to a learning path\n */\nexport const learningCreatePathAssessment = async (pathId: number,\n learningAssessmentWriteInput: LearningAssessmentWriteInput, options?: Parameters<typeof request>[1]): Promise<LearningPathAssessmentRead> => {\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<LearningPathAssessmentRead>(getLearningCreatePathAssessmentUrl(pathId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAssessmentWriteInput)\n }\n);}\n\n\nexport const getLearningWithdrawPathAssessmentUrl = (pathId: number,\n assessmentId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}/assessments/${assessmentId}`\n}\n\n/**\n * Requires path catalogue review authority or global authority. Marks the selected assessment inactive while retaining its identity and recorded evidence. assessmentId must belong to pathId. Repeating withdrawal leaves it inactive. Success returns 204 with no response body.\n * @summary Withdraw a path assessment\n */\nexport const learningWithdrawPathAssessment = async (pathId: number,\n assessmentId: number, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getLearningWithdrawPathAssessmentUrl(pathId,assessmentId),\n {\n ...options,\n method: 'DELET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,OAAO,QAAgD,CAAC,GAClF,IAAI,UAAU,KAAA,GAAW,QAAQ,QAAQ;EAE3C,OAAO;CACT;CACF,OAAO,QAAoC,mCAAmC,MAAM,GAClF;EACE,GAAG;EACH,QAAQ;EACR,SAAS;GAAE,gBAAgB;GAAoB,GAAG,WAAW,SAAS,OAAO;EAAE;EAC/E,MAAM,KAAK,UAAU,4BAA4B;CACnD,CACF;AAAE;AAGF,MAAa,wCAAwC,QACjD,iBAA0B;CAK5B,OAAO,0BAA0B,OAAO,eAAe;AACzD;;;;;AAMA,MAAa,iCAAiC,OAAO,QACjD,cAAsB,YAA2D;CAEnF,OAAO,QAAc,qCAAqC,QAAO,YAAY,GAC7E;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
|
|
1
|
+
{"version":3,"file":"biblio-learning-authoring.js","names":[],"sources":["../../src/api/biblio-learning-authoring/biblio-learning-authoring.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.20.2\n */\nimport type {\n CourseAuthorRevisionRead,\n CourseReviewWrite,\n CourseRevisionPage,\n CourseRevisionRead,\n CourseRevisionWriteInput,\n LearningAssessmentWriteInput,\n LearningAssetRead,\n LearningAssetWrite,\n LearningCaptionWrite,\n LearningCatalogueGrantWrite,\n LearningCatalogueListRead,\n LearningCatalogueRead,\n LearningCatalogueWrite,\n LearningCourseAdminPage,\n LearningCourseAdminRead,\n LearningCourseCreateWrite,\n LearningCourseSettingsWrite,\n LearningLibraryDocumentRead,\n LearningLibraryPage,\n LearningLibraryRead,\n LearningLibraryVersionPage,\n LearningLibraryVersionRead,\n LearningLibraryVersionWrite,\n LearningLibraryWrite,\n LearningListAuthorCoursesParams,\n LearningListLibrariesParams,\n LearningListLibraryVersionsParams,\n LearningListRevisionsParams,\n LearningPathAdminRead,\n LearningPathAssessmentRead,\n LearningPathWrite\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningListAuthorCataloguesUrl = () => {\n\n\n\n\n return `/learning/author/catalogues`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Lists active catalogues with creation, review or finance authority. Review permission also enables creation; finance permission alone does not. The collection is ordered by catalogue ID and is not paginated.\n * @summary List my authoring catalogues\n */\nexport const learningListAuthorCatalogues = async ( options?: Parameters<typeof request>[1]): Promise<LearningCatalogueListRead> => {\n\n return request<LearningCatalogueListRead>(getLearningListAuthorCataloguesUrl(),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateAuthorCatalogueUrl = () => {\n\n\n\n\n return `/learning/author/catalogues`\n}\n\n/**\n * Requires global catalogue write authority and rejects support impersonation. Creates an active authoring catalogue; the returned capability flags describe the operator making this request.\n * @summary Create a learning catalogue\n */\nexport const learningCreateAuthorCatalogue = async (learningCatalogueWrite: LearningCatalogueWrite, options?: Parameters<typeof request>[1]): Promise<LearningCatalogueRead> => {\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<LearningCatalogueRead>(getLearningCreateAuthorCatalogueUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCatalogueWrite)\n }\n);}\n\n\nexport const getLearningSetCatalogueAuthorityUrl = (catalogueId: number,) => {\n\n\n\n\n return `/learning/author/catalogues/${catalogueId}/authority`\n}\n\n/**\n * Requires global catalogue write authority. Replaces all three grants for the selected active independent account, including revocation when all flags are false. The reason is recorded for audit. Successful updates return 204 with no response body.\n * @summary Replace an author's catalogue permissions\n */\nexport const learningSetCatalogueAuthority = async (catalogueId: number,\n learningCatalogueGrantWrite: LearningCatalogueGrantWrite, 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>(getLearningSetCatalogueAuthorityUrl(catalogueId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCatalogueGrantWrite)\n }\n);}\n\n\nexport const getLearningListAuthorCoursesUrl = (params?: LearningListAuthorCoursesParams,) => {\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 ? `/learning/author/courses?${stringifiedParams}` : `/learning/author/courses`\n}\n\n/**\n * Returns courses assigned to the effective author and courses in active catalogues they may review. Global administrators and support readers can see all courses. Dependent profiles and support impersonation are refused. Pagination counts this authorized scope and sorts by course ID ascending; draft courses are included.\n * @summary List courses available to the author\n */\nexport const learningListAuthorCourses = async (params?: LearningListAuthorCoursesParams, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminPage> => {\n\n return request<LearningCourseAdminPage>(getLearningListAuthorCoursesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateCourseUrl = () => {\n\n\n\n\n return `/learning/author/courses`\n}\n\n/**\n * Create an inactive course from a title in an authorized catalogue, then register media and create an edition. Binding an existing catalogue contentId, or creating without catalogueId, requires global administration. Assigning other authors requires curator authority. Publication activates a new course; this request alone does not make it readable.\n * @summary Create a native course shell\n */\nexport const learningCreateCourse = async (learningCourseCreateWrite: LearningCourseCreateWrite, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminRead> => {\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<LearningCourseAdminRead>(getLearningCreateCourseUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCourseCreateWrite)\n }\n);}\n\n\nexport const getLearningUpdateCourseSettingsUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}`\n}\n\n/**\n * Requires course curator or global administrator authority and an audit reason. Non-null scalar fields replace their current values; null or omitted values leave them unchanged. authorIds replaces the complete author set, including clearing it with an empty list. A course must have a published edition before isActive can be true.\n * @summary Update publication and author settings\n */\nexport const learningUpdateCourseSettings = async (courseId: number,\n learningCourseSettingsWrite: LearningCourseSettingsWrite, options?: Parameters<typeof request>[1]): Promise<LearningCourseAdminRead> => {\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<LearningCourseAdminRead>(getLearningUpdateCourseSettingsUrl(courseId),\n {\n ...options,\n method: 'PATCH',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCourseSettingsWrite)\n }\n);}\n\n\nexport const getLearningRegisterAssetUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/assets`\n}\n\n/**\n * Requires edit authority on the course. Registers an immutable media reference for use in edition definitions. Vimeo requires a numeric video ID; external resources require HTTPS without credentials; HTML is sanitized; storage keys must identify an existing object under this author's learning prefix. The response identifies the asset and does not issue a playback URL. For new file bytes use the upload reservation workflow.\n * @summary Register a course media resource\n */\nexport const learningRegisterAsset = async (courseId: number,\n learningAssetWrite: LearningAssetWrite, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\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<LearningAssetRead>(getLearningRegisterAssetUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAssetWrite)\n }\n);}\n\n\nexport const getLearningAttachCaptionsUrl = (courseId: number,\n assetId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/assets/${assetId}/captions`\n}\n\n/**\n * Requires course edit authority. First upload validated UTF-8 WebVTT to the same course, then reference its asset ID here. Returns a new immutable media variant; existing editions keep their original asset. Repeating the original asset, caption asset and language returns the existing variant. Put the returned assetId into a draft edition to publish the captions.\n * @summary Create a captioned variant of course audio or video\n */\nexport const learningAttachCaptions = async (courseId: number,\n assetId: number,\n learningCaptionWrite: LearningCaptionWrite, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\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<LearningAssetRead>(getLearningAttachCaptionsUrl(courseId,assetId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningCaptionWrite)\n }\n);}\n\n\nexport const getLearningListRevisionsUrl = (courseId: number,\n params?: LearningListRevisionsParams,) => {\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 ? `/learning/author/courses/${courseId}/revisions?${stringifiedParams}` : `/learning/author/courses/${courseId}/revisions`\n}\n\n/**\n * Requires read authority on this course. Returns draft, submitted, published, rejected and superseded editions, newest version first. version identifies the course edition; editVersion is the optimistic concurrency counter within a working edition.\n * @summary List the course's edition history\n */\nexport const learningListRevisions = async (courseId: number,\n params?: LearningListRevisionsParams, options?: Parameters<typeof request>[1]): Promise<CourseRevisionPage> => {\n\n return request<CourseRevisionPage>(getLearningListRevisionsUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateRevisionUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions`\n}\n\n/**\n * Requires course edit authority. Creates a complete edition with the next version number; only one draft or submitted edition may exist for a course. Asset and library references must be available to this course. Chapters contain 1–2000 lessons with unique keys across the edition; the serialized authoring definition is limited to 2,000,000 bytes. Published editions and existing enrollments remain pinned to their definitions.\n * @summary Create the next draft edition\n */\nexport const learningCreateRevision = async (courseId: number,\n courseRevisionWriteInput: CourseRevisionWriteInput, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningCreateRevisionUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseRevisionWriteInput)\n }\n);}\n\n\nexport const getLearningReadAuthorRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}`\n}\n\n/**\n * Requires authoring read authority and checks that revisionId belongs to courseId. Returns editorial content, lessons, resources, vocabularies and private assessment solutions. Read revision.editVersion before replacing a changed definition. This author-only representation includes grading keys that are deliberately absent from reader questions.\n * @summary Read a complete editable edition definition\n */\nexport const learningReadAuthorRevision = async (courseId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<CourseAuthorRevisionRead> => {\n\n return request<CourseAuthorRevisionRead>(getLearningReadAuthorRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningReplaceRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}`\n}\n\n/**\n * Replaces the entire editorial and lesson graph of a draft or rejected edition. Send the editVersion last read as expectedEditVersion. An identical definition is an idempotent replay; a changed definition requires a matching version and increments editVersion. A changed rejected edition returns to draft and clears its review note and submission date. Published and submitted editions cannot be edited.\n * @summary Replace a draft edition with concurrency protection\n */\nexport const learningReplaceRevision = async (courseId: number,\n revisionId: number,\n courseRevisionWriteInput: CourseRevisionWriteInput, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningReplaceRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseRevisionWriteInput)\n }\n);}\n\n\nexport const getLearningReviewRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}/review`\n}\n\n/**\n * Requires course curator or global administrator authority. Approval revalidates materials, publishes this edition, supersedes its published predecessor, updates catalogue editorial fields and activates the course. Existing readers retain their selected edition until they explicitly upgrade. Rejection returns the edition for editing. Every decision requires a review note; repeated decisions return 409 once the edition leaves submitted.\n * @summary Publish or reject a submitted edition\n */\nexport const learningReviewRevision = async (courseId: number,\n revisionId: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\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<CourseRevisionRead>(getLearningReviewRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitRevisionUrl = (courseId: number,\n revisionId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/revisions/${revisionId}/submit`\n}\n\n/**\n * Requires course edit authority. Moves draft to submitted and records submittedAt; reviewers can then approve or reject it. Submission locks the definition against editing. This transition is not replay-idempotent: submitting an already submitted edition returns 409.\n * @summary Submit a draft edition for review\n */\nexport const learningSubmitRevision = async (courseId: number,\n revisionId: number, options?: Parameters<typeof request>[1]): Promise<CourseRevisionRead> => {\n\n return request<CourseRevisionRead>(getLearningSubmitRevisionUrl(courseId,revisionId),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningListLibrariesUrl = (params?: LearningListLibrariesParams,) => {\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 ? `/learning/author/libraries?${stringifiedParams}` : `/learning/author/libraries`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Lists owned or shared libraries for creators, all libraries in reviewable active catalogues for reviewers, and all libraries for global operators. Ordered by library ID. publishedVersion=0 means no native published version is selected.\n * @summary List reusable teaching libraries\n */\nexport const learningListLibraries = async (params?: LearningListLibrariesParams, options?: Parameters<typeof request>[1]): Promise<LearningLibraryPage> => {\n\n return request<LearningLibraryPage>(getLearningListLibrariesUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateLibraryUrl = () => {\n\n\n\n\n return `/learning/author/libraries`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Creates an empty assessment or vocabulary container owned by the caller. A null catalogueId requires global authority. shared allows catalogue peers to reuse published material; it does not grant them editing rights. Create a version separately.\n * @summary Create a reusable teaching library\n */\nexport const learningCreateLibrary = async (learningLibraryWrite: LearningLibraryWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryRead> => {\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<LearningLibraryRead>(getLearningCreateLibraryUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryWrite)\n }\n);}\n\n\nexport const getLearningListLibraryVersionsUrl = (libraryId: number,\n params?: LearningListLibraryVersionsParams,) => {\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 ? `/learning/author/libraries/${libraryId}/versions?${stringifiedParams}` : `/learning/author/libraries/${libraryId}/versions`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by version descending. Owners, reviewers and global operators can read drafts; other eligible users see published and superseded versions only. sealed is authoritative for editing: imported or referenced material can be sealed even with a draft status.\n * @summary List versions of a teaching library\n */\nexport const learningListLibraryVersions = async (libraryId: number,\n params?: LearningListLibraryVersionsParams, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionPage> => {\n\n return request<LearningLibraryVersionPage>(getLearningListLibraryVersionsUrl(libraryId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCreateLibraryVersionUrl = (libraryId: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Creates the next numbered draft without changing any previous definition. Supply exactly one assessment or vocabulary matching the library kind. There must be no submitted version or unsealed working draft. Sealed source drafts do not block a successor. Referenced questions must be published and accessible; sourceLessonKeys are not accepted for libraries.\n * @summary Create a successor library version\n */\nexport const learningCreateLibraryVersion = async (libraryId: number,\n learningLibraryVersionWrite: LearningLibraryVersionWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningCreateLibraryVersionUrl(libraryId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryVersionWrite)\n }\n);}\n\n\nexport const getLearningReadLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Returns the full authoring definition and stable question references. version is the library's sequential version number, not materialId. Draft visibility is restricted to owner/reviewer/global operator. Answer keys are part of this private authoring contract. A sealed source snapshot must be copied into a successor to change it.\n * @summary Read a teaching library version\n */\nexport const learningReadLibraryVersion = async (libraryId: number,\n version: number, options?: Parameters<typeof request>[1]): Promise<LearningLibraryDocumentRead> => {\n\n return request<LearningLibraryDocumentRead>(getLearningReadLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningReplaceLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Replaces an unsealed draft or rejected version. Supply the current expectedEditVersion when changing the definition; a semantic no-op returns the same version. Submitted, published, superseded, imported and referenced definitions are immutable. Create a successor for sealed material instead. Exactly one matching assessment or vocabulary is required.\n * @summary Replace an editable library definition\n */\nexport const learningReplaceLibraryVersion = async (libraryId: number,\n version: number,\n learningLibraryVersionWrite: LearningLibraryVersionWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningReplaceLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningLibraryVersionWrite)\n }\n);}\n\n\nexport const getLearningReviewLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}/review`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review or global authority. Approval revalidates resources, publishes this version and supersedes the previously published version. Rejection records the decision and makes an unpinned definition editable again. The supplied note is audited; it is not a field of the returned version summary.\n * @summary Approve or reject a submitted library version\n */\nexport const learningReviewLibraryVersion = async (libraryId: number,\n version: number,\n courseReviewWrite: CourseReviewWrite, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\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<LearningLibraryVersionRead>(getLearningReviewLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(courseReviewWrite)\n }\n);}\n\n\nexport const getLearningSubmitLibraryVersionUrl = (libraryId: number,\n version: number,) => {\n\n\n\n\n return `/learning/author/libraries/${libraryId}/versions/${version}/submit`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires library ownership, catalogue review authority or global authority for writes; sharing only permits reuse and reading published versions. Only an unsealed draft can be submitted. Submission locks its definition pending review; it does not publish the material. Source snapshots and referenced drafts require a successor before submission.\n * @summary Submit a library draft for review\n */\nexport const learningSubmitLibraryVersion = async (libraryId: number,\n version: number, options?: Parameters<typeof request>[1]): Promise<LearningLibraryVersionRead> => {\n\n return request<LearningLibraryVersionRead>(getLearningSubmitLibraryVersionUrl(libraryId,version),\n {\n ...options,\n method: 'POST'\n\n\n }\n);}\n\n\nexport const getLearningCreatePathUrl = () => {\n\n\n\n\n return `/learning/author/paths`\n}\n\n/**\n * Requires review authority for the chosen catalogue, or global authority for a null catalogueId. Creates a path with ordered, unique content IDs; these are catalogue content identities, not revision IDs. Creators without review permission cannot curate paths. Active publication requires active content and eligible catalogue resources.\n * @summary Create a curated learning path\n */\nexport const learningCreatePath = async (learningPathWrite: LearningPathWrite, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\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<LearningPathAdminRead>(getLearningCreatePathUrl(),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningPathWrite)\n }\n);}\n\n\nexport const getLearningReadAuthorPathUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}`\n}\n\n/**\n * Requires review authority for the path's original catalogue or global authority. Returns the complete ordered definition and its current editVersion; use that counter in the next replacement request.\n * @summary Read a path's authoring definition\n */\nexport const learningReadAuthorPath = async (pathId: number, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\n\n return request<LearningPathAdminRead>(getLearningReadAuthorPathUrl(pathId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningUpdatePathUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}`\n}\n\n/**\n * Requires review authority for the original catalogue or global authority. Replaces the entire definition and step ordering, increments editVersion, and requires expectedEditVersion to match. The catalogue cannot change. Setting isActive=true requires all referenced content to be active; step visibility for readers still follows their existing access grants.\n * @summary Replace and optionally publish a learning path\n */\nexport const learningUpdatePath = async (pathId: number,\n learningPathWrite: LearningPathWrite, options?: Parameters<typeof request>[1]): Promise<LearningPathAdminRead> => {\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<LearningPathAdminRead>(getLearningUpdatePathUrl(pathId),\n {\n ...options,\n method: 'PUT',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningPathWrite)\n }\n);}\n\n\nexport const getLearningCreatePathAssessmentUrl = (pathId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}/assessments`\n}\n\n/**\n * Requires path catalogue review authority or global authority. Creates a new assessment with kind=final and explicit questions or published questionRefs; sourceLessonKeys are not accepted. References must come from courses in this path. Existing assessments are immutable; withdraw one and create another when replacing it.\n * @summary Add a final assessment to a learning path\n */\nexport const learningCreatePathAssessment = async (pathId: number,\n learningAssessmentWriteInput: LearningAssessmentWriteInput, options?: Parameters<typeof request>[1]): Promise<LearningPathAssessmentRead> => {\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<LearningPathAssessmentRead>(getLearningCreatePathAssessmentUrl(pathId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningAssessmentWriteInput)\n }\n);}\n\n\nexport const getLearningWithdrawPathAssessmentUrl = (pathId: number,\n assessmentId: number,) => {\n\n\n\n\n return `/learning/author/paths/${pathId}/assessments/${assessmentId}`\n}\n\n/**\n * Requires path catalogue review authority or global authority. Marks the selected assessment inactive while retaining its identity and recorded evidence. assessmentId must belong to pathId. Repeating withdrawal leaves it inactive. Success returns 204 with no response body.\n * @summary Withdraw a path assessment\n */\nexport const learningWithdrawPathAssessment = async (pathId: number,\n assessmentId: number, options?: Parameters<typeof request>[1]): Promise<void> => {\n\n return request<void>(getLearningWithdrawPathAssessmentUrl(pathId,assessmentId),\n {\n ...options,\n method: 'DELETE'\n\n\n }\n);}\n\n\n"],"mappings":";;;AA2CA,MAAa,2CAA2C;CAKtD,OAAO;AACT;;;;;AAMA,MAAa,+BAA+B,OAAQ,YAAgF;CAElI,OAAO,QAAmC,mCAAmC,GAC7E;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,4C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AE;EAC/E,MAAM,KAAK,UAAU,4BAA4B;CACnD,CACF;AAAE;AAGF,MAAa,wCAAwC,QACjD,iBAA0B;CAK5B,OAAO,0BAA0B,OAAO,eAAe;AACzD;;;;;AAMA,MAAa,iCAAiC,OAAO,QACjD,cAAsB,YAA2D;CAEnF,OAAO,QAAc,qCAAqC,QAAO,YAAY,GAC7E;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
import {
|
|
2
|
+
import { Bl as LearningCatalogueMessagesParams, Cu as LearningAssetRead, El as LearningCourseMessagesParams, cs as LearningSubmissionHistoryParams, dl as LearningEditorialMessageWrite, fl as LearningEditorialMessagePage, gl as LearningEditorialFragmentDetailRead, ls as LearningSubmissionHistoryPage, ml as LearningEditorialFragmentPage, pl as LearningEditorialMessageRead, wl as LearningCourseRevisionFragmentsParams, zl as LearningCatalogueRevisionFragmentsParams } from "../chunks/index.js";
|
|
3
3
|
import { c as request } from "../chunks/client.js";
|
|
4
4
|
//#region src/api/biblio-learning-editorial/biblio-learning-editorial.d.ts
|
|
5
5
|
export declare const getLearningCatalogueMessagesUrl: (catalogueId: number, params?: LearningCatalogueMessagesParams) => string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"biblio-learning-editorial.js","names":[],"sources":["../../src/api/biblio-learning-editorial/biblio-learning-editorial.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.20.0\n */\nimport type {\n LearningAssetRead,\n LearningCatalogueMessagesParams,\n LearningCatalogueRevisionFragmentsParams,\n LearningCourseMessagesParams,\n LearningCourseRevisionFragmentsParams,\n LearningEditorialFragmentDetailRead,\n LearningEditorialFragmentPage,\n LearningEditorialMessagePage,\n LearningEditorialMessageRead,\n LearningEditorialMessageWrite,\n LearningSubmissionHistoryPage,\n LearningSubmissionHistoryParams\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningCatalogueMessagesUrl = (catalogueId: number,\n params?: LearningCatalogueMessagesParams,) => {\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 ? `/learning/author/catalogues/${catalogueId}/messages?${stringifiedParams}` : `/learning/author/catalogues/${catalogueId}/messages`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review authority. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID, including subjects not linked to a native course. sourceObjectClass and sourceObjectId are exact source-subject selectors and must be supplied together; they never grant access to another catalogue.\n * @summary List a catalogue's private editorial archive\n */\nexport const learningCatalogueMessages = async (catalogueId: number,\n params?: LearningCatalogueMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningCatalogueMessagesUrl(catalogueId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCatalogueRevisionFragmentsUrl = (catalogueId: number,\n params?: LearningCatalogueRevisionFragmentsParams,) => {\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 ? `/learning/author/catalogues/${catalogueId}/revision-fragments?${stringifiedParams}` : `/learning/author/catalogues/${catalogueId}/revision-fragments`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review authority. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Ordered by fragment ID. Optional sourceObjectClass/sourceObjectId must be supplied together and match exactly; this archive can include subjects without a native course mapping.\n * @summary List a catalogue's imported revision fragments\n */\nexport const learningCatalogueRevisionFragments = async (catalogueId: number,\n params?: LearningCatalogueRevisionFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningCatalogueRevisionFragmentsUrl(catalogueId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCourseMessagesUrl = (courseId: number,\n params?: LearningCourseMessagesParams,) => {\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 ? `/learning/author/courses/${courseId}/messages?${stringifiedParams}` : `/learning/author/courses/${courseId}/messages`\n}\n\n/**\n * Requires course read-authoring authority; support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID. Omitting revisionId includes all course messages; specifying it returns only that revision's messages and requires the revision to belong to courseId. Imported discussion can preserve unknown userId and createdAt.\n * @summary List private course editorial messages\n */\nexport const learningCourseMessages = async (courseId: number,\n params?: LearningCourseMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningCourseMessagesUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAddEditorialMessageUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/messages`\n}\n\n/**\n * Requires course edit authority, catalogue review authority or global authority; support impersonation is rejected. Appends an attributed message without changing the course definition. Optional revisionId must identify a revision of this course. Omit it or use null for a course-level discussion.\n * @summary Add a private course editorial message\n */\nexport const learningAddEditorialMessage = async (courseId: number,\n learningEditorialMessageWrite: LearningEditorialMessageWrite, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessageRead> => {\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<LearningEditorialMessageRead>(getLearningAddEditorialMessageUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningEditorialMessageWrite)\n }\n);}\n\n\nexport const getLearningCourseRevisionFragmentsUrl = (courseId: number,\n params?: LearningCourseRevisionFragmentsParams,) => {\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 ? `/learning/author/courses/${courseId}/revision-fragments?${stringifiedParams}` : `/learning/author/courses/${courseId}/revision-fragments`\n}\n\n/**\n * Requires course read-authoring authority and rejects support impersonation. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Summaries are ordered by fragment ID; use the fragment detail route for retained source bytes.\n * @summary List a course's imported revision fragments\n */\nexport const learningCourseRevisionFragments = async (courseId: number,\n params?: LearningCourseRevisionFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningCourseRevisionFragmentsUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningRevisionFragmentUrl = (fragmentId: number,) => {\n\n\n\n\n return `/learning/author/revision-fragments/${fragmentId}`\n}\n\n/**\n * Requires read-authoring authority on a linked course, or review authority on its catalogue when no course is linked. Unscoped fragments are unavailable. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. sourcePayload is opaque base64 source evidence, not a complete native course definition. sourcePayloadSha256 records its evidence digest; payload retention may be absent.\n * @summary Read a private imported revision fragment\n */\nexport const learningRevisionFragment = async (fragmentId: number, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentDetailRead> => {\n\n return request<LearningEditorialFragmentDetailRead>(getLearningRevisionFragmentUrl(fragmentId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningSubmissionHistoryUrl = (params?: LearningSubmissionHistoryParams,) => {\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 ? `/learning/submissions/history?${stringifiedParams}` : `/learning/submissions/history`\n}\n\n/**\n * Returns only the effective profile's imported submission evidence; support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by submission ID. A record attests that a submission existed, without inventing an attempt, date, grade or correction. assetId can be null when no retained file is linked.\n * @summary List my historical exercise submissions\n */\nexport const learningSubmissionHistory = async (params?: LearningSubmissionHistoryParams, options?: Parameters<typeof request>[1]): Promise<LearningSubmissionHistoryPage> => {\n\n return request<LearningSubmissionHistoryPage>(getLearningSubmissionHistoryUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningSubmissionHistoryResourceUrl = (submissionId: number,) => {\n\n\n\n\n return `/learning/submissions/history/${submissionId}/resource`\n}\n\n/**\n * Requires ownership of both the historical submission and its active, unshared submission asset. Support impersonation is rejected. Returns a delivery descriptor rather than file bytes; absence of a retained asset returns 404 and does not erase the submission evidence.\n * @summary Get my historical submission's private resource\n */\nexport const learningSubmissionHistoryResource = async (submissionId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningSubmissionHistoryResourceUrl(submissionId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAwBA,MAAa,mCAAmC,aAC5C,WAA8C;CAChD,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,+BAA+B,YAAY,YAAY,sBAAsB,+BAA+B,YAAY;AAChK;;;;;AAMA,MAAa,4BAA4B,OAAO,aAC5C,QAA0C,YAAmF;CAE/H,OAAO,QAAsC,gCAAgC,aAAY,MAAM,GAC/F;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,4CAA4C,aACrD,WAAuD;CACzD,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,+BAA+B,YAAY,sBAAsB,sBAAsB,+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E;AAGF,MAAa,2CAA2C,iBAA0B;CAKhF,OAAO,iCAAiC,aAAa;AACvD;;;;;AAMA,MAAa,oCAAoC,OAAO,cAAsB,YAAwE;CAEpJ,OAAO,QAA2B,wCAAwC,YAAY,GACtF;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
|
|
1
|
+
{"version":3,"file":"biblio-learning-editorial.js","names":[],"sources":["../../src/api/biblio-learning-editorial/biblio-learning-editorial.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.20.2\n */\nimport type {\n LearningAssetRead,\n LearningCatalogueMessagesParams,\n LearningCatalogueRevisionFragmentsParams,\n LearningCourseMessagesParams,\n LearningCourseRevisionFragmentsParams,\n LearningEditorialFragmentDetailRead,\n LearningEditorialFragmentPage,\n LearningEditorialMessagePage,\n LearningEditorialMessageRead,\n LearningEditorialMessageWrite,\n LearningSubmissionHistoryPage,\n LearningSubmissionHistoryParams\n} from '../../models';\n\nimport { request } from '../../client';\n\nexport const getLearningCatalogueMessagesUrl = (catalogueId: number,\n params?: LearningCatalogueMessagesParams,) => {\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 ? `/learning/author/catalogues/${catalogueId}/messages?${stringifiedParams}` : `/learning/author/catalogues/${catalogueId}/messages`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review authority. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID, including subjects not linked to a native course. sourceObjectClass and sourceObjectId are exact source-subject selectors and must be supplied together; they never grant access to another catalogue.\n * @summary List a catalogue's private editorial archive\n */\nexport const learningCatalogueMessages = async (catalogueId: number,\n params?: LearningCatalogueMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningCatalogueMessagesUrl(catalogueId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCatalogueRevisionFragmentsUrl = (catalogueId: number,\n params?: LearningCatalogueRevisionFragmentsParams,) => {\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 ? `/learning/author/catalogues/${catalogueId}/revision-fragments?${stringifiedParams}` : `/learning/author/catalogues/${catalogueId}/revision-fragments`\n}\n\n/**\n * Requires the effective independent author profile and the relevant catalogue, ownership or global authority. Support impersonation is rejected. Requires catalogue review authority. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Ordered by fragment ID. Optional sourceObjectClass/sourceObjectId must be supplied together and match exactly; this archive can include subjects without a native course mapping.\n * @summary List a catalogue's imported revision fragments\n */\nexport const learningCatalogueRevisionFragments = async (catalogueId: number,\n params?: LearningCatalogueRevisionFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningCatalogueRevisionFragmentsUrl(catalogueId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningCourseMessagesUrl = (courseId: number,\n params?: LearningCourseMessagesParams,) => {\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 ? `/learning/author/courses/${courseId}/messages?${stringifiedParams}` : `/learning/author/courses/${courseId}/messages`\n}\n\n/**\n * Requires course read-authoring authority; support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by message ID. Omitting revisionId includes all course messages; specifying it returns only that revision's messages and requires the revision to belong to courseId. Imported discussion can preserve unknown userId and createdAt.\n * @summary List private course editorial messages\n */\nexport const learningCourseMessages = async (courseId: number,\n params?: LearningCourseMessagesParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessagePage> => {\n\n return request<LearningEditorialMessagePage>(getLearningCourseMessagesUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningAddEditorialMessageUrl = (courseId: number,) => {\n\n\n\n\n return `/learning/author/courses/${courseId}/messages`\n}\n\n/**\n * Requires course edit authority, catalogue review authority or global authority; support impersonation is rejected. Appends an attributed message without changing the course definition. Optional revisionId must identify a revision of this course. Omit it or use null for a course-level discussion.\n * @summary Add a private course editorial message\n */\nexport const learningAddEditorialMessage = async (courseId: number,\n learningEditorialMessageWrite: LearningEditorialMessageWrite, options?: Parameters<typeof request>[1]): Promise<LearningEditorialMessageRead> => {\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<LearningEditorialMessageRead>(getLearningAddEditorialMessageUrl(courseId),\n {\n ...options,\n method: 'POST',\n headers: { 'Content-Type': 'application/json', ...getHeaders(options?.headers) },\n body: JSON.stringify(learningEditorialMessageWrite)\n }\n);}\n\n\nexport const getLearningCourseRevisionFragmentsUrl = (courseId: number,\n params?: LearningCourseRevisionFragmentsParams,) => {\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 ? `/learning/author/courses/${courseId}/revision-fragments?${stringifiedParams}` : `/learning/author/courses/${courseId}/revision-fragments`\n}\n\n/**\n * Requires course read-authoring authority and rejects support impersonation. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. Summaries are ordered by fragment ID; use the fragment detail route for retained source bytes.\n * @summary List a course's imported revision fragments\n */\nexport const learningCourseRevisionFragments = async (courseId: number,\n params?: LearningCourseRevisionFragmentsParams, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentPage> => {\n\n return request<LearningEditorialFragmentPage>(getLearningCourseRevisionFragmentsUrl(courseId,params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningRevisionFragmentUrl = (fragmentId: number,) => {\n\n\n\n\n return `/learning/author/revision-fragments/${fragmentId}`\n}\n\n/**\n * Requires read-authoring authority on a linked course, or review authority on its catalogue when no course is linked. Unscoped fragments are unavailable. A fragment is partial source evidence, not a complete native revision or a replayable patch. Missing source dates and publication facts remain unknown; neither version labels nor source status prove publication. sourcePayload is opaque base64 source evidence, not a complete native course definition. sourcePayloadSha256 records its evidence digest; payload retention may be absent.\n * @summary Read a private imported revision fragment\n */\nexport const learningRevisionFragment = async (fragmentId: number, options?: Parameters<typeof request>[1]): Promise<LearningEditorialFragmentDetailRead> => {\n\n return request<LearningEditorialFragmentDetailRead>(getLearningRevisionFragmentUrl(fragmentId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningSubmissionHistoryUrl = (params?: LearningSubmissionHistoryParams,) => {\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 ? `/learning/submissions/history?${stringifiedParams}` : `/learning/submissions/history`\n}\n\n/**\n * Returns only the effective profile's imported submission evidence; support impersonation is rejected. Results are filtered to the caller's scope before pagination; page is one-based and limit is bounded by the shared pagination contract. Ordered by submission ID. A record attests that a submission existed, without inventing an attempt, date, grade or correction. assetId can be null when no retained file is linked.\n * @summary List my historical exercise submissions\n */\nexport const learningSubmissionHistory = async (params?: LearningSubmissionHistoryParams, options?: Parameters<typeof request>[1]): Promise<LearningSubmissionHistoryPage> => {\n\n return request<LearningSubmissionHistoryPage>(getLearningSubmissionHistoryUrl(params),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\nexport const getLearningSubmissionHistoryResourceUrl = (submissionId: number,) => {\n\n\n\n\n return `/learning/submissions/history/${submissionId}/resource`\n}\n\n/**\n * Requires ownership of both the historical submission and its active, unshared submission asset. Support impersonation is rejected. Returns a delivery descriptor rather than file bytes; absence of a retained asset returns 404 and does not erase the submission evidence.\n * @summary Get my historical submission's private resource\n */\nexport const learningSubmissionHistoryResource = async (submissionId: number, options?: Parameters<typeof request>[1]): Promise<LearningAssetRead> => {\n\n return request<LearningAssetRead>(getLearningSubmissionHistoryResourceUrl(submissionId),\n {\n ...options,\n method: 'GET'\n\n\n }\n);}\n\n\n"],"mappings":";;;AAwBA,MAAa,mCAAmC,aAC5C,WAA8C;CAChD,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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AAGF,MAAa,kCAAkC,eAAwB;CAKrE,OAAO,uCAAuC;AAChD;;;;;AAMA,MAAa,2BAA2B,OAAO,YAAoB,YAA0F;CAE3J,OAAO,QAA6C,+BAA+B,UAAU,GAC7F;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,mCAAmC,WAA8C;CAC5F,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,iCAAiC,sBAAsB;AAC/F;;;;;AAMA,MAAa,4BAA4B,OAAO,QAA0C,YAAoF;CAE5K,OAAO,QAAuC,gCAAgC,MAAM,GACpF;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE;AAGF,MAAa,2CAA2C,iBAA0B;CAKhF,OAAO,iCAAiC,aAAa;AACvD;;;;;AAMA,MAAa,oCAAoC,OAAO,cAAsB,YAAwE;CAEpJ,OAAO,QAA2B,wCAAwC,YAAY,GACtF;EACE,GAAG;EACH,QAAQ;CAGV,CACF;AAAE"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
import {
|
|
2
|
+
import { Dc as LearningOwnFeedbackParams, Gs as LearningReportingScopePage, Sl as LearningCourseStatsRead, Wl as LearningCatalogueCustomerStatisticsParams, Ws as LearningReportingScopesParams, _l as LearningCustomerStatsRead, bl as LearningCustomerCourseStatisticsParams, cl as LearningFeedbackRead, ol as LearningFeedbackWrite, os as LearningTenantStatsRead, ql as LearningAuthorStatisticsParams, sl as LearningFeedbackPage, ss as LearningSurveyRead, vl as LearningCustomerStatisticsParams, xl as LearningCourseStatsPage, yl as LearningCustomerGrantWrite } from "../chunks/index.js";
|
|
3
3
|
import { c as request } from "../chunks/client.js";
|
|
4
4
|
//#region src/api/biblio-learning-feedback/biblio-learning-feedback.d.ts
|
|
5
5
|
export declare const getLearningSetCustomerReporterUrl: (catalogueId: number, tenantId: number) => string;
|