diff --git a/schemas/src/config/document.metadata.yaml b/schemas/src/config/document.metadata.yaml index 5146112e..418039d6 100644 --- a/schemas/src/config/document.metadata.yaml +++ b/schemas/src/config/document.metadata.yaml @@ -32,7 +32,7 @@ properties: properties: securityContext: $ref: ///metadata/Microsoft.DSC/securityContext.yaml - default: Current + default: current description: >- This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with diff --git a/schemas/v3.0.0/bundled/config/document.json b/schemas/v3.0.0/bundled/config/document.json index c453b023..11a012ed 100644 --- a/schemas/v3.0.0/bundled/config/document.json +++ b/schemas/v3.0.0/bundled/config/document.json @@ -18,21 +18,45 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ] }, "parameters": { @@ -339,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } @@ -378,9 +402,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/config/document.vscode.json b/schemas/v3.0.0/bundled/config/document.vscode.json index 849e0690..ec971f31 100644 --- a/schemas/v3.0.0/bundled/config/document.vscode.json +++ b/schemas/v3.0.0/bundled/config/document.vscode.json @@ -19,42 +19,90 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "parameters": { @@ -503,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ @@ -591,11 +639,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/extension/manifest.json b/schemas/v3.0.0/bundled/extension/manifest.json new file mode 100644 index 00000000..90fc2713 --- /dev/null +++ b/schemas/v3.0.0/bundled/extension/manifest.json @@ -0,0 +1,174 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.0/bundled/extension/manifest.vscode.json b/schemas/v3.0.0/bundled/extension/manifest.vscode.json new file mode 100644 index 00000000..3e571a6a --- /dev/null +++ b/schemas/v3.0.0/bundled/extension/manifest.vscode.json @@ -0,0 +1,271 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.0": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.0/bundled/extension/stdout/discover.json b/schemas/v3.0.0/bundled/extension/stdout/discover.json new file mode 100644 index 00000000..3c85e295 --- /dev/null +++ b/schemas/v3.0.0/bundled/extension/stdout/discover.json @@ -0,0 +1,19 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/extension/stdout/discover.vscode.json b/schemas/v3.0.0/bundled/extension/stdout/discover.vscode.json new file mode 100644 index 00000000..13558838 --- /dev/null +++ b/schemas/v3.0.0/bundled/extension/stdout/discover.vscode.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the full path a DSC resource manifest. DSC expects every JSON Line emitted to stdout\nfor the **Discover** operation to adhere to this schema. An extension indicates that it supports\nthe **Discover** operation by defining the [discover][01] field in its manifest.\n\nThe output must be a JSON object that defines the `manifestPath` property.\n\nIf the extension doesn't discover any resources, it shouldn't emit any data to stdout.\n\nUnless the extension raises an error, it should exit with code `0`, even when no resources are\ndiscovered.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the absolute path to a DSC resource manifest on the system. DSC expects this value to\nbe the absolute path to a manifest file that exists. If this value is a relative path, or if\nthe manifest doesn't exist, DSC raises an error.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true#manifestPath", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/outputs/config/get.json b/schemas/v3.0.0/bundled/outputs/config/get.json index 836ee6b0..944d64da 100644 --- a/schemas/v3.0.0/bundled/outputs/config/get.json +++ b/schemas/v3.0.0/bundled/outputs/config/get.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/resource/get.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/config/get.vscode.json b/schemas/v3.0.0/bundled/outputs/config/get.vscode.json index 153504d2..6d43855f 100644 --- a/schemas/v3.0.0/bundled/outputs/config/get.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/config/get.vscode.json @@ -297,11 +297,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/config/set.json b/schemas/v3.0.0/bundled/outputs/config/set.json index 2e9e76ad..d86e2b30 100644 --- a/schemas/v3.0.0/bundled/outputs/config/set.json +++ b/schemas/v3.0.0/bundled/outputs/config/set.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/resource/set.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/config/set.vscode.json b/schemas/v3.0.0/bundled/outputs/config/set.vscode.json index 17d22d00..251f4db7 100644 --- a/schemas/v3.0.0/bundled/outputs/config/set.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/config/set.vscode.json @@ -313,11 +313,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/config/test.json b/schemas/v3.0.0/bundled/outputs/config/test.json index c3a52e40..cf943698 100644 --- a/schemas/v3.0.0/bundled/outputs/config/test.json +++ b/schemas/v3.0.0/bundled/outputs/config/test.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/resource/test.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/config/test.vscode.json b/schemas/v3.0.0/bundled/outputs/config/test.vscode.json index 1afa06f2..190d224d 100644 --- a/schemas/v3.0.0/bundled/outputs/config/test.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/config/test.vscode.json @@ -319,11 +319,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/extension/list.json b/schemas/v3.0.0/bundled/outputs/extension/list.json new file mode 100644 index 00000000..a05e9592 --- /dev/null +++ b/schemas/v3.0.0/bundled/outputs/extension/list.json @@ -0,0 +1,231 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.0/bundled/outputs/extension/list.vscode.json b/schemas/v3.0.0/bundled/outputs/extension/list.vscode.json new file mode 100644 index 00000000..3e4fbf0c --- /dev/null +++ b/schemas/v3.0.0/bundled/outputs/extension/list.vscode.json @@ -0,0 +1,332 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.0": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC extensions always have at least one capability. Extension capabilities define the operations\nDSC can invoke for an extension and how the extension behaves when invoked.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nAn extension with the `discover` capability supports retrieving the path to DSC resource\nmanifests that aren't included in the `PATH` or `DSC_RESOURCE_PATH`, like manifests for\nsoftware installed as AppX packages.\n\nAn extension has this capability when its manifest defines the [discover][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true#discover\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true" + ] + } + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + } + }, + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.0/bundled/outputs/resource/get.json b/schemas/v3.0.0/bundled/outputs/resource/get.json index fa06a34e..64d9ab75 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/get.json +++ b/schemas/v3.0.0/bundled/outputs/resource/get.json @@ -97,9 +97,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/resource/get.vscode.json b/schemas/v3.0.0/bundled/outputs/resource/get.vscode.json index 92e371fd..00c405c8 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/get.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/resource/get.vscode.json @@ -123,11 +123,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.0/bundled/outputs/resource/list.json b/schemas/v3.0.0/bundled/outputs/resource/list.json index f58c873d..2f625e24 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/list.json +++ b/schemas/v3.0.0/bundled/outputs/resource/list.json @@ -99,9 +99,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -113,7 +113,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json": { @@ -166,21 +167,45 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -281,7 +306,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -299,9 +327,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1037,30 +1186,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.0/bundled/outputs/resource/list.vscode.json b/schemas/v3.0.0/bundled/outputs/resource/list.vscode.json index c76a3d60..6dc0e91f 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/list.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/resource/list.vscode.json @@ -105,11 +105,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -121,14 +121,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "semver.json": { @@ -509,42 +511,90 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../resource/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/resource/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/resource/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "type": { @@ -662,7 +712,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -680,9 +733,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1935,33 +2109,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.0/bundled/outputs/resource/set.json b/schemas/v3.0.0/bundled/outputs/resource/set.json index f8ec5f5b..bb95c187 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/set.json +++ b/schemas/v3.0.0/bundled/outputs/resource/set.json @@ -113,9 +113,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/resource/set.vscode.json b/schemas/v3.0.0/bundled/outputs/resource/set.vscode.json index e354740d..1c84c7a0 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/set.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/resource/set.vscode.json @@ -139,11 +139,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.0/bundled/outputs/resource/test.json b/schemas/v3.0.0/bundled/outputs/resource/test.json index 60287874..45ce05cc 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/test.json +++ b/schemas/v3.0.0/bundled/outputs/resource/test.json @@ -119,9 +119,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.0/bundled/outputs/resource/test.vscode.json b/schemas/v3.0.0/bundled/outputs/resource/test.vscode.json index 6961855b..70d4cbc3 100644 --- a/schemas/v3.0.0/bundled/outputs/resource/test.vscode.json +++ b/schemas/v3.0.0/bundled/outputs/resource/test.vscode.json @@ -145,11 +145,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.0/bundled/resource/manifest.json b/schemas/v3.0.0/bundled/resource/manifest.json index 3cf7cf55..73ac9bb5 100644 --- a/schemas/v3.0.0/bundled/resource/manifest.json +++ b/schemas/v3.0.0/bundled/resource/manifest.json @@ -19,21 +19,45 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -134,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -152,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -166,9 +314,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -189,7 +337,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.get.json": { @@ -920,30 +1069,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.0/bundled/resource/manifest.vscode.json b/schemas/v3.0.0/bundled/resource/manifest.vscode.json index 30bdb1dd..0e4af833 100644 --- a/schemas/v3.0.0/bundled/resource/manifest.vscode.json +++ b/schemas/v3.0.0/bundled/resource/manifest.vscode.json @@ -243,42 +243,90 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../resource/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/resource/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/resource/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "type": { @@ -396,7 +444,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -414,9 +465,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -434,11 +606,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -460,14 +632,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "commandExecutable.json": { @@ -1807,33 +1981,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.0/bundled/resource/stdout/delete.json b/schemas/v3.0.0/bundled/resource/stdout/delete.json new file mode 100644 index 00000000..619a9d8b --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/delete.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/delete.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/delete.vscode.json new file mode 100644 index 00000000..908c9c03 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/delete.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC does not expect the **Delete** operation for a resource to return any JSON to stdout.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/delete?view=dsc-3.0&preserve-view=true\n", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/export.json b/schemas/v3.0.0/bundled/resource/stdout/export.json new file mode 100644 index 00000000..d0826b7c --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/export.json @@ -0,0 +1,71 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json" + } + ], + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/export.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/export.vscode.json new file mode 100644 index 00000000..58ce8cd4 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/export.vscode.json @@ -0,0 +1,130 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a resource implementing the **Export** operation to return a series of JSON Lines.\n\nThe data that DSC expects depends on whether the resource kind is defined as `exporter`:\n\n- When the resource kind is `exporter`, DSC expects the resource to return JSON Lines\n representing DSC resource instance definitions to recursively export.\n- When the resource kind isn't `exporter`, DSC expects the resource to return JSON Lines\n representing the actual state of every instance of the resource on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a typical resource implementing the **Export** operation to return a series of\nJSON Lines.\n\nEach JSON Line represents the actual state of a resource instance in DSC. DSC expects every\nJSON Line emitted to stdout for the **Export** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects an exporter resource (one with the `kind` field in its manifest set to\n`exporter`) to return a series of JSON Lines.\n\nEach JSON Line represents a DSC resource instance definition to recursively invoke the\n**Export** operation for. DSC expects every JSON Line emitted to stdout for the **Export**\noperation to adhere to this schema.\n\nThe output must be a JSON object adhering to [DSC resource instance][01] schema, rather than\nthe instance schema for a specific resource. DSC expects the object to define at least the\n[name][02] and [type][03] fields. If the object defines the [properties][04] field, DSC\npasses those properties to the resource when recursively exporting it so that the resource\nmay filter the exported instance results.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#type\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + ], + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.0": { + "config": { + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + } + }, + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/get.json b/schemas/v3.0.0/bundled/resource/stdout/get.json new file mode 100644 index 00000000..6fc6dac8 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/get.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/get.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/get.vscode.json new file mode 100644 index 00000000..286c8437 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/get.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to\nstdout for the **Get** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of the\nresource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/get?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/list.json b/schemas/v3.0.0/bundled/resource/stdout/list.json new file mode 100644 index 00000000..0b26f12d --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/list.json @@ -0,0 +1,122 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "kind": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ] + } + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/list.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/list.vscode.json new file mode 100644 index 00000000..2264e6c6 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/list.vscode.json @@ -0,0 +1,157 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to\nstdout for the **List** operation to adhere to this schema.\n\nDSC includes the following adapter resources:\n\n- `Microsoft.DSC/PowerShell` run PowerShell and enables you to use PowerShell DSC (PSDSC)\n resources implemented as PowerShell classes in DSC.\n- `Microsoft.Windows/WindowsPowerShell` runs Windows PowerShell and enables you to use any\n available PSDSC resources in DSC. This adapter is only available when you install DSC on\n Windows.\n- `Microsoft.Windows/WMI` enables you to use WMI classes as resources in DSC. This adapter is\n only available when you install DSC on Windows.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/list?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "kind": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.0": { + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\nIndicates that the manifest is for a typical DSC command resource.\n", + "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", + "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" + ] + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC resources always have at least one capability. Resource capabilities define the operations\nyou can invoke for a resource and how the resource behaves when invoked.\n\nFor more information about the operations you can invoke for a resource, see\n[DSC resource operations][01].\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `get` capability supports retrieving the current state of an instance\nwith the [Get][01] operation.\n\nA command resource has this capability when its resource manifest defines the [get][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#get\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#get-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/get?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `set` capability supports enforcing the desired state of an instance with\nthe [Set][01] operation. Resources without this capability can't be used with the\n[dsc resource set][02] or [dsc config set][03] commands unless they're defined in a\n`Microsoft.DSC/Assertion` group as a nested instance.\n\nA command resource has this capability when its resource manifest defines the [set][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#set\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/set?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/set?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `setHandlesExist` capability indicates that you can use the [Set][01]\noperation to delete an instance. Resources with this capability must have the [_exist][02]\ncanonical resource property. Resources that don't have the `_exist` property never have this\ncapability.\n\nWhen a resource has the `_exist` property but not the `setHandlesExist` capability:\n\n- If the resource has the `delete` capability, DSC invokes the [Delete][03] operation instead\n of **Set** when the desired state for an instance defines `_exist` as false.\n- If the resource doesn't have the `delete` capability, DSC raises an error during a **Set**\n operation when the desired state for an instance defines `_exist` as false.\n\nA command resource has this capability when its resource manifest defines the\n[set.handlesExist][04] subproperty as `true`.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#sethandlesexist\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/existview=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#delete-operation\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/setview=dsc-3.0&preserve-view=true#handlesexist", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `whatIf` capability indicates that you can use the [Set][01] operation in\nwhat-if mode to have the resource return explicit information about how it would modify state\nin an actual **Set** operation.\n\nWhen a resource doesn't have this capability, DSC synthesizes how the resource would change\nan instance by converting the **Test** result for the instance into a **Set** result. The\nsynthetic operation can't indicate potential issues or changes that can't be determined by\ncomparing the result of the **Test** operation against the resource's desired state. For\nexample, the credentials used to test a resource might be valid for that operation, but not\nhave permissions to actually modify the system state. Only a resource with this capability\ncan fully report whether and how the resource would change system state.\n\nA resource has this capability when it defines the [whatIf][02] property.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#whatif\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `test` capability indicates that it implements the [Test][01] operation\ndirectly. Resources with this capability must have the [_inDesiredState][02] canonical\nresource property. Resources that don't have the `_inDesiredState` property never have this\ncapability.\n\nWhen a resource doesn't have this capability, DSC uses a synthetic test for instances of the\nresource. DSC performs the synthetic test by:\n\n1. Invoking the **Get** operation on the resource to retrieve the actual state of the\n instance.\n1. Synthetically testing each property for the desired state of an instance against the\n actual state returned. The synthetic test uses strict, case-sensitive equivalence.\n1. If the desired state for a property and the actual state aren't the same, DSC marks the\n property as out of the desired state.\n1. If any properties are out of the desired state, DSC reports the entire instance as not\n being in the desired state.\n\nSynthetic testing can't account for all resource behaviors. For example, if a package\nresource allows users to define a version range for the package, the **Get** operation\nreturns the actual version of the package, like `1.2.3`. If the user specified the version\nrange `~1` (NPM syntax indicating the package should be latest released semantic version with\nmajor version `1`), DSC would compare the desired state `~1` against the actual state `1.2.3`\nand consider the package to be in the incorrect state, even if `1.2.3` is actually the latest\nrelease matching the version pin.\n\nAny resource that has properties which can't use a strict case-sensitive comparison check\nshould have this capability.\n\nA command resource has this capability when its resource manifest defines the [test][03]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#test\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#test-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `delete` capability supports removing an instance with the [Delete][01]\noperation and the [dsc resource delete][02] command.\n\nThis capability isn't mutually exclusive with the `setHandlesExist` property. A resource can handle\nthe `_exist` property in **Set** operations and be called directly with `dsc resource delete` to\nremove an instance.\n\nFor resources with the `delete` capability and the [_exist][03] canonical resource property:\n\n- If the resource doesn't have the `setHandlesExist` capability, DSC invokes the **Delete**\n operation for the resource instead of **Set** when the desired state defines `_exist` as\n `false`.\n- If the resource does have the `setHandlesExist` capability, DSC invokes the **Set** operation for\n the resource when the desired state defines `_exist` as `false`.\n\nResources with the `delete` capability that don't have the `_exist` canonical resource property\nmust implement their **Set** operation to handle removing instances. DSC can't infer existence\nsemantics without the `_exist` property.\n\nA command resource has this capability when its resource manifest defines the [delete][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#delete\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#delete-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/delete?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/delete?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `export` capability supports enumerating every instance of the resource\nwith the [Export][01] operation.\n\nYou can use resources with this capability with the following commands:\n\n- [dsc config export][02] to return a configuration document representing the actual state\n for every instance of each resource defined in the input document.\n- [dsc resource export][03] to return a configuration document representing the actual state\n for every instance of the input resource.\n- `dsc resource get` with the [--all][04] option to return the actual state of every instance\n of the input resource.\n\nA command resource has this capability when its resource manifest defines the [export][05]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#export\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#export-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/export?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/export?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/get?view=dsc-3.0&preserve-view=true#--all\n[05]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/export?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `resolve` capability supports resolving nested resource instances from an\nexternal source. This capability is primarily used by [importer resources][01] to enable users to\ncompose configuration documents.\n\nA command resource has this capability when its resource manifest defines the [resolve][0220]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#resolve\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true#importer-resources\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/resolve?view=dsc-3.0&preserve-view=true" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/resolve.json b/schemas/v3.0.0/bundled/resource/stdout/resolve.json new file mode 100644 index 00000000..797ffcaf --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/resolve.json @@ -0,0 +1,453 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "type": "object" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.parameter.json" + } + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object" + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json" + } + }, + "metadata": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.metadata.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json" + } + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object" + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0 + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0 + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." + } + } + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/resolve.vscode.json new file mode 100644 index 00000000..0c0b0d62 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/resolve.vscode.json @@ -0,0 +1,708 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of a resolved configuration document. DSC expects the JSON Line\nemitted to stdout for the **Resolve** operation to adhere to this schema.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the resolved configuration document. If the configuration document defines any\nparameters, values for those parameters may be retrieved from the `parameters` property of\nthe **Resolve** operation output.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#configuration", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `parameters` property defines the set of resolved parameter values for the resolved\nconfiguration document. If the `parameters` property is omitted from the output for the\n**Resolve** operation, DSC doesn't pass any parameters to the resolved configuration\nwhen invoking operations on it.\n\nEach property of this object represents a different resolved parameter. The property name\nidentifies the name of a parameter. The property value is the resolved value for the\nparameter.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#parameters", + "type": "object" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.0": { + "config": { + "document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDescribes a valid DSC configuration document.\n\nDSC configurations enable users to define state by combining different DSC resources. A\nconfiguration document uses parameters and variables to pass to a set of one or more resources\nthat define a desired state.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/config/document.parameter.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines runtime options for the configuration. Users and integrating tools can override use\nthe defined parameters to pass alternate values to the configuration.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#parameters\n", + "defaultSnippets": [ + { + "label": " New Parameter", + "markdownDescription": "Defines a new runtime option for the configuration.\n\n```yaml\nparameterId:\n type: \n description: \n defaultValue: \n allowedValues:\n - \n```", + "body": { + "${1:parameterId}": { + "type": "$2", + "description": "$3", + "defaultValue": "$4", + "allowedValues": [ + "$5" + ] + } + } + }, + { + "label": " New Integer Parameter", + "markdownDescription": "Defines a new runtime option for the configuration as an integer value.\n\n```yaml\nparameterId:\n type: int\n description: \n defaultValue: \n minValue: \n minValue: \n```", + "body": { + "${1:parameterId}": { + "type": "int", + "description": "$2", + "defaultValue": "$3", + "minValue": "$4", + "maxValue": "$5" + } + } + } + ] + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of reusable values for the configuration document. The names of this value's\nproperties are the strings used to reference a variable's value.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#variables\n", + "defaultSnippets": [ + { + "label": " New variable property", + "markdownDescription": "Defines a new variable as a key-value pair.\n\n```yaml\nvariableName: variableValue\n```", + "body": { + "${1:variableName}": "${2:variableValue}" + } + }, + { + "label": " New variable property (object)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an object.\n\n```yaml\nvariableName:\n key: value\n```", + "body": { + "${1:variableName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New variable property (array)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an array.\n\n```yaml\nvariableName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:variableName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances for the configuration to manage.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#resources\n" + }, + "metadata": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/config/document.metadata.json" + } + } + }, + "document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a runtime option for a DSC configuration document.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the default value for the parameter.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of valid values for the parameter. If the parameter is defined with any other\nvalues, it's invalid.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a synopsis for the parameter explaining its purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the parameter. This metadata isn't validated.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#metadata-1\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid value for an integer type. If defined with the `maxValue` property,\nthis value must be less than the value of `maxValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minvalue\n" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid value for an integer type. If defined with the `minValue` property,\nthis value must be greater than the value of `minValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxvalue\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `maxLength` property, this value must be less than the value of `maxLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minLength\n" + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `minLength` property, this value must be less than the value of `minLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxLength\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + }, + "document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe `Microsoft.DSC` metadata property contains directives and information that DSC itself\nuses when processing a configuration document. Unlike other metadata key-value pairs, DSC\nvalidates these properties.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "markdownEnumDescriptions": [ + "\n\n> ### Current security context\n>\n> Indicates that the configuration document is usable under any security context. You\n> can invoke DSC operations against the document when elevated as root or an\n> administrator and as a normal user or account.\n", + "\n\n> ### Elevated security context\n>\n> Indicates that the configuration document is usable only in an elevated security\n> context. You can invoke DSC operations against the document when elevated as root or\n> an administrator. When you invoke DSC operations against the document as a\n> non-elevated user or account, DSC raises an error when it validates the configuration\n> document.\n", + "\n\n> ### Restricted security context\n>\n> Indicates that the configuration document is usable only in a non-elevated security\n> context. You can invoke DSC operations against the document as a non-elevated user or\n> account. When you invoke DSC operations against the document as root or an\n> administrator, DSC raises an error when it validates the configuration document.\n" + ] + } + } + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC`\nproperty, this metadata isn't validated. You can pass any data into this property of a\nconfiguration document.\n\nThe `Microsoft.DSC` metadata property contains metadata directives and information that DSC\nitself uses when processing the configuration document. For more information, see\n[Microsoft.DSC][02]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "definitions": { + "parameters": { + "dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the data type for the parameter value.\n\nThe valid data types for a parameter are:\n\n- `array` for arrays\n- `bool` for booleans\n- `int` for integers\n- `object` for objects\n- `string` for strings\n- `secureObject` for secure objects\n- `secureString` for secure strings\n\nAccess parameters in a configuration using this syntax:\n\n```yaml\n\"[parameter('')]\"\n```\n\nIn YAML, the parameter syntax needs to be enclosed in double-quotes when used as an inline value.\nIf the syntax isn't quoted, YAML interprets the syntax as an array.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "_Strings are an arbitrary set of text._\n\n> To define a long strings in YAML, use the folded block syntax or literal block syntax by\n> adding a `>` or `|` and a line break after the key. Then, indent the next line. Every line\n> in the string must start at the same level of indentation. You can trim the trailing\n> whitespace by using `>-` or `|-` instead.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#strings\n", + "_Secure strings are text that needs to be handled securely._\n\n> Secure strings are an arbitrary set of text that DSC and integrating tools shouldn't log or\n> record. If a secure data type parameter is used for a resource instance property that doesn't\n> expect a secure value, the resource may still log or record the value. If the resource has\n> independent logging or recording that isn't handled by DSC, the value may be stored\n> insecurely.\n>\n> Use secure strings for passwords and secrets. Never define a default value for secure string\n> parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Integer values are numbers without a fractional part._\n\n> Integer values may be limited by integrating tools or the DSC resources they're used with.\n> DSC itself supports integer values between `-9223372036854775808` and `9223372036854775807`.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#integers\n", + "_Boolean values are either `true` or `false`._\n\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#booleans\n", + "_Objects define a set of key-value pairs._\n\n> The value for each key can be any valid data type. The values can be the same type or\n> different types.\n>\n> Access keys in the object using dot-notation. Dot-notation uses this syntax:\n>\n> ```yaml\n> \"[parameters('').]\n> ```\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#objects\n", + "_Secure objects are key-value pairs that need to be handled securely._\n\n> Secure objects define a set of key-value pairs that DSC and integrating tools shouldn't log\n> or record. If a secure data type parameter is used for a resource instance property that\n> doesn't expect a secure value, the resource may still log or record the value. If the\n> resource has independent logging or recording that isn't handled by DSC, the value may be\n> stored insecurely.\n>\n> Never define a default value for secure object parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Arrays are a list of one or more values._\n\n> The values in the array can be any valid data type. Values in the array can be the same type\n> or different types.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#arrays\n" + ] + }, + "validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + } + }, + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + }, + "metadata": { + "Microsoft.DSC": { + "securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "markdownDescription": "Defines the security context that DSC was run under. If the value for this metadata property is\n`elevated`, DSC was run as `root` (non-Windows) or an elevated session with Administrator\nprivileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in\na non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/schema.json b/schemas/v3.0.0/bundled/resource/stdout/schema.json new file mode 100644 index 00000000..b8d7ce3e --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/schema.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/schema.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/schema.vscode.json new file mode 100644 index 00000000..c3028eb7 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/schema.vscode.json @@ -0,0 +1,14 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the JSON Schema that validates instances of the resource. DSC expects a resource that\ndefines the [`schema.command`][01] field in its resource manifest to return this value for that\ncommand.\n\nThe output must be a JSON object. The object must be a valid JSON Schema. For more information\nabout what DSC expects for resource instance JSON Schemas, see\n[DSC Resource manifest embedded schema reference][02], which describes the expectations in full.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/set.json b/schemas/v3.0.0/bundled/resource/stdout/set.json new file mode 100644 index 00000000..2c31beb9 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/set.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/set.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/set.vscode.json new file mode 100644 index 00000000..10cf21ad --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/set.vscode.json @@ -0,0 +1,32 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation.\n\nDSC expects this output for both actual **Set** operations and **Set** operations in `whatIf`\nmode. If the resource has the `whatIf` capability, the output should be the same for both modes.\n\nDSC expects different output from the command resource depending on the definition of\n[set.return][01] in the resource manifest:\n\n- If the field isn't defined, DSC doesn't expect the resource to return any JSON to stdout.\n Instead, DSC invokes the **Get** operation on the resource after the **Set** operation\n concludes and synthesizes the **Set** result, including the after state of the resource and\n the list of changed properties.\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource doesn't define [set.return][01] in its resource manifest, DSC doesn't expect\nthe resource to emit any JSON to stdout for the **Set** operation.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#null-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nactual state of the resource instance after the **Set** operation changes the system.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/test.json b/schemas/v3.0.0/bundled/resource/stdout/test.json new file mode 100644 index 00000000..37722c2c --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/test.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/test.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/test.vscode.json new file mode 100644 index 00000000..d8fba5a0 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/test.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Test** operation.\n\nDSC expects different output from the command resource depending on the definition of\n[test.return][01] in the resource manifest:\n\n- If the field is omitted or defined as `state` (the default value), DSC expects the resource to\n emit a JSON Line to stdout representing the actual state of the resource instance with the\n [_inDesiredState][02] canonical resource property included in the returned object.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource instance with\n the `_inDesiredState` included in the returned object. The second JSON Line should be an array\n representing the names of the resource properties that aren't in the desired state.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nFor the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout\nrepresenting the actual state of the resource instance with the [_inDesiredState][01]\ncanonical resource property included in the returned object.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [test.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that aren't in the desired state.\n\nThis output must be emitted after the JSON Line representing the actual state of the resource\ninstance with the [_inDesiredState][02] canonical resource property included in the returned\nobject.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique. The array should never include the `_inDesiredState`\nproperty.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/validate.json b/schemas/v3.0.0/bundled/resource/stdout/validate.json new file mode 100644 index 00000000..d8fa8bb4 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/validate.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource." + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource." + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/validate.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/validate.vscode.json new file mode 100644 index 00000000..fc7dfc6d --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/validate.vscode.json @@ -0,0 +1,24 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.\n\nDSC expects the resource to return a JSON object that indicates whether the instance is valid and\noptionally a string indicating how the resource is invalid.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nIndicates whether the instance is valid for the resource. When the value is `true`, the\ninstance is valid for the resource.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#valid" + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDescribes how and why the instance is invalid for the resource. Always define this property\nin the output object when `valid` is `false`. Don't define this property in the output object\nwhen `valid` is `true`.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#reason" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/whatIf.json b/schemas/v3.0.0/bundled/resource/stdout/whatIf.json new file mode 100644 index 00000000..c63ecbe1 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/whatIf.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/bundled/resource/stdout/whatIf.vscode.json b/schemas/v3.0.0/bundled/resource/stdout/whatIf.vscode.json new file mode 100644 index 00000000..1140dc70 --- /dev/null +++ b/schemas/v3.0.0/bundled/resource/stdout/whatIf.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if\nmode.\n\nDSC expects different output from the command resource depending on the definition of\n[whatIf.return][01] in the resource manifest:\n\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nexpected actual state of the resource instance after the **Set** operation changes the\nsystem.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.0/config/document.json b/schemas/v3.0.0/config/document.json index 6d6eb74f..fe676762 100644 --- a/schemas/v3.0.0/config/document.json +++ b/schemas/v3.0.0/config/document.json @@ -18,21 +18,45 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ] }, "parameters": { diff --git a/schemas/v3.0.0/config/document.metadata.json b/schemas/v3.0.0/config/document.metadata.json index c6b1b058..91c62783 100644 --- a/schemas/v3.0.0/config/document.metadata.json +++ b/schemas/v3.0.0/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.0.0/definitions/extensionCapabilities.json b/schemas/v3.0.0/definitions/extensionCapabilities.json new file mode 100644 index 00000000..536c7543 --- /dev/null +++ b/schemas/v3.0.0/definitions/extensionCapabilities.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } +} diff --git a/schemas/v3.0.0/definitions/extensionType.json b/schemas/v3.0.0/definitions/extensionType.json new file mode 100644 index 00000000..8e248d35 --- /dev/null +++ b/schemas/v3.0.0/definitions/extensionType.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" +} diff --git a/schemas/v3.0.0/definitions/resourceKind.json b/schemas/v3.0.0/definitions/resourceKind.json index b402ee49..e5b1f34c 100644 --- a/schemas/v3.0.0/definitions/resourceKind.json +++ b/schemas/v3.0.0/definitions/resourceKind.json @@ -8,6 +8,7 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] } diff --git a/schemas/v3.0.0/definitions/resourceType.json b/schemas/v3.0.0/definitions/resourceType.json index 8313b45c..8eda9a59 100644 --- a/schemas/v3.0.0/definitions/resourceType.json +++ b/schemas/v3.0.0/definitions/resourceType.json @@ -2,7 +2,7 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" } diff --git a/schemas/v3.0.0/extension/manifest.discover.json b/schemas/v3.0.0/extension/manifest.discover.json new file mode 100644 index 00000000..ad14f50c --- /dev/null +++ b/schemas/v3.0.0/extension/manifest.discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/commandArgs.json" + } + } +} diff --git a/schemas/v3.0.0/extension/manifest.json b/schemas/v3.0.0/extension/manifest.json new file mode 100644 index 00000000..95e8d428 --- /dev/null +++ b/schemas/v3.0.0/extension/manifest.json @@ -0,0 +1,92 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } +} diff --git a/schemas/v3.0.0/extension/stdout/discover.json b/schemas/v3.0.0/extension/stdout/discover.json new file mode 100644 index 00000000..b6d1f511 --- /dev/null +++ b/schemas/v3.0.0/extension/stdout/discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + } +} diff --git a/schemas/v3.0.0/outputs/extension/list.json b/schemas/v3.0.0/outputs/extension/list.json new file mode 100644 index 00000000..516aab6f --- /dev/null +++ b/schemas/v3.0.0/outputs/extension/list.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/extension/manifest.json" + } + } +} diff --git a/schemas/v3.0.0/resource/manifest.json b/schemas/v3.0.0/resource/manifest.json index 7d12a2d3..40c51de8 100644 --- a/schemas/v3.0.0/resource/manifest.json +++ b/schemas/v3.0.0/resource/manifest.json @@ -19,21 +19,45 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -134,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -152,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] diff --git a/schemas/v3.0.0/resource/manifest.schema.json b/schemas/v3.0.0/resource/manifest.schema.json index 06415058..fb0ee64a 100644 --- a/schemas/v3.0.0/resource/manifest.schema.json +++ b/schemas/v3.0.0/resource/manifest.schema.json @@ -93,30 +93,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.0/resource/stdout/export.json b/schemas/v3.0.0/resource/stdout/export.json index d66ebdd1..0155d048 100644 --- a/schemas/v3.0.0/resource/stdout/export.json +++ b/schemas/v3.0.0/resource/stdout/export.json @@ -3,5 +3,16 @@ "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/stdout/export.json", "title": "Export resource operation stdout", "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", - "type": "object" + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.0/config/document.resource.json" + } + ] } diff --git a/schemas/v3.0.1/bundled/config/document.json b/schemas/v3.0.1/bundled/config/document.json index a5dd847c..5dda9ecc 100644 --- a/schemas/v3.0.1/bundled/config/document.json +++ b/schemas/v3.0.1/bundled/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -27,9 +33,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -38,7 +53,10 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ] }, "parameters": { @@ -345,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } @@ -384,9 +402,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/config/document.vscode.json b/schemas/v3.0.1/bundled/config/document.vscode.json index 9529b525..34483f0e 100644 --- a/schemas/v3.0.1/bundled/config/document.vscode.json +++ b/schemas/v3.0.1/bundled/config/document.vscode.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -28,9 +34,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -39,13 +54,22 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -55,9 +79,18 @@ "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -66,7 +99,10 @@ "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "parameters": { @@ -515,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ @@ -603,11 +639,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/extension/manifest.json b/schemas/v3.0.1/bundled/extension/manifest.json new file mode 100644 index 00000000..ce65d8e0 --- /dev/null +++ b/schemas/v3.0.1/bundled/extension/manifest.json @@ -0,0 +1,174 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.1/bundled/extension/manifest.vscode.json b/schemas/v3.0.1/bundled/extension/manifest.vscode.json new file mode 100644 index 00000000..43890264 --- /dev/null +++ b/schemas/v3.0.1/bundled/extension/manifest.vscode.json @@ -0,0 +1,271 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.1": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.1/bundled/extension/stdout/discover.json b/schemas/v3.0.1/bundled/extension/stdout/discover.json new file mode 100644 index 00000000..e5031820 --- /dev/null +++ b/schemas/v3.0.1/bundled/extension/stdout/discover.json @@ -0,0 +1,19 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/extension/stdout/discover.vscode.json b/schemas/v3.0.1/bundled/extension/stdout/discover.vscode.json new file mode 100644 index 00000000..8343781c --- /dev/null +++ b/schemas/v3.0.1/bundled/extension/stdout/discover.vscode.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the full path a DSC resource manifest. DSC expects every JSON Line emitted to stdout\nfor the **Discover** operation to adhere to this schema. An extension indicates that it supports\nthe **Discover** operation by defining the [discover][01] field in its manifest.\n\nThe output must be a JSON object that defines the `manifestPath` property.\n\nIf the extension doesn't discover any resources, it shouldn't emit any data to stdout.\n\nUnless the extension raises an error, it should exit with code `0`, even when no resources are\ndiscovered.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the absolute path to a DSC resource manifest on the system. DSC expects this value to\nbe the absolute path to a manifest file that exists. If this value is a relative path, or if\nthe manifest doesn't exist, DSC raises an error.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true#manifestPath", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/outputs/config/get.json b/schemas/v3.0.1/bundled/outputs/config/get.json index f3f5d1ca..17c98df3 100644 --- a/schemas/v3.0.1/bundled/outputs/config/get.json +++ b/schemas/v3.0.1/bundled/outputs/config/get.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/resource/get.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/config/get.vscode.json b/schemas/v3.0.1/bundled/outputs/config/get.vscode.json index 999fe2f7..5b761c25 100644 --- a/schemas/v3.0.1/bundled/outputs/config/get.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/config/get.vscode.json @@ -297,11 +297,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/config/set.json b/schemas/v3.0.1/bundled/outputs/config/set.json index a240f048..c0f8dab5 100644 --- a/schemas/v3.0.1/bundled/outputs/config/set.json +++ b/schemas/v3.0.1/bundled/outputs/config/set.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/resource/set.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/config/set.vscode.json b/schemas/v3.0.1/bundled/outputs/config/set.vscode.json index 5b8d9e61..526287ae 100644 --- a/schemas/v3.0.1/bundled/outputs/config/set.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/config/set.vscode.json @@ -313,11 +313,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/config/test.json b/schemas/v3.0.1/bundled/outputs/config/test.json index 1e35b83d..97bcc7bf 100644 --- a/schemas/v3.0.1/bundled/outputs/config/test.json +++ b/schemas/v3.0.1/bundled/outputs/config/test.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/resource/test.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/config/test.vscode.json b/schemas/v3.0.1/bundled/outputs/config/test.vscode.json index 6e77a91e..6c1f3b6a 100644 --- a/schemas/v3.0.1/bundled/outputs/config/test.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/config/test.vscode.json @@ -319,11 +319,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/extension/list.json b/schemas/v3.0.1/bundled/outputs/extension/list.json new file mode 100644 index 00000000..ef5fe28c --- /dev/null +++ b/schemas/v3.0.1/bundled/outputs/extension/list.json @@ -0,0 +1,231 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.1/bundled/outputs/extension/list.vscode.json b/schemas/v3.0.1/bundled/outputs/extension/list.vscode.json new file mode 100644 index 00000000..ccc5f5f3 --- /dev/null +++ b/schemas/v3.0.1/bundled/outputs/extension/list.vscode.json @@ -0,0 +1,332 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.1": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC extensions always have at least one capability. Extension capabilities define the operations\nDSC can invoke for an extension and how the extension behaves when invoked.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nAn extension with the `discover` capability supports retrieving the path to DSC resource\nmanifests that aren't included in the `PATH` or `DSC_RESOURCE_PATH`, like manifests for\nsoftware installed as AppX packages.\n\nAn extension has this capability when its manifest defines the [discover][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true#discover\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true" + ] + } + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + } + }, + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.1/bundled/outputs/resource/get.json b/schemas/v3.0.1/bundled/outputs/resource/get.json index 3376bed4..916085a1 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/get.json +++ b/schemas/v3.0.1/bundled/outputs/resource/get.json @@ -97,9 +97,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/resource/get.vscode.json b/schemas/v3.0.1/bundled/outputs/resource/get.vscode.json index ac702a9a..85d877a8 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/get.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/resource/get.vscode.json @@ -123,11 +123,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.1/bundled/outputs/resource/list.json b/schemas/v3.0.1/bundled/outputs/resource/list.json index bf25e9b8..e3e31e45 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/list.json +++ b/schemas/v3.0.1/bundled/outputs/resource/list.json @@ -99,9 +99,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -113,7 +113,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json": { @@ -166,6 +167,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -175,9 +182,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -186,7 +202,10 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -287,7 +306,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -305,9 +327,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1043,30 +1186,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.1/bundled/outputs/resource/list.vscode.json b/schemas/v3.0.1/bundled/outputs/resource/list.vscode.json index 505e6f30..ac1bac5f 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/list.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/resource/list.vscode.json @@ -105,11 +105,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -121,14 +121,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "semver.json": { @@ -509,6 +511,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -518,9 +526,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -529,13 +546,22 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../resource/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/resource/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/resource/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -545,9 +571,18 @@ "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -556,7 +591,10 @@ "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "type": { @@ -674,7 +712,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -692,9 +733,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1947,33 +2109,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.1/bundled/outputs/resource/set.json b/schemas/v3.0.1/bundled/outputs/resource/set.json index 503d513d..e434c77a 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/set.json +++ b/schemas/v3.0.1/bundled/outputs/resource/set.json @@ -113,9 +113,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/resource/set.vscode.json b/schemas/v3.0.1/bundled/outputs/resource/set.vscode.json index b910028a..c8d3df71 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/set.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/resource/set.vscode.json @@ -139,11 +139,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.1/bundled/outputs/resource/test.json b/schemas/v3.0.1/bundled/outputs/resource/test.json index 87c0f0b7..f9c8e839 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/test.json +++ b/schemas/v3.0.1/bundled/outputs/resource/test.json @@ -119,9 +119,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.1/bundled/outputs/resource/test.vscode.json b/schemas/v3.0.1/bundled/outputs/resource/test.vscode.json index 43698553..c6e51334 100644 --- a/schemas/v3.0.1/bundled/outputs/resource/test.vscode.json +++ b/schemas/v3.0.1/bundled/outputs/resource/test.vscode.json @@ -145,11 +145,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.1/bundled/resource/manifest.json b/schemas/v3.0.1/bundled/resource/manifest.json index 2eebd743..0d72f1a2 100644 --- a/schemas/v3.0.1/bundled/resource/manifest.json +++ b/schemas/v3.0.1/bundled/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -28,9 +34,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -39,7 +54,10 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -140,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -158,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -172,9 +314,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -195,7 +337,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.get.json": { @@ -926,30 +1069,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.1/bundled/resource/manifest.vscode.json b/schemas/v3.0.1/bundled/resource/manifest.vscode.json index fc330add..5cc63ce2 100644 --- a/schemas/v3.0.1/bundled/resource/manifest.vscode.json +++ b/schemas/v3.0.1/bundled/resource/manifest.vscode.json @@ -243,6 +243,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -252,9 +258,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -263,13 +278,22 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ], "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../resource/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/resource/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/resource/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -279,9 +303,18 @@ "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -290,7 +323,10 @@ "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", - "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0.2` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" ] }, "type": { @@ -408,7 +444,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -426,9 +465,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -446,11 +606,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -472,14 +632,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "commandExecutable.json": { @@ -1819,33 +1981,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.1/bundled/resource/stdout/delete.json b/schemas/v3.0.1/bundled/resource/stdout/delete.json new file mode 100644 index 00000000..eab06805 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/delete.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/delete.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/delete.vscode.json new file mode 100644 index 00000000..bf3756c2 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/delete.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC does not expect the **Delete** operation for a resource to return any JSON to stdout.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/delete?view=dsc-3.0&preserve-view=true\n", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/export.json b/schemas/v3.0.1/bundled/resource/stdout/export.json new file mode 100644 index 00000000..16f8c3bb --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/export.json @@ -0,0 +1,71 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json" + } + ], + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/export.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/export.vscode.json new file mode 100644 index 00000000..1c4b2176 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/export.vscode.json @@ -0,0 +1,130 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a resource implementing the **Export** operation to return a series of JSON Lines.\n\nThe data that DSC expects depends on whether the resource kind is defined as `exporter`:\n\n- When the resource kind is `exporter`, DSC expects the resource to return JSON Lines\n representing DSC resource instance definitions to recursively export.\n- When the resource kind isn't `exporter`, DSC expects the resource to return JSON Lines\n representing the actual state of every instance of the resource on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a typical resource implementing the **Export** operation to return a series of\nJSON Lines.\n\nEach JSON Line represents the actual state of a resource instance in DSC. DSC expects every\nJSON Line emitted to stdout for the **Export** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects an exporter resource (one with the `kind` field in its manifest set to\n`exporter`) to return a series of JSON Lines.\n\nEach JSON Line represents a DSC resource instance definition to recursively invoke the\n**Export** operation for. DSC expects every JSON Line emitted to stdout for the **Export**\noperation to adhere to this schema.\n\nThe output must be a JSON object adhering to [DSC resource instance][01] schema, rather than\nthe instance schema for a specific resource. DSC expects the object to define at least the\n[name][02] and [type][03] fields. If the object defines the [properties][04] field, DSC\npasses those properties to the resource when recursively exporting it so that the resource\nmay filter the exported instance results.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#type\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + ], + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.1": { + "config": { + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + } + }, + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/get.json b/schemas/v3.0.1/bundled/resource/stdout/get.json new file mode 100644 index 00000000..c8895a6a --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/get.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/get.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/get.vscode.json new file mode 100644 index 00000000..101e1296 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/get.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to\nstdout for the **Get** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of the\nresource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/get?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/list.json b/schemas/v3.0.1/bundled/resource/stdout/list.json new file mode 100644 index 00000000..7a6d7545 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/list.json @@ -0,0 +1,122 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "kind": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ] + } + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/list.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/list.vscode.json new file mode 100644 index 00000000..12059974 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/list.vscode.json @@ -0,0 +1,157 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to\nstdout for the **List** operation to adhere to this schema.\n\nDSC includes the following adapter resources:\n\n- `Microsoft.DSC/PowerShell` run PowerShell and enables you to use PowerShell DSC (PSDSC)\n resources implemented as PowerShell classes in DSC.\n- `Microsoft.Windows/WindowsPowerShell` runs Windows PowerShell and enables you to use any\n available PSDSC resources in DSC. This adapter is only available when you install DSC on\n Windows.\n- `Microsoft.Windows/WMI` enables you to use WMI classes as resources in DSC. This adapter is\n only available when you install DSC on Windows.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/list?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "kind": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.1": { + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\nIndicates that the manifest is for a typical DSC command resource.\n", + "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", + "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" + ] + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC resources always have at least one capability. Resource capabilities define the operations\nyou can invoke for a resource and how the resource behaves when invoked.\n\nFor more information about the operations you can invoke for a resource, see\n[DSC resource operations][01].\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `get` capability supports retrieving the current state of an instance\nwith the [Get][01] operation.\n\nA command resource has this capability when its resource manifest defines the [get][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#get\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#get-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/get?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `set` capability supports enforcing the desired state of an instance with\nthe [Set][01] operation. Resources without this capability can't be used with the\n[dsc resource set][02] or [dsc config set][03] commands unless they're defined in a\n`Microsoft.DSC/Assertion` group as a nested instance.\n\nA command resource has this capability when its resource manifest defines the [set][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#set\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/set?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/set?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `setHandlesExist` capability indicates that you can use the [Set][01]\noperation to delete an instance. Resources with this capability must have the [_exist][02]\ncanonical resource property. Resources that don't have the `_exist` property never have this\ncapability.\n\nWhen a resource has the `_exist` property but not the `setHandlesExist` capability:\n\n- If the resource has the `delete` capability, DSC invokes the [Delete][03] operation instead\n of **Set** when the desired state for an instance defines `_exist` as false.\n- If the resource doesn't have the `delete` capability, DSC raises an error during a **Set**\n operation when the desired state for an instance defines `_exist` as false.\n\nA command resource has this capability when its resource manifest defines the\n[set.handlesExist][04] subproperty as `true`.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#sethandlesexist\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/existview=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#delete-operation\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/setview=dsc-3.0&preserve-view=true#handlesexist", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `whatIf` capability indicates that you can use the [Set][01] operation in\nwhat-if mode to have the resource return explicit information about how it would modify state\nin an actual **Set** operation.\n\nWhen a resource doesn't have this capability, DSC synthesizes how the resource would change\nan instance by converting the **Test** result for the instance into a **Set** result. The\nsynthetic operation can't indicate potential issues or changes that can't be determined by\ncomparing the result of the **Test** operation against the resource's desired state. For\nexample, the credentials used to test a resource might be valid for that operation, but not\nhave permissions to actually modify the system state. Only a resource with this capability\ncan fully report whether and how the resource would change system state.\n\nA resource has this capability when it defines the [whatIf][02] property.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#whatif\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `test` capability indicates that it implements the [Test][01] operation\ndirectly. Resources with this capability must have the [_inDesiredState][02] canonical\nresource property. Resources that don't have the `_inDesiredState` property never have this\ncapability.\n\nWhen a resource doesn't have this capability, DSC uses a synthetic test for instances of the\nresource. DSC performs the synthetic test by:\n\n1. Invoking the **Get** operation on the resource to retrieve the actual state of the\n instance.\n1. Synthetically testing each property for the desired state of an instance against the\n actual state returned. The synthetic test uses strict, case-sensitive equivalence.\n1. If the desired state for a property and the actual state aren't the same, DSC marks the\n property as out of the desired state.\n1. If any properties are out of the desired state, DSC reports the entire instance as not\n being in the desired state.\n\nSynthetic testing can't account for all resource behaviors. For example, if a package\nresource allows users to define a version range for the package, the **Get** operation\nreturns the actual version of the package, like `1.2.3`. If the user specified the version\nrange `~1` (NPM syntax indicating the package should be latest released semantic version with\nmajor version `1`), DSC would compare the desired state `~1` against the actual state `1.2.3`\nand consider the package to be in the incorrect state, even if `1.2.3` is actually the latest\nrelease matching the version pin.\n\nAny resource that has properties which can't use a strict case-sensitive comparison check\nshould have this capability.\n\nA command resource has this capability when its resource manifest defines the [test][03]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#test\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#test-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `delete` capability supports removing an instance with the [Delete][01]\noperation and the [dsc resource delete][02] command.\n\nThis capability isn't mutually exclusive with the `setHandlesExist` property. A resource can handle\nthe `_exist` property in **Set** operations and be called directly with `dsc resource delete` to\nremove an instance.\n\nFor resources with the `delete` capability and the [_exist][03] canonical resource property:\n\n- If the resource doesn't have the `setHandlesExist` capability, DSC invokes the **Delete**\n operation for the resource instead of **Set** when the desired state defines `_exist` as\n `false`.\n- If the resource does have the `setHandlesExist` capability, DSC invokes the **Set** operation for\n the resource when the desired state defines `_exist` as `false`.\n\nResources with the `delete` capability that don't have the `_exist` canonical resource property\nmust implement their **Set** operation to handle removing instances. DSC can't infer existence\nsemantics without the `_exist` property.\n\nA command resource has this capability when its resource manifest defines the [delete][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#delete\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#delete-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/delete?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/delete?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `export` capability supports enumerating every instance of the resource\nwith the [Export][01] operation.\n\nYou can use resources with this capability with the following commands:\n\n- [dsc config export][02] to return a configuration document representing the actual state\n for every instance of each resource defined in the input document.\n- [dsc resource export][03] to return a configuration document representing the actual state\n for every instance of the input resource.\n- `dsc resource get` with the [--all][04] option to return the actual state of every instance\n of the input resource.\n\nA command resource has this capability when its resource manifest defines the [export][05]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#export\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#export-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/export?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/export?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/get?view=dsc-3.0&preserve-view=true#--all\n[05]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/export?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `resolve` capability supports resolving nested resource instances from an\nexternal source. This capability is primarily used by [importer resources][01] to enable users to\ncompose configuration documents.\n\nA command resource has this capability when its resource manifest defines the [resolve][0220]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#resolve\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true#importer-resources\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/resolve?view=dsc-3.0&preserve-view=true" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/resolve.json b/schemas/v3.0.1/bundled/resource/stdout/resolve.json new file mode 100644 index 00000000..5b7c1581 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/resolve.json @@ -0,0 +1,453 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "type": "object" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.parameter.json" + } + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object" + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json" + } + }, + "metadata": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.metadata.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json" + } + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object" + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0 + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0 + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." + } + } + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/resolve.vscode.json new file mode 100644 index 00000000..75ebcbc5 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/resolve.vscode.json @@ -0,0 +1,708 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of a resolved configuration document. DSC expects the JSON Line\nemitted to stdout for the **Resolve** operation to adhere to this schema.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the resolved configuration document. If the configuration document defines any\nparameters, values for those parameters may be retrieved from the `parameters` property of\nthe **Resolve** operation output.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#configuration", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `parameters` property defines the set of resolved parameter values for the resolved\nconfiguration document. If the `parameters` property is omitted from the output for the\n**Resolve** operation, DSC doesn't pass any parameters to the resolved configuration\nwhen invoking operations on it.\n\nEach property of this object represents a different resolved parameter. The property name\nidentifies the name of a parameter. The property value is the resolved value for the\nparameter.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#parameters", + "type": "object" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.1": { + "config": { + "document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDescribes a valid DSC configuration document.\n\nDSC configurations enable users to define state by combining different DSC resources. A\nconfiguration document uses parameters and variables to pass to a set of one or more resources\nthat define a desired state.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/config/document.parameter.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines runtime options for the configuration. Users and integrating tools can override use\nthe defined parameters to pass alternate values to the configuration.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#parameters\n", + "defaultSnippets": [ + { + "label": " New Parameter", + "markdownDescription": "Defines a new runtime option for the configuration.\n\n```yaml\nparameterId:\n type: \n description: \n defaultValue: \n allowedValues:\n - \n```", + "body": { + "${1:parameterId}": { + "type": "$2", + "description": "$3", + "defaultValue": "$4", + "allowedValues": [ + "$5" + ] + } + } + }, + { + "label": " New Integer Parameter", + "markdownDescription": "Defines a new runtime option for the configuration as an integer value.\n\n```yaml\nparameterId:\n type: int\n description: \n defaultValue: \n minValue: \n minValue: \n```", + "body": { + "${1:parameterId}": { + "type": "int", + "description": "$2", + "defaultValue": "$3", + "minValue": "$4", + "maxValue": "$5" + } + } + } + ] + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of reusable values for the configuration document. The names of this value's\nproperties are the strings used to reference a variable's value.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#variables\n", + "defaultSnippets": [ + { + "label": " New variable property", + "markdownDescription": "Defines a new variable as a key-value pair.\n\n```yaml\nvariableName: variableValue\n```", + "body": { + "${1:variableName}": "${2:variableValue}" + } + }, + { + "label": " New variable property (object)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an object.\n\n```yaml\nvariableName:\n key: value\n```", + "body": { + "${1:variableName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New variable property (array)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an array.\n\n```yaml\nvariableName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:variableName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances for the configuration to manage.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#resources\n" + }, + "metadata": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/config/document.metadata.json" + } + } + }, + "document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a runtime option for a DSC configuration document.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the default value for the parameter.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of valid values for the parameter. If the parameter is defined with any other\nvalues, it's invalid.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a synopsis for the parameter explaining its purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the parameter. This metadata isn't validated.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#metadata-1\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid value for an integer type. If defined with the `maxValue` property,\nthis value must be less than the value of `maxValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minvalue\n" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid value for an integer type. If defined with the `minValue` property,\nthis value must be greater than the value of `minValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxvalue\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `maxLength` property, this value must be less than the value of `maxLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minLength\n" + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `minLength` property, this value must be less than the value of `minLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxLength\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + }, + "document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe `Microsoft.DSC` metadata property contains directives and information that DSC itself\nuses when processing a configuration document. Unlike other metadata key-value pairs, DSC\nvalidates these properties.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "markdownEnumDescriptions": [ + "\n\n> ### Current security context\n>\n> Indicates that the configuration document is usable under any security context. You\n> can invoke DSC operations against the document when elevated as root or an\n> administrator and as a normal user or account.\n", + "\n\n> ### Elevated security context\n>\n> Indicates that the configuration document is usable only in an elevated security\n> context. You can invoke DSC operations against the document when elevated as root or\n> an administrator. When you invoke DSC operations against the document as a\n> non-elevated user or account, DSC raises an error when it validates the configuration\n> document.\n", + "\n\n> ### Restricted security context\n>\n> Indicates that the configuration document is usable only in a non-elevated security\n> context. You can invoke DSC operations against the document as a non-elevated user or\n> account. When you invoke DSC operations against the document as root or an\n> administrator, DSC raises an error when it validates the configuration document.\n" + ] + } + } + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC`\nproperty, this metadata isn't validated. You can pass any data into this property of a\nconfiguration document.\n\nThe `Microsoft.DSC` metadata property contains metadata directives and information that DSC\nitself uses when processing the configuration document. For more information, see\n[Microsoft.DSC][02]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "definitions": { + "parameters": { + "dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the data type for the parameter value.\n\nThe valid data types for a parameter are:\n\n- `array` for arrays\n- `bool` for booleans\n- `int` for integers\n- `object` for objects\n- `string` for strings\n- `secureObject` for secure objects\n- `secureString` for secure strings\n\nAccess parameters in a configuration using this syntax:\n\n```yaml\n\"[parameter('')]\"\n```\n\nIn YAML, the parameter syntax needs to be enclosed in double-quotes when used as an inline value.\nIf the syntax isn't quoted, YAML interprets the syntax as an array.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "_Strings are an arbitrary set of text._\n\n> To define a long strings in YAML, use the folded block syntax or literal block syntax by\n> adding a `>` or `|` and a line break after the key. Then, indent the next line. Every line\n> in the string must start at the same level of indentation. You can trim the trailing\n> whitespace by using `>-` or `|-` instead.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#strings\n", + "_Secure strings are text that needs to be handled securely._\n\n> Secure strings are an arbitrary set of text that DSC and integrating tools shouldn't log or\n> record. If a secure data type parameter is used for a resource instance property that doesn't\n> expect a secure value, the resource may still log or record the value. If the resource has\n> independent logging or recording that isn't handled by DSC, the value may be stored\n> insecurely.\n>\n> Use secure strings for passwords and secrets. Never define a default value for secure string\n> parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Integer values are numbers without a fractional part._\n\n> Integer values may be limited by integrating tools or the DSC resources they're used with.\n> DSC itself supports integer values between `-9223372036854775808` and `9223372036854775807`.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#integers\n", + "_Boolean values are either `true` or `false`._\n\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#booleans\n", + "_Objects define a set of key-value pairs._\n\n> The value for each key can be any valid data type. The values can be the same type or\n> different types.\n>\n> Access keys in the object using dot-notation. Dot-notation uses this syntax:\n>\n> ```yaml\n> \"[parameters('').]\n> ```\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#objects\n", + "_Secure objects are key-value pairs that need to be handled securely._\n\n> Secure objects define a set of key-value pairs that DSC and integrating tools shouldn't log\n> or record. If a secure data type parameter is used for a resource instance property that\n> doesn't expect a secure value, the resource may still log or record the value. If the\n> resource has independent logging or recording that isn't handled by DSC, the value may be\n> stored insecurely.\n>\n> Never define a default value for secure object parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Arrays are a list of one or more values._\n\n> The values in the array can be any valid data type. Values in the array can be the same type\n> or different types.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#arrays\n" + ] + }, + "validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + } + }, + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + }, + "metadata": { + "Microsoft.DSC": { + "securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "markdownDescription": "Defines the security context that DSC was run under. If the value for this metadata property is\n`elevated`, DSC was run as `root` (non-Windows) or an elevated session with Administrator\nprivileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in\na non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/schema.json b/schemas/v3.0.1/bundled/resource/stdout/schema.json new file mode 100644 index 00000000..08932d57 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/schema.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/schema.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/schema.vscode.json new file mode 100644 index 00000000..c044a8e4 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/schema.vscode.json @@ -0,0 +1,14 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the JSON Schema that validates instances of the resource. DSC expects a resource that\ndefines the [`schema.command`][01] field in its resource manifest to return this value for that\ncommand.\n\nThe output must be a JSON object. The object must be a valid JSON Schema. For more information\nabout what DSC expects for resource instance JSON Schemas, see\n[DSC Resource manifest embedded schema reference][02], which describes the expectations in full.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/set.json b/schemas/v3.0.1/bundled/resource/stdout/set.json new file mode 100644 index 00000000..c0419f29 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/set.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/set.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/set.vscode.json new file mode 100644 index 00000000..fce3cd09 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/set.vscode.json @@ -0,0 +1,32 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation.\n\nDSC expects this output for both actual **Set** operations and **Set** operations in `whatIf`\nmode. If the resource has the `whatIf` capability, the output should be the same for both modes.\n\nDSC expects different output from the command resource depending on the definition of\n[set.return][01] in the resource manifest:\n\n- If the field isn't defined, DSC doesn't expect the resource to return any JSON to stdout.\n Instead, DSC invokes the **Get** operation on the resource after the **Set** operation\n concludes and synthesizes the **Set** result, including the after state of the resource and\n the list of changed properties.\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource doesn't define [set.return][01] in its resource manifest, DSC doesn't expect\nthe resource to emit any JSON to stdout for the **Set** operation.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#null-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nactual state of the resource instance after the **Set** operation changes the system.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/test.json b/schemas/v3.0.1/bundled/resource/stdout/test.json new file mode 100644 index 00000000..4dc5fc0a --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/test.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/test.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/test.vscode.json new file mode 100644 index 00000000..76c3d905 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/test.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Test** operation.\n\nDSC expects different output from the command resource depending on the definition of\n[test.return][01] in the resource manifest:\n\n- If the field is omitted or defined as `state` (the default value), DSC expects the resource to\n emit a JSON Line to stdout representing the actual state of the resource instance with the\n [_inDesiredState][02] canonical resource property included in the returned object.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource instance with\n the `_inDesiredState` included in the returned object. The second JSON Line should be an array\n representing the names of the resource properties that aren't in the desired state.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nFor the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout\nrepresenting the actual state of the resource instance with the [_inDesiredState][01]\ncanonical resource property included in the returned object.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [test.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that aren't in the desired state.\n\nThis output must be emitted after the JSON Line representing the actual state of the resource\ninstance with the [_inDesiredState][02] canonical resource property included in the returned\nobject.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique. The array should never include the `_inDesiredState`\nproperty.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/validate.json b/schemas/v3.0.1/bundled/resource/stdout/validate.json new file mode 100644 index 00000000..2fc0ccb4 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/validate.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource." + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource." + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/validate.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/validate.vscode.json new file mode 100644 index 00000000..b04406f8 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/validate.vscode.json @@ -0,0 +1,24 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.\n\nDSC expects the resource to return a JSON object that indicates whether the instance is valid and\noptionally a string indicating how the resource is invalid.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nIndicates whether the instance is valid for the resource. When the value is `true`, the\ninstance is valid for the resource.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#valid" + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDescribes how and why the instance is invalid for the resource. Always define this property\nin the output object when `valid` is `false`. Don't define this property in the output object\nwhen `valid` is `true`.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#reason" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/whatIf.json b/schemas/v3.0.1/bundled/resource/stdout/whatIf.json new file mode 100644 index 00000000..eb8c13d0 --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/whatIf.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/bundled/resource/stdout/whatIf.vscode.json b/schemas/v3.0.1/bundled/resource/stdout/whatIf.vscode.json new file mode 100644 index 00000000..5023697e --- /dev/null +++ b/schemas/v3.0.1/bundled/resource/stdout/whatIf.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if\nmode.\n\nDSC expects different output from the command resource depending on the definition of\n[whatIf.return][01] in the resource manifest:\n\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nexpected actual state of the resource instance after the **Set** operation changes the\nsystem.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.1/config/document.json b/schemas/v3.0.1/config/document.json index 915198b9..48356118 100644 --- a/schemas/v3.0.1/config/document.json +++ b/schemas/v3.0.1/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -27,9 +33,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -38,7 +53,10 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" ] }, "parameters": { diff --git a/schemas/v3.0.1/config/document.metadata.json b/schemas/v3.0.1/config/document.metadata.json index 4bd5ad88..fc612493 100644 --- a/schemas/v3.0.1/config/document.metadata.json +++ b/schemas/v3.0.1/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.0.1/definitions/extensionCapabilities.json b/schemas/v3.0.1/definitions/extensionCapabilities.json new file mode 100644 index 00000000..7542aaf5 --- /dev/null +++ b/schemas/v3.0.1/definitions/extensionCapabilities.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } +} diff --git a/schemas/v3.0.1/definitions/extensionType.json b/schemas/v3.0.1/definitions/extensionType.json new file mode 100644 index 00000000..943c942b --- /dev/null +++ b/schemas/v3.0.1/definitions/extensionType.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" +} diff --git a/schemas/v3.0.1/definitions/resourceKind.json b/schemas/v3.0.1/definitions/resourceKind.json index 598d8993..fc35f4af 100644 --- a/schemas/v3.0.1/definitions/resourceKind.json +++ b/schemas/v3.0.1/definitions/resourceKind.json @@ -8,6 +8,7 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] } diff --git a/schemas/v3.0.1/definitions/resourceType.json b/schemas/v3.0.1/definitions/resourceType.json index f02ea693..77d6b5fa 100644 --- a/schemas/v3.0.1/definitions/resourceType.json +++ b/schemas/v3.0.1/definitions/resourceType.json @@ -2,7 +2,7 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" } diff --git a/schemas/v3.0.1/extension/manifest.discover.json b/schemas/v3.0.1/extension/manifest.discover.json new file mode 100644 index 00000000..bf3f4b2f --- /dev/null +++ b/schemas/v3.0.1/extension/manifest.discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/commandArgs.json" + } + } +} diff --git a/schemas/v3.0.1/extension/manifest.json b/schemas/v3.0.1/extension/manifest.json new file mode 100644 index 00000000..ab7df057 --- /dev/null +++ b/schemas/v3.0.1/extension/manifest.json @@ -0,0 +1,92 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } +} diff --git a/schemas/v3.0.1/extension/stdout/discover.json b/schemas/v3.0.1/extension/stdout/discover.json new file mode 100644 index 00000000..8975205f --- /dev/null +++ b/schemas/v3.0.1/extension/stdout/discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + } +} diff --git a/schemas/v3.0.1/outputs/extension/list.json b/schemas/v3.0.1/outputs/extension/list.json new file mode 100644 index 00000000..59965d6d --- /dev/null +++ b/schemas/v3.0.1/outputs/extension/list.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/extension/manifest.json" + } + } +} diff --git a/schemas/v3.0.1/resource/manifest.json b/schemas/v3.0.1/resource/manifest.json index b371eaab..63589523 100644 --- a/schemas/v3.0.1/resource/manifest.json +++ b/schemas/v3.0.1/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -28,9 +34,18 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -39,7 +54,10 @@ "https://aka.ms/dsc/schemas/v3.0.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0.1/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.json", - "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json" + "https://aka.ms/dsc/schemas/v3.0.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/resource/manifest.vscode.json" ] }, "type": { @@ -140,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -158,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] diff --git a/schemas/v3.0.1/resource/manifest.schema.json b/schemas/v3.0.1/resource/manifest.schema.json index 976504a7..69427cff 100644 --- a/schemas/v3.0.1/resource/manifest.schema.json +++ b/schemas/v3.0.1/resource/manifest.schema.json @@ -93,30 +93,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.1/resource/stdout/export.json b/schemas/v3.0.1/resource/stdout/export.json index 6b8aaf63..37a4548c 100644 --- a/schemas/v3.0.1/resource/stdout/export.json +++ b/schemas/v3.0.1/resource/stdout/export.json @@ -3,5 +3,16 @@ "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/stdout/export.json", "title": "Export resource operation stdout", "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", - "type": "object" + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.1/config/document.resource.json" + } + ] } diff --git a/schemas/v3.0.2/bundled/config/document.json b/schemas/v3.0.2/bundled/config/document.json index 17af6ea4..028f50d0 100644 --- a/schemas/v3.0.2/bundled/config/document.json +++ b/schemas/v3.0.2/bundled/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -33,6 +39,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -351,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } @@ -390,9 +402,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/config/document.vscode.json b/schemas/v3.0.2/bundled/config/document.vscode.json index 0340c324..a4663fd1 100644 --- a/schemas/v3.0.2/bundled/config/document.vscode.json +++ b/schemas/v3.0.2/bundled/config/document.vscode.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -52,6 +64,12 @@ "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -67,6 +85,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -527,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ @@ -615,11 +639,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/extension/manifest.json b/schemas/v3.0.2/bundled/extension/manifest.json new file mode 100644 index 00000000..ceaa5dd4 --- /dev/null +++ b/schemas/v3.0.2/bundled/extension/manifest.json @@ -0,0 +1,174 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.2/bundled/extension/manifest.vscode.json b/schemas/v3.0.2/bundled/extension/manifest.vscode.json new file mode 100644 index 00000000..18f60631 --- /dev/null +++ b/schemas/v3.0.2/bundled/extension/manifest.vscode.json @@ -0,0 +1,271 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.2": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.2/bundled/extension/stdout/discover.json b/schemas/v3.0.2/bundled/extension/stdout/discover.json new file mode 100644 index 00000000..e1d2446b --- /dev/null +++ b/schemas/v3.0.2/bundled/extension/stdout/discover.json @@ -0,0 +1,19 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/extension/stdout/discover.vscode.json b/schemas/v3.0.2/bundled/extension/stdout/discover.vscode.json new file mode 100644 index 00000000..760a8526 --- /dev/null +++ b/schemas/v3.0.2/bundled/extension/stdout/discover.vscode.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the full path a DSC resource manifest. DSC expects every JSON Line emitted to stdout\nfor the **Discover** operation to adhere to this schema. An extension indicates that it supports\nthe **Discover** operation by defining the [discover][01] field in its manifest.\n\nThe output must be a JSON object that defines the `manifestPath` property.\n\nIf the extension doesn't discover any resources, it shouldn't emit any data to stdout.\n\nUnless the extension raises an error, it should exit with code `0`, even when no resources are\ndiscovered.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the absolute path to a DSC resource manifest on the system. DSC expects this value to\nbe the absolute path to a manifest file that exists. If this value is a relative path, or if\nthe manifest doesn't exist, DSC raises an error.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true#manifestPath", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/outputs/config/get.json b/schemas/v3.0.2/bundled/outputs/config/get.json index c5d1cf59..b7db0f31 100644 --- a/schemas/v3.0.2/bundled/outputs/config/get.json +++ b/schemas/v3.0.2/bundled/outputs/config/get.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/resource/get.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/config/get.vscode.json b/schemas/v3.0.2/bundled/outputs/config/get.vscode.json index f8c5ec63..aa605ec6 100644 --- a/schemas/v3.0.2/bundled/outputs/config/get.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/config/get.vscode.json @@ -297,11 +297,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/config/set.json b/schemas/v3.0.2/bundled/outputs/config/set.json index daa6f19d..5af88d09 100644 --- a/schemas/v3.0.2/bundled/outputs/config/set.json +++ b/schemas/v3.0.2/bundled/outputs/config/set.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/resource/set.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/config/set.vscode.json b/schemas/v3.0.2/bundled/outputs/config/set.vscode.json index 18e67e4d..71cd8b2e 100644 --- a/schemas/v3.0.2/bundled/outputs/config/set.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/config/set.vscode.json @@ -313,11 +313,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/config/test.json b/schemas/v3.0.2/bundled/outputs/config/test.json index 14985ddd..a3f3d486 100644 --- a/schemas/v3.0.2/bundled/outputs/config/test.json +++ b/schemas/v3.0.2/bundled/outputs/config/test.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/resource/test.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/config/test.vscode.json b/schemas/v3.0.2/bundled/outputs/config/test.vscode.json index 6c040b8c..387167f4 100644 --- a/schemas/v3.0.2/bundled/outputs/config/test.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/config/test.vscode.json @@ -319,11 +319,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/extension/list.json b/schemas/v3.0.2/bundled/outputs/extension/list.json new file mode 100644 index 00000000..9f793876 --- /dev/null +++ b/schemas/v3.0.2/bundled/outputs/extension/list.json @@ -0,0 +1,231 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0.2/bundled/outputs/extension/list.vscode.json b/schemas/v3.0.2/bundled/outputs/extension/list.vscode.json new file mode 100644 index 00000000..3a2b58a3 --- /dev/null +++ b/schemas/v3.0.2/bundled/outputs/extension/list.vscode.json @@ -0,0 +1,332 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.2": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC extensions always have at least one capability. Extension capabilities define the operations\nDSC can invoke for an extension and how the extension behaves when invoked.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nAn extension with the `discover` capability supports retrieving the path to DSC resource\nmanifests that aren't included in the `PATH` or `DSC_RESOURCE_PATH`, like manifests for\nsoftware installed as AppX packages.\n\nAn extension has this capability when its manifest defines the [discover][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true#discover\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true" + ] + } + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + } + }, + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.2/bundled/outputs/resource/get.json b/schemas/v3.0.2/bundled/outputs/resource/get.json index 0e10619a..e5314a0a 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/get.json +++ b/schemas/v3.0.2/bundled/outputs/resource/get.json @@ -97,9 +97,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/resource/get.vscode.json b/schemas/v3.0.2/bundled/outputs/resource/get.vscode.json index 774b3169..7630e4ad 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/get.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/resource/get.vscode.json @@ -123,11 +123,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.2/bundled/outputs/resource/list.json b/schemas/v3.0.2/bundled/outputs/resource/list.json index 3ce6a4ae..2f6cd75f 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/list.json +++ b/schemas/v3.0.2/bundled/outputs/resource/list.json @@ -99,9 +99,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -113,7 +113,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json": { @@ -166,6 +167,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -181,6 +188,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -293,7 +306,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -311,9 +327,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1049,30 +1186,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.2/bundled/outputs/resource/list.vscode.json b/schemas/v3.0.2/bundled/outputs/resource/list.vscode.json index b2a99290..1956aaf2 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/list.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/resource/list.vscode.json @@ -105,11 +105,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -121,14 +121,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "semver.json": { @@ -509,6 +511,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -524,6 +532,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -542,6 +556,12 @@ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -557,6 +577,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -686,7 +712,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -704,9 +733,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1959,33 +2109,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.2/bundled/outputs/resource/set.json b/schemas/v3.0.2/bundled/outputs/resource/set.json index fa996921..7312fd28 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/set.json +++ b/schemas/v3.0.2/bundled/outputs/resource/set.json @@ -113,9 +113,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/resource/set.vscode.json b/schemas/v3.0.2/bundled/outputs/resource/set.vscode.json index 1f848848..3e92e2c2 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/set.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/resource/set.vscode.json @@ -139,11 +139,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.2/bundled/outputs/resource/test.json b/schemas/v3.0.2/bundled/outputs/resource/test.json index 58917e69..4987f551 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/test.json +++ b/schemas/v3.0.2/bundled/outputs/resource/test.json @@ -119,9 +119,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0.2/bundled/outputs/resource/test.vscode.json b/schemas/v3.0.2/bundled/outputs/resource/test.vscode.json index bccc1598..bac8c35f 100644 --- a/schemas/v3.0.2/bundled/outputs/resource/test.vscode.json +++ b/schemas/v3.0.2/bundled/outputs/resource/test.vscode.json @@ -145,11 +145,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0.2/bundled/resource/manifest.json b/schemas/v3.0.2/bundled/resource/manifest.json index 231d32bf..10f11942 100644 --- a/schemas/v3.0.2/bundled/resource/manifest.json +++ b/schemas/v3.0.2/bundled/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -146,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -164,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -178,9 +314,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -201,7 +337,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/manifest.get.json": { @@ -932,30 +1069,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.2/bundled/resource/manifest.vscode.json b/schemas/v3.0.2/bundled/resource/manifest.vscode.json index 26c28f39..46132a25 100644 --- a/schemas/v3.0.2/bundled/resource/manifest.vscode.json +++ b/schemas/v3.0.2/bundled/resource/manifest.vscode.json @@ -243,6 +243,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -258,6 +264,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -276,6 +288,12 @@ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -291,6 +309,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -420,7 +444,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -438,9 +465,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -458,11 +606,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -484,14 +632,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "commandExecutable.json": { @@ -1831,33 +1981,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0.2/bundled/resource/stdout/delete.json b/schemas/v3.0.2/bundled/resource/stdout/delete.json new file mode 100644 index 00000000..f5002ba9 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/delete.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/delete.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/delete.vscode.json new file mode 100644 index 00000000..d78dd348 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/delete.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC does not expect the **Delete** operation for a resource to return any JSON to stdout.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/delete?view=dsc-3.0&preserve-view=true\n", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/export.json b/schemas/v3.0.2/bundled/resource/stdout/export.json new file mode 100644 index 00000000..73420fe9 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/export.json @@ -0,0 +1,71 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json" + } + ], + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/export.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/export.vscode.json new file mode 100644 index 00000000..f40762b0 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/export.vscode.json @@ -0,0 +1,130 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a resource implementing the **Export** operation to return a series of JSON Lines.\n\nThe data that DSC expects depends on whether the resource kind is defined as `exporter`:\n\n- When the resource kind is `exporter`, DSC expects the resource to return JSON Lines\n representing DSC resource instance definitions to recursively export.\n- When the resource kind isn't `exporter`, DSC expects the resource to return JSON Lines\n representing the actual state of every instance of the resource on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a typical resource implementing the **Export** operation to return a series of\nJSON Lines.\n\nEach JSON Line represents the actual state of a resource instance in DSC. DSC expects every\nJSON Line emitted to stdout for the **Export** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects an exporter resource (one with the `kind` field in its manifest set to\n`exporter`) to return a series of JSON Lines.\n\nEach JSON Line represents a DSC resource instance definition to recursively invoke the\n**Export** operation for. DSC expects every JSON Line emitted to stdout for the **Export**\noperation to adhere to this schema.\n\nThe output must be a JSON object adhering to [DSC resource instance][01] schema, rather than\nthe instance schema for a specific resource. DSC expects the object to define at least the\n[name][02] and [type][03] fields. If the object defines the [properties][04] field, DSC\npasses those properties to the resource when recursively exporting it so that the resource\nmay filter the exported instance results.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#type\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + ], + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.2": { + "config": { + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + } + }, + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/get.json b/schemas/v3.0.2/bundled/resource/stdout/get.json new file mode 100644 index 00000000..1948f873 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/get.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/get.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/get.vscode.json new file mode 100644 index 00000000..f06629fa --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/get.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to\nstdout for the **Get** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of the\nresource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/get?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/list.json b/schemas/v3.0.2/bundled/resource/stdout/list.json new file mode 100644 index 00000000..6fa150e8 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/list.json @@ -0,0 +1,122 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "kind": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ] + } + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/list.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/list.vscode.json new file mode 100644 index 00000000..98faa029 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/list.vscode.json @@ -0,0 +1,157 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to\nstdout for the **List** operation to adhere to this schema.\n\nDSC includes the following adapter resources:\n\n- `Microsoft.DSC/PowerShell` run PowerShell and enables you to use PowerShell DSC (PSDSC)\n resources implemented as PowerShell classes in DSC.\n- `Microsoft.Windows/WindowsPowerShell` runs Windows PowerShell and enables you to use any\n available PSDSC resources in DSC. This adapter is only available when you install DSC on\n Windows.\n- `Microsoft.Windows/WMI` enables you to use WMI classes as resources in DSC. This adapter is\n only available when you install DSC on Windows.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/list?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "kind": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.2": { + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\nIndicates that the manifest is for a typical DSC command resource.\n", + "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", + "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" + ] + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC resources always have at least one capability. Resource capabilities define the operations\nyou can invoke for a resource and how the resource behaves when invoked.\n\nFor more information about the operations you can invoke for a resource, see\n[DSC resource operations][01].\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `get` capability supports retrieving the current state of an instance\nwith the [Get][01] operation.\n\nA command resource has this capability when its resource manifest defines the [get][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#get\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#get-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/get?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `set` capability supports enforcing the desired state of an instance with\nthe [Set][01] operation. Resources without this capability can't be used with the\n[dsc resource set][02] or [dsc config set][03] commands unless they're defined in a\n`Microsoft.DSC/Assertion` group as a nested instance.\n\nA command resource has this capability when its resource manifest defines the [set][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#set\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/set?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/set?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `setHandlesExist` capability indicates that you can use the [Set][01]\noperation to delete an instance. Resources with this capability must have the [_exist][02]\ncanonical resource property. Resources that don't have the `_exist` property never have this\ncapability.\n\nWhen a resource has the `_exist` property but not the `setHandlesExist` capability:\n\n- If the resource has the `delete` capability, DSC invokes the [Delete][03] operation instead\n of **Set** when the desired state for an instance defines `_exist` as false.\n- If the resource doesn't have the `delete` capability, DSC raises an error during a **Set**\n operation when the desired state for an instance defines `_exist` as false.\n\nA command resource has this capability when its resource manifest defines the\n[set.handlesExist][04] subproperty as `true`.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#sethandlesexist\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/existview=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#delete-operation\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/setview=dsc-3.0&preserve-view=true#handlesexist", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `whatIf` capability indicates that you can use the [Set][01] operation in\nwhat-if mode to have the resource return explicit information about how it would modify state\nin an actual **Set** operation.\n\nWhen a resource doesn't have this capability, DSC synthesizes how the resource would change\nan instance by converting the **Test** result for the instance into a **Set** result. The\nsynthetic operation can't indicate potential issues or changes that can't be determined by\ncomparing the result of the **Test** operation against the resource's desired state. For\nexample, the credentials used to test a resource might be valid for that operation, but not\nhave permissions to actually modify the system state. Only a resource with this capability\ncan fully report whether and how the resource would change system state.\n\nA resource has this capability when it defines the [whatIf][02] property.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#whatif\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `test` capability indicates that it implements the [Test][01] operation\ndirectly. Resources with this capability must have the [_inDesiredState][02] canonical\nresource property. Resources that don't have the `_inDesiredState` property never have this\ncapability.\n\nWhen a resource doesn't have this capability, DSC uses a synthetic test for instances of the\nresource. DSC performs the synthetic test by:\n\n1. Invoking the **Get** operation on the resource to retrieve the actual state of the\n instance.\n1. Synthetically testing each property for the desired state of an instance against the\n actual state returned. The synthetic test uses strict, case-sensitive equivalence.\n1. If the desired state for a property and the actual state aren't the same, DSC marks the\n property as out of the desired state.\n1. If any properties are out of the desired state, DSC reports the entire instance as not\n being in the desired state.\n\nSynthetic testing can't account for all resource behaviors. For example, if a package\nresource allows users to define a version range for the package, the **Get** operation\nreturns the actual version of the package, like `1.2.3`. If the user specified the version\nrange `~1` (NPM syntax indicating the package should be latest released semantic version with\nmajor version `1`), DSC would compare the desired state `~1` against the actual state `1.2.3`\nand consider the package to be in the incorrect state, even if `1.2.3` is actually the latest\nrelease matching the version pin.\n\nAny resource that has properties which can't use a strict case-sensitive comparison check\nshould have this capability.\n\nA command resource has this capability when its resource manifest defines the [test][03]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#test\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#test-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `delete` capability supports removing an instance with the [Delete][01]\noperation and the [dsc resource delete][02] command.\n\nThis capability isn't mutually exclusive with the `setHandlesExist` property. A resource can handle\nthe `_exist` property in **Set** operations and be called directly with `dsc resource delete` to\nremove an instance.\n\nFor resources with the `delete` capability and the [_exist][03] canonical resource property:\n\n- If the resource doesn't have the `setHandlesExist` capability, DSC invokes the **Delete**\n operation for the resource instead of **Set** when the desired state defines `_exist` as\n `false`.\n- If the resource does have the `setHandlesExist` capability, DSC invokes the **Set** operation for\n the resource when the desired state defines `_exist` as `false`.\n\nResources with the `delete` capability that don't have the `_exist` canonical resource property\nmust implement their **Set** operation to handle removing instances. DSC can't infer existence\nsemantics without the `_exist` property.\n\nA command resource has this capability when its resource manifest defines the [delete][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#delete\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#delete-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/delete?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/delete?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `export` capability supports enumerating every instance of the resource\nwith the [Export][01] operation.\n\nYou can use resources with this capability with the following commands:\n\n- [dsc config export][02] to return a configuration document representing the actual state\n for every instance of each resource defined in the input document.\n- [dsc resource export][03] to return a configuration document representing the actual state\n for every instance of the input resource.\n- `dsc resource get` with the [--all][04] option to return the actual state of every instance\n of the input resource.\n\nA command resource has this capability when its resource manifest defines the [export][05]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#export\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#export-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/export?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/export?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/get?view=dsc-3.0&preserve-view=true#--all\n[05]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/export?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `resolve` capability supports resolving nested resource instances from an\nexternal source. This capability is primarily used by [importer resources][01] to enable users to\ncompose configuration documents.\n\nA command resource has this capability when its resource manifest defines the [resolve][0220]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#resolve\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true#importer-resources\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/resolve?view=dsc-3.0&preserve-view=true" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/resolve.json b/schemas/v3.0.2/bundled/resource/stdout/resolve.json new file mode 100644 index 00000000..622f1df3 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/resolve.json @@ -0,0 +1,453 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "type": "object" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.parameter.json" + } + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object" + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json" + } + }, + "metadata": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.metadata.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json" + } + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object" + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0 + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0 + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." + } + } + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/resolve.vscode.json new file mode 100644 index 00000000..edb71882 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/resolve.vscode.json @@ -0,0 +1,708 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of a resolved configuration document. DSC expects the JSON Line\nemitted to stdout for the **Resolve** operation to adhere to this schema.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the resolved configuration document. If the configuration document defines any\nparameters, values for those parameters may be retrieved from the `parameters` property of\nthe **Resolve** operation output.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#configuration", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `parameters` property defines the set of resolved parameter values for the resolved\nconfiguration document. If the `parameters` property is omitted from the output for the\n**Resolve** operation, DSC doesn't pass any parameters to the resolved configuration\nwhen invoking operations on it.\n\nEach property of this object represents a different resolved parameter. The property name\nidentifies the name of a parameter. The property value is the resolved value for the\nparameter.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#parameters", + "type": "object" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0.2": { + "config": { + "document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDescribes a valid DSC configuration document.\n\nDSC configurations enable users to define state by combining different DSC resources. A\nconfiguration document uses parameters and variables to pass to a set of one or more resources\nthat define a desired state.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/config/document.parameter.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines runtime options for the configuration. Users and integrating tools can override use\nthe defined parameters to pass alternate values to the configuration.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#parameters\n", + "defaultSnippets": [ + { + "label": " New Parameter", + "markdownDescription": "Defines a new runtime option for the configuration.\n\n```yaml\nparameterId:\n type: \n description: \n defaultValue: \n allowedValues:\n - \n```", + "body": { + "${1:parameterId}": { + "type": "$2", + "description": "$3", + "defaultValue": "$4", + "allowedValues": [ + "$5" + ] + } + } + }, + { + "label": " New Integer Parameter", + "markdownDescription": "Defines a new runtime option for the configuration as an integer value.\n\n```yaml\nparameterId:\n type: int\n description: \n defaultValue: \n minValue: \n minValue: \n```", + "body": { + "${1:parameterId}": { + "type": "int", + "description": "$2", + "defaultValue": "$3", + "minValue": "$4", + "maxValue": "$5" + } + } + } + ] + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of reusable values for the configuration document. The names of this value's\nproperties are the strings used to reference a variable's value.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#variables\n", + "defaultSnippets": [ + { + "label": " New variable property", + "markdownDescription": "Defines a new variable as a key-value pair.\n\n```yaml\nvariableName: variableValue\n```", + "body": { + "${1:variableName}": "${2:variableValue}" + } + }, + { + "label": " New variable property (object)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an object.\n\n```yaml\nvariableName:\n key: value\n```", + "body": { + "${1:variableName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New variable property (array)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an array.\n\n```yaml\nvariableName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:variableName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances for the configuration to manage.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#resources\n" + }, + "metadata": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/config/document.metadata.json" + } + } + }, + "document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a runtime option for a DSC configuration document.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the default value for the parameter.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of valid values for the parameter. If the parameter is defined with any other\nvalues, it's invalid.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a synopsis for the parameter explaining its purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the parameter. This metadata isn't validated.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#metadata-1\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid value for an integer type. If defined with the `maxValue` property,\nthis value must be less than the value of `maxValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minvalue\n" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid value for an integer type. If defined with the `minValue` property,\nthis value must be greater than the value of `minValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxvalue\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `maxLength` property, this value must be less than the value of `maxLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minLength\n" + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `minLength` property, this value must be less than the value of `minLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxLength\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + }, + "document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe `Microsoft.DSC` metadata property contains directives and information that DSC itself\nuses when processing a configuration document. Unlike other metadata key-value pairs, DSC\nvalidates these properties.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "markdownEnumDescriptions": [ + "\n\n> ### Current security context\n>\n> Indicates that the configuration document is usable under any security context. You\n> can invoke DSC operations against the document when elevated as root or an\n> administrator and as a normal user or account.\n", + "\n\n> ### Elevated security context\n>\n> Indicates that the configuration document is usable only in an elevated security\n> context. You can invoke DSC operations against the document when elevated as root or\n> an administrator. When you invoke DSC operations against the document as a\n> non-elevated user or account, DSC raises an error when it validates the configuration\n> document.\n", + "\n\n> ### Restricted security context\n>\n> Indicates that the configuration document is usable only in a non-elevated security\n> context. You can invoke DSC operations against the document as a non-elevated user or\n> account. When you invoke DSC operations against the document as root or an\n> administrator, DSC raises an error when it validates the configuration document.\n" + ] + } + } + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC`\nproperty, this metadata isn't validated. You can pass any data into this property of a\nconfiguration document.\n\nThe `Microsoft.DSC` metadata property contains metadata directives and information that DSC\nitself uses when processing the configuration document. For more information, see\n[Microsoft.DSC][02]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "definitions": { + "parameters": { + "dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the data type for the parameter value.\n\nThe valid data types for a parameter are:\n\n- `array` for arrays\n- `bool` for booleans\n- `int` for integers\n- `object` for objects\n- `string` for strings\n- `secureObject` for secure objects\n- `secureString` for secure strings\n\nAccess parameters in a configuration using this syntax:\n\n```yaml\n\"[parameter('')]\"\n```\n\nIn YAML, the parameter syntax needs to be enclosed in double-quotes when used as an inline value.\nIf the syntax isn't quoted, YAML interprets the syntax as an array.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "_Strings are an arbitrary set of text._\n\n> To define a long strings in YAML, use the folded block syntax or literal block syntax by\n> adding a `>` or `|` and a line break after the key. Then, indent the next line. Every line\n> in the string must start at the same level of indentation. You can trim the trailing\n> whitespace by using `>-` or `|-` instead.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#strings\n", + "_Secure strings are text that needs to be handled securely._\n\n> Secure strings are an arbitrary set of text that DSC and integrating tools shouldn't log or\n> record. If a secure data type parameter is used for a resource instance property that doesn't\n> expect a secure value, the resource may still log or record the value. If the resource has\n> independent logging or recording that isn't handled by DSC, the value may be stored\n> insecurely.\n>\n> Use secure strings for passwords and secrets. Never define a default value for secure string\n> parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Integer values are numbers without a fractional part._\n\n> Integer values may be limited by integrating tools or the DSC resources they're used with.\n> DSC itself supports integer values between `-9223372036854775808` and `9223372036854775807`.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#integers\n", + "_Boolean values are either `true` or `false`._\n\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#booleans\n", + "_Objects define a set of key-value pairs._\n\n> The value for each key can be any valid data type. The values can be the same type or\n> different types.\n>\n> Access keys in the object using dot-notation. Dot-notation uses this syntax:\n>\n> ```yaml\n> \"[parameters('').]\n> ```\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#objects\n", + "_Secure objects are key-value pairs that need to be handled securely._\n\n> Secure objects define a set of key-value pairs that DSC and integrating tools shouldn't log\n> or record. If a secure data type parameter is used for a resource instance property that\n> doesn't expect a secure value, the resource may still log or record the value. If the\n> resource has independent logging or recording that isn't handled by DSC, the value may be\n> stored insecurely.\n>\n> Never define a default value for secure object parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Arrays are a list of one or more values._\n\n> The values in the array can be any valid data type. Values in the array can be the same type\n> or different types.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#arrays\n" + ] + }, + "validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + } + }, + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + }, + "metadata": { + "Microsoft.DSC": { + "securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "markdownDescription": "Defines the security context that DSC was run under. If the value for this metadata property is\n`elevated`, DSC was run as `root` (non-Windows) or an elevated session with Administrator\nprivileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in\na non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/schema.json b/schemas/v3.0.2/bundled/resource/stdout/schema.json new file mode 100644 index 00000000..390e6032 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/schema.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/schema.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/schema.vscode.json new file mode 100644 index 00000000..e5131f92 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/schema.vscode.json @@ -0,0 +1,14 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the JSON Schema that validates instances of the resource. DSC expects a resource that\ndefines the [`schema.command`][01] field in its resource manifest to return this value for that\ncommand.\n\nThe output must be a JSON object. The object must be a valid JSON Schema. For more information\nabout what DSC expects for resource instance JSON Schemas, see\n[DSC Resource manifest embedded schema reference][02], which describes the expectations in full.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/set.json b/schemas/v3.0.2/bundled/resource/stdout/set.json new file mode 100644 index 00000000..20e81ec3 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/set.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/set.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/set.vscode.json new file mode 100644 index 00000000..eab16f4e --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/set.vscode.json @@ -0,0 +1,32 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation.\n\nDSC expects this output for both actual **Set** operations and **Set** operations in `whatIf`\nmode. If the resource has the `whatIf` capability, the output should be the same for both modes.\n\nDSC expects different output from the command resource depending on the definition of\n[set.return][01] in the resource manifest:\n\n- If the field isn't defined, DSC doesn't expect the resource to return any JSON to stdout.\n Instead, DSC invokes the **Get** operation on the resource after the **Set** operation\n concludes and synthesizes the **Set** result, including the after state of the resource and\n the list of changed properties.\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource doesn't define [set.return][01] in its resource manifest, DSC doesn't expect\nthe resource to emit any JSON to stdout for the **Set** operation.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#null-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nactual state of the resource instance after the **Set** operation changes the system.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/test.json b/schemas/v3.0.2/bundled/resource/stdout/test.json new file mode 100644 index 00000000..e4b366e8 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/test.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/test.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/test.vscode.json new file mode 100644 index 00000000..06129ce4 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/test.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Test** operation.\n\nDSC expects different output from the command resource depending on the definition of\n[test.return][01] in the resource manifest:\n\n- If the field is omitted or defined as `state` (the default value), DSC expects the resource to\n emit a JSON Line to stdout representing the actual state of the resource instance with the\n [_inDesiredState][02] canonical resource property included in the returned object.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource instance with\n the `_inDesiredState` included in the returned object. The second JSON Line should be an array\n representing the names of the resource properties that aren't in the desired state.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nFor the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout\nrepresenting the actual state of the resource instance with the [_inDesiredState][01]\ncanonical resource property included in the returned object.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [test.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that aren't in the desired state.\n\nThis output must be emitted after the JSON Line representing the actual state of the resource\ninstance with the [_inDesiredState][02] canonical resource property included in the returned\nobject.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique. The array should never include the `_inDesiredState`\nproperty.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/validate.json b/schemas/v3.0.2/bundled/resource/stdout/validate.json new file mode 100644 index 00000000..97c02348 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/validate.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource." + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource." + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/validate.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/validate.vscode.json new file mode 100644 index 00000000..8e9e79ca --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/validate.vscode.json @@ -0,0 +1,24 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.\n\nDSC expects the resource to return a JSON object that indicates whether the instance is valid and\noptionally a string indicating how the resource is invalid.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nIndicates whether the instance is valid for the resource. When the value is `true`, the\ninstance is valid for the resource.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#valid" + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDescribes how and why the instance is invalid for the resource. Always define this property\nin the output object when `valid` is `false`. Don't define this property in the output object\nwhen `valid` is `true`.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#reason" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/whatIf.json b/schemas/v3.0.2/bundled/resource/stdout/whatIf.json new file mode 100644 index 00000000..744680c2 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/whatIf.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/bundled/resource/stdout/whatIf.vscode.json b/schemas/v3.0.2/bundled/resource/stdout/whatIf.vscode.json new file mode 100644 index 00000000..78de3e05 --- /dev/null +++ b/schemas/v3.0.2/bundled/resource/stdout/whatIf.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if\nmode.\n\nDSC expects different output from the command resource depending on the definition of\n[whatIf.return][01] in the resource manifest:\n\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nexpected actual state of the resource instance after the **Set** operation changes the\nsystem.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0.2/config/document.json b/schemas/v3.0.2/config/document.json index b18067ac..a64940d5 100644 --- a/schemas/v3.0.2/config/document.json +++ b/schemas/v3.0.2/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -33,6 +39,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", diff --git a/schemas/v3.0.2/config/document.metadata.json b/schemas/v3.0.2/config/document.metadata.json index b758e188..7be1b639 100644 --- a/schemas/v3.0.2/config/document.metadata.json +++ b/schemas/v3.0.2/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.0.2/definitions/extensionCapabilities.json b/schemas/v3.0.2/definitions/extensionCapabilities.json new file mode 100644 index 00000000..d7f7c5d7 --- /dev/null +++ b/schemas/v3.0.2/definitions/extensionCapabilities.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } +} diff --git a/schemas/v3.0.2/definitions/extensionType.json b/schemas/v3.0.2/definitions/extensionType.json new file mode 100644 index 00000000..b058179f --- /dev/null +++ b/schemas/v3.0.2/definitions/extensionType.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" +} diff --git a/schemas/v3.0.2/definitions/resourceKind.json b/schemas/v3.0.2/definitions/resourceKind.json index a8b407f6..2693e14c 100644 --- a/schemas/v3.0.2/definitions/resourceKind.json +++ b/schemas/v3.0.2/definitions/resourceKind.json @@ -8,6 +8,7 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] } diff --git a/schemas/v3.0.2/definitions/resourceType.json b/schemas/v3.0.2/definitions/resourceType.json index 16ae060e..be0bbce6 100644 --- a/schemas/v3.0.2/definitions/resourceType.json +++ b/schemas/v3.0.2/definitions/resourceType.json @@ -2,7 +2,7 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" } diff --git a/schemas/v3.0.2/extension/manifest.discover.json b/schemas/v3.0.2/extension/manifest.discover.json new file mode 100644 index 00000000..57e5167c --- /dev/null +++ b/schemas/v3.0.2/extension/manifest.discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/commandArgs.json" + } + } +} diff --git a/schemas/v3.0.2/extension/manifest.json b/schemas/v3.0.2/extension/manifest.json new file mode 100644 index 00000000..66ae290d --- /dev/null +++ b/schemas/v3.0.2/extension/manifest.json @@ -0,0 +1,92 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } +} diff --git a/schemas/v3.0.2/extension/stdout/discover.json b/schemas/v3.0.2/extension/stdout/discover.json new file mode 100644 index 00000000..7c447d20 --- /dev/null +++ b/schemas/v3.0.2/extension/stdout/discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + } +} diff --git a/schemas/v3.0.2/outputs/extension/list.json b/schemas/v3.0.2/outputs/extension/list.json new file mode 100644 index 00000000..8ee3a7da --- /dev/null +++ b/schemas/v3.0.2/outputs/extension/list.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/extension/manifest.json" + } + } +} diff --git a/schemas/v3.0.2/resource/manifest.json b/schemas/v3.0.2/resource/manifest.json index c28967c7..8c54420a 100644 --- a/schemas/v3.0.2/resource/manifest.json +++ b/schemas/v3.0.2/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -146,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -164,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] diff --git a/schemas/v3.0.2/resource/manifest.schema.json b/schemas/v3.0.2/resource/manifest.schema.json index 024917d2..9e64b987 100644 --- a/schemas/v3.0.2/resource/manifest.schema.json +++ b/schemas/v3.0.2/resource/manifest.schema.json @@ -93,30 +93,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0.2/resource/stdout/export.json b/schemas/v3.0.2/resource/stdout/export.json index d5311a12..d203c44c 100644 --- a/schemas/v3.0.2/resource/stdout/export.json +++ b/schemas/v3.0.2/resource/stdout/export.json @@ -3,5 +3,16 @@ "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/stdout/export.json", "title": "Export resource operation stdout", "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", - "type": "object" + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0.2/config/document.resource.json" + } + ] } diff --git a/schemas/v3.0/bundled/config/document.json b/schemas/v3.0/bundled/config/document.json index fa929500..d0762eb5 100644 --- a/schemas/v3.0/bundled/config/document.json +++ b/schemas/v3.0/bundled/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -33,6 +39,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -351,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } @@ -390,9 +402,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/config/document.vscode.json b/schemas/v3.0/bundled/config/document.vscode.json index c919523e..925968c9 100644 --- a/schemas/v3.0/bundled/config/document.vscode.json +++ b/schemas/v3.0/bundled/config/document.vscode.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", @@ -52,6 +64,12 @@ "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -67,6 +85,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -527,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ @@ -615,11 +639,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "instanceName.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/extension/manifest.json b/schemas/v3.0/bundled/extension/manifest.json new file mode 100644 index 00000000..067585bc --- /dev/null +++ b/schemas/v3.0/bundled/extension/manifest.json @@ -0,0 +1,174 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0/bundled/extension/manifest.vscode.json b/schemas/v3.0/bundled/extension/manifest.vscode.json new file mode 100644 index 00000000..2efb5863 --- /dev/null +++ b/schemas/v3.0/bundled/extension/manifest.vscode.json @@ -0,0 +1,271 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0/bundled/extension/stdout/discover.json b/schemas/v3.0/bundled/extension/stdout/discover.json new file mode 100644 index 00000000..81e27f24 --- /dev/null +++ b/schemas/v3.0/bundled/extension/stdout/discover.json @@ -0,0 +1,19 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0/bundled/extension/stdout/discover.vscode.json b/schemas/v3.0/bundled/extension/stdout/discover.vscode.json new file mode 100644 index 00000000..35601e79 --- /dev/null +++ b/schemas/v3.0/bundled/extension/stdout/discover.vscode.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the full path a DSC resource manifest. DSC expects every JSON Line emitted to stdout\nfor the **Discover** operation to adhere to this schema. An extension indicates that it supports\nthe **Discover** operation by defining the [discover][01] field in its manifest.\n\nThe output must be a JSON object that defines the `manifestPath` property.\n\nIf the extension doesn't discover any resources, it shouldn't emit any data to stdout.\n\nUnless the extension raises an error, it should exit with code `0`, even when no resources are\ndiscovered.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the absolute path to a DSC resource manifest on the system. DSC expects this value to\nbe the absolute path to a manifest file that exists. If this value is a relative path, or if\nthe manifest doesn't exist, DSC raises an error.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true#manifestPath", + "type": "string" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0/bundled/outputs/config/get.json b/schemas/v3.0/bundled/outputs/config/get.json index b914276f..f00bbbec 100644 --- a/schemas/v3.0/bundled/outputs/config/get.json +++ b/schemas/v3.0/bundled/outputs/config/get.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/resource/get.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/config/get.vscode.json b/schemas/v3.0/bundled/outputs/config/get.vscode.json index 09f6eca6..32e22545 100644 --- a/schemas/v3.0/bundled/outputs/config/get.vscode.json +++ b/schemas/v3.0/bundled/outputs/config/get.vscode.json @@ -297,11 +297,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/config/set.json b/schemas/v3.0/bundled/outputs/config/set.json index 47dc93a0..6205d4d5 100644 --- a/schemas/v3.0/bundled/outputs/config/set.json +++ b/schemas/v3.0/bundled/outputs/config/set.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/resource/set.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/config/set.vscode.json b/schemas/v3.0/bundled/outputs/config/set.vscode.json index 24aba796..7856a5fd 100644 --- a/schemas/v3.0/bundled/outputs/config/set.vscode.json +++ b/schemas/v3.0/bundled/outputs/config/set.vscode.json @@ -313,11 +313,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/config/test.json b/schemas/v3.0/bundled/outputs/config/test.json index 9892bbb5..320a9d2f 100644 --- a/schemas/v3.0/bundled/outputs/config/test.json +++ b/schemas/v3.0/bundled/outputs/config/test.json @@ -237,9 +237,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/resource/test.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/config/test.vscode.json b/schemas/v3.0/bundled/outputs/config/test.vscode.json index a063508c..de0b96d2 100644 --- a/schemas/v3.0/bundled/outputs/config/test.vscode.json +++ b/schemas/v3.0/bundled/outputs/config/test.vscode.json @@ -319,11 +319,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "message.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/extension/list.json b/schemas/v3.0/bundled/outputs/extension/list.json new file mode 100644 index 00000000..cc934f70 --- /dev/null +++ b/schemas/v3.0/bundled/outputs/extension/list.json @@ -0,0 +1,231 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command." + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "type": "boolean", + "default": false + } + } + } + ] + } + } + } +} diff --git a/schemas/v3.0/bundled/outputs/extension/list.vscode.json b/schemas/v3.0/bundled/outputs/extension/list.vscode.json new file mode 100644 index 00000000..c946d0e0 --- /dev/null +++ b/schemas/v3.0/bundled/outputs/extension/list.vscode.json @@ -0,0 +1,332 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0": { + "definitions": { + "extensionType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC extension, using the syntax:\n\n```yaml\nowner[{.namespace}]/name\n```\n\nFor example:\n\n- `Microsoft/Example`\n- `Microsoft.DSC/Docs`\n- `Microsoft.Windows.Appx/Discover`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensiontype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid extension type names always define an owner and a name separated by a\nslash, like `Microsoft/Example`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows.Appx/Discover`.\n" + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "extensionCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC extensions always have at least one capability. Extension capabilities define the operations\nDSC can invoke for an extension and how the extension behaves when invoked.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nAn extension with the `discover` capability supports retrieving the path to DSC resource\nmanifests that aren't included in the `PATH` or `DSC_RESOURCE_PATH`, like manifests for\nsoftware installed as AppX packages.\n\nAn extension has this capability when its manifest defines the [discover][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/extensionCapabilities?view=dsc-3.0&preserve-view=true#discover\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true" + ] + } + }, + "commandExecutable.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "title": "Executable Command Name", + "description": "The name of the command to run.", + "type": "string" + }, + "commandArgs.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "title": "Executable Command Arguments", + "description": "The list of arguments to pass to the command. The arguments can be any number of strings. If you want to pass the JSON object representing the property bag for the resource to an argument, you can define a single item in the array as a JSON object, indicating the name of the argument with the `jsonInputArg` string property and whether the argument is mandatory for the command with the `mandatory` boolean property.", + "type": "array", + "items": { + "defaultSnippets": [ + { + "label": "String argument", + "markdownDescription": "Add a string argument to the command, like `config` or `--config`.", + "body": "${1:argument_name}" + }, + { + "label": "JSON input argument", + "markdownDescription": "Add a JSON input argument to the command. A command can only define one JSON input argument\nin the `args` list. When you define a JSON input argument, DSC passes the input data for\nthe command to the specified argument as a string representing the data as a compressed\nJSON object. The compressed JSON object doesn't have any spaces or newlines between the\nobject properties and values.\n\nIf the command doesn't define the `input` property, it must define a JSON input argument.\n\nIf the command defines both the `input` property and a JSON input argument, DSC sends the\ninput data to the command in both ways. For example, if the command defines `input` as\n`stdin` and has a JSON input argument in `args`, DSC sends the input data as a compressed\nJSON object over stdin and to the the specified argument.", + "body": { + "jsonInputArg": "${1:argument_name}", + "mandatory": "^$2" + } + } + ], + "oneOf": [ + { + "type": "string", + "title": "String argument", + "description": "Any item in the argument array can be a string representing a static argument to pass to the command.", + "markdownDescription": "Any item in the argument array can be a string representing a static argument to pass to\nthe command.\n" + }, + { + "type": "object", + "title": "JSON input argument", + "description": "Defines an argument for the command that accepts the JSON input object as a string. DSC passes the JSON input to the named argument when available. You can define the `mandatory` property to indicate whether DSC should always pass the argument to the command, even when there's no JSON input for the command. In that case, DSC passes an empty string to the JSON input argument. You can only define one JSON input argument per arguments array.", + "markdownDescription": "Defines an argument for the command that accepts the JSON input object as a string. DSC\npasses the JSON input to the named argument when available. You can define the `mandatory`\nproperty to indicate whether DSC should always pass the argument to the command, even when\nthere's no JSON input for the command. In that case, DSC passes an empty string to the\nJSON input argument. You can only define one JSON input argument per arguments array.\n\nIf you define a JSON input argument and an `input` kind for a command, DSC sends the JSON\ndata both ways:\n\n- If you define `input` as `env` and a JSON input argument, DSC sets an environment variable\n for each property in the JSON input and passes the JSON input object as a string to the\n defined argument.\n- If you define `input` as `stdin` and a JSON input argument, DSC passes the JSON input over\n stdin and as a string to the defined argument.\n- If you define a JSON input argument without defining the `input` property, DSC only passes\n the JSON input as a string to the defined argument.\n\nIf you don't define the `input` property and don't define a JSON input argument, DSC can't\npass the input JSON to the resource. This makes the manifest invalid. You must define the\n`input` property, a JSON input argument in the `args` property array, or both.\n", + "required": [ + "jsonInputArg" + ], + "unevaluatedProperties": false, + "properties": { + "jsonInputArg": { + "title": "JSON input argument name", + "description": "Defines the argument that accepts the JSON property bag for the resource as input.", + "markdownDescription": "Defines the argument that accepts the JSON property bag for the resource as input.\n", + "type": "string" + }, + "mandatory": { + "title": "Mandatory argument", + "description": "Defines whether the argument is mandatory. If this property is set to `true`, DSC passes an empty string when no JSON input is provided. The default value is `false`.", + "markdownDescription": "Defines whether the argument is mandatory. If this property is set to `true`, DSC\npasses an empty string when no JSON input is provided. The default value is `false`.\n", + "type": "boolean", + "default": false + } + } + } + ] + } + } + }, + "extension": { + "manifest.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the information DSC requires to process and surface a DSC extension. For DSC to use a\nmanifest on a system, the manifest file must:\n\n1. Be discoverable in the `PATH` environment variable.\n1. Follow the naming convention `.dsc.extension.json`.\n1. Be valid for this schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the canonical URI of this schema that the manifest validates\nagainst. This property is mandatory. DSC uses this value to validate the manifest against the\ncorrect JSON schema.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../extension/manifest.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n\n```yaml\n.../bundled/extension/manifest.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n> \n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/extension/manifest.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n> \n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the extension manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe semantic version ([semver][02]) of the DSC extension.\n\nThis value uses the [suggested regular expression][03] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#version\n[02]: https://semver.org/\n[03]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a short synopsis of the DSC extension's purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of searchable terms for the extension.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#tags\n", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$", + "patternErrorMessage": "Invalid tag. Tags must be a string of alphanumeric characters and underscores. No other\ncharacters are permitted.\n" + } + }, + "discover": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$", + "patternErrorMessage": "Invalid exit code. Must be a string representing a 32-bit signed integer.\n" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines a map of valid exit codes for the DSC extension. DSC always interprets\nexit code `0` as a successful operation and any other exit code as an error. Use this\nproperty to indicate human-readable semantic meanings for the DSC extension's exit codes.\n\nDefine the keys in this property as strings representing a valid 32-bit signed integer. You\ncan't use alternate formats for the exit code. For example, instead of the hexadecimal value\n`0x80070005` for \"Access denied\", specify the exit code as `-2147024891`. If you're authoring\nyour extension manifest in YAML, be sure to wrap the exit code in single quotes, like\n`'0': Success` instead of `0: Success` to ensure the YAML file can be parsed correctly.\n\nDefine the value for each key as a string explaining what the exit code indicates.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/root?view=dsc-3.0&preserve-view=true#exitcodes\n", + "defaultSnippets": [ + { + "label": " Defined exit codes", + "description": "Defines exit codes with semantic meaning for the extension.", + "body": { + "0": "Success", + "${1:first exit code number}": "${2:first exit code meaning}", + "${3:second exit code number}": "${4:second exit code meaning}" + } + } + ] + } + } + }, + "manifest.discover.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines how DSC must call the DSC extension to discover the paths to resource manifests. An\nextension that defines this field in its manifest has the `discover` capability.\n\nBy default, DSC only discovers resource manifests in the `PATH` environment variable. If the\n`DSC_RESOURCE_PATH` environment variable is defined, DSC searches those paths for resource\nmanifests instead.\n\nIf initial discovery finds any extension manifests that have the `discover` capability, DSC uses\nthose extensions to discover resources that aren't available in `PATH` or `DSC_RESOURCE_PATH`.\n\nFor more information about the output DSC expects the extension to emit for this command, see\n[Discover extension operation stdout][01].\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/stdout/discover?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the name of the command to run. The value must be the name of a command discoverable\nin the system's `PATH` environment variable or the full path to the command. A file extension\nis only required when the command isn't recognizable by the operating system as an\nexecutable.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#executable\n" + }, + "args": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an array of strings to pass as arguments to the command. DSC passes the arguments to\nthe command in the order they're specified.\n\nFor example, the given the following definition:\n\n```json\n{\n \"executable\": \"myextension\",\n \"args\": [\"discover\", \"--all\"],\n}\n```\n\nDSC invokes the command for the resource as:\n\n```bash\nmyextension discover --all\n```\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/extension/manifest/discover?view=dsc-3.0&preserve-view=true#args\n" + } + }, + "defaultSnippets": [ + { + "label": " Define without arguments", + "markdownDescription": "Define the `discover` command for the extension when no arguments are required.\n", + "body": { + "executable": "${2:executable_name}" + } + }, + { + "label": " Define with arguments", + "markdownDescription": "Define the `discover` command for the extension when at least one argument is required.", + "body": { + "executable": "${2:executable_name}", + "args": [ + "${3:--first-argument}" + ] + } + } + ] + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0/bundled/outputs/resource/get.json b/schemas/v3.0/bundled/outputs/resource/get.json index 274c9a07..b04c30f6 100644 --- a/schemas/v3.0/bundled/outputs/resource/get.json +++ b/schemas/v3.0/bundled/outputs/resource/get.json @@ -97,9 +97,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/resource/get.vscode.json b/schemas/v3.0/bundled/outputs/resource/get.vscode.json index 6b12e910..9c15269d 100644 --- a/schemas/v3.0/bundled/outputs/resource/get.vscode.json +++ b/schemas/v3.0/bundled/outputs/resource/get.vscode.json @@ -123,11 +123,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0/bundled/outputs/resource/list.json b/schemas/v3.0/bundled/outputs/resource/list.json index d3eda0a5..80247533 100644 --- a/schemas/v3.0/bundled/outputs/resource/list.json +++ b/schemas/v3.0/bundled/outputs/resource/list.json @@ -99,9 +99,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -113,7 +113,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json": { @@ -166,6 +167,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -181,6 +188,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -293,7 +306,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -311,9 +327,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1049,30 +1186,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0/bundled/outputs/resource/list.vscode.json b/schemas/v3.0/bundled/outputs/resource/list.vscode.json index e67961f4..7f00161e 100644 --- a/schemas/v3.0/bundled/outputs/resource/list.vscode.json +++ b/schemas/v3.0/bundled/outputs/resource/list.vscode.json @@ -105,11 +105,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "resourceKind.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -121,14 +121,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "semver.json": { @@ -509,6 +511,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -524,6 +532,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -542,6 +556,12 @@ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -557,6 +577,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -686,7 +712,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -704,9 +733,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] @@ -1959,33 +2109,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0/bundled/outputs/resource/set.json b/schemas/v3.0/bundled/outputs/resource/set.json index 88d5349e..8847aae6 100644 --- a/schemas/v3.0/bundled/outputs/resource/set.json +++ b/schemas/v3.0/bundled/outputs/resource/set.json @@ -113,9 +113,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/resource/set.vscode.json b/schemas/v3.0/bundled/outputs/resource/set.vscode.json index 27dd4a8a..1c2afaab 100644 --- a/schemas/v3.0/bundled/outputs/resource/set.vscode.json +++ b/schemas/v3.0/bundled/outputs/resource/set.vscode.json @@ -139,11 +139,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0/bundled/outputs/resource/test.json b/schemas/v3.0/bundled/outputs/resource/test.json index f96b1049..04084174 100644 --- a/schemas/v3.0/bundled/outputs/resource/test.json +++ b/schemas/v3.0/bundled/outputs/resource/test.json @@ -119,9 +119,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/duration.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", diff --git a/schemas/v3.0/bundled/outputs/resource/test.vscode.json b/schemas/v3.0/bundled/outputs/resource/test.vscode.json index 8fe88470..851d84a2 100644 --- a/schemas/v3.0/bundled/outputs/resource/test.vscode.json +++ b/schemas/v3.0/bundled/outputs/resource/test.vscode.json @@ -145,11 +145,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" } } } diff --git a/schemas/v3.0/bundled/resource/manifest.json b/schemas/v3.0/bundled/resource/manifest.json index 3db08645..44f16e35 100644 --- a/schemas/v3.0/bundled/resource/manifest.json +++ b/schemas/v3.0/bundled/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -146,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -164,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -178,9 +314,9 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -201,7 +337,8 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] }, "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.get.json": { @@ -932,30 +1069,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0/bundled/resource/manifest.vscode.json b/schemas/v3.0/bundled/resource/manifest.vscode.json index c535907f..0994d742 100644 --- a/schemas/v3.0/bundled/resource/manifest.vscode.json +++ b/schemas/v3.0/bundled/resource/manifest.vscode.json @@ -243,6 +243,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -258,6 +264,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -276,6 +288,12 @@ "\n\n> #### `v3` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -291,6 +309,12 @@ "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3` schema. This URL points to the\n> enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.1.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the resource manifest adheres to the `v3.0` schema. This URL points to\n> the enhanced authoring schema. This schema is much larger than the other schemas, as it\n> includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", @@ -420,7 +444,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -438,9 +465,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" + ] + }, + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { "required": [ "get" ] @@ -458,11 +606,11 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", - "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\nowner[.group][.area]/name\n```\n\nFor example:\n\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", - "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include a group and area to namespace\nthe resource under the owner, like `Microsoft.Windows/Registry`.\n" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" }, "semver.json": { "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -484,14 +632,16 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", "markdownEnumDescriptions": [ "\n\nIndicates that the manifest is for a typical DSC command resource.\n", "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", - "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n" + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" ] }, "commandExecutable.json": { @@ -1831,33 +1981,197 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the resource can enforce whether instances exist, handling whether an\ninstance should be added, updated, or removed during a set operation. The default\nvalue is `true`.\n\nResources that define this property declare that the implementation adheres to the\nfollowing behavior contract:\n\n1. When the desired state for `_exist` is `true`, the resource expects the instance\n to exist. If it doesn't exist, the resource creates or adds the instance during\n the set operation.\n1. When the desired state for `_exist` is `false`, the resource expects the instance\n to not exist. If it does exist, the resource deletes or removes the instance\n during the set operation.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n" }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource returns this value for it's own `test` method. This\nproperty is mandatory when the manifest defines the `test` property. It shouldn't\nbe included if the DSC resource relies on DSC's synthetic testing.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/indesiredstate?view=dsc-3.0&preserve-view=true\n" }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_purge` property to specify\nwhether the DSC resource should remove all non-specified members when it manages\nan array of members or values.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/purge?view=dsc-3.0&preserve-view=true\n" }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" - }, + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ], "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nIndicates that the DSC resource uses the standard `_rebootRequested` property to\nreport whether the machine should be rebooted after the `set` method executes.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/rebootrequested?view=dsc-3.0&preserve-view=true\n" } }, diff --git a/schemas/v3.0/bundled/resource/stdout/delete.json b/schemas/v3.0/bundled/resource/stdout/delete.json new file mode 100644 index 00000000..b2ac7954 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/delete.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/delete.vscode.json b/schemas/v3.0/bundled/resource/stdout/delete.vscode.json new file mode 100644 index 00000000..7f7f6f4f --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/delete.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/delete.json", + "title": "Delete resource operation stdout", + "description": "DSC does not expect the **Delete** operation for a resource to return any JSON to stdout.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC does not expect the **Delete** operation for a resource to return any JSON to stdout.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/delete?view=dsc-3.0&preserve-view=true\n", + "type": "null", + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/export.json b/schemas/v3.0/bundled/resource/stdout/export.json new file mode 100644 index 00000000..72efaaf7 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/export.json @@ -0,0 +1,71 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json" + } + ], + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/export.vscode.json b/schemas/v3.0/bundled/resource/stdout/export.vscode.json new file mode 100644 index 00000000..c6225d65 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/export.vscode.json @@ -0,0 +1,130 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/export.json", + "title": "Export resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a resource implementing the **Export** operation to return a series of JSON Lines.\n\nThe data that DSC expects depends on whether the resource kind is defined as `exporter`:\n\n- When the resource kind is `exporter`, DSC expects the resource to return JSON Lines\n representing DSC resource instance definitions to recursively export.\n- When the resource kind isn't `exporter`, DSC expects the resource to return JSON Lines\n representing the actual state of every instance of the resource on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects a typical resource implementing the **Export** operation to return a series of\nJSON Lines.\n\nEach JSON Line represents the actual state of a resource instance in DSC. DSC expects every\nJSON Line emitted to stdout for the **Export** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC expects an exporter resource (one with the `kind` field in its manifest set to\n`exporter`) to return a series of JSON Lines.\n\nEach JSON Line represents a DSC resource instance definition to recursively invoke the\n**Export** operation for. DSC expects every JSON Line emitted to stdout for the **Export**\noperation to adhere to this schema.\n\nThe output must be a JSON object adhering to [DSC resource instance][01] schema, rather than\nthe instance schema for a specific resource. DSC expects the object to define at least the\n[name][02] and [type][03] fields. If the object defines the [properties][04] field, DSC\npasses those properties to the resource when recursively exporting it so that the resource\nmay filter the exported instance results.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true#typical-resource-expected-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#type\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + ], + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0": { + "config": { + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + } + }, + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/get.json b/schemas/v3.0/bundled/resource/stdout/get.json new file mode 100644 index 00000000..e937530e --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/get.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/get.vscode.json b/schemas/v3.0/bundled/resource/stdout/get.vscode.json new file mode 100644 index 00000000..cdfeee07 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/get.vscode.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/get.json", + "title": "Get resource operation stdout", + "description": "Represents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to stdout for the **Get** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the actual state of a resource instance in DSC. DSC expects the JSON Line emitted to\nstdout for the **Get** operation to adhere to this schema.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of the\nresource.\n\nCommand resources define their instance schema with the [schema.command][01] or\n[schema.embedded][02] fields in their resource manifest. If a command resource returns JSON that\nis invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/get?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/list.json b/schemas/v3.0/bundled/resource/stdout/list.json new file mode 100644 index 00000000..2d22de0a --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/list.json @@ -0,0 +1,122 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "kind": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ] + } + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/list.vscode.json b/schemas/v3.0/bundled/resource/stdout/list.vscode.json new file mode 100644 index 00000000..d0a86eb2 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/list.vscode.json @@ -0,0 +1,157 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/list.json", + "title": "List resource operation stdout", + "description": "Defines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to stdout for the **List** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of an adapted resource in DSC. DSC expects every JSON Line emitted to\nstdout for the **List** operation to adhere to this schema.\n\nDSC includes the following adapter resources:\n\n- `Microsoft.DSC/PowerShell` run PowerShell and enables you to use PowerShell DSC (PSDSC)\n resources implemented as PowerShell classes in DSC.\n- `Microsoft.Windows/WindowsPowerShell` runs Windows PowerShell and enables you to use any\n available PSDSC resources in DSC. This adapter is only available when you install DSC on\n Windows.\n- `Microsoft.Windows/WMI` enables you to use WMI classes as resources in DSC. This adapter is\n only available when you install DSC on Windows.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/list?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type", + "kind", + "version", + "capabilities", + "path", + "directory", + "implementedAs", + "properties", + "requireAdapter" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "kind": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json" + }, + "version": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceCapabilities.json" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the adapted resource on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the adapted resource on the file system." + }, + "implementedAs": { + "title": "Custom implementation name", + "description": "Indicates that the adapted resource uses a custom implementation. The name can be used to distinguish between different implementations for the adapted resources.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the adapted Resource.", + "type": [ + "string", + "null" + ], + "pattern": "^\\w+( \\w+)*" + }, + "properties": { + "title": "Properties", + "description": "Defines the adapted resource's property names.", + "type": "array", + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "requireAdapter": { + "title": "Required adapter", + "description": "Defines the fully qualified type name of the adapter that the adapted resource depends on. An adapter should always set this value to its own fully qualified resource type name.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0": { + "definitions": { + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "resourceKind.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceKind.json", + "title": "Resource kind", + "description": "Defines whether the resource is a normal DSC resource, a group resource, or an adapter resource. This property is only required for group resources.", + "type": "string", + "enum": [ + "resource", + "adapter", + "group", + "importer", + "exporter" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines how DSC should interpret the resource - as a typical resource, an adapter, a group, or an\nimporter. This property is required for group, exporter, and importer resources.\n\nDSC infers the default value for this property based on whether the [adapter][02] property is\ndefined in the manifest:\n\n- If the `adapter` property is defined in the manifest, the default `kind` is `adapter`.\n- If the `adapter` property is not defined in the manifest, the default `kind` is `resource`.\n\nFor more information about the different kinds of DSC resources, see [DSC resource kinds][01]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/root?view=dsc-3.0&preserve-view=true#kind\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\nIndicates that the manifest is for a typical DSC command resource.\n", + "\n\nIndicates that the manifest is for a resource that enables the use of non-command resources\nwith DSC.\n", + "\n\nIndicates that the manifest is for a resource that processes an array of nested resource\ninstances.\n", + "\n\nIndicates that the manifest is for a resource that resolves an external source to DSC\nresource instances. DSC processes the resolved instances as nested instances for the importer\nresource.\n", + "\n\nIndicates that the manifest is for a resource that only implements the **Export** operation\nto use for inventory and fact-gathering scenarios. For exporter resources, DSC expects the\nresource to return one or more resource definitions to recursively export, rather than the\nactual state of instances.\n\nFor more information about the expected output, see [Export resource operation stdout][02].\n" + ] + }, + "semver.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json", + "type": "string", + "title": "Semantic Version", + "description": "A valid semantic version (semver) string.\n\nFor reference, see https://semver.org/\n", + "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$", + "patternErrorMessage": "Invalid value, must be a semantic version like `..`, such as `1.2.3`.\n\nThe value may also include pre-release version information and build metadata.\n", + "$comment": "A valid semantic version ([semver][01]) string.\n\nThis value uses the [suggested regular expression][02] to validate whether the string is valid\nsemver. This is the same pattern, made multi-line for easier readability:\n\n```regex\n^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\n(?:-(\n (?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)\n (?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))\n*))?\n(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$\n```\n\nThe first line matches the `major.minor.patch` components of the version. The middle lines match\nthe pre-release components. The last line matches the build metadata component.\n\n[01]: https://semver.org/\n[02]: https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string\n" + }, + "resourceCapabilities.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations you can invoke for a resource and how the resource behaves when invoked.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDSC resources always have at least one capability. Resource capabilities define the operations\nyou can invoke for a resource and how the resource behaves when invoked.\n\nFor more information about the operations you can invoke for a resource, see\n[DSC resource operations][01].\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true\n[00]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true", + "type": "array", + "items": { + "type": "string", + "enum": [ + "get", + "set", + "setHandlesExist", + "whatIf", + "test", + "delete", + "export", + "resolve" + ], + "markdownEnumDescriptions": [ + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `get` capability supports retrieving the current state of an instance\nwith the [Get][01] operation.\n\nA command resource has this capability when its resource manifest defines the [get][02]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#get\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#get-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/get?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `set` capability supports enforcing the desired state of an instance with\nthe [Set][01] operation. Resources without this capability can't be used with the\n[dsc resource set][02] or [dsc config set][03] commands unless they're defined in a\n`Microsoft.DSC/Assertion` group as a nested instance.\n\nA command resource has this capability when its resource manifest defines the [set][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#set\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/set?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/set?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `setHandlesExist` capability indicates that you can use the [Set][01]\noperation to delete an instance. Resources with this capability must have the [_exist][02]\ncanonical resource property. Resources that don't have the `_exist` property never have this\ncapability.\n\nWhen a resource has the `_exist` property but not the `setHandlesExist` capability:\n\n- If the resource has the `delete` capability, DSC invokes the [Delete][03] operation instead\n of **Set** when the desired state for an instance defines `_exist` as false.\n- If the resource doesn't have the `delete` capability, DSC raises an error during a **Set**\n operation when the desired state for an instance defines `_exist` as false.\n\nA command resource has this capability when its resource manifest defines the\n[set.handlesExist][04] subproperty as `true`.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#sethandlesexist\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/existview=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#delete-operation\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/setview=dsc-3.0&preserve-view=true#handlesexist", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `whatIf` capability indicates that you can use the [Set][01] operation in\nwhat-if mode to have the resource return explicit information about how it would modify state\nin an actual **Set** operation.\n\nWhen a resource doesn't have this capability, DSC synthesizes how the resource would change\nan instance by converting the **Test** result for the instance into a **Set** result. The\nsynthetic operation can't indicate potential issues or changes that can't be determined by\ncomparing the result of the **Test** operation against the resource's desired state. For\nexample, the credentials used to test a resource might be valid for that operation, but not\nhave permissions to actually modify the system state. Only a resource with this capability\ncan fully report whether and how the resource would change system state.\n\nA resource has this capability when it defines the [whatIf][02] property.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#whatif\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#set-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `test` capability indicates that it implements the [Test][01] operation\ndirectly. Resources with this capability must have the [_inDesiredState][02] canonical\nresource property. Resources that don't have the `_inDesiredState` property never have this\ncapability.\n\nWhen a resource doesn't have this capability, DSC uses a synthetic test for instances of the\nresource. DSC performs the synthetic test by:\n\n1. Invoking the **Get** operation on the resource to retrieve the actual state of the\n instance.\n1. Synthetically testing each property for the desired state of an instance against the\n actual state returned. The synthetic test uses strict, case-sensitive equivalence.\n1. If the desired state for a property and the actual state aren't the same, DSC marks the\n property as out of the desired state.\n1. If any properties are out of the desired state, DSC reports the entire instance as not\n being in the desired state.\n\nSynthetic testing can't account for all resource behaviors. For example, if a package\nresource allows users to define a version range for the package, the **Get** operation\nreturns the actual version of the package, like `1.2.3`. If the user specified the version\nrange `~1` (NPM syntax indicating the package should be latest released semantic version with\nmajor version `1`), DSC would compare the desired state `~1` against the actual state `1.2.3`\nand consider the package to be in the incorrect state, even if `1.2.3` is actually the latest\nrelease matching the version pin.\n\nAny resource that has properties which can't use a strict case-sensitive comparison check\nshould have this capability.\n\nA command resource has this capability when its resource manifest defines the [test][03]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#test\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#test-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `delete` capability supports removing an instance with the [Delete][01]\noperation and the [dsc resource delete][02] command.\n\nThis capability isn't mutually exclusive with the `setHandlesExist` property. A resource can handle\nthe `_exist` property in **Set** operations and be called directly with `dsc resource delete` to\nremove an instance.\n\nFor resources with the `delete` capability and the [_exist][03] canonical resource property:\n\n- If the resource doesn't have the `setHandlesExist` capability, DSC invokes the **Delete**\n operation for the resource instead of **Set** when the desired state defines `_exist` as\n `false`.\n- If the resource does have the `setHandlesExist` capability, DSC invokes the **Set** operation for\n the resource when the desired state defines `_exist` as `false`.\n\nResources with the `delete` capability that don't have the `_exist` canonical resource property\nmust implement their **Set** operation to handle removing instances. DSC can't infer existence\nsemantics without the `_exist` property.\n\nA command resource has this capability when its resource manifest defines the [delete][04]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#delete\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operations?view=dsc-3.0&preserve-view=true#delete-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/delete?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/exist?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/delete?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `export` capability supports enumerating every instance of the resource\nwith the [Export][01] operation.\n\nYou can use resources with this capability with the following commands:\n\n- [dsc config export][02] to return a configuration document representing the actual state\n for every instance of each resource defined in the input document.\n- [dsc resource export][03] to return a configuration document representing the actual state\n for every instance of the input resource.\n- `dsc resource get` with the [--all][04] option to return the actual state of every instance\n of the input resource.\n\nA command resource has this capability when its resource manifest defines the [export][05]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#export\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/operationsview=dsc-3.0&preserve-view=true#export-operation\n[02]: https://learn.microsoft.com/powershell/dsc/reference/cli/config/export?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/export?view=dsc-3.0&preserve-view=true\n[04]: https://learn.microsoft.com/powershell/dsc/reference/cli/resource/get?view=dsc-3.0&preserve-view=true#--all\n[05]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/export?view=dsc-3.0&preserve-view=true", + "***\n[_Online Documentation_][00]\n***\n\nA resource with the `resolve` capability supports resolving nested resource instances from an\nexternal source. This capability is primarily used by [importer resources][01] to enable users to\ncompose configuration documents.\n\nA command resource has this capability when its resource manifest defines the [resolve][0220]\nproperty.\n\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourceCapabilities?view=dsc-3.0&preserve-view=true#resolve\n[01]: https://learn.microsoft.com/powershell/dsc/concepts/resources/kinds?view=dsc-3.0&preserve-view=true#importer-resources\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/resolve?view=dsc-3.0&preserve-view=true" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/resolve.json b/schemas/v3.0/bundled/resource/stdout/resolve.json new file mode 100644 index 00000000..70395d35 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/resolve.json @@ -0,0 +1,453 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "type": "object" + } + }, + "$defs": { + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.parameter.json" + } + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object" + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json" + } + }, + "metadata": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.metadata.json" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json" + } + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object" + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0 + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0 + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "name": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$" + } + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object" + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." + } + } + } + } + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1 + }, + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.0/bundled/resource/stdout/resolve.vscode.json new file mode 100644 index 00000000..1f03ca48 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/resolve.vscode.json @@ -0,0 +1,708 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/resolve.json", + "title": "Resolve resource operation stdout", + "description": "Defines the representation of a resolved configuration document. DSC expects the JSON Line emitted to stdout for the **Resolve** operation to adhere to this schema.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the representation of a resolved configuration document. DSC expects the JSON Line\nemitted to stdout for the **Resolve** operation to adhere to this schema.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "configuration" + ], + "properties": { + "configuration": { + "title": "Resolved configuration document", + "description": "Defines the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the resolved configuration document. If the configuration document defines any\nparameters, values for those parameters may be retrieved from the `parameters` property of\nthe **Resolve** operation output.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#configuration", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/config/document.json" + }, + "parameters": { + "title": "Resolved parameters", + "description": "The `parameters` property defines the set of resolved parameter values for the resolved configuration document.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `parameters` property defines the set of resolved parameter values for the resolved\nconfiguration document. If the `parameters` property is omitted from the output for the\n**Resolve** operation, DSC doesn't pass any parameters to the resolved configuration\nwhen invoking operations on it.\n\nEach property of this object represents a different resolved parameter. The property name\nidentifies the name of a parameter. The property value is the resolved value for the\nparameter.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/resolve?view=dsc-3.0&preserve-view=true#parameters", + "type": "object" + } + }, + "$defs": { + "PowerShell": { + "DSC": { + "main": { + "schemas": { + "v3.0": { + "config": { + "document.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "title": "DSC configuration document schema", + "description": "Describes a valid DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDescribes a valid DSC configuration document.\n\nDSC configurations enable users to define state by combining different DSC resources. A\nconfiguration document uses parameters and variables to pass to a set of one or more resources\nthat define a desired state.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "resources" + ], + "properties": { + "$schema": { + "title": "Schema", + "description": "Indicates the URI that resolves to the version of this schema that the document adheres to. DSC uses this property when validating and processing the configuration document.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.0/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.0.2/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.0.2/bundled/config/document.vscode.json" + ], + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nThe `$schema` property indicates the URI that resolves to the version of this schema that the\ndocument adheres to. DSC uses this property when validating and processing the configuration\ndocument.\n\nThe JSON schemas for DSC are published in multiple versions and forms. This documentation is\nfor the latest version of the schema. As a convenience, you can specify either the full URI\nfor the schema hosted in GitHub or use the shorter `aka.ms` URI. You can specify the schema\nfor a specific semantic version, the latest schema for a minor version, or the latest schema\nfor a major version of DSC. For more information about schema URIs and versioning, see\n[DSC JSON Schema URIs][01].\n\nFor every version of the schema, there are three valid urls:\n\n```yaml\n.../config/document.json\n```\n\n> The URL to the canonical non-bundled schema. When it's used for validation, the validating\n> client needs to retrieve this schema and every schema it references.\n \n```yaml\n.../bundled/config/document.json\n```\n\n> The URL to the bundled schema. When it's used for validation, the validating client only\n> needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n\n```yaml\n.../bundled/config/document.vscode.json\n```\n\n> The URL to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and snippets\n> that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#schema\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/schema-uris?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "\n\n> #### `v3` non-bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, canonical URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a major version folder. If you pin to a major version\n> folder, like `v3`, the schemas you use will update with every nonbreaking release. You\n> can use those schemas until you want or need to migrate to a new major version of DSC.\n", + "\n\n> #### `v3.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.1`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.1.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.1.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.1.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.1.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0` schema. This URL points\n> to the enhanced authoring schema. This schema is much larger than the other schemas, as\n> it includes additional definitions that provide contextual help and snippets that the\n> others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a minor version folder. If you pin to a minor version\n> folder, like `v3.0`, the schemas you use will update with every patch release. Pinning\n> to a minor version folder enables you to take advantage of fixes to the schemas without\n> continually updating your schema URIs. However, to take advantage of any improvements\n> or new features, you need to update the URI whenever a new minor version is released.\n", + "\n\n> #### `v3.0.0` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.0` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.0` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.0`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.1` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.1` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.1`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` non-bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the canonical non-bundled schema. When it's used for validation, the\n> validating client needs to retrieve this schema and every schema it references.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` bundled, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the bundled schema. When it's used for validation, the validating client\n> only needs to retrieve this schema.\n>\n> This schema uses the bundling model introduced for JSON Schema 2020-12. While DSC can\n> still validate the document when it uses this schema, other tools may error or behave\n> in unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n", + "\n\n> #### `v3.0.2` enhanced authoring, short URI\n>\n> Indicates that the configuration document adheres to the `v3.0.2` schema. This URL\n> points to the enhanced authoring schema. This schema is much larger than the other\n> schemas, as it includes additional definitions that provide contextual help and\n> snippets that the others don't include.\n>\n> This schema uses keywords that are only recognized by VS Code. While DSC can still\n> validate the document when it uses this schema, other tools may error or behave in\n> unexpected ways.\n>\n> This URI is for the schemas in a full semantic version folder. If you pin to a full\n> semantic version folder, like `v3.0.2`, you're pinning to schemas that won't change.\n> However, to take advantage of any improvements or fixes to the schemas, you need to\n> update the URI with each release.\n" + ] + }, + "parameters": { + "title": "DSC configuration document parameters", + "description": "Defines runtime options for the configuration. Users and integrating tools can override use the defined parameters to pass alternate values to the configuration.", + "type": "object", + "additionalProperties": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/config/document.parameter.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines runtime options for the configuration. Users and integrating tools can override use\nthe defined parameters to pass alternate values to the configuration.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#parameters\n", + "defaultSnippets": [ + { + "label": " New Parameter", + "markdownDescription": "Defines a new runtime option for the configuration.\n\n```yaml\nparameterId:\n type: \n description: \n defaultValue: \n allowedValues:\n - \n```", + "body": { + "${1:parameterId}": { + "type": "$2", + "description": "$3", + "defaultValue": "$4", + "allowedValues": [ + "$5" + ] + } + } + }, + { + "label": " New Integer Parameter", + "markdownDescription": "Defines a new runtime option for the configuration as an integer value.\n\n```yaml\nparameterId:\n type: int\n description: \n defaultValue: \n minValue: \n minValue: \n```", + "body": { + "${1:parameterId}": { + "type": "int", + "description": "$2", + "defaultValue": "$3", + "minValue": "$4", + "maxValue": "$5" + } + } + } + ] + }, + "variables": { + "title": "Configuration variables", + "description": "Defines a set of reusable values for the configuration document. The names of this value's properties are the strings used to reference a variable's value.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of reusable values for the configuration document. The names of this value's\nproperties are the strings used to reference a variable's value.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#variables\n", + "defaultSnippets": [ + { + "label": " New variable property", + "markdownDescription": "Defines a new variable as a key-value pair.\n\n```yaml\nvariableName: variableValue\n```", + "body": { + "${1:variableName}": "${2:variableValue}" + } + }, + { + "label": " New variable property (object)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an object.\n\n```yaml\nvariableName:\n key: value\n```", + "body": { + "${1:variableName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New variable property (array)", + "markdownDescription": "Defines a new key-value pair for the variables where the value is an array.\n\n```yaml\nvariableName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:variableName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + }, + "resources": { + "title": "DSC configuration document resources", + "description": "Defines a list of DSC resource instances for the configuration to manage.", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances for the configuration to manage.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/document?view=dsc-3.0&preserve-view=true#resources\n" + }, + "metadata": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/config/document.metadata.json" + } + } + }, + "document.parameter.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.parameter.json", + "title": "Parameter", + "description": "Defines a runtime option for a DSC configuration document.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a runtime option for a DSC configuration document.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/dataTypes.json" + }, + "defaultValue": { + "title": "Default value", + "description": "Defines the default value for the parameter.", + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the default value for the parameter.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "allowedValues": { + "title": "Allowed values", + "description": "Defines a list of valid values for the parameter. If the parameter is defined with any other values, it's invalid.", + "type": "array", + "items": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json" + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of valid values for the parameter. If the parameter is defined with any other\nvalues, it's invalid.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#allowedvalues\n" + }, + "description": { + "title": "Parameter description", + "description": "Defines a synopsis for the parameter explaining its purpose.", + "type": "string", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a synopsis for the parameter explaining its purpose.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#description-1\n" + }, + "metadata": { + "title": "Parameter metadata", + "description": "Defines a set of key-value pairs for the parameter. This metadata isn't validated.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the parameter. This metadata isn't validated.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#metadata-1\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "allOf": [ + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "minValue": { + "title": "Minimum value", + "description": "The minimum valid value for an integer type. If defined with the `maxValue` property, this value must be less than the value of `maxValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid value for an integer type. If defined with the `maxValue` property,\nthis value must be less than the value of `maxValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minvalue\n" + }, + "maxValue": { + "title": "Maximum value", + "description": "The maximum valid value for an integer type. If defined with the `minValue` property, this value must be greater than the value of `minValue`.", + "type": "integer", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid value for an integer type. If defined with the `minValue` property,\nthis value must be greater than the value of `minValue`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxvalue\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + }, + { + "properties": { + "type": { + "const": "array" + } + } + } + ] + }, + "then": { + "properties": { + "minLength": { + "title": "Minimum length", + "description": "The minimum valid length for a `string`, `secureString`, or `array`. If defined with the `maxLength` property, this value must be less than the value of `maxLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe minimum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `maxLength` property, this value must be less than the value of `maxLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#minLength\n" + }, + "maxLength": { + "title": "Maximum length", + "description": "The maximum valid length for a `string`, `secureString`, or `array`. If defined with the `minLength` property, this value must be less than the value of `minLength`.", + "type": "integer", + "minimum": 0, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe maximum valid length for a `string`, `secureString`, or `array`. If defined with\nthe `minLength` property, this value must be less than the value of `minLength`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/parameter?view=dsc-3.0&preserve-view=true#maxLength\n" + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "string" + } + } + }, + { + "properties": { + "type": { + "const": "secureString" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "string" + }, + "allowedValues": { + "items": { + "type": "string" + } + } + } + } + }, + { + "if": { + "oneOf": [ + { + "properties": { + "type": { + "const": "object" + } + } + }, + { + "properties": { + "type": { + "const": "secureObject" + } + } + } + ] + }, + "then": { + "properties": { + "defaultValue": { + "type": "object" + }, + "allowedValues": { + "items": { + "type": "object" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "int" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "integer" + }, + "allowedValues": { + "items": { + "type": "integer" + } + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "array" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "array" + } + } + } + }, + { + "if": { + "properties": { + "type": { + "const": "bool" + } + } + }, + "then": { + "properties": { + "defaultValue": { + "type": "boolean" + }, + "allowedValues": { + "items": { + "type": "boolean" + } + } + } + } + } + ] + }, + "document.resource.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json", + "title": "DSC resource instance", + "description": "Defines an instance of a DSC resource in a configuration.", + "type": "object", + "required": [ + "type", + "name" + ], + "properties": { + "type": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json" + }, + "name": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json" + }, + "dependsOn": { + "title": "Instance depends on", + "description": "Defines a list of DSC resource instances that DSC must successfully process before processing this instance. Each value for this property must be the `resourceID()` lookup for another instance in the configuration. Multiple instances can depend on the same instance, but every dependency for an instance must be unique in that instance's `dependsOn` property.", + "type": "array", + "items": { + "type": "string", + "uniqueItems": true, + "pattern": "^\\[resourceId\\(\\s*'\\w+(\\.\\w+){0,2}\\/\\w+'\\s*,\\s*'[a-zA-Z0-9 ]+'\\s*\\)\\]$", + "patternErrorMessage": "Invalid value, must be a value like `[resourceId('', '`)], such as\n`[resourceId('Microsoft/OSInfo', 'Foo')]`.\n\nThe `` and `` should be the fully qualified type of the resource and its\nfriendly name in the configuration.\n", + "defaultSnippets": [ + { + "label": " New dependency", + "markdownDescription": "Defines a new dependency for the resource instance.\n\n```yaml\n\"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\n```", + "bodyText": "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + } + ] + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a list of DSC resource instances that DSC must successfully process before processing\nthis instance. Each value for this property must be the `resourceID()` lookup for another\ninstance in the configuration. Multiple instances can depend on the same instance, but every\ndependency for an instance must be unique in that instance's `dependsOn` property.\n\nThe `resourceID()` function uses this syntax:\n\n```yaml\n\"[resourceId('', '']\"\n```\n\nThe `` value is the `type` property of the dependent resource and\n`` is the dependency's `name` property. When adding a dependency in a\nYAML-format configuration document, always wrap the `resourceID()` lookup in double quotes\n(`\"`).\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + }, + "properties": { + "title": "Managed instance properties", + "description": "Defines the properties of the DSC resource this instance manages. This property's value must be an object. DSC validates the property's value against the DSC resource's schema.", + "type": "object", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the properties of the DSC resource this instance manages. This property's value must\nbe an object. DSC validates the property's value against the DSC resource's schema.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#properties-1\n" + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines an instance of a DSC resource in a configuration.\n\nThe `resources` property of a DSC configuration document always includes at least one DSC resource\ninstance. Together, the instances in a configuration define the desired state that DSC can get,\ntest, and set on a machine.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true\n", + "defaultSnippets": [ + { + "label": " New resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "properties": { + "${3:propertyName}": "${4:propertyValue}" + } + } + }, + { + "label": " New dependent resource instance", + "markdownDescription": "Defines a new instance of a DSC resource for the configuration that depends on another\ninstance.\n\n```yaml\ntype: owner[.group][.area]/name\nname: instance_name\ndependsOn:\n - \"[resourceId('dependencyInstance/Type', 'dependencyInstanceName')]\"\nproperties:\n propertyName: propertyValue\n```", + "body": { + "type": "${1:owner[.group][.area]/name}", + "name": "${2:instance_name}", + "dependsOn": [ + "\"[resourceId('${3:dependencyInstance/Type}', '${4:dependencyInstanceName}')]\"" + ], + "properties": { + "${5:propertyName}": "${6:propertyValue}" + } + } + } + ] + }, + "document.metadata.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.metadata.json", + "title": "Configuration metadata", + "description": "Defines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC` property, this metadata isn't validated. You can pass any data into this property of a configuration document.", + "type": "object", + "properties": { + "Microsoft.DSC": { + "type": "object", + "title": "DSC metadata", + "description": "The `Microsoft.DSC` metadata property contains directives and information that DSC itself uses when processing a configuration document. Unlike other metadata key-value pairs, DSC validates these properties.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe `Microsoft.DSC` metadata property contains directives and information that DSC itself\nuses when processing a configuration document. Unlike other metadata key-value pairs, DSC\nvalidates these properties.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "unevaluatedProperties": false, + "properties": { + "securityContext": { + "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", + "default": "current", + "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "markdownEnumDescriptions": [ + "\n\n> ### Current security context\n>\n> Indicates that the configuration document is usable under any security context. You\n> can invoke DSC operations against the document when elevated as root or an\n> administrator and as a normal user or account.\n", + "\n\n> ### Elevated security context\n>\n> Indicates that the configuration document is usable only in an elevated security\n> context. You can invoke DSC operations against the document when elevated as root or\n> an administrator. When you invoke DSC operations against the document as a\n> non-elevated user or account, DSC raises an error when it validates the configuration\n> document.\n", + "\n\n> ### Restricted security context\n>\n> Indicates that the configuration document is usable only in a non-elevated security\n> context. You can invoke DSC operations against the document as a non-elevated user or\n> account. When you invoke DSC operations against the document as root or an\n> administrator, DSC raises an error when it validates the configuration document.\n" + ] + } + } + } + }, + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines a set of key-value pairs for the configuration. Except for the `Microsoft.DSC`\nproperty, this metadata isn't validated. You can pass any data into this property of a\nconfiguration document.\n\nThe `Microsoft.DSC` metadata property contains metadata directives and information that DSC\nitself uses when processing the configuration document. For more information, see\n[Microsoft.DSC][02]\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", + "defaultSnippets": [ + { + "label": " New metadata property", + "markdownDescription": "Defines a key-value pair for the metadata:\n\n```yaml\nmetadataName: value\n```", + "body": { + "${1:metadataName}": "${2:value}" + } + }, + { + "label": " New metadata property (object)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an object.\n\n```yaml\nmetadataName:\n key: value\n```", + "body": { + "${1:metadataName}": { + "${2:key}": "${3:value}" + } + } + }, + { + "label": " New metadata property (array)", + "markdownDescription": "Defines a new key-value pair for the metadata where the value is an array.\n\n```yaml\nmetadataName:\n - firstValue\n - secondValue\n```", + "body": { + "${1:metadataName}": [ + "${2:firstValue}", + "${3:secondValue}" + ] + } + } + ] + } + }, + "definitions": { + "parameters": { + "dataTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/dataTypes.json", + "title": "Data Types", + "description": "Defines the data type for the parameter value.", + "type": "string", + "enum": [ + "string", + "secureString", + "int", + "bool", + "object", + "secureObject", + "array" + ], + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the data type for the parameter value.\n\nThe valid data types for a parameter are:\n\n- `array` for arrays\n- `bool` for booleans\n- `int` for integers\n- `object` for objects\n- `string` for strings\n- `secureObject` for secure objects\n- `secureString` for secure strings\n\nAccess parameters in a configuration using this syntax:\n\n```yaml\n\"[parameter('')]\"\n```\n\nIn YAML, the parameter syntax needs to be enclosed in double-quotes when used as an inline value.\nIf the syntax isn't quoted, YAML interprets the syntax as an array.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true\n", + "markdownEnumDescriptions": [ + "_Strings are an arbitrary set of text._\n\n> To define a long strings in YAML, use the folded block syntax or literal block syntax by\n> adding a `>` or `|` and a line break after the key. Then, indent the next line. Every line\n> in the string must start at the same level of indentation. You can trim the trailing\n> whitespace by using `>-` or `|-` instead.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#strings\n", + "_Secure strings are text that needs to be handled securely._\n\n> Secure strings are an arbitrary set of text that DSC and integrating tools shouldn't log or\n> record. If a secure data type parameter is used for a resource instance property that doesn't\n> expect a secure value, the resource may still log or record the value. If the resource has\n> independent logging or recording that isn't handled by DSC, the value may be stored\n> insecurely.\n>\n> Use secure strings for passwords and secrets. Never define a default value for secure string\n> parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Integer values are numbers without a fractional part._\n\n> Integer values may be limited by integrating tools or the DSC resources they're used with.\n> DSC itself supports integer values between `-9223372036854775808` and `9223372036854775807`.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#integers\n", + "_Boolean values are either `true` or `false`._\n\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#booleans\n", + "_Objects define a set of key-value pairs._\n\n> The value for each key can be any valid data type. The values can be the same type or\n> different types.\n>\n> Access keys in the object using dot-notation. Dot-notation uses this syntax:\n>\n> ```yaml\n> \"[parameters('').]\n> ```\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#objects\n", + "_Secure objects are key-value pairs that need to be handled securely._\n\n> Secure objects define a set of key-value pairs that DSC and integrating tools shouldn't log\n> or record. If a secure data type parameter is used for a resource instance property that\n> doesn't expect a secure value, the resource may still log or record the value. If the\n> resource has independent logging or recording that isn't handled by DSC, the value may be\n> stored insecurely.\n>\n> Never define a default value for secure object parameters.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#secure-strings-and-objects\n", + "_Arrays are a list of one or more values._\n\n> The values in the array can be any valid data type. Values in the array can be the same type\n> or different types.\n>\n> For more information, see the [_Online Documentation_][01].\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/parameters/datatypes?view=dsc-3.0&preserve-view=true#arrays\n" + ] + }, + "validValueTypes.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/parameters/validValueTypes.json", + "$comment": "This schema fragment makes it a little easier to compose the valid properties\nfor DSC configuration document parameters. As-written, values must be one of\nthose on this list - the schema definition for dataType excludes `null` and\nnumbers with fractional parts, like `3.5`.\n", + "type": [ + "string", + "integer", + "object", + "array", + "boolean" + ] + } + }, + "resourceType.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", + "title": "DSC resource fully qualified type name", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThe namespaced name of the DSC resource, using the syntax:\n\n```yaml\n[.][.][.]/\n```\n\nFor example:\n\n- `Microsoft/OSInfo`\n- `Microsoft.SqlServer/Database`\n- `Microsoft.SqlServer.Database/User`\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/definitions/resourcetype?view=dsc-3.0&preserve-view=true\n", + "patternErrorMessage": "Invalid type name. Valid resource type names always define an owner and a name separated by a\nslash, like `Microsoft/OSInfo`. Type names may optionally include the group, area, and subarea\nsegments to namespace the resource under the owner, like `Microsoft.Windows/Registry`.\n" + }, + "instanceName.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/instanceName.json", + "title": "Instance name", + "description": "The short, human-readable name for a DSC resource instance. Must be unique within a DSC Configuration document. Must be a non-empty string containing only letters, numbers, and spaces.", + "type": "string", + "pattern": "^[a-zA-Z0-9 ]+$", + "minLength": 1, + "patternErrorMessage": "Invalid value for instance name. An instance name must be a non-empty string containing only\nletters, numbers, and spaces.\n", + "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nDefines the short, human-readable name for a DSC resource instance. This property must be unique\nwithin a DSC configuration document. If any resource instances share the same name, DSC raises an\nerror.\n\nThe instance name must be a non-empty string containing only letters, numbers, and spaces.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/resource?view=dsc-3.0&preserve-view=true#name\n" + } + }, + "metadata": { + "Microsoft.DSC": { + "securityContext.json": { + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", + "title": "Security context", + "description": "Defines the security context that DSC was run under. If the value for this metadata property is `elevated`, DSC was run as root (non-Windows) or an elevated session with Administrator privileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in a non-elevated session.", + "markdownDescription": "Defines the security context that DSC was run under. If the value for this metadata property is\n`elevated`, DSC was run as `root` (non-Windows) or an elevated session with Administrator\nprivileges (on Windows). If the value is `restricted`, DSC was run as a normal user or account in\na non-elevated session.", + "type": "string", + "enum": [ + "current", + "elevated", + "restricted" + ] + } + } + } + } + } + } + } + } + } +} diff --git a/schemas/v3.0/bundled/resource/stdout/schema.json b/schemas/v3.0/bundled/resource/stdout/schema.json new file mode 100644 index 00000000..465b3e6b --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/schema.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/schema.vscode.json b/schemas/v3.0/bundled/resource/stdout/schema.vscode.json new file mode 100644 index 00000000..adf7abb4 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/schema.vscode.json @@ -0,0 +1,14 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/schema.json", + "title": "Schema resource command stdout", + "description": "Represents the JSON Schema that validates instances of the resource. DSC expects a resource that defines the `schema.command` field in its resource manifest to return this value for that command.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nRepresents the JSON Schema that validates instances of the resource. DSC expects a resource that\ndefines the [`schema.command`][01] field in its resource manifest to return this value for that\ncommand.\n\nThe output must be a JSON object. The object must be a valid JSON Schema. For more information\nabout what DSC expects for resource instance JSON Schemas, see\n[DSC Resource manifest embedded schema reference][02], which describes the expectations in full.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/export?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "$schema", + "type", + "properties" + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/set.json b/schemas/v3.0/bundled/resource/stdout/set.json new file mode 100644 index 00000000..e39bd95d --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/set.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/set.vscode.json b/schemas/v3.0/bundled/resource/stdout/set.vscode.json new file mode 100644 index 00000000..fa8b294e --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/set.vscode.json @@ -0,0 +1,32 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/set.json", + "title": "Set resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation.\n\nDSC expects this output for both actual **Set** operations and **Set** operations in `whatIf`\nmode. If the resource has the `whatIf` capability, the output should be the same for both modes.\n\nDSC expects different output from the command resource depending on the definition of\n[set.return][01] in the resource manifest:\n\n- If the field isn't defined, DSC doesn't expect the resource to return any JSON to stdout.\n Instead, DSC invokes the **Get** operation on the resource after the **Set** operation\n concludes and synthesizes the **Set** result, including the after state of the resource and\n the list of changed properties.\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "Null output", + "description": "When a command resource doesn't define `set.return` in its resource manifest, DSC doesn't expect the resource to emit any JSON to stdout for the **Set** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource doesn't define [set.return][01] in its resource manifest, DSC doesn't expect\nthe resource to emit any JSON to stdout for the **Set** operation.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#null-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "null" + }, + { + "title": "state output", + "description": "When a resource defines `set.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nactual state of the resource instance after the **Set** operation changes the system.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `set.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [set.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/set?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/set?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/test.json b/schemas/v3.0/bundled/resource/stdout/test.json new file mode 100644 index 00000000..a471e52e --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/test.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/test.vscode.json b/schemas/v3.0/bundled/resource/stdout/test.vscode.json new file mode 100644 index 00000000..f314b71c --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/test.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/test.json", + "title": "Test resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Test** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Test** operation.\n\nDSC expects different output from the command resource depending on the definition of\n[test.return][01] in the resource manifest:\n\n- If the field is omitted or defined as `state` (the default value), DSC expects the resource to\n emit a JSON Line to stdout representing the actual state of the resource instance with the\n [_inDesiredState][02] canonical resource property included in the returned object.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource instance with\n the `_inDesiredState` included in the returned object. The second JSON Line should be an array\n representing the names of the resource properties that aren't in the desired state.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "For the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout representing the actual state of the resource instance with the `_inDesiredState` canonical resource property included in the returned object.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nFor the **Test** operation, DSC always expects the resource to emit a JSON Line to stdout\nrepresenting the actual state of the resource instance with the [_inDesiredState][01]\ncanonical resource property included in the returned object.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `test.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [test.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that aren't in the desired state.\n\nThis output must be emitted after the JSON Line representing the actual state of the resource\ninstance with the [_inDesiredState][02] canonical resource property included in the returned\nobject.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique. The array should never include the `_inDesiredState`\nproperty.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/test?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/test?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/properties/inDesiredState?view=dsc-3.0&preserve-view=true", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/validate.json b/schemas/v3.0/bundled/resource/stdout/validate.json new file mode 100644 index 00000000..eb9e8457 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/validate.json @@ -0,0 +1,21 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource." + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource." + } + }, + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/validate.vscode.json b/schemas/v3.0/bundled/resource/stdout/validate.vscode.json new file mode 100644 index 00000000..f802049c --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/validate.vscode.json @@ -0,0 +1,24 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/validate.json", + "title": "Validate resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Validate** operation.\n\nDSC expects the resource to return a JSON object that indicates whether the instance is valid and\noptionally a string indicating how the resource is invalid.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true\n", + "type": "object", + "required": [ + "valid" + ], + "properties": { + "valid": { + "title": "Instance validity", + "description": "Indicates whether the instance is valid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nIndicates whether the instance is valid for the resource. When the value is `true`, the\ninstance is valid for the resource.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#valid" + }, + "reason": { + "title": "Reason instance is invalid", + "description": "Describes how and why the instance is invalid for the resource.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDescribes how and why the instance is invalid for the resource. Always define this property\nin the output object when `valid` is `false`. Don't define this property in the output object\nwhen `valid` is `true`.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/validate?view=dsc-3.0&preserve-view=true#reason" + } + }, + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/whatIf.json b/schemas/v3.0/bundled/resource/stdout/whatIf.json new file mode 100644 index 00000000..f88e87d1 --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/whatIf.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/bundled/resource/stdout/whatIf.vscode.json b/schemas/v3.0/bundled/resource/stdout/whatIf.vscode.json new file mode 100644 index 00000000..4b6a258b --- /dev/null +++ b/schemas/v3.0/bundled/resource/stdout/whatIf.vscode.json @@ -0,0 +1,26 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/whatIf.json", + "title": "Set (what-if mode) resource operation stdout", + "description": "Defines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if mode.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nDefines the JSON DSC expects a resource to emit to stdout for the **Set** operation in what-if\nmode.\n\nDSC expects different output from the command resource depending on the definition of\n[whatIf.return][01] in the resource manifest:\n\n- If the field is defined as `state`, DSC expects the resource to emit a JSON Line to stdout\n representing the actual state of the resource instance after the **Set** operation changes the\n system.\n- If the field is defined as `stateAndDiff`, DSC expects the resource to emit two JSON Lines. The\n first JSON Line should be an object representing the actual state of the resource after the\n **Set** operation. The second JSON Line should be an array representing the names of the\n resource properties that the operation changed on the system.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n", + "oneOf": [ + { + "title": "state output", + "description": "When a resource defines `whatIf.return` in its manifest as `state` or `stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the predicted actual state of the resource instance after the **Set** operation changes the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `state` or\n`stateAndDiff`, DSC expects the resource to emit a JSON Line to stdout representing the\nexpected actual state of the resource instance after the **Set** operation changes the\nsystem.\n\nThe output must be a JSON object. The object must be a valid representation of an instance of\nthe resource.\n\nCommand resources define their instance schema with the [schema.command][02] or\n[schema.embedded][03] fields in their resource manifest. If a command resource returns JSON\nthat is invalid against the resource instance schema, DSC raises an error.\n\nAdapted resource instances are validated by their adapter when the adapter invokes them.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#state-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return\n[02]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/command?view=dsc-3.0&preserve-view=true\n[03]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/schema/embedded?view=dsc-3.0&preserve-view=true", + "type": "object" + }, + { + "title": "diff output", + "description": "When a command resource defines `whatIf.return` in its manifest as `stateAndDiff`, DSC expects the resource to emit a second JSON Line to stdout representing the names of the resource properties that the operation changed on the system.", + "markdownDescription": "***\n[_Online Documentation_][00]\n***\n\nWhen a command resource defines [whatIf.return][01] in its manifest as `stateAndDiff`, DSC\nexpects the resource to emit a second JSON Line to stdout representing the names of the\nresource properties that the operation changed on the system.\n\nThis output must be emitted after the JSON Line representing the state of the resource\ninstance after the operation changes the system.\n\nThe output must be a JSON array. The array may be empty, or it may contain one or more\nstrings. Each string in the array must be the name of one of the resource's properties. Each\nstring in the array must be unique.\n\n[00]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/stdout/whatIf?view=dsc-3.0&preserve-view=true#diff-output\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/resource/manifest/whatif?view=dsc-3.0&preserve-view=true#return", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string" + } + } + ], + "$defs": {} +} diff --git a/schemas/v3.0/config/document.json b/schemas/v3.0/config/document.json index 8d1c10df..59a6fa17 100644 --- a/schemas/v3.0/config/document.json +++ b/schemas/v3.0/config/document.json @@ -18,6 +18,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/config/document.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/config/document.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/config/document.vscode.json", @@ -33,6 +39,12 @@ "https://aka.ms/dsc/schemas/v3/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/config/document.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/config/document.vscode.json", "https://aka.ms/dsc/schemas/v3.0/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.json", "https://aka.ms/dsc/schemas/v3.0/bundled/config/document.vscode.json", diff --git a/schemas/v3.0/config/document.metadata.json b/schemas/v3.0/config/document.metadata.json index 34618db4..6d6d5edd 100644 --- a/schemas/v3.0/config/document.metadata.json +++ b/schemas/v3.0/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.0/definitions/extensionCapabilities.json b/schemas/v3.0/definitions/extensionCapabilities.json new file mode 100644 index 00000000..c8e37650 --- /dev/null +++ b/schemas/v3.0/definitions/extensionCapabilities.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json", + "title": "Resource capabilities", + "description": "Define the operations DSC can invoke for an extension and how the extension behaves when invoked.", + "type": "array", + "items": { + "type": "string", + "enum": [ + "discover" + ] + } +} diff --git a/schemas/v3.0/definitions/extensionType.json b/schemas/v3.0/definitions/extensionType.json new file mode 100644 index 00000000..f932386b --- /dev/null +++ b/schemas/v3.0/definitions/extensionType.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json", + "title": "DSC extension fully qualified type name", + "description": "The namespaced name of the DSC extension, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n - Microsoft/Example\n - Microsoft.DSC/Docs\n - Microsoft.Windows.Appx/Discover\n", + "type": "string", + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" +} diff --git a/schemas/v3.0/definitions/resourceKind.json b/schemas/v3.0/definitions/resourceKind.json index 91389a6a..6fbd0ccc 100644 --- a/schemas/v3.0/definitions/resourceKind.json +++ b/schemas/v3.0/definitions/resourceKind.json @@ -8,6 +8,7 @@ "resource", "adapter", "group", - "importer" + "importer", + "exporter" ] } diff --git a/schemas/v3.0/definitions/resourceType.json b/schemas/v3.0/definitions/resourceType.json index 1a649fff..e43c4689 100644 --- a/schemas/v3.0/definitions/resourceType.json +++ b/schemas/v3.0/definitions/resourceType.json @@ -2,7 +2,7 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/definitions/resourceType.json", "title": "DSC resource fully qualified type name", - "description": "The namespaced name of the DSC resource, using the syntax:\n\nowner[.group][.area]/name\n\nFor example:\n\n - Microsoft.SqlServer/Database\n - Microsoft.SqlServer.Database/User\n", + "description": "The namespaced name of the DSC resource, using the syntax:\n\n[.][.][.]/\n\nFor example:\n\n- Microsoft/OSInfo\n- Microsoft.SqlServer/Database\n- Microsoft.SqlServer.Database/User\n", "type": "string", - "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$" + "pattern": "^\\w+(\\.\\w+){0,3}\\/\\w+$" } diff --git a/schemas/v3.0/extension/manifest.discover.json b/schemas/v3.0/extension/manifest.discover.json new file mode 100644 index 00000000..c7d4fbaa --- /dev/null +++ b/schemas/v3.0/extension/manifest.discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json", + "title": "Discover operation command", + "description": "Defines how DSC must call the DSC extension to discover the paths to resource manifests.", + "type": "object", + "required": [ + "executable" + ], + "properties": { + "executable": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandExecutable.json" + }, + "args": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/commandArgs.json" + } + } +} diff --git a/schemas/v3.0/extension/manifest.json b/schemas/v3.0/extension/manifest.json new file mode 100644 index 00000000..c25d1907 --- /dev/null +++ b/schemas/v3.0/extension/manifest.json @@ -0,0 +1,92 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json", + "title": "DSC extension manifest", + "description": "Defines the information DSC requires to process and surface a DSC extension.", + "type": "object", + "required": [ + "$schema", + "type", + "version" + ], + "properties": { + "$schema": { + "title": "Manifest Schema", + "description": "This property must be the canonical URL of the Command-based DSC resource Manifest schema that the manifest is implemented for.", + "type": "string", + "format": "uri", + "enum": [ + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/extension/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/extension/manifest.vscode.json" + ] + }, + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "title": "Extension Semantic Version", + "description": "The semantic version (semver) of the DSC extension.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "tags": { + "title": "Tags", + "description": "Defines a list of searchable terms for the extension.", + "type": "array", + "uniqueItems": true, + "items": { + "type": "string", + "pattern": "^\\w+$" + } + }, + "discover": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/extension/manifest.discover.json" + }, + "exitCodes": { + "title": "Exit codes", + "description": "This property defines a map of valid exit codes for the DSC extension. DSC always interprets exit code `0` as a successful operation and any other exit code as an error. Use this property to indicate human-readable semantic meanings for the DSC extension's exit codes.", + "type": "object", + "propertyNames": { + "pattern": "^-?[0-9]+$" + }, + "patternProperties": { + "^-?[0-9]+$": { + "type": "string" + } + }, + "unevaluatedProperties": false, + "default": { + "0": "Success", + "1": "Error" + }, + "examples": [ + { + "0": "Success", + "1": "Invalid parameter", + "2": "Invalid input", + "3": "JSON serialization failed" + } + ] + } + } +} diff --git a/schemas/v3.0/extension/stdout/discover.json b/schemas/v3.0/extension/stdout/discover.json new file mode 100644 index 00000000..e74abb27 --- /dev/null +++ b/schemas/v3.0/extension/stdout/discover.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/extension/stdout/discover.json", + "title": "Discover extension operation stdout", + "description": "Represents the full path a DSC resource manifest.", + "type": "object", + "additionalProperties": false, + "required": [ + "manifestPath" + ], + "properties": { + "manifestPath": { + "title": "DSC manifest path", + "description": "Defines the absolute path to a DSC resource manifest on the system.", + "type": "string" + } + } +} diff --git a/schemas/v3.0/outputs/extension/list.json b/schemas/v3.0/outputs/extension/list.json new file mode 100644 index 00000000..e4417b71 --- /dev/null +++ b/schemas/v3.0/outputs/extension/list.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/outputs/extension/list.json", + "title": "dsc extension list result", + "description": "Describes the return data for a DSC extension instance from the `dsc extension list` command.", + "type": "object", + "properties": { + "type": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionType.json" + }, + "version": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/semver.json" + }, + "capabilities": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/definitions/extensionCapabilities.json" + }, + "description": { + "title": "Extension description", + "description": "A short synopsis of the DSC extension's purpose.", + "type": "string" + }, + "path": { + "title": "Path", + "description": "Indicates the path to the DSC extension on the file system.", + "type": "string" + }, + "directory": { + "title": "Directory", + "description": "Indicates the path to the folder containing the DSC extension on the file system.", + "type": "string" + }, + "author": { + "title": "Author", + "description": "Indicates the name of the person or organization that developed and maintains the DSC extension.", + "type": [ + "string", + "null" + ] + }, + "manifest": { + "$ref": "/PowerShell/DSC/main/schemas/v3.0/extension/manifest.json" + } + } +} diff --git a/schemas/v3.0/resource/manifest.json b/schemas/v3.0/resource/manifest.json index 3f1c4c01..7b00123b 100644 --- a/schemas/v3.0/resource/manifest.json +++ b/schemas/v3.0/resource/manifest.json @@ -19,6 +19,12 @@ "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.json", + "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.json", "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -34,6 +40,12 @@ "https://aka.ms/dsc/schemas/v3/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1/bundled/resource/manifest.vscode.json", + "https://aka.ms/dsc/schemas/v3.1.0/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.json", + "https://aka.ms/dsc/schemas/v3.1.0/bundled/resource/manifest.vscode.json", "https://aka.ms/dsc/schemas/v3.0/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.json", "https://aka.ms/dsc/schemas/v3.0/bundled/resource/manifest.vscode.json", @@ -146,7 +158,10 @@ }, "then": { "required": [ - "adapter" + "adapter", + "get", + "test", + "set" ] } }, @@ -164,9 +179,130 @@ "then": { "required": [ "resolve" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "export" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "const": "exporter" + } + }, + "required": [ + "kind" ] }, - "else": { + "then": { + "required": [ + "export" + ], + "not": { + "anyOf": [ + { + "required": [ + "adapter" + ] + }, + { + "required": [ + "delete" + ] + }, + { + "required": [ + "get" + ] + }, + { + "required": [ + "resolve" + ] + }, + { + "required": [ + "set" + ] + }, + { + "required": [ + "test" + ] + }, + { + "required": [ + "validate" + ] + }, + { + "required": [ + "whatIf" + ] + } + ] + } + } + }, + { + "if": { + "properties": { + "kind": { + "enum": [ + "resource", + "adapter", + "group" + ] + } + }, + "required": [ + "kind" + ] + }, + "then": { "required": [ "get" ] diff --git a/schemas/v3.0/resource/manifest.schema.json b/schemas/v3.0/resource/manifest.schema.json index 443ca0d1..2ad687a4 100644 --- a/schemas/v3.0/resource/manifest.schema.json +++ b/schemas/v3.0/resource/manifest.schema.json @@ -93,30 +93,194 @@ "_exist": { "title": "Standard Property: _exist", "description": "Indicates that the DSC resource uses the standard `_exist` property to specify whether an instance should exist as a boolean value that defaults to `true`.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/exist.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/exist.json" + } + ] }, "_inDesiredState": { "title": "Standard Property: _inDesiredState", "description": "Indicates that the DSC resource returns this value for it's own `test` method. This read-only property is mandatory when the manifest defines the `test` property. It shouldn't be included if the DSC resource relies on DSC's synthetic testing.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/inDesiredState.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/inDesiredState.json" + } + ] }, "_purge": { "title": "Standard Property: _purge", "description": "Indicates that the DSC resource uses the standard `_purge` property to specify whether the DSC resource should remove all non-specified members when it manages an array of members or values.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/purge.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/purge.json" + } + ] }, "_rebootRequested": { "title": "Standard property: _rebootRequested", "description": "Indicates whether a resource instance requires a reboot after a set operation. To use DSC's built-in reboot notification processing, resources must define this property in their manifest.", - "const": { - "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" - } + "enum": [ + { + "$ref": "https://aka.ms/dsc/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://aka.ms/dsc/schemas/v3.0.2/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.1.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.0/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.1/resource/properties/rebootRequested.json" + }, + { + "$ref": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0.2/resource/properties/rebootRequested.json" + } + ] } } } diff --git a/schemas/v3.0/resource/stdout/export.json b/schemas/v3.0/resource/stdout/export.json index 06272c09..ad83b8f5 100644 --- a/schemas/v3.0/resource/stdout/export.json +++ b/schemas/v3.0/resource/stdout/export.json @@ -3,5 +3,16 @@ "$id": "https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/v3.0/resource/stdout/export.json", "title": "Export resource operation stdout", "description": "Represents the actual state of a resource instance in DSC. DSC expects every JSON Line emitted to stdout for the **Export** operation to adhere to this schema.", - "type": "object" + "anyOf": [ + { + "title": "Typical resource expected output", + "description": "Defines the expected output for a resource whose `kind` isn't `exporter` as the actual state of every existing instance of that resource on the system.", + "type": "object" + }, + { + "title": "Exporter resource expected output", + "description": "Defines the expected output for an `exporter` resource as a resource instance definition to recursively invoke the **Export** operation for.", + "$ref": "/PowerShell/DSC/main/schemas/v3.0/config/document.resource.json" + } + ] } diff --git a/schemas/v3.1.0/bundled/config/document.json b/schemas/v3.1.0/bundled/config/document.json index aeb87865..3d525806 100644 --- a/schemas/v3.1.0/bundled/config/document.json +++ b/schemas/v3.1.0/bundled/config/document.json @@ -363,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.1.0/bundled/config/document.vscode.json b/schemas/v3.1.0/bundled/config/document.vscode.json index 3270996a..617fc156 100644 --- a/schemas/v3.1.0/bundled/config/document.vscode.json +++ b/schemas/v3.1.0/bundled/config/document.vscode.json @@ -551,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.1.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3.1.0/bundled/resource/stdout/resolve.json b/schemas/v3.1.0/bundled/resource/stdout/resolve.json index 7cdda1d9..1651638e 100644 --- a/schemas/v3.1.0/bundled/resource/stdout/resolve.json +++ b/schemas/v3.1.0/bundled/resource/stdout/resolve.json @@ -385,7 +385,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.1.0/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.1.0/bundled/resource/stdout/resolve.vscode.json index 8c6c4377..8bb4b6a1 100644 --- a/schemas/v3.1.0/bundled/resource/stdout/resolve.vscode.json +++ b/schemas/v3.1.0/bundled/resource/stdout/resolve.vscode.json @@ -576,7 +576,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.1.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3.1.0/config/document.metadata.json b/schemas/v3.1.0/config/document.metadata.json index 8635e038..19fae9ed 100644 --- a/schemas/v3.1.0/config/document.metadata.json +++ b/schemas/v3.1.0/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1.0/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.1/bundled/config/document.json b/schemas/v3.1/bundled/config/document.json index ea706d01..cedc7931 100644 --- a/schemas/v3.1/bundled/config/document.json +++ b/schemas/v3.1/bundled/config/document.json @@ -363,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.1/bundled/config/document.vscode.json b/schemas/v3.1/bundled/config/document.vscode.json index d81b5ec5..fa4629ad 100644 --- a/schemas/v3.1/bundled/config/document.vscode.json +++ b/schemas/v3.1/bundled/config/document.vscode.json @@ -551,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3.1/bundled/resource/stdout/resolve.json b/schemas/v3.1/bundled/resource/stdout/resolve.json index 5aa8da5b..533e40d6 100644 --- a/schemas/v3.1/bundled/resource/stdout/resolve.json +++ b/schemas/v3.1/bundled/resource/stdout/resolve.json @@ -385,7 +385,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3.1/bundled/resource/stdout/resolve.vscode.json b/schemas/v3.1/bundled/resource/stdout/resolve.vscode.json index c5551196..cf34b7b4 100644 --- a/schemas/v3.1/bundled/resource/stdout/resolve.vscode.json +++ b/schemas/v3.1/bundled/resource/stdout/resolve.vscode.json @@ -576,7 +576,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3.1/config/document.metadata.json b/schemas/v3.1/config/document.metadata.json index 7e8a9207..d16a4b78 100644 --- a/schemas/v3.1/config/document.metadata.json +++ b/schemas/v3.1/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3.1/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3/bundled/config/document.json b/schemas/v3/bundled/config/document.json index 6428d589..72c296b0 100644 --- a/schemas/v3/bundled/config/document.json +++ b/schemas/v3/bundled/config/document.json @@ -363,7 +363,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3/bundled/config/document.vscode.json b/schemas/v3/bundled/config/document.vscode.json index 139fb84d..1ea2eb3b 100644 --- a/schemas/v3/bundled/config/document.vscode.json +++ b/schemas/v3/bundled/config/document.vscode.json @@ -551,7 +551,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3/bundled/resource/stdout/resolve.json b/schemas/v3/bundled/resource/stdout/resolve.json index 88e3db2a..22d0c36b 100644 --- a/schemas/v3/bundled/resource/stdout/resolve.json +++ b/schemas/v3/bundled/resource/stdout/resolve.json @@ -385,7 +385,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } } diff --git a/schemas/v3/bundled/resource/stdout/resolve.vscode.json b/schemas/v3/bundled/resource/stdout/resolve.vscode.json index 6a1be5d3..8a22fe49 100644 --- a/schemas/v3/bundled/resource/stdout/resolve.vscode.json +++ b/schemas/v3/bundled/resource/stdout/resolve.vscode.json @@ -576,7 +576,7 @@ "properties": { "securityContext": { "$ref": "#/$defs/PowerShell/DSC/main/schemas/v3/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`.", "markdownDescription": "***\n[_Online Documentation_][01]\n***\n\nThis property defines the security context a configuration requires. If you invoke a DSC\noperation against the configuration document in a security context that conflicts with\nthis metadata, DSC raises an error when it validates the configuration document.\n\nThe default security context is `Current`.\n\n[01]: https://learn.microsoft.com/powershell/dsc/reference/schemas/config/metadata?view=dsc-3.0&preserve-view=true#microsoft.dsc\n", "markdownEnumDescriptions": [ diff --git a/schemas/v3/config/document.metadata.json b/schemas/v3/config/document.metadata.json index c1e1e8e4..cccdefe1 100644 --- a/schemas/v3/config/document.metadata.json +++ b/schemas/v3/config/document.metadata.json @@ -13,7 +13,7 @@ "properties": { "securityContext": { "$ref": "/PowerShell/DSC/main/schemas/v3/metadata/Microsoft.DSC/securityContext.json", - "default": "Current", + "default": "current", "description": "This property defines the security context a configuration requires. If you invoke a DSC operation against the configuration document in a security context that conflicts with this metadata, DSC raises an error when it validates the configuration document.\nThe default security context is `Current`." } }