@lti-tool/core 0.12.2 → 0.13.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 (38) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/ltiTool.d.ts +24 -0
  3. package/dist/ltiTool.d.ts.map +1 -1
  4. package/dist/ltiTool.js +34 -1
  5. package/dist/schemas/index.d.ts +1 -0
  6. package/dist/schemas/index.d.ts.map +1 -1
  7. package/dist/schemas/index.js +1 -0
  8. package/dist/schemas/lti13/ags/lineItem.schema.d.ts +3 -3
  9. package/dist/schemas/lti13/deepLinking/contentItem.schema.d.ts +313 -0
  10. package/dist/schemas/lti13/deepLinking/contentItem.schema.d.ts.map +1 -0
  11. package/dist/schemas/lti13/deepLinking/contentItem.schema.js +163 -0
  12. package/dist/schemas/lti13/dynamicRegistration/ltiMessages.schema.d.ts +3 -3
  13. package/dist/schemas/lti13/dynamicRegistration/registrationResponse.schema.d.ts +1 -1
  14. package/dist/schemas/lti13/dynamicRegistration/toolRegistrationPayload.schema.d.ts +2 -2
  15. package/dist/services/ags.service.d.ts +23 -0
  16. package/dist/services/ags.service.d.ts.map +1 -1
  17. package/dist/services/ags.service.js +23 -0
  18. package/dist/services/deepLinking.service.d.ts +61 -0
  19. package/dist/services/deepLinking.service.d.ts.map +1 -0
  20. package/dist/services/deepLinking.service.js +109 -0
  21. package/dist/services/dynamicRegistration.service.d.ts +7 -0
  22. package/dist/services/dynamicRegistration.service.d.ts.map +1 -1
  23. package/dist/services/dynamicRegistration.service.js +7 -0
  24. package/dist/services/nrps.service.d.ts +15 -1
  25. package/dist/services/nrps.service.d.ts.map +1 -1
  26. package/dist/services/nrps.service.js +15 -1
  27. package/dist/services/token.service.d.ts +5 -2
  28. package/dist/services/token.service.d.ts.map +1 -1
  29. package/dist/services/token.service.js +5 -2
  30. package/package.json +1 -1
  31. package/src/ltiTool.ts +44 -1
  32. package/src/schemas/index.ts +9 -0
  33. package/src/schemas/lti13/deepLinking/contentItem.schema.ts +206 -0
  34. package/src/services/ags.service.ts +23 -0
  35. package/src/services/deepLinking.service.ts +128 -0
  36. package/src/services/dynamicRegistration.service.ts +7 -0
  37. package/src/services/nrps.service.ts +15 -1
  38. package/src/services/token.service.ts +5 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @lti-tool/core
2
2
 
3
+ ## 0.13.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 7bb4c98: Improve JSDoc for service layers
8
+
9
+ ## 0.13.0
10
+
11
+ ### Minor Changes
12
+
13
+ - d5a2793: Pass through keyId to utilize in kid when signing the Deep Linking JWT
14
+
3
15
  ## 0.12.2
4
16
 
5
17
  ### Patch Changes
