{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://ondaclip.com/docs/config.schema.json",
  "title": ".ondaclip/config.yaml",
  "description": "Settings of the video tutorials of a repository (Ondaclip). Docs: https://ondaclip.com/docs/configuration/",
  "type": "object",
  "required": [
    "version"
  ],
  "additionalProperties": false,
  "properties": {
    "version": {
      "const": 1,
      "description": "The format of the file: 1"
    },
    "product": {
      "type": "object"
    },
    "$comment": {
      "type": "string"
    },
    "locales": {
      "type": "array"
    },
    "appEnvironment": {
      "enum": [
        "dev",
        "staging",
        "production"
      ]
    },
    "devGuard": {
      "type": "object"
    },
    "apiPattern": {
      "type": "string"
    },
    "firebaseGuard": {
      "type": "string"
    },
    "safeEmail": {
      "type": "string"
    },
    "signedOutPattern": {
      "type": "string"
    },
    "signIn": {
      "enum": [
        "none",
        "manual",
        "firebaseCustomToken"
      ]
    },
    "signInForm": {
      "type": "object"
    },
    "homePath": {
      "type": "string"
    },
    "before": {
      "type": "object"
    },
    "appAuth": {
      "type": "string"
    },
    "appAuthAudience": {
      "type": "string"
    },
    "accountsSecret": {
      "type": "string"
    },
    "allowedWrites": {
      "type": "array"
    },
    "blockedHosts": {
      "type": "string"
    },
    "audiences": {
      "type": "array"
    },
    "voice": {
      "type": "object"
    },
    "agent": {
      "type": "object"
    },
    "cloud": {
      "type": "object"
    },
    "publish": {
      "type": "object"
    },
    "freshness": {
      "type": "object"
    },
    "watch": {
      "type": "object"
    },
    "window": {
      "type": "object"
    },
    "browser": {
      "type": "object"
    },
    "neverShow": {
      "type": "object"
    },
    "brand": {
      "type": "object"
    },
    "guide": {
      "type": "object"
    },
    "findingsFile": {
      "type": "string"
    },
    "testIdAttribute": {
      "type": "string"
    },
    "platform": {
      "enum": [
        "web",
        "android"
      ]
    },
    "android": {
      "type": "object"
    },
    "pullRequests": {
      "type": "object"
    },
    "appUrl": {
      "type": "string"
    },
    "demoData": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "reset"
      ],
      "description": "Since v0.48.0. How the team resets its demo data (for example a seed command): a tutorial that writes then needs no cleanup",
      "properties": {
        "reset": {
          "type": "string"
        }
      }
    },
    "firebase": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "projectId",
        "apiKey"
      ],
      "description": "Since v0.49.0. For signIn firebaseCustomToken: the Firebase web config of the app (projectId, the public apiKey) and, optionally, the service account that signs (signer)",
      "properties": {
        "projectId": {
          "type": "string"
        },
        "apiKey": {
          "type": "string"
        },
        "signer": {
          "type": "string"
        }
      }
    },
    "products": {
      "type": "object",
      "description": "Several products in one repository (a monorepo): one entry per product, its id as the key",
      "propertyNames": {
        "pattern": "^[a-z][a-z0-9-]{0,39}$"
      },
      "additionalProperties": {
        "type": "object",
        "additionalProperties": false,
        "description": "One product of the repository: its keys go over the shared keys of the file",
        "properties": {
          "locales": {
            "type": "array"
          },
          "appEnvironment": {
            "enum": [
              "dev",
              "staging",
              "production"
            ]
          },
          "devGuard": {
            "type": "object"
          },
          "apiPattern": {
            "type": "string"
          },
          "firebaseGuard": {
            "type": "string"
          },
          "safeEmail": {
            "type": "string"
          },
          "signedOutPattern": {
            "type": "string"
          },
          "signIn": {
            "enum": [
              "none",
              "manual",
              "firebaseCustomToken"
            ]
          },
          "signInForm": {
            "type": "object"
          },
          "homePath": {
            "type": "string"
          },
          "before": {
            "type": "object"
          },
          "appAuth": {
            "type": "string"
          },
          "appAuthAudience": {
            "type": "string"
          },
          "accountsSecret": {
            "type": "string"
          },
          "allowedWrites": {
            "type": "array"
          },
          "blockedHosts": {
            "type": "string"
          },
          "audiences": {
            "type": "array"
          },
          "voice": {
            "type": "object"
          },
          "agent": {
            "type": "object"
          },
          "cloud": {
            "type": "object"
          },
          "publish": {
            "type": "object"
          },
          "freshness": {
            "type": "object"
          },
          "watch": {
            "type": "object"
          },
          "window": {
            "type": "object"
          },
          "browser": {
            "type": "object"
          },
          "neverShow": {
            "type": "object"
          },
          "brand": {
            "type": "object"
          },
          "guide": {
            "type": "object"
          },
          "findingsFile": {
            "type": "string"
          },
          "testIdAttribute": {
            "type": "string"
          },
          "platform": {
            "enum": [
              "web",
              "android"
            ]
          },
          "android": {
            "type": "object"
          },
          "pullRequests": {
            "type": "object"
          },
          "appUrl": {
            "type": "string"
          },
          "demoData": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "reset"
            ],
            "description": "Since v0.48.0. How the team resets its demo data (for example a seed command): a tutorial that writes then needs no cleanup",
            "properties": {
              "reset": {
                "type": "string"
              }
            }
          },
          "firebase": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "projectId",
              "apiKey"
            ],
            "description": "Since v0.49.0. For signIn firebaseCustomToken: the Firebase web config of the app (projectId, the public apiKey) and, optionally, the service account that signs (signer)",
            "properties": {
              "projectId": {
                "type": "string"
              },
              "apiKey": {
                "type": "string"
              },
              "signer": {
                "type": "string"
              }
            }
          },
          "name": {
            "type": "string",
            "description": "The name shown in the studio"
          },
          "tutorials": {
            "type": "string",
            "description": "Its tutorials folder, inside .ondaclip/ (default <id>/tutorials)"
          },
          "publication": {
            "type": "string",
            "description": "Its publication list, inside .ondaclip/ (default <id>/publication.yaml)"
          }
        }
      },
      "minProperties": 1
    }
  }
}
