Skip to content

Instantly share code, notes, and snippets.

@eyemyth
Created August 17, 2021 13:28
Show Gist options
  • Save eyemyth/05c780ce93e32ec65170a9c490a62faa to your computer and use it in GitHub Desktop.
Save eyemyth/05c780ce93e32ec65170a9c490a62faa to your computer and use it in GitHub Desktop.
{"title": "SphericalVideoPage", "description": "note that transcript is part of video schema", "type": "object", "properties": {"title": {"title": "Title", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "page_type": {"title": "Page Type", "type": "string"}, "canonical_image": {"$ref": "#/definitions/Image"}, "summary": {"title": "Summary", "type": "string"}, "url": {"$ref": "#/definitions/Hyperlink"}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+novapage", "type": "string"}, "topic": {"$ref": "#/definitions/Topic"}, "brand": {"$ref": "#/definitions/Brand"}, "short_description": {"title": "Short Description", "type": "string"}, "long_description": {"title": "Long Description", "type": "string"}, "publish_date": {"title": "Publish Date", "type": "string", "format": "date"}, "related_content": {"title": "Related Content", "type": "array", "items": {"$ref": "#/definitions/NovaPage"}}, "video": {"$ref": "#/definitions/YouTubeVideo"}}, "required": ["title", "topic", "brand", "short_description", "long_description", "video"], "definitions": {"ScaledImage": {"title": "ScaledImage", "type": "object", "properties": {"width": {"title": "Width", "type": "integer"}, "height": {"title": "Height", "type": "integer"}, "src": {"title": "Src", "minLength": 1, "maxLength": 2083, "format": "uri", "type": "string"}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+scaled_image", "type": "string"}}, "required": ["width", "src"]}, "Image": {"title": "Image", "type": "object", "properties": {"mime_type": {"title": "Mime Type", "type": "string"}, "alt_text": {"title": "Alt Text", "type": "string"}, "caption": {"title": "Caption", "anyOf": [{"type": "string", "contentMediaType": "text/html"}, {"type": "string", "contentMediaType": "application/vnd.atjson+offset"}]}, "credit": {"title": "Credit", "anyOf": [{"type": "string", "contentMediaType": "text/html"}, {"type": "string", "contentMediaType": "application/vnd.atjson+offset"}]}, "src": {"title": "Src", "minLength": 1, "maxLength": 2083, "format": "uri", "type": "string"}, "renditions": {"title": "Renditions", "type": "array", "items": {"$ref": "#/definitions/ScaledImage"}}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+image", "type": "string"}}, "required": ["mime_type", "alt_text", "src"]}, "Hyperlink": {"title": "Hyperlink", "type": "object", "properties": {"href": {"title": "Href", "minLength": 1, "maxLength": 2083, "format": "uri", "type": "string"}, "rel": {"title": "Rel", "type": "array", "items": {"type": "string"}}, "text": {"title": "Text", "type": "string"}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+hyperlink", "type": "string"}}, "required": ["href", "text"]}, "Topic": {"title": "Topic", "type": "object", "properties": {"name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "canonical_image": {"$ref": "#/definitions/Image"}}, "required": ["name", "slug"]}, "Brand": {"title": "Brand", "description": "This is not intended for use in the current DRF setup. It's a minimal set\nof fields needed to define schemas for these page types.", "type": "object", "properties": {"name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "logo": {"title": "Logo", "type": "string", "contentMediaType": "image/svg+xml"}}, "required": ["name", "slug", "logo"]}, "NovaPage": {"title": "NovaPage", "description": "This is not intended for use in the current DRF setup. It's a minimal set\nof fields needed to define schemas for these page types.\n\nNote: Nova uses 'short_description' for the same purpose as theseus\nPage.summary. That will require more refactoring than we have time to do.\n\nSimilarly, Nova uses 'hero_image' for the same purpose as\nPage.canonical_image.", "type": "object", "properties": {"title": {"title": "Title", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "page_type": {"title": "Page Type", "type": "string"}, "canonical_image": {"$ref": "#/definitions/Image"}, "summary": {"title": "Summary", "type": "string"}, "url": {"$ref": "#/definitions/Hyperlink"}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+novapage", "type": "string"}, "topic": {"$ref": "#/definitions/Topic"}, "brand": {"$ref": "#/definitions/Brand"}, "short_description": {"title": "Short Description", "type": "string"}, "long_description": {"title": "Long Description", "type": "string"}, "publish_date": {"title": "Publish Date", "type": "string", "format": "date"}, "related_content": {"title": "Related Content", "type": "array", "items": {"$ref": "#/definitions/NovaPage"}}}, "required": ["title", "topic", "brand", "short_description", "long_description"]}, "Availability": {"title": "Availability", "type": "object", "properties": {"start": {"title": "Start", "type": "string", "format": "date-time"}, "end": {"title": "End", "type": "string", "format": "date-time"}}, "required": ["start"]}, "YouTubeVideo": {"title": "YouTubeVideo", "type": "object", "properties": {"title": {"title": "Title", "type": "string"}, "description": {"title": "Description", "anyOf": [{"type": "string", "contentMediaType": "text/html"}, {"type": "string", "contentMediaType": "application/vnd.atjson+offset"}]}, "transcript": {"title": "Transcript", "anyOf": [{"type": "string", "contentMediaType": "text/html"}, {"type": "string", "contentMediaType": "application/vnd.atjson+offset"}]}, "duration": {"title": "Duration", "type": "number", "format": "time-delta"}, "placeholder_image": {"$ref": "#/definitions/Image"}, "embed": {"title": "Embed", "anyOf": [{"type": "string", "contentMediaType": "text/html"}, {"type": "string", "contentMediaType": "application/vnd.atjson+offset"}]}, "video_id": {"title": "Video Id", "type": "string"}, "availability": {"$ref": "#/definitions/Availability"}, "contentType": {"title": "Contenttype", "default": "application/vnd.theseus+youtube_video", "type": "string"}}, "required": ["title", "duration"]}}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment