SplatDev.Umbraco.Plugins.Schema2Yaml
1.0.11
See the version list below for details.
dotnet add package SplatDev.Umbraco.Plugins.Schema2Yaml --version 1.0.11
NuGet\Install-Package SplatDev.Umbraco.Plugins.Schema2Yaml -Version 1.0.11
<PackageReference Include="SplatDev.Umbraco.Plugins.Schema2Yaml" Version="1.0.11" />
<PackageVersion Include="SplatDev.Umbraco.Plugins.Schema2Yaml" Version="1.0.11" />
<PackageReference Include="SplatDev.Umbraco.Plugins.Schema2Yaml" />
paket add SplatDev.Umbraco.Plugins.Schema2Yaml --version 1.0.11
#r "nuget: SplatDev.Umbraco.Plugins.Schema2Yaml, 1.0.11"
#:package SplatDev.Umbraco.Plugins.Schema2Yaml@1.0.11
#addin nuget:?package=SplatDev.Umbraco.Plugins.Schema2Yaml&version=1.0.11
#tool nuget:?package=SplatDev.Umbraco.Plugins.Schema2Yaml&version=1.0.11
SplatDev.Umbraco.Plugins.Schema2Yaml
An Infrastructure-as-Code tool for Umbraco 13 that exports your entire Umbraco site structure to YAML format. Export once, version-control it, and import anywhere using the companion Yaml2Schema plugin.
v1.0.x supports Umbraco 13 only (net8.0). For Umbraco 14-17, use v2.x from the
masterbranch.
Features
Complete Schema Export
- DataTypes — Property editors with full configuration (JSON serialized)
- DocumentTypes — Content types with properties, tabs, compositions, allowed children, and templates
- Media Types — Media types with properties and folder structure
- Templates — Razor templates with full content and master template hierarchy
- Languages — Multi-language configuration with default/mandatory flags
- Dictionary Items — Translations for all languages with parent-child hierarchy
Content & Media Export
- Content — All content nodes with properties, sort order, and published state (recursive)
- Media — Media items with automatic file download to local folder
- Media Files — Physical files downloaded and organized in Umbraco folder structure
User Management Export
- Members — Member accounts with custom properties and groups (passwords excluded)
- Users — Back-office users with roles (opt-in, passwords excluded)
Export Features
- Single ZIP Download — YAML + media bundled in one archive
- Export Statistics — Live counts per entity type with duration
- Dashboard UI — AngularJS dashboard in the Settings section
- Folder Structure — Media files maintain Umbraco's original folder hierarchy
Installation
dotnet add package SplatDev.Umbraco.Plugins.Schema2Yaml --version "1.0.*"
No further registration is required — the plugin self-registers via Schema2YamlComposer on startup and the dashboard appears automatically in the Settings section.
Usage
Via Dashboard (Recommended)
- Navigate to Settings in the Umbraco back-office
- Click the Schema Export dashboard tab
- Click Export to YAML to generate YAML from your current site
- Review the export statistics and YAML preview
- Click Download YAML for a single file, or Download ZIP for YAML + media
The ZIP archive structure:
umbraco-export.zip
├── umbraco.yml # Complete schema + content
└── media/ # Media files in Umbraco folder structure
├── images/
│ └── logo.png
└── documents/
└── brochure.pdf
Via API (Programmatic)
using SplatDev.Umbraco.Plugins.Schema2Yaml.Services;
public class MyController : Controller
{
private readonly ISchemaExportService _exportService;
public MyController(ISchemaExportService exportService)
{
_exportService = exportService;
}
public async Task<IActionResult> ExportSchema()
{
// Export to YAML string
var yaml = await _exportService.ExportToYamlAsync();
// Export to file on disk
await _exportService.ExportToFileAsync("exports/umbraco.yml");
// Export to ZIP with media files
var zipBytes = await _exportService.ExportToZipAsync();
return File(zipBytes, "application/zip", "umbraco-export.zip");
}
}
REST API Endpoints
The plugin exposes authenticated endpoints under /umbraco/backoffice/api/SchemaExport/:
| Method | Endpoint | Description |
|---|---|---|
| GET | /Export |
Export and return { yaml, statistics } as JSON |
| GET | /DownloadYaml |
Stream YAML as a file download |
| GET | /DownloadZip |
Stream ZIP (YAML + media) as a file download |
| GET | /Statistics |
Return statistics from the last export |
All endpoints require the Settings section access policy.
Configuration
Override defaults in appsettings.json:
{
"UmbracoSchema2Yaml": {
"ExportPath": "exports/umbraco.yml",
"IncludeMedia": true,
"MediaPath": "exports/media",
"IncludeContent": true,
"IncludeMembers": true,
"IncludeUsers": false,
"IncludeDictionary": true,
"IncludeLanguages": true,
"CompressYaml": false,
"MaxHierarchyDepth": 50
}
}
| Setting | Default | Description |
|---|---|---|
ExportPath |
exports/umbraco.yml |
Default YAML export file path |
IncludeMedia |
true |
Include media items and file downloads |
MediaPath |
exports/media |
Media files download location |
IncludeContent |
true |
Include content nodes |
IncludeMembers |
true |
Include member accounts |
IncludeUsers |
false |
Include back-office users (security consideration) |
IncludeDictionary |
true |
Include dictionary items |
IncludeLanguages |
true |
Include languages |
CompressYaml |
false |
Minimise YAML output |
MaxHierarchyDepth |
50 |
Max depth for content/media tree traversal |
Generated YAML Structure
umbraco:
languages:
- isoCode: en-US
cultureName: English (United States)
isDefault: true
isMandatory: true
dataTypes:
- alias: pageTitle
name: Page Title
editorUiAlias: Umbraco.TextBox
config:
maxLength: 100
documentTypes:
- alias: homePage
name: Home Page
icon: icon-home
allowedAsRoot: true
allowedTemplates:
- homePage
defaultTemplate: homePage
tabs:
- name: Content
properties:
- alias: pageTitle
name: Page Title
dataType: Page Title
required: true
templates:
- alias: homePage
name: Home Page
content: |
@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage
@{ Layout = "_Layout.cshtml"; }
<h1>@Model.Value("pageTitle")</h1>
content:
- name: Home
documentType: homePage
template: homePage
isPublished: true
properties:
pageTitle: Welcome to My Site
dictionaryItems:
- key: Welcome
translations:
en-US: Welcome
es-ES: Bienvenido
members:
- name: John Doe
email: john@example.com
username: johndoe
memberType: Member
isApproved: true
Security
- Passwords are never exported — members and users require a password reset after import
- Review exported YAML for sensitive property values before committing to version control
- Add
exports/to.gitignoreto prevent accidental commits IncludeUsersis off by default — opt in explicitly
Performance
- For large sites (1000+ content nodes), export may take several minutes
- Set
"IncludeMedia": falsefor schema-only exports - Set
"IncludeContent": falsefor structure-only exports
Support
- Issues: GitHub Issues
- Repository: github.com/SplatDev-Ltda/umbraco-yaml
License
MIT — see LICENSE for details.
Developed by SplatDev Ltda
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Newtonsoft.Json (>= 13.0.3)
- Umbraco.Cms.Core (>= 13.0.0 && < 14.0.0)
- Umbraco.Cms.Web.BackOffice (>= 13.0.0 && < 14.0.0)
- Umbraco.Cms.Web.Common (>= 13.0.0 && < 14.0.0)
- YamlDotNet (>= 15.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
v1.0.11: Fix dashboard 404 — use UmbracoAuthorizedApiController for correct backoffice routing; add dashboard localization.