Skill Detail

schema-dts TypeScript Types for Schema.org Structured Data

An agent skill built on schema-dts by Google, which provides complete TypeScript type definitions for the Schema.org vocabulary. Enables type-safe generation and validation of JSON-LD structured data markup for SEO, rich search results, and knowledge graph integration.

Content Writing & SEOCustom Agents
Content Writing & SEO Custom Agents Security Reviewed
Tool match: schema-dts โญ 1.2k GitHub stars โฌ‡ 1.5M/wk npm
INSTALL WITH ANY AGENT
npx skills add agentskillexchange/skills --skill schema-dts-typescript-types-schemaorg-structured-data Copy
Works best when you want a reusable capability, not another fragile one-off prompt.
At a glance
Last updated
Mar 28, 2026
Quick brief

schema-dts is an open-source npm package maintained by Google that provides comprehensive TypeScript type definitions for the entire Schema.org vocabulary. With over 1,100 GitHub stars and 35 published versions, it is the standard library for type-safe structured data generation in the TypeScript/JavaScript ecosystem.

How it works

What this skill actually does

What It Does

The package auto-generates TypeScript interfaces from the official Schema.org ontology releases. Every Schema.org type โ€” Article, Product, Organization, Event, Recipe, FAQPage, HowTo, BreadcrumbList, and hundreds more โ€” gets a corresponding TypeScript interface with all properties correctly typed. This means your IDE provides autocomplete, and the TypeScript compiler catches invalid structured data at build time rather than in production.

JSON-LD Generation

schema-dts is designed specifically for JSON-LD output, the format recommended by Google for structured data. Import the types, construct your structured data objects with full type checking, and serialize to JSON-LD for embedding in HTML <script type="application/ld+json"> tags. The library handles the @context, @type, and @id properties correctly.

SEO and Rich Results

Properly structured data is essential for Google Rich Results, knowledge panels, and AI-powered search features. schema-dts ensures your markup conforms to the Schema.org specification, reducing validation errors in Google’s Rich Results Test and Schema Markup Validator. Common use cases include Article markup for blog posts, Product markup for e-commerce, FAQ markup for help pages, and Organization markup for brand identity.

Usage

Install with npm install schema-dts. Import types like import type { Article, WithContext } from 'schema-dts'. The WithContext wrapper type adds the required @context property. Build your structured data object, and TypeScript will validate every property name and value type against the Schema.org specification.

Integration Points

schema-dts integrates with Next.js, Nuxt, Gatsby, Astro, and any TypeScript project. It pairs well with next-seo for Next.js applications and can be used in build pipelines to generate and validate structured data at compile time. The package is licensed under Apache-2.0 and receives regular updates tracking new Schema.org releases.