{
  "backend": {
    "name": "turbo-github",
    "turbo_site_id": "b24f96b1-13a7-4f46-abf9-921db041c41e",
    "branch": "editorial/content",
    "deploy_status": false
  },
  "publish_mode": "simple",
  "locale": "pt",
  "media_folder": "public/uploads",
  "public_folder": "/uploads",
  "collections": [
    {
      "name": "products",
      "label": "Produtos",
      "folder": "src/content/products",
      "create": true,
      "delete": false,
      "format": "json",
      "extension": "json",
      "identifier_field": "id",
      "slug": "{{id}}",
      "summary": "{{id}}",
      "editor": {
        "preview": false
      },
      "fields": [
        {
          "name": "id",
          "label": "Identificador estável (não alterar)",
          "widget": "string",
          "pattern": [
            "^[a-z0-9]+(?:-[a-z0-9]+)*$",
            "Use letras minúsculas, números e hífens"
          ]
        },
        {
          "name": "slug",
          "label": "Slug da URL",
          "widget": "string",
          "pattern": [
            "^[a-z0-9]+(?:-[a-z0-9]+)*$",
            "Use um slug válido"
          ]
        },
        {
          "name": "name",
          "label": "Nome",
          "widget": "string",
          "hint": "O botão Publicar do Decap salva no backend configurado; não publica o produto no site. O estado editorial controla a visibilidade após o build."
        },
        {
          "name": "manufacturer",
          "label": "Fabricante",
          "widget": "string",
          "required": false
        },
        {
          "name": "model",
          "label": "Modelo",
          "widget": "string",
          "required": false
        },
        {
          "name": "category",
          "label": "Categoria",
          "widget": "select",
          "options": [
            "tecnologia",
            "ferramentas",
            "automotivo"
          ]
        },
        {
          "name": "summary",
          "label": "Resumo",
          "widget": "text"
        },
        {
          "name": "description",
          "label": "Descrição",
          "widget": "text"
        },
        {
          "name": "intendedUse",
          "label": "Finalidade",
          "widget": "text"
        },
        {
          "name": "audience",
          "label": "Público indicado",
          "widget": "text",
          "required": false
        },
        {
          "name": "characteristics",
          "label": "Características",
          "widget": "list",
          "required": true,
          "field": {
            "name": "item",
            "label": "Texto",
            "widget": "string"
          },
          "min": 1
        },
        {
          "name": "advantages",
          "label": "Vantagens",
          "widget": "list",
          "required": false,
          "field": {
            "name": "item",
            "label": "Texto",
            "widget": "string"
          }
        },
        {
          "name": "limitations",
          "label": "Limitações",
          "widget": "list",
          "required": true,
          "field": {
            "name": "item",
            "label": "Texto",
            "widget": "string"
          },
          "min": 1
        },
        {
          "name": "comparisonCriteria",
          "label": "Critérios de comparação",
          "widget": "list",
          "required": false,
          "field": {
            "name": "item",
            "label": "Texto",
            "widget": "string"
          }
        },
        {
          "name": "pendingChecks",
          "label": "Pendências de revisão",
          "widget": "list",
          "required": false,
          "field": {
            "name": "item",
            "label": "Texto",
            "widget": "string"
          }
        },
        {
          "name": "sourceIds",
          "label": "Fontes documentais",
          "widget": "relation",
          "collection": "sources",
          "search_fields": [
            "id",
            "title"
          ],
          "value_field": "id",
          "display_fields": [
            "title"
          ],
          "multiple": true,
          "required": false
        },
        {
          "name": "verifiedAt",
          "label": "Data da consulta documental",
          "widget": "datetime",
          "format": "YYYY-MM-DD",
          "date_format": "DD/MM/YYYY",
          "time_format": false,
          "required": false
        },
        {
          "name": "status",
          "label": "Estado editorial",
          "widget": "select",
          "default": "draft",
          "hint": "Este painel permite Rascunho, Em revisão e Inativo. O estado Publicado exige alteração revisada no arquivo e build válido.",
          "options": [
            {
              "label": "Rascunho",
              "value": "draft"
            },
            {
              "label": "Em revisão",
              "value": "review"
            },
            {
              "label": "Inativo",
              "value": "inactive"
            }
          ]
        },
        {
          "name": "contentType",
          "label": "Tipo de conteúdo",
          "widget": "select",
          "default": "documental",
          "options": [
            {
              "label": "Demonstração",
              "value": "demonstration"
            },
            {
              "label": "Ficha documental",
              "value": "documental"
            }
          ]
        }
      ]
    },
    {
      "name": "sources",
      "label": "Fontes",
      "folder": "src/content/sources",
      "create": true,
      "delete": false,
      "format": "json",
      "extension": "json",
      "identifier_field": "id",
      "slug": "{{id}}",
      "summary": "{{id}}",
      "editor": {
        "preview": false
      },
      "fields": [
        {
          "name": "id",
          "label": "Identificador estável (não alterar)",
          "widget": "string",
          "pattern": [
            "^[a-z0-9]+(?:-[a-z0-9]+)*$",
            "Use letras minúsculas, números e hífens"
          ]
        },
        {
          "name": "title",
          "label": "Título",
          "widget": "string"
        },
        {
          "name": "origin",
          "label": "Autor / instituição",
          "widget": "string"
        },
        {
          "name": "url",
          "label": "URL HTTPS",
          "widget": "string",
          "pattern": [
            "^https://",
            "Use HTTPS"
          ]
        },
        {
          "name": "consultedAt",
          "label": "Data da consulta",
          "widget": "datetime",
          "format": "YYYY-MM-DD",
          "date_format": "DD/MM/YYYY",
          "time_format": false,
          "required": true
        }
      ]
    },
    {
      "name": "offers",
      "label": "Ofertas",
      "folder": "src/content/offers",
      "create": true,
      "delete": false,
      "format": "json",
      "extension": "json",
      "identifier_field": "id",
      "slug": "{{id}}",
      "summary": "{{id}}",
      "editor": {
        "preview": false
      },
      "fields": [
        {
          "name": "id",
          "label": "Identificador estável (não alterar)",
          "widget": "string",
          "pattern": [
            "^[a-z0-9]+(?:-[a-z0-9]+)*$",
            "Use letras minúsculas, números e hífens"
          ]
        },
        {
          "name": "productId",
          "label": "Produto",
          "widget": "relation",
          "collection": "products",
          "search_fields": [
            "id",
            "name"
          ],
          "value_field": "id",
          "display_fields": [
            "name"
          ],
          "multiple": false,
          "required": true
        },
        {
          "name": "marketplace",
          "label": "Loja",
          "widget": "string"
        },
        {
          "name": "authorizedUrl",
          "label": "URL comercial autorizada",
          "widget": "string",
          "pattern": [
            "^https://",
            "Use HTTPS"
          ]
        },
        {
          "name": "programId",
          "label": "Identificador do programa autorizado",
          "widget": "string"
        },
        {
          "name": "status",
          "label": "Disponibilidade",
          "widget": "select",
          "default": "inativa",
          "options": [
            {
              "label": "Ativa",
              "value": "ativa"
            },
            {
              "label": "Inativa",
              "value": "inativa"
            }
          ]
        },
        {
          "name": "checkedAt",
          "label": "Data de verificação",
          "widget": "datetime",
          "format": "YYYY-MM-DD",
          "date_format": "DD/MM/YYYY",
          "time_format": false,
          "required": true
        }
      ]
    }
  ],
  "omit_empty_optional_fields": true
}
