Skip to content

Reference ​

Complete API, package, and configuration reference for DCS integration.

NPM Packages ​

Official packages for DCS integration:

PackageDescription
@duffcloudservices/cmsVue 3 composables and Vite plugins
@duffcloudservices/cliCLI for site onboarding and configuration

→ View all packages


Hosting & Deployment ​


API Reference ​

Text Content API ​

Public API for fetching text overrides.

Configuration Files ​

Reference for all DCS configuration files.

ResourceDescription
Text Content APIFetch text overrides
site.yamlSite identity configuration
Visual EditorPage editor HTML annotations
pages.yamlPage definitions
content.yamlText content overrides
seo.yamlSEO metadata configuration

Environment Variables ​

Frontend (Vite) ​

These are read by the @duffcloudservices/cms package. Your generated deployment workflow injects them at build time from your site configuration — most sites never need to set them by hand.

VariableRequiredDescription
VITE_API_BASE_URLNoDCS API base URL (defaults to https://portal.duffcloudservices.com)
VITE_SITE_SLUGNo (deprecated)Legacy site identifier; the site is now resolved server-side from the request host
VITE_TEXT_OVERRIDE_MODENoText-content override mode used during editing/preview

File Structure ​

.dcs/
├── site.yaml            # Site identity and deployment configuration
├── pages.yaml           # Page definitions
├── content.yaml         # Text content (portal-managed)
└── seo.yaml             # SEO metadata (portal-managed)

Editor Schema Support ​

DCS provides JSON schemas for all configuration files, enabling autocompletion and validation in VS Code and other editors.

VS Code Setup ​

Add to your workspace .vscode/settings.json:

json
{
  "yaml.schemas": {
    "https://schema.duffcloudservices.com/1.0.0/site.json": "/.dcs/site.yaml",
    "https://schema.duffcloudservices.com/1.0.0/pages.json": "/.dcs/pages.yaml",
    "https://schema.duffcloudservices.com/1.0.0/content.json": "/.dcs/content.yaml",
    "https://schema.duffcloudservices.com/1.0.0/seo.json": "/.dcs/seo.yaml"
  }
}

TIP

The YAML extension by Red Hat is required for schema validation.

Status Codes ​

Success ​

CodeMeaning
200Success
201Created
204No Content
304Not Modified

Client Errors ​

CodeMeaning
400Bad Request
401Unauthorized
403Forbidden
404Not Found
429Rate Limited

Server Errors ​

CodeMeaning
500Server Error
503Service Unavailable