Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions schemas/schemas.config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ bundle_schemas:
OutputDirectory: bundled/resource
OutputFormat: ['Json', 'JsonVSCode']

# Adapted resource manifest bundle
- ConfigFilePath: adaptedresource/manifest.json
Name: manifest
OutputDirectory: bundled/adaptedresource
OutputFormat: ['Json', 'JsonVSCode']

Comment on lines +19 to +24
Copy link

Copilot AI Apr 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This adds a bundle for adaptedresource/manifest.json, but schemas/build.ps1’s schema registry is built only from config/metadata/definitions/extension/outputs/resource directories. Without adding the adaptedresource directory there, bundling won’t inline refs to /.../adaptedresource/* and the post-processing step that strips VS Code-only keywords also won’t run on the adaptedresource schemas.

Suggested change
# Adapted resource manifest bundle
- ConfigFilePath: adaptedresource/manifest.json
Name: manifest
OutputDirectory: bundled/adaptedresource
OutputFormat: ['Json', 'JsonVSCode']

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@michaeltlombardi - do you know by heart if this is a valid comment?

# Configuration document bundle
- ConfigFilePath: config/document.json
Name: document
Expand Down
99 changes: 99 additions & 0 deletions schemas/src/adaptedresource/manifest.schema.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
# yaml-language-server: $schema=https://json-schema.org/draft/2020-12/schema
$schema: https://json-schema.org/draft/2020-12/schema
$id: <HOST>/<PREFIX>/<VERSION>/adaptedresource/manifest.schema.yaml

title: Instance Schema
description: >-
Defines the JSON Schema for validating a JSON blob representing an instance of the adapted DSC
resource.

type: object
required:
- embedded
properties:
embedded:
title: Embedded Instance Schema
description: >-
Defines the JSON Schema DSC must use to validate a JSON blob representing an instance of the
adapted DSC resource.
markdownDescription: | # VS Code only
***
[_Online Documentation_][01]
***

Defines the JSON Schema DSC must use to validate a JSON blob representing an instance of the
adapted DSC resource.

[01]: <DOCS_BASE_URL>/reference/schemas/adaptedresource/manifest/schema/embedded?<DOCS_VERSION_PIN>
type: object
required:
- $schema
- type
- properties
properties:
type:
title: Instance Type
description: >-
Defines the JSON type for an instance of the adapted DSC resource. DSC resource instances
always have the `object` type.
const: object
markdownDescription: | # VS Code only
Defines the JSON type for an instance of the adapted DSC resource. DSC resource instances
always have the `object` type.
$schema:
title: Instance Schema Dialect
description: >-
Defines which dialect of JSON Schema the embedded schema uses.
type: string
enum:
- https://json-schema.org/draft/2020-12/schema
- https://json-schema.org/draft/2019-09/schema
- http://json-schema.org/draft-07/schema#
$id:
title: Instance Schema ID
description: >-
Defines the unique ID for the embedded schema. If defined, DSC can cache the schema for
faster validation.
type: string
format: uri
title:
title: Instance Schema Title
description: >-
Defines the title for the embedded schema.
type: string
description:
title: Instance Schema Description
description: >-
Defines the description for the embedded schema.
type: string
required:
title: Required Properties
description: >-
Defines the list of required properties for an instance of the adapted DSC resource.
type: array
items:
type: string
additionalProperties:
title: Additional Properties
description: >-
Defines whether the embedded schema allows additional properties.
type: boolean
properties:
title: Instance Properties
description: >-
Defines the properties of an instance of the adapted DSC resource.
type: object
additionalProperties:
type: object

# VS Code only
markdownDescription: |
***
[_Online Documentation_][01]
***

Defines the JSON Schema for validating a JSON blob representing an instance of the adapted
DSC resource. For adapted resources, only embedded schemas are supported. The adapter is
responsible for providing the schema during resource discovery.

[01]: <DOCS_BASE_URL>/reference/schemas/adaptedresource/manifest/schema?<DOCS_VERSION_PIN>
Loading
Loading