{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "$id": "http://example.com/product.schema.json",
    "title": "Step-by-Step Challenge v1.0.0",
    "description": "A step-by-step challenge definition v1.0.0",
    "type": "object",
    "properties": {
        "id": {
            "description": "A unique identifier for this challenge",
            "type": "string"
        },
        "name": {
            "description": "A display name for this challenge",
            "type": "string"
        },
        "version": {
            "description": "The version for this step-by-step challenge. this will be used by the editor to know how to load this data. Usually generated by the challenge generator",
            "type": "string"
        },
        "defaultApp": {
            "description": "A stringified app exported from an editor. Usually exported by the challenge generator",
            "type": "string"
        },
        "steps": {
            "type": "array",
            "items": {
                "$ref": "./step.json"
            }
        },
        "whitelist": {
            "description": "A set of APIs that will be available in the editor. Any other APIs will be hidden",
            "patternProperties": {
                ".*": {
                    "description": "An API id availabel threough the editor",
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            }
        },
        "partsWhitelist": {
            "description": "A list fo parts and their APIs that will be included in this challenge",
            "patternProperties": {
                ".*": {
                    "description": "A part type. The part will then be made available in the editor during this challenge",
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            }
        }
    },
    "additionalProperties": false
  }