Put "media" into schema
[ouya-game-data.git] / schema.json
index 30867fd1118ac442af29a52de5c596aa8b697619..8ce2e304a466a80d887767ca46021e5ca8e9404a 100644 (file)
         "media",
         "developer"
     ],
-    "additionalProperties": false,    
+    "additionalProperties": false,
     "properties": {
         "packageName": {
             "description": "Java package name (\"com.vendor.gamename\")",
             "type": "string"
         },
-        
+
         "title": {
             "description": "Game name",
             "type": "string"
         },
-        
+
         "description": {
             "description": "Text describing the game. Newlines (CRLF) allowed",
             "type": "string"
         },
-        
+
         "players": {
             "description": "How many players can play this game at the same time?",
             "type": "array",
@@ -37,7 +37,7 @@
                 "minimum": 1
             }
         },
-        
+
         "genres": {
             "description": "Categories",
             "type": "array",
@@ -66,7 +66,9 @@
                     "Sim/Strategy",
                     "Sports",
                     "Utility",
-                    "Video"
+                    "Video",
+
+                    "Open Source"
                 ]
             }
         },
@@ -86,7 +88,7 @@
                 ],
                 "additionalProperties": false,
                 "properties": {
-                
+
                     "name": {
                         "description": "Human readable version number ('1.6')",
                         "type": "string"
 
         "media": {
             "type": "object",
-            "FIXME": ""
+            "required": [
+                "discover",
+                "large"
+            ],
+            "additionalProperties": false,
+            "properties": {
+                "discover": {
+                    "description": "Image for the OUYA discover store. FIXME: Size",
+                    "type": "string",
+                    "format": "url"
+                },
+
+                "large": {
+                    "description": "Large game cover image for the store details page.",
+                    "type": "string",
+                    "format": "url"
+                },
+
+                "video": {
+                    "description": "Video for the store details page. Vimeo and Youtube URLs supported",
+                    "type": "string",
+                    "format": "url"
+                },
+
+                "screenshots": {
+                    "description": "Additional images for the store details page.",
+                    "type": "array",
+                    "items": {
+                        "type": "string",
+                        "format": "url"
+                    }
+                },
+
+                "details": {
+                    "description": "Images and videos for the details page. Can be in any order. If no detail images and videos are given, the large image, video and screenshots are used instead",
+                    "type": "array",
+                    "items": {
+                        "type": "object",
+                        "required": [
+                            "type",
+                            "url"
+                        ],
+                        "additionalProperties": false,
+                        "properties": {
+                            "type": {
+                                "description": "Medium type: image or video",
+                                "type": "string",
+                                "enum": ["image", "video"]
+                            },
+
+                            "url": {
+                                "description": "Image URL or video URL. Vimeo and Youtube URLs supported",
+                                "type": "string",
+                                "format": "url"
+                            },
+
+                            "thumb": {
+                                "description": "Small preview image",
+                                "type": "string",
+                                "format": "url"
+                            }
+                        }
+                    }
+                }
+            }
         },
 
         "developer": {
             ],
             "additionalProperties": false,
             "properties": {
-                
+
                 "uuid": {
                     "description": "Unique ID for the developer",
                     "type": "string"
                 },
-                
+
                 "name": {
                     "description": "Developer (company or person) name",
                     "type": "string"
                 },
-                
+
                 "supportEmail": {
                     "description": "E-Mail address for support questions",
                     "type": "string",
                     "format": "email"
                 },
-                
+
                 "supportPhone": {
                     "description": "Telephone number",
                     "type": "string"
                 },
-                
+
                 "founder": {
                     "description": "If the developer was an OUYA founder",
                     "type": "boolean"
             "type": "object",
             "additionalProperties": false,
             "properties": {
-                
+
                 "likeCount": {
                     "description": "Number of likes this game has",
                     "type": "number",
                     "minimum": 0
                 },
-                
+
                 "average": {
                     "description": "Average rating for this game (0-5)",
                     "type": "number",
                     "minimum": 0
                 },
-                
+
                 "count": {
                     "description": "Number of ratings",
                     "type": "number",