@instructure/athena-api-client 3.47.0 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/README.md +9 -6
  2. package/dist/apis/AdminApi.d.ts +53 -37
  3. package/dist/apis/AdminApi.js +75 -32
  4. package/dist/apis/ConceptDiagramsApi.d.ts +15 -1
  5. package/dist/apis/ConceptDiagramsApi.js +41 -0
  6. package/dist/apis/ConceptImagesApi.d.ts +15 -1
  7. package/dist/apis/ConceptImagesApi.js +41 -0
  8. package/dist/esm/apis/AdminApi.d.ts +53 -37
  9. package/dist/esm/apis/AdminApi.js +76 -33
  10. package/dist/esm/apis/ConceptDiagramsApi.d.ts +15 -1
  11. package/dist/esm/apis/ConceptDiagramsApi.js +42 -1
  12. package/dist/esm/apis/ConceptImagesApi.d.ts +15 -1
  13. package/dist/esm/apis/ConceptImagesApi.js +42 -1
  14. package/dist/esm/models/AdminConceptDiagram.d.ts +19 -1
  15. package/dist/esm/models/AdminConceptDiagram.js +12 -0
  16. package/dist/esm/models/AdminConceptDiagramDetail.d.ts +19 -1
  17. package/dist/esm/models/AdminConceptDiagramDetail.js +12 -0
  18. package/dist/esm/models/AdminConceptImage.d.ts +19 -1
  19. package/dist/esm/models/AdminConceptImage.js +12 -0
  20. package/dist/esm/models/AdminConceptImageDetail.d.ts +19 -1
  21. package/dist/esm/models/AdminConceptImageDetail.js +12 -0
  22. package/dist/esm/models/AdminConceptMediaJob.d.ts +157 -0
  23. package/dist/esm/models/AdminConceptMediaJob.js +139 -0
  24. package/dist/esm/models/AdminShownConceptDiagram.d.ts +19 -1
  25. package/dist/esm/models/AdminShownConceptDiagram.js +12 -0
  26. package/dist/esm/models/AdminShownConceptImage.d.ts +19 -1
  27. package/dist/esm/models/AdminShownConceptImage.js +12 -0
  28. package/dist/esm/models/ConceptMediaFlagResult.d.ts +32 -0
  29. package/dist/esm/models/ConceptMediaFlagResult.js +43 -0
  30. package/dist/esm/models/index.d.ts +2 -2
  31. package/dist/esm/models/index.js +2 -2
  32. package/dist/models/AdminConceptDiagram.d.ts +19 -1
  33. package/dist/models/AdminConceptDiagram.js +12 -0
  34. package/dist/models/AdminConceptDiagramDetail.d.ts +19 -1
  35. package/dist/models/AdminConceptDiagramDetail.js +12 -0
  36. package/dist/models/AdminConceptImage.d.ts +19 -1
  37. package/dist/models/AdminConceptImage.js +12 -0
  38. package/dist/models/AdminConceptImageDetail.d.ts +19 -1
  39. package/dist/models/AdminConceptImageDetail.js +12 -0
  40. package/dist/models/AdminConceptMediaJob.d.ts +157 -0
  41. package/dist/models/AdminConceptMediaJob.js +147 -0
  42. package/dist/models/AdminShownConceptDiagram.d.ts +19 -1
  43. package/dist/models/AdminShownConceptDiagram.js +12 -0
  44. package/dist/models/AdminShownConceptImage.d.ts +19 -1
  45. package/dist/models/AdminShownConceptImage.js +12 -0
  46. package/dist/models/ConceptMediaFlagResult.d.ts +32 -0
  47. package/dist/models/ConceptMediaFlagResult.js +50 -0
  48. package/dist/models/index.d.ts +2 -2
  49. package/dist/models/index.js +2 -2
  50. package/package.json +1 -1
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AdminChat, AdminChatAnalysis, AdminChatCanvasUsage, AdminChatWithStats, AdminCohortStats, AdminConceptDiagramDetail, AdminConceptImageDetail, AdminConceptSearchResult, AdminGenerateConceptDiagramRequest, AdminGenerateConceptImageRequest, AdminGeneratedConceptDiagram, AdminGeneratedConceptImage, AdminPaginatedActiveStreaks, AdminPaginatedChats, AdminPaginatedConceptDiagrams, AdminPaginatedConceptImages, AdminPaginatedLastExchanges, AdminPaginatedQuizParticipantSessions, AdminPaginatedQuizSessions, AdminPaginatedStudyObjectiveUserCounts, AdminPaginatedStudyObjectives, AdminPaginatedTaxonomyEnrollments, AdminRegenerateConceptDiagramRequest, AdminRegenerateConceptImageRequest, AdminResetLearningDataResponse, AdminShowConceptMediaRequest, AdminShownConceptDiagram, AdminShownConceptImage, AdminStreak, AdminStudyObjectiveSummary, AdminTriggerAnalysisResponse, AdminUpdateChatRequest, AdminUserActivity, AdminUserActivityTotals, AdminUserEngagement, AdminUsersActivityRequest, AdminUsersActivityTotalsRequest, QuizSessionSummary } from '../models/index';
13
+ import type { AdminChat, AdminChatAnalysis, AdminChatCanvasUsage, AdminChatWithStats, AdminCohortStats, AdminConceptDiagramDetail, AdminConceptImageDetail, AdminConceptMediaJob, AdminConceptSearchResult, AdminGenerateConceptDiagramRequest, AdminGenerateConceptImageRequest, AdminPaginatedActiveStreaks, AdminPaginatedChats, AdminPaginatedConceptDiagrams, AdminPaginatedConceptImages, AdminPaginatedLastExchanges, AdminPaginatedQuizParticipantSessions, AdminPaginatedQuizSessions, AdminPaginatedStudyObjectiveUserCounts, AdminPaginatedStudyObjectives, AdminPaginatedTaxonomyEnrollments, AdminRegenerateConceptDiagramRequest, AdminRegenerateConceptImageRequest, AdminResetLearningDataResponse, AdminShowConceptMediaRequest, AdminShownConceptDiagram, AdminShownConceptImage, AdminStreak, AdminStudyObjectiveSummary, AdminTriggerAnalysisResponse, AdminUpdateChatRequest, AdminUserActivity, AdminUserActivityTotals, AdminUserEngagement, AdminUsersActivityRequest, AdminUsersActivityTotalsRequest, QuizSessionSummary } from '../models/index';
14
14
  export interface AdminDeleteConceptDiagramRequest {
15
15
  xUserId: string;
16
16
  diagramId: string;
@@ -52,6 +52,10 @@ export interface AdminGetConceptImageRequest {
52
52
  xUserId: string;
53
53
  imageId: string;
54
54
  }
55
+ export interface AdminGetConceptMediaJobRequest {
56
+ xUserId: string;
57
+ jobId: string;
58
+ }
55
59
  export interface AdminGetQuizSessionSummaryRequest {
56
60
  xUserId: string;
57
61
  sessionId: string;
@@ -239,25 +243,25 @@ export declare class AdminApi extends runtime.BaseAPI {
239
243
  */
240
244
  adminDeleteConceptImage(requestParameters: AdminDeleteConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptImageDetail>;
241
245
  /**
242
- * Generates a new diagram filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours), not the learner limit.
243
- * Generate a hidden draft diagram for a concept
246
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
247
+ * Enqueue a hidden draft diagram for a concept
244
248
  */
245
- adminGenerateConceptDiagramRaw(requestParameters: AdminGenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminGeneratedConceptDiagram>>;
249
+ adminGenerateConceptDiagramRaw(requestParameters: AdminGenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptMediaJob>>;
246
250
  /**
247
- * Generates a new diagram filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours), not the learner limit.
248
- * Generate a hidden draft diagram for a concept
251
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
252
+ * Enqueue a hidden draft diagram for a concept
249
253
  */
250
- adminGenerateConceptDiagram(requestParameters: AdminGenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminGeneratedConceptDiagram>;
254
+ adminGenerateConceptDiagram(requestParameters: AdminGenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptMediaJob>;
251
255
  /**
252
- * Generates a new image filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours), not the learner limit.
253
- * Generate a hidden draft image for a concept
256
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
257
+ * Enqueue a hidden draft image for a concept
254
258
  */
255
- adminGenerateConceptImageRaw(requestParameters: AdminGenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminGeneratedConceptImage>>;
259
+ adminGenerateConceptImageRaw(requestParameters: AdminGenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptMediaJob>>;
256
260
  /**
257
- * Generates a new image filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours), not the learner limit.
258
- * Generate a hidden draft image for a concept
261
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
262
+ * Enqueue a hidden draft image for a concept
259
263
  */
260
- adminGenerateConceptImage(requestParameters: AdminGenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminGeneratedConceptImage>;
264
+ adminGenerateConceptImage(requestParameters: AdminGenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptMediaJob>;
261
265
  /**
262
266
  * Get any chat by ID within the account
263
267
  */
@@ -310,6 +314,16 @@ export declare class AdminApi extends runtime.BaseAPI {
310
314
  * Get a library concept image in any state
311
315
  */
312
316
  adminGetConceptImage(requestParameters: AdminGetConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptImageDetail>;
317
+ /**
318
+ * Poll after a generate or regenerate (every few seconds) until status is succeeded or failed. On success, resultMediaId is the new hidden draft: open it with adminGetConceptImage or adminGetConceptDiagram per kind. On failure, errorCode and errorMessage say why. A job left pending or running past its deadline (the generation timeout plus a margin while running; 30 minutes while pending) is reported failed with errorCode timeout. Only jobs requested by account users in the caller\'s account are found.
319
+ * Get an admin concept media generation job
320
+ */
321
+ adminGetConceptMediaJobRaw(requestParameters: AdminGetConceptMediaJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptMediaJob>>;
322
+ /**
323
+ * Poll after a generate or regenerate (every few seconds) until status is succeeded or failed. On success, resultMediaId is the new hidden draft: open it with adminGetConceptImage or adminGetConceptDiagram per kind. On failure, errorCode and errorMessage say why. A job left pending or running past its deadline (the generation timeout plus a margin while running; 30 minutes while pending) is reported failed with errorCode timeout. Only jobs requested by account users in the caller\'s account are found.
324
+ * Get an admin concept media generation job
325
+ */
326
+ adminGetConceptMediaJob(requestParameters: AdminGetConceptMediaJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptMediaJob>;
313
327
  /**
314
328
  * Returns the session summary (quiz details, questions, responses, score) for any quiz session belonging to a user within the caller\'s account. Intended for admin-style views in calling applications; authorization on whether the calling user is allowed to act as an admin is the calling application\'s responsibility - this endpoint only enforces account isolation. Unlike the per-user `getQuizSessionSummary` endpoint, this endpoint does not gate on the `enhanced-quizzing` feature flag; an admin can read any historical session in their account regardless of whether the chat owner currently has the feature.
315
329
  * Get quiz session summary for any session within the account
@@ -367,22 +381,22 @@ export declare class AdminApi extends runtime.BaseAPI {
367
381
  */
368
382
  adminGetUsersActivityTotals(requestParameters: AdminGetUsersActivityTotalsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AdminUserActivityTotals>>;
369
383
  /**
370
- * Keeps the diagram out of every learner read. Idempotent: an already hidden diagram keeps its original hide time and actor. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
384
+ * Keeps the diagram out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: a diagram an admin already hid keeps its original hide time and actor. A diagram hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
371
385
  * Hide a concept diagram from learners
372
386
  */
373
387
  adminHideConceptDiagramRaw(requestParameters: AdminHideConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptDiagramDetail>>;
374
388
  /**
375
- * Keeps the diagram out of every learner read. Idempotent: an already hidden diagram keeps its original hide time and actor. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
389
+ * Keeps the diagram out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: a diagram an admin already hid keeps its original hide time and actor. A diagram hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
376
390
  * Hide a concept diagram from learners
377
391
  */
378
392
  adminHideConceptDiagram(requestParameters: AdminHideConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptDiagramDetail>;
379
393
  /**
380
- * Keeps the image out of every learner read. Idempotent: an already hidden image keeps its original hide time and actor. Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
394
+ * Keeps the image out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: an image an admin already hid keeps its original hide time and actor. An image hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
381
395
  * Hide a concept image from learners
382
396
  */
383
397
  adminHideConceptImageRaw(requestParameters: AdminHideConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptImageDetail>>;
384
398
  /**
385
- * Keeps the image out of every learner read. Idempotent: an already hidden image keeps its original hide time and actor. Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
399
+ * Keeps the image out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: an image an admin already hid keeps its original hide time and actor. An image hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
386
400
  * Hide a concept image from learners
387
401
  */
388
402
  adminHideConceptImage(requestParameters: AdminHideConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptImageDetail>;
@@ -489,25 +503,25 @@ export declare class AdminApi extends runtime.BaseAPI {
489
503
  */
490
504
  adminListTopStreaks(requestParameters: AdminListTopStreaksRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AdminStreak>>;
491
505
  /**
492
- * Generates a new diagram from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
493
- * Generate a hidden revision of a concept diagram
506
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new diagram is generated from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
507
+ * Enqueue a hidden revision of a concept diagram
494
508
  */
495
- adminRegenerateConceptDiagramRaw(requestParameters: AdminRegenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptDiagramDetail>>;
509
+ adminRegenerateConceptDiagramRaw(requestParameters: AdminRegenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptMediaJob>>;
496
510
  /**
497
- * Generates a new diagram from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
498
- * Generate a hidden revision of a concept diagram
511
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new diagram is generated from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
512
+ * Enqueue a hidden revision of a concept diagram
499
513
  */
500
- adminRegenerateConceptDiagram(requestParameters: AdminRegenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptDiagramDetail>;
514
+ adminRegenerateConceptDiagram(requestParameters: AdminRegenerateConceptDiagramOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptMediaJob>;
501
515
  /**
502
- * Generates a new image from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
503
- * Generate a hidden revision of a concept image
516
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new image is generated from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
517
+ * Enqueue a hidden revision of a concept image
504
518
  */
505
- adminRegenerateConceptImageRaw(requestParameters: AdminRegenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptImageDetail>>;
519
+ adminRegenerateConceptImageRaw(requestParameters: AdminRegenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptMediaJob>>;
506
520
  /**
507
- * Generates a new image from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
508
- * Generate a hidden revision of a concept image
521
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new image is generated from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
522
+ * Enqueue a hidden revision of a concept image
509
523
  */
510
- adminRegenerateConceptImage(requestParameters: AdminRegenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptImageDetail>;
524
+ adminRegenerateConceptImage(requestParameters: AdminRegenerateConceptImageOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptMediaJob>;
511
525
  /**
512
526
  * Wipes all per-user learning data (chats, quizzes, flashcards, study objectives, concepts, streaks, files, etc.) for the target user while preserving their account-user and user records — and therefore their external identity and Canvas connection. Does not re-seed any demo data. Intended for single-account demo/test users: learning streaks are keyed on the user (not the account), so a user who belongs to multiple accounts has their streak cleared everywhere.
513
527
  * Reset a user\'s Athena learning data to a blank slate
@@ -519,22 +533,22 @@ export declare class AdminApi extends runtime.BaseAPI {
519
533
  */
520
534
  adminResetUserLearningData(requestParameters: AdminResetUserLearningDataRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminResetLearningDataResponse>;
521
535
  /**
522
- * Clears the deletion and leaves the diagram hidden for review; show it to serve it to learners again. A diagram that is not deleted is unchanged.
536
+ * Clears the deletion and any approval and leaves the diagram hidden for review (a diagram already hidden keeps its hide); show it to serve it to learners again. A diagram that is not deleted is unchanged.
523
537
  * Restore a soft-deleted concept diagram
524
538
  */
525
539
  adminRestoreConceptDiagramRaw(requestParameters: AdminRestoreConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptDiagramDetail>>;
526
540
  /**
527
- * Clears the deletion and leaves the diagram hidden for review; show it to serve it to learners again. A diagram that is not deleted is unchanged.
541
+ * Clears the deletion and any approval and leaves the diagram hidden for review (a diagram already hidden keeps its hide); show it to serve it to learners again. A diagram that is not deleted is unchanged.
528
542
  * Restore a soft-deleted concept diagram
529
543
  */
530
544
  adminRestoreConceptDiagram(requestParameters: AdminRestoreConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptDiagramDetail>;
531
545
  /**
532
- * Clears the deletion and leaves the image hidden for review; show it to serve it to learners again. A image that is not deleted is unchanged.
546
+ * Clears the deletion and any approval and leaves the image hidden for review (an image already hidden keeps its hide); show it to serve it to learners again. An image that is not deleted is unchanged.
533
547
  * Restore a soft-deleted concept image
534
548
  */
535
549
  adminRestoreConceptImageRaw(requestParameters: AdminRestoreConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminConceptImageDetail>>;
536
550
  /**
537
- * Clears the deletion and leaves the image hidden for review; show it to serve it to learners again. A image that is not deleted is unchanged.
551
+ * Clears the deletion and any approval and leaves the image hidden for review (an image already hidden keeps its hide); show it to serve it to learners again. An image that is not deleted is unchanged.
538
552
  * Restore a soft-deleted concept image
539
553
  */
540
554
  adminRestoreConceptImage(requestParameters: AdminRestoreConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminConceptImageDetail>;
@@ -549,22 +563,22 @@ export declare class AdminApi extends runtime.BaseAPI {
549
563
  */
550
564
  adminSearchConcepts(requestParameters: AdminSearchConceptsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AdminConceptSearchResult>>;
551
565
  /**
552
- * Clears the hide so learners can be served the diagram again. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
566
+ * Clears the hide so learners can be served the diagram again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved diagram. Showing a visible diagram approves it too. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
553
567
  * Show a hidden concept diagram to learners
554
568
  */
555
569
  adminShowConceptDiagramRaw(requestParameters: AdminShowConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminShownConceptDiagram>>;
556
570
  /**
557
- * Clears the hide so learners can be served the diagram again. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
571
+ * Clears the hide so learners can be served the diagram again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved diagram. Showing a visible diagram approves it too. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
558
572
  * Show a hidden concept diagram to learners
559
573
  */
560
574
  adminShowConceptDiagram(requestParameters: AdminShowConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminShownConceptDiagram>;
561
575
  /**
562
- * Clears the hide so learners can be served the image again. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
576
+ * Clears the hide so learners can be served the image again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved image. Showing a visible image approves it too. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
563
577
  * Show a hidden concept image to learners
564
578
  */
565
579
  adminShowConceptImageRaw(requestParameters: AdminShowConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AdminShownConceptImage>>;
566
580
  /**
567
- * Clears the hide so learners can be served the image again. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
581
+ * Clears the hide so learners can be served the image again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved image. Showing a visible image approves it too. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
568
582
  * Show a hidden concept image to learners
569
583
  */
570
584
  adminShowConceptImage(requestParameters: AdminShowConceptImageRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AdminShownConceptImage>;
@@ -592,6 +606,7 @@ export declare const AdminListConceptDiagramsStateEnum: {
592
606
  readonly NotDeleted: "not_deleted";
593
607
  readonly Visible: "visible";
594
608
  readonly Hidden: "hidden";
609
+ readonly Flagged: "flagged";
595
610
  readonly Deleted: "deleted";
596
611
  readonly All: "all";
597
612
  };
@@ -611,6 +626,7 @@ export declare const AdminListConceptImagesStateEnum: {
611
626
  readonly NotDeleted: "not_deleted";
612
627
  readonly Visible: "visible";
613
628
  readonly Hidden: "hidden";
629
+ readonly Flagged: "flagged";
614
630
  readonly Deleted: "deleted";
615
631
  readonly All: "all";
616
632
  };
@@ -21,7 +21,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
21
21
  });
22
22
  };
23
23
  import * as runtime from '../runtime';
24
- import { AdminChatFromJSON, AdminChatAnalysisFromJSON, AdminChatCanvasUsageFromJSON, AdminChatWithStatsFromJSON, AdminCohortStatsFromJSON, AdminConceptDiagramDetailFromJSON, AdminConceptImageDetailFromJSON, AdminConceptSearchResultFromJSON, AdminGenerateConceptDiagramRequestToJSON, AdminGenerateConceptImageRequestToJSON, AdminGeneratedConceptDiagramFromJSON, AdminGeneratedConceptImageFromJSON, AdminPaginatedActiveStreaksFromJSON, AdminPaginatedChatsFromJSON, AdminPaginatedConceptDiagramsFromJSON, AdminPaginatedConceptImagesFromJSON, AdminPaginatedLastExchangesFromJSON, AdminPaginatedQuizParticipantSessionsFromJSON, AdminPaginatedQuizSessionsFromJSON, AdminPaginatedStudyObjectiveUserCountsFromJSON, AdminPaginatedStudyObjectivesFromJSON, AdminPaginatedTaxonomyEnrollmentsFromJSON, AdminRegenerateConceptDiagramRequestToJSON, AdminRegenerateConceptImageRequestToJSON, AdminResetLearningDataResponseFromJSON, AdminShowConceptMediaRequestToJSON, AdminShownConceptDiagramFromJSON, AdminShownConceptImageFromJSON, AdminStreakFromJSON, AdminStudyObjectiveSummaryFromJSON, AdminTriggerAnalysisResponseFromJSON, AdminUpdateChatRequestToJSON, AdminUserActivityFromJSON, AdminUserActivityTotalsFromJSON, AdminUserEngagementFromJSON, AdminUsersActivityRequestToJSON, AdminUsersActivityTotalsRequestToJSON, QuizSessionSummaryFromJSON, } from '../models/index';
24
+ import { AdminChatFromJSON, AdminChatAnalysisFromJSON, AdminChatCanvasUsageFromJSON, AdminChatWithStatsFromJSON, AdminCohortStatsFromJSON, AdminConceptDiagramDetailFromJSON, AdminConceptImageDetailFromJSON, AdminConceptMediaJobFromJSON, AdminConceptSearchResultFromJSON, AdminGenerateConceptDiagramRequestToJSON, AdminGenerateConceptImageRequestToJSON, AdminPaginatedActiveStreaksFromJSON, AdminPaginatedChatsFromJSON, AdminPaginatedConceptDiagramsFromJSON, AdminPaginatedConceptImagesFromJSON, AdminPaginatedLastExchangesFromJSON, AdminPaginatedQuizParticipantSessionsFromJSON, AdminPaginatedQuizSessionsFromJSON, AdminPaginatedStudyObjectiveUserCountsFromJSON, AdminPaginatedStudyObjectivesFromJSON, AdminPaginatedTaxonomyEnrollmentsFromJSON, AdminRegenerateConceptDiagramRequestToJSON, AdminRegenerateConceptImageRequestToJSON, AdminResetLearningDataResponseFromJSON, AdminShowConceptMediaRequestToJSON, AdminShownConceptDiagramFromJSON, AdminShownConceptImageFromJSON, AdminStreakFromJSON, AdminStudyObjectiveSummaryFromJSON, AdminTriggerAnalysisResponseFromJSON, AdminUpdateChatRequestToJSON, AdminUserActivityFromJSON, AdminUserActivityTotalsFromJSON, AdminUserEngagementFromJSON, AdminUsersActivityRequestToJSON, AdminUsersActivityTotalsRequestToJSON, QuizSessionSummaryFromJSON, } from '../models/index';
25
25
  /**
26
26
  *
27
27
  */
@@ -109,8 +109,8 @@ export class AdminApi extends runtime.BaseAPI {
109
109
  });
110
110
  }
111
111
  /**
112
- * Generates a new diagram filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours), not the learner limit.
113
- * Generate a hidden draft diagram for a concept
112
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
113
+ * Enqueue a hidden draft diagram for a concept
114
114
  */
115
115
  adminGenerateConceptDiagramRaw(requestParameters, initOverrides) {
116
116
  return __awaiter(this, void 0, void 0, function* () {
@@ -137,12 +137,12 @@ export class AdminApi extends runtime.BaseAPI {
137
137
  query: queryParameters,
138
138
  body: AdminGenerateConceptDiagramRequestToJSON(requestParameters['adminGenerateConceptDiagramRequest']),
139
139
  }, initOverrides);
140
- return new runtime.JSONApiResponse(response, (jsonValue) => AdminGeneratedConceptDiagramFromJSON(jsonValue));
140
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptMediaJobFromJSON(jsonValue));
141
141
  });
142
142
  }
143
143
  /**
144
- * Generates a new diagram filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours), not the learner limit.
145
- * Generate a hidden draft diagram for a concept
144
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The diagram is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing diagram. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
145
+ * Enqueue a hidden draft diagram for a concept
146
146
  */
147
147
  adminGenerateConceptDiagram(requestParameters, initOverrides) {
148
148
  return __awaiter(this, void 0, void 0, function* () {
@@ -151,8 +151,8 @@ export class AdminApi extends runtime.BaseAPI {
151
151
  });
152
152
  }
153
153
  /**
154
- * Generates a new image filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours), not the learner limit.
155
- * Generate a hidden draft image for a concept
154
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
155
+ * Enqueue a hidden draft image for a concept
156
156
  */
157
157
  adminGenerateConceptImageRaw(requestParameters, initOverrides) {
158
158
  return __awaiter(this, void 0, void 0, function* () {
@@ -179,12 +179,12 @@ export class AdminApi extends runtime.BaseAPI {
179
179
  query: queryParameters,
180
180
  body: AdminGenerateConceptImageRequestToJSON(requestParameters['adminGenerateConceptImageRequest']),
181
181
  }, initOverrides);
182
- return new runtime.JSONApiResponse(response, (jsonValue) => AdminGeneratedConceptImageFromJSON(jsonValue));
182
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptMediaJobFromJSON(jsonValue));
183
183
  });
184
184
  }
185
185
  /**
186
- * Generates a new image filed under exactly one concept: conceptId as-is, or conceptName resolved first (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the response says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat. It is stored hidden for review and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours), not the learner limit.
187
- * Generate a hidden draft image for a concept
186
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The draft is filed under exactly one concept: conceptId as-is, or conceptName resolved before the job is queued (exact normalized name match, else the nearest concept within the dedup distance, else a new concept, which stays even if generation then fails). conceptResolution in the job says which. Exactly one of conceptId and conceptName is required. The image is attributed to the calling account user with no source chat, stored hidden for review, and never matched to an existing image. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours, counting queued and running jobs as well as saved drafts), not the learner limit.
187
+ * Enqueue a hidden draft image for a concept
188
188
  */
189
189
  adminGenerateConceptImage(requestParameters, initOverrides) {
190
190
  return __awaiter(this, void 0, void 0, function* () {
@@ -438,6 +438,47 @@ export class AdminApi extends runtime.BaseAPI {
438
438
  return yield response.value();
439
439
  });
440
440
  }
441
+ /**
442
+ * Poll after a generate or regenerate (every few seconds) until status is succeeded or failed. On success, resultMediaId is the new hidden draft: open it with adminGetConceptImage or adminGetConceptDiagram per kind. On failure, errorCode and errorMessage say why. A job left pending or running past its deadline (the generation timeout plus a margin while running; 30 minutes while pending) is reported failed with errorCode timeout. Only jobs requested by account users in the caller\'s account are found.
443
+ * Get an admin concept media generation job
444
+ */
445
+ adminGetConceptMediaJobRaw(requestParameters, initOverrides) {
446
+ return __awaiter(this, void 0, void 0, function* () {
447
+ if (requestParameters['xUserId'] == null) {
448
+ throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling adminGetConceptMediaJob().');
449
+ }
450
+ if (requestParameters['jobId'] == null) {
451
+ throw new runtime.RequiredError('jobId', 'Required parameter "jobId" was null or undefined when calling adminGetConceptMediaJob().');
452
+ }
453
+ const queryParameters = {};
454
+ const headerParameters = {};
455
+ if (requestParameters['xUserId'] != null) {
456
+ headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
457
+ }
458
+ if (this.configuration && this.configuration.apiKey) {
459
+ headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
460
+ }
461
+ let urlPath = `/api/v1/admin/concept-media-jobs/{jobId}`;
462
+ urlPath = urlPath.replace(`{${"jobId"}}`, encodeURIComponent(String(requestParameters['jobId'])));
463
+ const response = yield this.request({
464
+ path: urlPath,
465
+ method: 'GET',
466
+ headers: headerParameters,
467
+ query: queryParameters,
468
+ }, initOverrides);
469
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptMediaJobFromJSON(jsonValue));
470
+ });
471
+ }
472
+ /**
473
+ * Poll after a generate or regenerate (every few seconds) until status is succeeded or failed. On success, resultMediaId is the new hidden draft: open it with adminGetConceptImage or adminGetConceptDiagram per kind. On failure, errorCode and errorMessage say why. A job left pending or running past its deadline (the generation timeout plus a margin while running; 30 minutes while pending) is reported failed with errorCode timeout. Only jobs requested by account users in the caller\'s account are found.
474
+ * Get an admin concept media generation job
475
+ */
476
+ adminGetConceptMediaJob(requestParameters, initOverrides) {
477
+ return __awaiter(this, void 0, void 0, function* () {
478
+ const response = yield this.adminGetConceptMediaJobRaw(requestParameters, initOverrides);
479
+ return yield response.value();
480
+ });
481
+ }
441
482
  /**
442
483
  * Returns the session summary (quiz details, questions, responses, score) for any quiz session belonging to a user within the caller\'s account. Intended for admin-style views in calling applications; authorization on whether the calling user is allowed to act as an admin is the calling application\'s responsibility - this endpoint only enforces account isolation. Unlike the per-user `getQuizSessionSummary` endpoint, this endpoint does not gate on the `enhanced-quizzing` feature flag; an admin can read any historical session in their account regardless of whether the chat owner currently has the feature.
443
484
  * Get quiz session summary for any session within the account
@@ -679,7 +720,7 @@ export class AdminApi extends runtime.BaseAPI {
679
720
  });
680
721
  }
681
722
  /**
682
- * Keeps the diagram out of every learner read. Idempotent: an already hidden diagram keeps its original hide time and actor. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
723
+ * Keeps the diagram out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: a diagram an admin already hid keeps its original hide time and actor. A diagram hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
683
724
  * Hide a concept diagram from learners
684
725
  */
685
726
  adminHideConceptDiagramRaw(requestParameters, initOverrides) {
@@ -710,7 +751,7 @@ export class AdminApi extends runtime.BaseAPI {
710
751
  });
711
752
  }
712
753
  /**
713
- * Keeps the diagram out of every learner read. Idempotent: an already hidden diagram keeps its original hide time and actor. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
754
+ * Keeps the diagram out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: a diagram an admin already hid keeps its original hide time and actor. A diagram hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
714
755
  * Hide a concept diagram from learners
715
756
  */
716
757
  adminHideConceptDiagram(requestParameters, initOverrides) {
@@ -720,7 +761,7 @@ export class AdminApi extends runtime.BaseAPI {
720
761
  });
721
762
  }
722
763
  /**
723
- * Keeps the image out of every learner read. Idempotent: an already hidden image keeps its original hide time and actor. Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
764
+ * Keeps the image out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: an image an admin already hid keeps its original hide time and actor. An image hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
724
765
  * Hide a concept image from learners
725
766
  */
726
767
  adminHideConceptImageRaw(requestParameters, initOverrides) {
@@ -751,7 +792,7 @@ export class AdminApi extends runtime.BaseAPI {
751
792
  });
752
793
  }
753
794
  /**
754
- * Keeps the image out of every learner read. Idempotent: an already hidden image keeps its original hide time and actor. Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
795
+ * Keeps the image out of every learner read and clears any approval (approvedAt), so a later show re-approves it. Idempotent: an image an admin already hid keeps its original hide time and actor. An image hidden by a learner flag becomes an admin hide (hiddenByFlag false, with this call\'s time and actor). Applies to later reads only: a signed URL already handed out stays valid until it expires (12 hours).
755
796
  * Hide a concept image from learners
756
797
  */
757
798
  adminHideConceptImage(requestParameters, initOverrides) {
@@ -1320,8 +1361,8 @@ export class AdminApi extends runtime.BaseAPI {
1320
1361
  });
1321
1362
  }
1322
1363
  /**
1323
- * Generates a new diagram from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
1324
- * Generate a hidden revision of a concept diagram
1364
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new diagram is generated from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
1365
+ * Enqueue a hidden revision of a concept diagram
1325
1366
  */
1326
1367
  adminRegenerateConceptDiagramRaw(requestParameters, initOverrides) {
1327
1368
  return __awaiter(this, void 0, void 0, function* () {
@@ -1352,12 +1393,12 @@ export class AdminApi extends runtime.BaseAPI {
1352
1393
  query: queryParameters,
1353
1394
  body: AdminRegenerateConceptDiagramRequestToJSON(requestParameters['adminRegenerateConceptDiagramRequest']),
1354
1395
  }, initOverrides);
1355
- return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptDiagramDetailFromJSON(jsonValue));
1396
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptMediaJobFromJSON(jsonValue));
1356
1397
  });
1357
1398
  }
1358
1399
  /**
1359
- * Generates a new diagram from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
1360
- * Generate a hidden revision of a concept diagram
1400
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new diagram is generated from an edited brief, linked to the original by revisesDiagramId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_DIAGRAM_DAILY_LIMIT per rolling 24 hours).
1401
+ * Enqueue a hidden revision of a concept diagram
1361
1402
  */
1362
1403
  adminRegenerateConceptDiagram(requestParameters, initOverrides) {
1363
1404
  return __awaiter(this, void 0, void 0, function* () {
@@ -1366,8 +1407,8 @@ export class AdminApi extends runtime.BaseAPI {
1366
1407
  });
1367
1408
  }
1368
1409
  /**
1369
- * Generates a new image from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
1370
- * Generate a hidden revision of a concept image
1410
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new image is generated from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
1411
+ * Enqueue a hidden revision of a concept image
1371
1412
  */
1372
1413
  adminRegenerateConceptImageRaw(requestParameters, initOverrides) {
1373
1414
  return __awaiter(this, void 0, void 0, function* () {
@@ -1398,12 +1439,12 @@ export class AdminApi extends runtime.BaseAPI {
1398
1439
  query: queryParameters,
1399
1440
  body: AdminRegenerateConceptImageRequestToJSON(requestParameters['adminRegenerateConceptImageRequest']),
1400
1441
  }, initOverrides);
1401
- return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptImageDetailFromJSON(jsonValue));
1442
+ return new runtime.JSONApiResponse(response, (jsonValue) => AdminConceptMediaJobFromJSON(jsonValue));
1402
1443
  });
1403
1444
  }
1404
1445
  /**
1405
- * Generates a new image from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
1406
- * Generate a hidden revision of a concept image
1446
+ * Returns 202 with a pending job at once; the generation runs in a background worker. Poll adminGetConceptMediaJob with the job id until status is succeeded (resultMediaId is the new draft) or failed (errorCode says why: off_topic, moderation_blocked, timeout, not_found, generation_failed, authoring_failed, save_failed, limit_reached, internal_error, delivery_failed). Each job runs its paid generation at most once: retry a failed job by enqueueing a new one. The new image is generated from an edited prompt, linked to the original by revisesImageId even when the original is hidden or deleted, filed under the original\'s concept, attributed to the caller, and stored hidden. The original is left as it is. Counts against the caller\'s admin limit (ADMIN_CONCEPT_IMAGE_DAILY_LIMIT per rolling 24 hours).
1447
+ * Enqueue a hidden revision of a concept image
1407
1448
  */
1408
1449
  adminRegenerateConceptImage(requestParameters, initOverrides) {
1409
1450
  return __awaiter(this, void 0, void 0, function* () {
@@ -1453,7 +1494,7 @@ export class AdminApi extends runtime.BaseAPI {
1453
1494
  });
1454
1495
  }
1455
1496
  /**
1456
- * Clears the deletion and leaves the diagram hidden for review; show it to serve it to learners again. A diagram that is not deleted is unchanged.
1497
+ * Clears the deletion and any approval and leaves the diagram hidden for review (a diagram already hidden keeps its hide); show it to serve it to learners again. A diagram that is not deleted is unchanged.
1457
1498
  * Restore a soft-deleted concept diagram
1458
1499
  */
1459
1500
  adminRestoreConceptDiagramRaw(requestParameters, initOverrides) {
@@ -1484,7 +1525,7 @@ export class AdminApi extends runtime.BaseAPI {
1484
1525
  });
1485
1526
  }
1486
1527
  /**
1487
- * Clears the deletion and leaves the diagram hidden for review; show it to serve it to learners again. A diagram that is not deleted is unchanged.
1528
+ * Clears the deletion and any approval and leaves the diagram hidden for review (a diagram already hidden keeps its hide); show it to serve it to learners again. A diagram that is not deleted is unchanged.
1488
1529
  * Restore a soft-deleted concept diagram
1489
1530
  */
1490
1531
  adminRestoreConceptDiagram(requestParameters, initOverrides) {
@@ -1494,7 +1535,7 @@ export class AdminApi extends runtime.BaseAPI {
1494
1535
  });
1495
1536
  }
1496
1537
  /**
1497
- * Clears the deletion and leaves the image hidden for review; show it to serve it to learners again. A image that is not deleted is unchanged.
1538
+ * Clears the deletion and any approval and leaves the image hidden for review (an image already hidden keeps its hide); show it to serve it to learners again. An image that is not deleted is unchanged.
1498
1539
  * Restore a soft-deleted concept image
1499
1540
  */
1500
1541
  adminRestoreConceptImageRaw(requestParameters, initOverrides) {
@@ -1525,7 +1566,7 @@ export class AdminApi extends runtime.BaseAPI {
1525
1566
  });
1526
1567
  }
1527
1568
  /**
1528
- * Clears the deletion and leaves the image hidden for review; show it to serve it to learners again. A image that is not deleted is unchanged.
1569
+ * Clears the deletion and any approval and leaves the image hidden for review (an image already hidden keeps its hide); show it to serve it to learners again. An image that is not deleted is unchanged.
1529
1570
  * Restore a soft-deleted concept image
1530
1571
  */
1531
1572
  adminRestoreConceptImage(requestParameters, initOverrides) {
@@ -1578,7 +1619,7 @@ export class AdminApi extends runtime.BaseAPI {
1578
1619
  });
1579
1620
  }
1580
1621
  /**
1581
- * Clears the hide so learners can be served the diagram again. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
1622
+ * Clears the hide so learners can be served the diagram again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved diagram. Showing a visible diagram approves it too. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
1582
1623
  * Show a hidden concept diagram to learners
1583
1624
  */
1584
1625
  adminShowConceptDiagramRaw(requestParameters, initOverrides) {
@@ -1611,7 +1652,7 @@ export class AdminApi extends runtime.BaseAPI {
1611
1652
  });
1612
1653
  }
1613
1654
  /**
1614
- * Clears the hide so learners can be served the diagram again. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
1655
+ * Clears the hide so learners can be served the diagram again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved diagram. Showing a visible diagram approves it too. A deleted diagram must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this diagram changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads.
1615
1656
  * Show a hidden concept diagram to learners
1616
1657
  */
1617
1658
  adminShowConceptDiagram(requestParameters, initOverrides) {
@@ -1621,7 +1662,7 @@ export class AdminApi extends runtime.BaseAPI {
1621
1662
  });
1622
1663
  }
1623
1664
  /**
1624
- * Clears the hide so learners can be served the image again. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
1665
+ * Clears the hide so learners can be served the image again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved image. Showing a visible image approves it too. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
1625
1666
  * Show a hidden concept image to learners
1626
1667
  */
1627
1668
  adminShowConceptImageRaw(requestParameters, initOverrides) {
@@ -1654,7 +1695,7 @@ export class AdminApi extends runtime.BaseAPI {
1654
1695
  });
1655
1696
  }
1656
1697
  /**
1657
- * Clears the hide so learners can be served the image again. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
1698
+ * Clears the hide so learners can be served the image again, and records the caller\'s approval (approvedAt, approvedBy): a learner flag never hides an approved image. Showing a visible image approves it too. A deleted image must be restored first (409, and nothing changes). The body is optional; without it, or with hideOtherVersions false, only this image changes. With hideOtherVersions true, every other visible version in its revision family (the rows history lists) is hidden in the same transaction, with the caller recorded as hider and their approval cleared; hidden and deleted versions are left as they are. hiddenVersionIds lists what was hidden, and hiddenVersionsTruncated says when the family exceeded the history cap so only the capped set was checked. Learner reads are unaffected beyond the rows hidden, and only for later reads (a signed URL already handed out stays valid until it expires, 12 hours).
1658
1699
  * Show a hidden concept image to learners
1659
1700
  */
1660
1701
  adminShowConceptImage(requestParameters, initOverrides) {
@@ -1754,6 +1795,7 @@ export const AdminListConceptDiagramsStateEnum = {
1754
1795
  NotDeleted: 'not_deleted',
1755
1796
  Visible: 'visible',
1756
1797
  Hidden: 'hidden',
1798
+ Flagged: 'flagged',
1757
1799
  Deleted: 'deleted',
1758
1800
  All: 'all'
1759
1801
  };
@@ -1771,6 +1813,7 @@ export const AdminListConceptImagesStateEnum = {
1771
1813
  NotDeleted: 'not_deleted',
1772
1814
  Visible: 'visible',
1773
1815
  Hidden: 'hidden',
1816
+ Flagged: 'flagged',
1774
1817
  Deleted: 'deleted',
1775
1818
  All: 'all'
1776
1819
  };
@@ -10,7 +10,11 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { ConceptDiagramDetail, PaginatedConceptDiagrams } from '../models/index';
13
+ import type { ConceptDiagramDetail, ConceptMediaFlagResult, PaginatedConceptDiagrams } from '../models/index';
14
+ export interface FlagConceptDiagramRequest {
15
+ xUserId: string;
16
+ diagramId: string;
17
+ }
14
18
  export interface GetMyConceptDiagramRequest {
15
19
  xUserId: string;
16
20
  diagramId: string;
@@ -24,6 +28,16 @@ export interface ListMyConceptDiagramsRequest {
24
28
  *
25
29
  */
26
30
  export declare class ConceptDiagramsApi extends runtime.BaseAPI {
31
+ /**
32
+ * Acts on a learner\'s thumbs-down on a shared concept diagram. A visible diagram that no admin has approved is hidden at once, from every learner, until an admin shows it again or shows a revision of it. Any authenticated learner may flag any diagram id; the calling client is expected to check that the diagram was shown to this learner. Idempotent: a diagram that is already hidden or deleted is left as it is (the first hide keeps its time and actor), and an admin-approved diagram stays visible. hidden says whether learners are kept from it after the call. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
33
+ * Flag a concept diagram so learners stop being shown it
34
+ */
35
+ flagConceptDiagramRaw(requestParameters: FlagConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ConceptMediaFlagResult>>;
36
+ /**
37
+ * Acts on a learner\'s thumbs-down on a shared concept diagram. A visible diagram that no admin has approved is hidden at once, from every learner, until an admin shows it again or shows a revision of it. Any authenticated learner may flag any diagram id; the calling client is expected to check that the diagram was shown to this learner. Idempotent: a diagram that is already hidden or deleted is left as it is (the first hide keeps its time and actor), and an admin-approved diagram stays visible. hidden says whether learners are kept from it after the call. Applies to later reads only: a diagram already rendered in an open chat stays until the chat is reloaded.
38
+ * Flag a concept diagram so learners stop being shown it
39
+ */
40
+ flagConceptDiagram(requestParameters: FlagConceptDiagramRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ConceptMediaFlagResult>;
27
41
  /**
28
42
  * Returns one non-hidden diagram the authenticated user authored, including its assembled HTML document.
29
43
  * Get a concept diagram the user authored