{
  "allOf": [
    {
      "$schema": "http://json-schema.org/draft-07/schema",
      "description": "[deprecated] see resource-type.json",
      "__comment": "[deprecated] see resource-type.json",
      "type": "object",
      "required": [
        "$md"
      ],
      "properties": {
        "$md": {
          "additionalProperties": false,
          "type": "object",
          "required": [
            "name"
          ],
          "properties": {
            "label": {
              "type": "string",
              "description": "The label in the Massdriver UI."
            },
            "icon": {
              "type": "string",
              "description": "Path to an icon file for this artifact type. Must be a valid URL."
            },
            "ui": {
              "type": "object",
              "properties": {
                "environmentDefaultGroup": {
                  "type": "string",
                  "description": "[deprecated]"
                },
                "connectionOrientation": {
                  "type": "string",
                  "description": "How to orient the artifact's connection to a bundle in the UI. `link` will be line based, `environmentDefault` will make it the default for a given type in the entire environment.",
                  "enum": [
                    "link",
                    "environmentDefault"
                  ],
                  "default": "link"
                },
                "instructions": {
                  "type": "array",
                  "description": "Onboarding instructions for this artifact type. Only valid for 'credentials' artifact definitions.",
                  "items": {
                    "type": "object",
                    "required": [
                      "label",
                      "content"
                    ],
                    "properties": {
                      "label": {
                        "type": "string",
                        "description": "The label for the instruction."
                      },
                      "content": {
                        "type": "string",
                        "description": "The content of the instruction."
                      }
                    }
                  }
                }
              }
            },
            "cloud": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            },
            "containerRepositories": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            },
            "dnsZones": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            },
            "diagram": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            },
            "export": {
              "type": "array",
              "minItems": 0,
              "items": {
                "additionalProperties": false,
                "type": "object",
                "required": [
                  "templateLang",
                  "fileFormat",
                  "template",
                  "downloadButtonText"
                ],
                "properties": {
                  "downloadButtonText": {
                    "type": "string",
                    "description": "The text on the download button in the Massdriver UI for this export format."
                  },
                  "templateLang": {
                    "type": "string",
                    "enum": [
                      "liquid"
                    ],
                    "description": "The template language used to render the export file."
                  },
                  "fileFormat": {
                    "description": "The file format to add to the export file.",
                    "type": "string",
                    "enum": [
                      "yaml"
                    ]
                  },
                  "template": {
                    "type": "string",
                    "description": "The template for the export file — base64-encoded, or the raw template as published from a massdriver.yaml templatePath."
                  }
                }
              }
            },
            "importing": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            },
            "defaultTargetConnectionGroup": {
              "description": "[deprecated] see ui.environmentDefaultGroup",
              "type": "string"
            },
            "defaultTargetConnectionGroupLabel": {
              "description": "[deprecated] see label",
              "type": "string"
            },
            "access": {
              "description": "Deprecated, all artifact definitions (besides the `massdriver` core artifact types https://github.com/massdriver-cloud/artifact-definitions) are private only now.",
              "type": "string"
            },
            "name": {
              "description": "The type name of the artifact definition. This should be unique to your organization and will be prefixed with your organizations slug",
              "type": "string",
              "pattern": "^[a-z0-9-]{3,100}$"
            },
            "extensions": {
              "type": "object",
              "additionalProperties": true,
              "description": "[deprecated]"
            }
          }
        }
      }
    },
    {
      "$ref": "http://json-schema.org/draft-07/schema#"
    }
  ]
}
