| title |
Object |
| description |
Object protocol schemas |
{/* ⚠️ AUTO-GENERATED — DO NOT EDIT. Run build-docs.ts to regenerate. Hand-written docs live in the module folders under content/docs/. */}
**Source:** `packages/spec/src/api/object.zod.ts`
import { VersioningConfig } from '@objectstack/spec/api';
import type { VersioningConfig } from '@objectstack/spec/api';
// Validate data
const result = VersioningConfig.parse(data);
| Property |
Type |
Required |
Description |
| strategy |
Enum<'urlPath' | 'header' | 'queryParam' | 'dateBased'> |
✅ |
How the API version is specified by clients |
| current |
string |
✅ |
The current/recommended API version identifier |
| default |
string |
✅ |
Fallback version when client does not specify one |
| versions |
{ version: string; status: Enum<'preview' | 'current' | 'supported' | 'deprecated' | 'retired'>; releasedAt: string; deprecatedAt?: string; … }[] |
✅ |
All available API versions with lifecycle metadata |
| headerName |
string |
✅ |
HTTP header name for version negotiation (header/dateBased strategies) |
| queryParamName |
string |
✅ |
Query parameter name for version specification (queryParam strategy) |
| urlPrefix |
string |
✅ |
URL prefix before version segment (urlPath strategy) |
| deprecation |
{ warnHeader: boolean; sunsetHeader: boolean; linkHeader: boolean; rejectRetired: boolean; … } |
optional |
Deprecation lifecycle behavior |
| includeInDiscovery |
boolean |
✅ |
Include version information in the API discovery endpoint |