package/dist/ltiTool.d.ts CHANGED
@@ -8,6 +8,7 @@ import { type DynamicRegistrationForm, type LTI13JwtPayload, type RegistrationRe
8
8
  import { type CreateLineItem, type LineItem, type LineItems, type UpdateLineItem } from './schemas/lti13/ags/lineItem.schema.js';
9
9
  import { type Results } from './schemas/lti13/ags/result.schema.js';
10
10
  import { type ScoreSubmission } from './schemas/lti13/ags/scoreSubmission.schema.js';
11
+ import { type DeepLinkingContentItem } from './schemas/lti13/deepLinking/contentItem.schema.js';
11
12
  import { type OpenIDConfiguration } from './schemas/lti13/dynamicRegistration/openIDConfiguration.schema.js';
12
13
  import { type Member } from './schemas/lti13/nrps/contextMembership.schema.js';
13
14
  /**
@@ -41,6 +42,7 @@ export declare class LTITool {
41
42
  private tokenService;
42
43
  private agsService;
43
44
  private nrpsService;
45
+ private deepLinkingService;
44
46
  private dynamicRegistrationService?;
45
47
  /**
46
48
  * Creates a new LTI Tool instance.
@@ -197,6 +199,28 @@ export declare class LTITool {
197
199
  * ```
198
200
  */
199
201
  getMembers(session: LTISession): Promise<Member[]>;
202
+ /**
203
+ * Creates a Deep Linking response with selected content items.
204
+ * Generates a signed JWT and returns HTML form that auto-submits to the platform.
205
+ *
206
+ * @param session - Active LTI session containing Deep Linking configuration
207
+ * @param contentItems - Array of content items selected by the user
208
+ * @returns HTML string containing auto-submit form
209
+ * @throws {Error} When Deep Linking is not available for the session
210
+ *
211
+ * @example
212
+ * ```typescript
213
+ * const html = await ltiTool.createDeepLinkingResponse(session, [
214
+ * {
215
+ * type: 'ltiResourceLink',
216
+ * title: 'Quiz 1',
217
+ * url: 'https://tool.example.com/quiz/1'
218
+ * }
219
+ * ]);
220
+ * // Render the HTML to return content items to platform
221
+ * ```
222
+ */
223
+ createDeepLinkingResponse(session: LTISession, contentItems: DeepLinkingContentItem[]): Promise<string>;
200
224
  /**
201
225
  * Fetches and validates the OpenID Connect configuration from an LTI platform during dynamic registration.
202
226
  * Validates that the OIDC endpoint and issuer have matching hostnames for security.
@@ -1 +1 @@
1
- {"version":3,"file":"ltiTool.d.ts","sourceRoot":"","sources":["../src/ltiTool.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AACjD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,+CAA+C,CAAC;AACnG,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,OAAO,EACL,KAAK,uBAAuB,EAE5B,KAAK,eAAe,EAEpB,KAAK,mBAAmB,EAGzB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,QAAQ,EACb,KAAK,SAAS,EAGd,KAAK,cAAc,EACpB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,KAAK,OAAO,EAAiB,MAAM,sCAAsC,CAAC;AACnF,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,+CAA+C,CAAC;AACrF,OAAO,EAAE,KAAK,mBA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AC,GAAG,OAAO,CAAC,MAAM,CAAC;IAK/E;;;;OAIG;IACG,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAMnD;;;;;OAKG;IACG,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,EAAE,CAAC;IAIjE;;;;;;OAMG;IACG,aAAa,CACjB,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,MAAM,GACnB,OAAO,CAAC,aAAa,GAAG,SAAS,CAAC;IAIrC;;;;;;OAMG;IACG,aAAa,CACjB,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,GACpC,OAAO,CAAC,MAAM,CAAC;IAIlB;;;;;;OAMG;IACG,gBAAgB,CACpB,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,MAAM,EACpB,UAAU,EAAE,OAAO,CAAC,aAAa,CAAC,GACjC,OAAO,CAAC,IAAI,CAAC;IAIhB;;;;;OAKG;IACG,gBAAgB,CAAC,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAM7E;;;;;;OAMG;IACG,sBAAsB,CAC1B,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,6BAA6B,GACrC,OAAO,CAAC,IAAI,CAAC;IAIhB;;;;;;OAMG;IACG,sBAAsB,CAC1B,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,6BAA6B,GAAG,SAAS,CAAC;IAIrD;;;;;OAKG;IACG,yBAAyB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAGlE"}
package/dist/ltiTool.js CHANGED
@@ -5,6 +5,7 @@ import { LineItemSchema, LineItemsSchema, } from './schemas/lti13/ags/lineItem.s
5
5
  import { ResultsSchema } from './schemas/lti13/ags/result.schema.js';
6
6
  import { NRPSContextMembershipResponseSchema, } from './schemas/lti13/nrps/contextMembership.schema.js';
7
7
  import { AGSService } from './services/ags.service.js';
8
+ import { DeepLinkingService } from './services/deepLinking.service.js';
8
9
  import { DynamicRegistrationService } from './services/dynamicRegistration.service.js';
9
10
  import { NRPSService } from './services/nrps.service.js';
10
11
  import { createSession } from './services/session.service.js';
@@ -41,6 +42,7 @@ export class LTITool {
41
42
  tokenService;
42
43
  agsService;
43
44
  nrpsService;
45
+ deepLinkingService;
44
46
  dynamicRegistrationService;
45
47
  /**
46
48
  * Creates a new LTI Tool instance.
@@ -60,6 +62,7 @@ export class LTITool {
60
62
  this.tokenService = new TokenService(this.config.keyPair, this.config.security?.keyId ?? 'main');
61
63
  this.agsService = new AGSService(this.tokenService, this.config.storage, this.logger);
62
64
  this.nrpsService = new NRPSService(this.tokenService, this.config.storage, this.logger);
65
+ this.deepLinkingService = new DeepLinkingService(this.config.keyPair, this.logger, this.config.security?.keyId ?? 'main');
63
66
  if (this.config.dynamicRegistration) {
64
67
  this.dynamicRegistrationService = new DynamicRegistrationService(this.config.storage, this.config.dynamicRegistration, this.logger);
65
68
  }
@@ -365,6 +368,36 @@ export class LTITool {
365
368
  roles: member.roles,
366
369
  }));
367
370
  }
371
+ /**
372
+ * Creates a Deep Linking response with selected content items.
373
+ * Generates a signed JWT and returns HTML form that auto-submits to the platform.
374
+ *
375
+ * @param session - Active LTI session containing Deep Linking configuration
376
+ * @param contentItems - Array of content items selected by the user
377
+ * @returns HTML string containing auto-submit form
378
+ * @throws {Error} When Deep Linking is not available for the session
379
+ *
380
+ * @example
381
+ * ```typescript
382
+ * const html = await ltiTool.createDeepLinkingResponse(session, [
383
+ * {
384
+ * type: 'ltiResourceLink',
385
+ * title: 'Quiz 1',
386
+ * url: 'https://tool.example.com/quiz/1'
387
+ * }
388
+ * ]);
389
+ * // Render the HTML to return content items to platform
390
+ * ```
391
+ */
392
+ async createDeepLinkingResponse(session, contentItems) {
393
+ if (!session) {
394
+ throw new Error('session is required');
395
+ }
396
+ if (!contentItems) {
397
+ throw new Error('contentItems is required');
398
+ }
399
+ return await this.deepLinkingService.createResponse(session, contentItems);
400
+ }
368
401
  /**
369
402
  * Fetches and validates the OpenID Connect configuration from an LTI platform during dynamic registration.
370
403
  * Validates that the OIDC endpoint and issuer have matching hostnames for security.
@@ -413,7 +446,7 @@ export class LTITool {
413
446
  */
414
447
  async completeDynamicRegistration(dynamicRegistrationForm) {
415
448
  if (!this.dynamicRegistrationService) {
416
- throw new Error('Dynmaic registration service is not configured');
449
+ throw new Error('Dynamic registration service is not configured');
417
450
  }
418
451
  return await this.dynamicRegistrationService.completeDynamicRegistration(dynamicRegistrationForm);
419
452
  }
@@ -1,4 +1,5 @@
1
1
  export { SessionIdSchema } from './common.schema.js';
2
+ export { ContentItemSchema, type DeepLinkingContentItem, type DeepLinkingFile, type DeepLinkingHtml, type DeepLinkingImage, type DeepLinkingLink, type DeepLinkingLtiResourceLink, } from './lti13/deepLinking/contentItem.schema.js';
2
3
  export { DynamicRegistrationFormSchema, type DynamicRegistrationForm, } from './lti13/dynamicRegistration/ltiDynamicRegistration.schema.js';
3
4
  export { LTIMessagesArraySchema, type LTIMessage, } from './lti13/dynamicRegistration/ltiMessages.schema.js';
4
5
  export { type OpenIDConfiguration } from './lti13/dynamicRegistration/openIDConfiguration.schema.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EACL,6BAA6B,EAC7B,KAAK,uBAAuB,GAC7B,MAAM,8DAA8D,CAAC;AACtE,OAAO,EACL,sBAAsB,EACtB,KAAK,UAAU,GAChB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2DAA2D,CAAC;AACrG,OAAO,EACL,yBAAyB,EACzB,KAAK,mBAAmB,GACzB,MAAM,2DAA2D,CAAC;AACnE,OAAO,EACL,0BAA0B,EAC1B,KAAK,oBAAoB,GAC1B,MAAM,4DAA4D,CAAC;AACpE,OAAO,EACL,qBAAqB,EACrB,KAAK,eAAe,GACrB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,iBAAiB,EACjB,wBAAwB,GACzB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EACL,iBAAiB,EACjB,KAAK,sBAAsB,EAC3B,KAAK,eAAe,EACpB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,0BAA0B,GAChC,MAAM,2CAA2C,CAAC;AACnD,OAAO,EACL,6BAA6B,EAC7B,KAAK,uBAAuB,GAC7B,MAAM,8DAA8D,CAAC;AACtE,OAAO,EACL,sBAAsB,EACtB,KAAK,UAAU,GAChB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2DAA2D,CAAC;AACrG,OAAO,EACL,yBAAyB,EACzB,KAAK,mBAAmB,GACzB,MAAM,2DAA2D,CAAC;AACnE,OAAO,EACL,0BAA0B,EAC1B,KAAK,oBAAoB,GAC1B,MAAM,4DAA4D,CAAC;AACpE,OAAO,EACL,qBAAqB,EACrB,KAAK,eAAe,GACrB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,iBAAiB,EACjB,wBAAwB,GACzB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC"}
@@ -1,4 +1,5 @@
1
1
  export { SessionIdSchema } from './common.schema.js';
2
+ export { ContentItemSchema, } from './lti13/deepLinking/contentItem.schema.js';
2
3
  export { DynamicRegistrationFormSchema, } from './lti13/dynamicRegistration/ltiDynamicRegistration.schema.js';
3
4
  export { LTIMessagesArraySchema, } from './lti13/dynamicRegistration/ltiMessages.schema.js';
4
5
  export { RegistrationRequestSchema, } from './lti13/dynamicRegistration/registrationRequest.schema.js';
@@ -22,13 +22,13 @@ export declare const LineItemSchema: z.ZodObject<{
22
22
  * @see https://www.imsglobal.org/spec/lti-ags/v2p0/#line-item-service
23
23
  */
24
24
  export declare const CreateLineItemSchema: z.ZodObject<{
25
- label: z.ZodString;
26
25
  scoreMaximum: z.ZodNumber;
26
+ label: z.ZodString;
27
27
  resourceId: z.ZodOptional<z.ZodString>;
28
- resourceLinkId: z.ZodOptional<z.ZodString>;
29
28
  tag: z.ZodOptional<z.ZodString>;
30
29
  startDateTime: z.ZodOptional<z.ZodISODateTime>;
31
30
  endDateTime: z.ZodOptional<z.ZodISODateTime>;
31
+ resourceLinkId: z.ZodOptional<z.ZodString>;
32
32
  }, z.core.$strip>;
33
33
  /**
34
34
  * Schema for updating an existing LTI Assignment and Grade Services (AGS) Line Item.
@@ -38,8 +38,8 @@ export declare const CreateLineItemSchema: z.ZodObject<{
38
38
  * @see https://www.imsglobal.org/spec/lti-ags/v2p0/#line-item-service
39
39
  */
40
40
  export declare const UpdateLineItemSchema: z.ZodObject<{
41
- label: z.ZodString;
42
41
  scoreMaximum: z.ZodNumber;
42
+ label: z.ZodString;
43
43
  resourceId: z.ZodOptional<z.ZodString>;
44
44
  tag: z.ZodOptional<z.ZodString>;
45
45
  startDateTime: z.ZodOptional<z.ZodISODateTime>;
@@ -0,0 +1,313 @@
1
+ import * as z from 'zod';
2
+ /**
3
+ * Zod schema for LTI Resource Link content item.
4
+ * Represents a launchable LTI tool resource that can be embedded in the platform.
5
+ *
6
+ * @property type - Always 'ltiResourceLink' for this content type
7
+ * @property url - Optional launch URL for the resource
8
+ * @property custom - Optional custom parameters passed to the tool on launch
9
+ * @property lineItem - Optional gradebook column configuration for this resource
10
+ * @property available - Optional availability window with start/end dates
11
+ * @property submission - Optional submission window with start/end dates
12
+ *
13
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#lti-resource-link
14
+ */
15
+ export declare const LtiResourceLinkSchema: z.ZodObject<{
16
+ title: z.ZodOptional<z.ZodString>;
17
+ text: z.ZodOptional<z.ZodString>;
18
+ icon: z.ZodOptional<z.ZodObject<{
19
+ url: z.ZodURL;
20
+ width: z.ZodOptional<z.ZodNumber>;
21
+ height: z.ZodOptional<z.ZodNumber>;
22
+ }, z.core.$strip>>;
23
+ thumbnail: z.ZodOptional<z.ZodObject<{
24
+ url: z.ZodURL;
25
+ width: z.ZodOptional<z.ZodNumber>;
26
+ height: z.ZodOptional<z.ZodNumber>;
27
+ }, z.core.$strip>>;
28
+ type: z.ZodLiteral<"ltiResourceLink">;
29
+ url: z.ZodOptional<z.ZodURL>;
30
+ custom: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
31
+ lineItem: z.ZodOptional<z.ZodObject<{
32
+ scoreMaximum: z.ZodNumber;
33
+ label: z.ZodString;
34
+ resourceId: z.ZodOptional<z.ZodString>;
35
+ tag: z.ZodOptional<z.ZodString>;
36
+ }, z.core.$strip>>;
37
+ available: z.ZodOptional<z.ZodObject<{
38
+ startDateTime: z.ZodOptional<z.ZodISODateTime>;
39
+ endDateTime: z.ZodOptional<z.ZodISODateTime>;
40
+ }, z.core.$strip>>;
41
+ submission: z.ZodOptional<z.ZodObject<{
42
+ startDateTime: z.ZodOptional<z.ZodISODateTime>;
43
+ endDateTime: z.ZodOptional<z.ZodISODateTime>;
44
+ }, z.core.$strip>>;
45
+ }, z.core.$strip>;
46
+ /**
47
+ * Zod schema for simple link content item.
48
+ * Represents a standard web link that can be opened in various ways.
49
+ *
50
+ * @property type - Always 'link' for this content type
51
+ * @property url - Target URL for the link
52
+ * @property embed - Optional HTML embed code
53
+ * @property window - Optional window configuration for opening the link
54
+ * @property iframe - Optional iframe configuration for embedding the link
55
+ *
56
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#link
57
+ */
58
+ export declare const LinkSchema: z.ZodObject<{
59
+ title: z.ZodOptional<z.ZodString>;
60
+ text: z.ZodOptional<z.ZodString>;
61
+ icon: z.ZodOptional<z.ZodObject<{
62
+ url: z.ZodURL;
63
+ width: z.ZodOptional<z.ZodNumber>;
64
+ height: z.ZodOptional<z.ZodNumber>;
65
+ }, z.core.$strip>>;
66
+ thumbnail: z.ZodOptional<z.ZodObject<{
67
+ url: z.ZodURL;
68
+ width: z.ZodOptional<z.ZodNumber>;
69
+ height: z.ZodOptional<z.ZodNumber>;
70
+ }, z.core.$strip>>;
71
+ type: z.ZodLiteral<"link">;
72
+ url: z.ZodURL;
73
+ embed: z.ZodOptional<z.ZodObject<{
74
+ html: z.ZodString;
75
+ }, z.core.$strip>>;
76
+ window: z.ZodOptional<z.ZodObject<{
77
+ targetName: z.ZodOptional<z.ZodString>;
78
+ windowFeatures: z.ZodOptional<z.ZodString>;
79
+ }, z.core.$strip>>;
80
+ iframe: z.ZodOptional<z.ZodObject<{
81
+ width: z.ZodOptional<z.ZodNumber>;
82
+ height: z.ZodOptional<z.ZodNumber>;
83
+ src: z.ZodURL;
84
+ }, z.core.$strip>>;
85
+ }, z.core.$strip>;
86
+ /**
87
+ * Zod schema for HTML fragment content item.
88
+ * Represents raw HTML content to be embedded directly in the platform.
89
+ *
90
+ * @property type - Always 'html' for this content type
91
+ * @property html - HTML content to be embedded
92
+ *
93
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#html-fragment
94
+ */
95
+ export declare const HtmlSchema: z.ZodObject<{
96
+ title: z.ZodOptional<z.ZodString>;
97
+ text: z.ZodOptional<z.ZodString>;
98
+ icon: z.ZodOptional<z.ZodObject<{
99
+ url: z.ZodURL;
100
+ width: z.ZodOptional<z.ZodNumber>;
101
+ height: z.ZodOptional<z.ZodNumber>;
102
+ }, z.core.$strip>>;
103
+ thumbnail: z.ZodOptional<z.ZodObject<{
104
+ url: z.ZodURL;
105
+ width: z.ZodOptional<z.ZodNumber>;
106
+ height: z.ZodOptional<z.ZodNumber>;
107
+ }, z.core.$strip>>;
108
+ type: z.ZodLiteral<"html">;
109
+ html: z.ZodString;
110
+ }, z.core.$strip>;
111
+ /**
112
+ * Zod schema for file content item.
113
+ * Represents a downloadable file resource.
114
+ *
115
+ * @property type - Always 'file' for this content type
116
+ * @property url - URL to download the file
117
+ * @property mediaType - MIME type of the file
118
+ * @property expiresAt - Optional expiration timestamp for the file URL
119
+ *
120
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#file
121
+ */
122
+ export declare const FileSchema: z.ZodObject<{
123
+ title: z.ZodOptional<z.ZodString>;
124
+ text: z.ZodOptional<z.ZodString>;
125
+ icon: z.ZodOptional<z.ZodObject<{
126
+ url: z.ZodURL;
127
+ width: z.ZodOptional<z.ZodNumber>;
128
+ height: z.ZodOptional<z.ZodNumber>;
129
+ }, z.core.$strip>>;
130
+ thumbnail: z.ZodOptional<z.ZodObject<{
131
+ url: z.ZodURL;
132
+ width: z.ZodOptional<z.ZodNumber>;
133
+ height: z.ZodOptional<z.ZodNumber>;
134
+ }, z.core.$strip>>;
135
+ type: z.ZodLiteral<"file">;
136
+ url: z.ZodURL;
137
+ mediaType: z.ZodString;
138
+ expiresAt: z.ZodOptional<z.ZodISODateTime>;
139
+ }, z.core.$strip>;
140
+ /**
141
+ * Zod schema for image content item.
142
+ * Represents an image resource with optional dimensions.
143
+ *
144
+ * @property type - Always 'image' for this content type
145
+ * @property url - URL to the image
146
+ * @property width - Optional image width in pixels
147
+ * @property height - Optional image height in pixels
148
+ *
149
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#image
150
+ */
151
+ export declare const ImageSchema: z.ZodObject<{
152
+ title: z.ZodOptional<z.ZodString>;
153
+ text: z.ZodOptional<z.ZodString>;
154
+ icon: z.ZodOptional<z.ZodObject<{
155
+ url: z.ZodURL;
156
+ width: z.ZodOptional<z.ZodNumber>;
157
+ height: z.ZodOptional<z.ZodNumber>;
158
+ }, z.core.$strip>>;
159
+ thumbnail: z.ZodOptional<z.ZodObject<{
160
+ url: z.ZodURL;
161
+ width: z.ZodOptional<z.ZodNumber>;
162
+ height: z.ZodOptional<z.ZodNumber>;
163
+ }, z.core.$strip>>;
164
+ type: z.ZodLiteral<"image">;
165
+ url: z.ZodURL;
166
+ width: z.ZodOptional<z.ZodNumber>;
167
+ height: z.ZodOptional<z.ZodNumber>;
168
+ }, z.core.$strip>;
169
+ /**
170
+ * Zod schema for validating any Deep Linking content item type.
171
+ * Uses discriminated union on the 'type' field to determine the specific content item schema.
172
+ * Supports: ltiResourceLink, link, html, file, and image content types.
173
+ *
174
+ * @see https://www.imsglobal.org/spec/lti-dl/v2p0#content-item-types
175
+ */
176
+ export declare const ContentItemSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
177
+ title: z.ZodOptional<z.ZodString>;
178
+ text: z.ZodOptional<z.ZodString>;
179
+ icon: z.ZodOptional<z.ZodObject<{
180
+ url: z.ZodURL;
181
+ width: z.ZodOptional<z.ZodNumber>;
182
+ height: z.ZodOptional<z.ZodNumber>;
183
+ }, z.core.$strip>>;
184
+ thumbnail: z.ZodOptional<z.ZodObject<{
185
+ url: z.ZodURL;
186
+ width: z.ZodOptional<z.ZodNumber>;
187
+ height: z.ZodOptional<z.ZodNumber>;
188
+ }, z.core.$strip>>;
189
+ type: z.ZodLiteral<"ltiResourceLink">;
190
+ url: z.ZodOptional<z.ZodURL>;
191
+ custom: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
192
+ lineItem: z.ZodOptional<z.ZodObject<{
193
+ scoreMaximum: z.ZodNumber;
194
+ label: z.ZodString;
195
+ resourceId: z.ZodOptional<z.ZodString>;
196
+ tag: z.ZodOptional<z.ZodString>;
197
+ }, z.core.$strip>>;
198
+ available: z.ZodOptional<z.ZodObject<{
199
+ startDateTime: z.ZodOptional<z.ZodISODateTime>;
200
+ endDateTime: z.ZodOptional<z.ZodISODateTime>;
201
+ }, z.core.$strip>>;
202
+ submission: z.ZodOptional<z.ZodObject<{
203
+ startDateTime: z.ZodOptional<z.ZodISODateTime>;
204
+ endDateTime: z.ZodOptional<z.ZodISODateTime>;
205
+ }, z.core.$strip>>;
206
+ }, z.core.$strip>, z.ZodObject<{
207
+ title: z.ZodOptional<z.ZodString>;
208
+ text: z.ZodOptional<z.ZodString>;
209
+ icon: z.ZodOptional<z.ZodObject<{
210
+ url: z.ZodURL;
211
+ width: z.ZodOptional<z.ZodNumber>;
212
+ height: z.ZodOptional<z.ZodNumber>;
213
+ }, z.core.$strip>>;
214
+ thumbnail: z.ZodOptional<z.ZodObject<{
215
+ url: z.ZodURL;
216
+ width: z.ZodOptional<z.ZodNumber>;
217
+ height: z.ZodOptional<z.ZodNumber>;
218
+ }, z.core.$strip>>;
219
+ type: z.ZodLiteral<"link">;
220
+ url: z.ZodURL;
221
+ embed: z.ZodOptional<z.ZodObject<{
222
+ html: z.ZodString;
223
+ }, z.core.$strip>>;
224
+ window: z.ZodOptional<z.ZodObject<{
225
+ targetName: z.ZodOptional<z.ZodString>;
226
+ windowFeatures: z.ZodOptional<z.ZodString>;
227
+ }, z.core.$strip>>;
228
+ iframe: z.ZodOptional<z.ZodObject<{
229
+ width: z.ZodOptional<z.ZodNumber>;
230
+ height: z.ZodOptional<z.ZodNumber>;
231
+ src: z.ZodURL;
232
+ }, z.core.$strip>>;
233
+ }, z.core.$strip>, z.ZodObject<{
234
+ title: z.ZodOptional<z.ZodString>;
235
+ text: z.ZodOptional<z.ZodString>;
236
+ icon: z.ZodOptional<z.ZodObject<{
237
+ url: z.ZodURL;
238
+ width: z.ZodOptional<z.ZodNumber>;
239
+ height: z.ZodOptional<z.ZodNumber>;
240
+ }, z.core.$strip>>;
241
+ thumbnail: z.ZodOptional<z.ZodObject<{
242
+ url: z.ZodURL;
243
+ width: z.ZodOptional<z.ZodNumber>;
244
+ height: z.ZodOptional<z.ZodNumber>;
245
+ }, z.core.$strip>>;
246
+ type: z.ZodLiteral<"html">;
247
+ html: z.ZodString;
248
+ }, z.core.$strip>, z.ZodObject<{
249
+ title: z.ZodOptional<z.ZodString>;
250
+ text: z.ZodOptional<z.ZodString>;
251
+ icon: z.ZodOptional<z.ZodObject<{
252
+ url: z.ZodURL;
253
+ width: z.ZodOptional<z.ZodNumber>;
254
+ height: z.ZodOptional<z.ZodNumber>;
255
+ }, z.core.$strip>>;
256
+ thumbnail: z.ZodOptional<z.ZodObject<{
257
+ url: z.ZodURL;
258
+ width: z.ZodOptional<z.ZodNumber>;
259
+ height: z.ZodOptional<z.ZodNumber>;
260
+ }, z.core.$strip>>;
261
+ type: z.ZodLiteral<"file">;
262
+ url: z.ZodURL;
263
+ mediaType: z.ZodString;
264
+ expiresAt: z.ZodOptional<z.ZodISODateTime>;
265
+ }, z.core.$strip>, z.ZodObject<{
266
+ title: z.ZodOptional<z.ZodString>;
267
+ text: z.ZodOptional<z.ZodString>;
268
+ icon: z.ZodOptional<z.ZodObject<{
269
+ url: z.ZodURL;
270
+ width: z.ZodOptional<z.ZodNumber>;
271
+ height: z.ZodOptional<z.ZodNumber>;
272
+ }, z.core.$strip>>;
273
+ thumbnail: z.ZodOptional<z.ZodObject<{
274
+ url: z.ZodURL;
275
+ width: z.ZodOptional<z.ZodNumber>;
276
+ height: z.ZodOptional<z.ZodNumber>;
277
+ }, z.core.$strip>>;
278
+ type: z.ZodLiteral<"image">;
279
+ url: z.ZodURL;
280
+ width: z.ZodOptional<z.ZodNumber>;
281
+ height: z.ZodOptional<z.ZodNumber>;
282
+ }, z.core.$strip>], "type">;
283
+ /**
284
+ * Type representing a validated LTI Resource Link content item.
285
+ * Used for creating launchable LTI tool resources.
286
+ */
287
+ export type DeepLinkingLtiResourceLink = z.infer<typeof LtiResourceLinkSchema>;
288
+ /**
289
+ * Type representing a validated simple link content item.
290
+ * Used for creating standard web links.
291
+ */
292
+ export type DeepLinkingLink = z.infer<typeof LinkSchema>;
293
+ /**
294
+ * Type representing a validated HTML fragment content item.
295
+ * Used for embedding raw HTML content.
296
+ */
297
+ export type DeepLinkingHtml = z.infer<typeof HtmlSchema>;
298
+ /**
299
+ * Type representing a validated file content item.
300
+ * Used for linking to downloadable files.
301
+ */
302
+ export type DeepLinkingFile = z.infer<typeof FileSchema>;
303
+ /**
304
+ * Type representing a validated image content item.
305
+ * Used for embedding images.
306
+ */
307
+ export type DeepLinkingImage = z.infer<typeof ImageSchema>;
308
+ /**
309
+ * Type representing any validated Deep Linking content item.
310
+ * Can be any of: DeepLinkingLtiResourceLink, DeepLinkingLink, DeepLinkingHtml, DeepLinkingFile, or DeepLinkingImage.
311
+ */
312
+ export type DeepLinkingContentItem = z.infer<typeof ContentItemSchema>;
313
+ //# sourceMappingURL=contentItem.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contentItem.schema.d.ts","sourceRoot":"","sources":["../../../../src/schemas/lti13/deepLinking/contentItem.schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAgCzB;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAwBhC,CAAC;AAEH;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAqBrB,CAAC;AAEH;;;;;;;;GAQG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;iBAGrB,CAAC;AAEH;;;;;;;;;;GAUG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;iBAKrB,CAAC;AAEH;;;;;;;;;;GAUG;AACH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;iBAKtB,CAAC;AAEH;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAM5B,CAAC;AAEH;;;GAGG;AACH,MAAM,MAAM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