API Reference

Access Schema.org vocabulary data programmatically

REST API Endpoints

GET /api/types

List all Schema.org types with optional filtering

Query Parameters:

  • category - Filter by category
  • parent - Filter by parent type
  • search - Search in name and description
  • limit - Limit results (default: 100)
  • offset - Pagination offset (default: 0)
Try it: /api/types?limit=5 →
GET /api/types/:name

Get details for a specific type by name

Query Parameters:

  • format - Response format (json or jsonld)
GET /api/graph

Get the complete type hierarchy graph

Query Parameters:

  • format - Response format (graph or hierarchy)
  • depth - Maximum depth for hierarchy format

TypeScript SDK

import { $ } from 'sdk.do'

// Query for a type
const product = await $.Product.get()

// Create structured data
const org = await $.Organization.create({
  name: 'Example Corp',
  url: 'https://example.com'
})

Learn more about the SDK at platform.do

JSON-LD Format

All types support JSON-LD output for semantic web applications

{
  "@context": "https://schema.org",
  "@type": "Product",
  "name": "Example Product",
  "description": "Product description",
  "offers": {
    "@type": "Offer",
    "price": "99.99",
    "priceCurrency": "USD"
  }
}