Skip to main content

YAML Reference

Complete reference for Virtual API configuration.

Virtual API structure

virtual_api:
  # Required
  name: string              # Unique identifier
  source: string            # Enrolled data source name

  # Optional
  description: string       # Human-readable description
  endpoint: string          # Source endpoint to expose
  version: string           # Semantic version (auto-incremented if omitted)

  # Control Blocks
  controls:
    - type: redact | tokenize | anonymize | combine | coalesce
      # ... control-specific options

  # Access Controls
  access:
    expires: date           # ISO 8601 date or relative (e.g., "90d")
    geo_allow: [string]     # Country codes
    geo_deny: [string]      # Country codes
    ip_allow: [string]      # CIDR ranges
    rate_limit:
      requests: number
      period: string        # e.g., "1h", "1d"

  # Delivery
  delivery:
    type: rest | mcp | data_lake
    # ... delivery-specific options

  # Marketplace (optional)
  marketplace:
    listed: boolean
    visibility: public | internal
    pricing:
      model: per_request | subscription | free
      price: number

Source enrollment

source:
  name: string              # Unique identifier
  type: rest                # Currently only REST supported
  base_url: string          # Base URL of the API

  auth:
    type: bearer | api_key | basic
    # ... auth-specific options

  endpoints:
    - path: string          # e.g., "/customers"
      method: GET | POST    # HTTP method

  schema:                   # Optional explicit schema
    /path:
      type: object | array
      properties: { ... }

Control Blocks

Redact

- type: redact
  fields:
    - field_name
    - nested.field
    - array[].field

Tokenize

- type: tokenize
  fields:
    - field_name

Anonymize

- type: anonymize
  fields:
    - field_name

Combine

- type: combine
  fields:
    - first_field
    - second_field
  into: new_field_name
  separator: string         # Default: " "
  remove_source: boolean    # Default: false

Coalesce

- type: coalesce
  fields:
    - primary_field
    - fallback_field
  into: new_field_name

Authentication types

Bearer token

auth:
  type: bearer
  token: ${ENV_VAR}

API key (header)

auth:
  type: api_key
  header: X-API-Key
  key: ${ENV_VAR}

API key (query)

auth:
  type: api_key
  param: api_key
  key: ${ENV_VAR}

Basic auth

auth:
  type: basic
  username: ${USERNAME}
  password: ${PASSWORD}

Delivery options

REST

delivery:
  type: rest
  keys:
    - name: string
      expires: date
      rate_limit: string    # e.g., "1000/h"

MCP

delivery:
  type: mcp
  oauth:
    enabled: true

Data Lake

delivery:
  type: data_lake
  destination:
    type: databricks | snowflake | fabric | bigquery
    # ... destination-specific options
  sync:
    schedule: hourly | daily | weekly
    mode: full | incremental

Environment variables

Use ${VAR_NAME} syntax to reference environment variables:
auth:
  token: ${API_TOKEN}
Variables are resolved at runtime. Never commit secrets to configuration files.