forked from jonsmy/glowers-radio
		
	readme.md: update schema
This commit is contained in:
		
							
								
								
									
										32
									
								
								readme.md
									
									
									
									
									
								
							
							
						
						
									
										32
									
								
								readme.md
									
									
									
									
									
								
							| @@ -4,6 +4,8 @@ This repo contains backing information for Glowers Radio. | |||||||
| ## Format | ## Format | ||||||
| The `songs.json` format **is only intended for use for Glowers Radio**, and is effectively a living standard as a result. **Live data may change drastically without warning** | The `songs.json` format **is only intended for use for Glowers Radio**, and is effectively a living standard as a result. **Live data may change drastically without warning** | ||||||
|  |  | ||||||
|  | If you do wish to use this data for your own purposes, i.e: to make a custom player, you should be caching the songs list so your application has something to fallback to if a breaking change to the format is made. | ||||||
|  |  | ||||||
| ```yaml | ```yaml | ||||||
| required: [ version, songs ] | required: [ version, songs ] | ||||||
| properties: | properties: | ||||||
| @@ -15,6 +17,7 @@ properties: | |||||||
|         id: |         id: | ||||||
|           type: string |           type: string | ||||||
|         tags: |         tags: | ||||||
|  |           description: 'A list of tags used for filtering. Entries are arbitrary, see latest songs list.' | ||||||
|           type: array |           type: array | ||||||
|           items: [ { type: string } ] |           items: [ { type: string } ] | ||||||
|         metadata: |         metadata: | ||||||
| @@ -22,13 +25,36 @@ properties: | |||||||
|           properties: |           properties: | ||||||
|             title: { type: string } |             title: { type: string } | ||||||
|             artist: { type: string } |             artist: { type: string } | ||||||
|  |             href: | ||||||
|  |               description: 'A URL the original source can be found, if known. Link may be dead' | ||||||
|  |               type: string | ||||||
|  |               format: url | ||||||
|  |             _nigid: | ||||||
|  |               description: 'The original song id from nigge.rs. Do not use for nigge.rs detection, use the "niggers" tag instead' | ||||||
|  |               type: string | ||||||
|  |             _nigkey: | ||||||
|  |               description: 'Content of _id from the original nigge.rs song entry. Do not use for nigge.rs detection, use the "niggers" tag instead' | ||||||
|  |               type: string | ||||||
|         sources: |         sources: | ||||||
|           type: array |           type: array | ||||||
|           items: |           items: | ||||||
|           - required: [ type, url ] |           - required: [ type, url ] | ||||||
|             properties: |             properties: | ||||||
|               type: { type: string, format: mimetype } |               type: { type: string, format: mimetype } | ||||||
|               url: { type: string, format: uri } |               uri: | ||||||
|               thumbnail_type: { type: number } |                 description: 'A URI that points to the source file. See `GWMediaPlayer.fromURIToAbsolute()` for how to convert to a URL' | ||||||
|               thumbnail_url: { format: uri } |                 type: string | ||||||
|  |               previews: | ||||||
|  |                 description: >- | ||||||
|  |                   This is an array so GWMediaPlayer can better display videos being played as audio only. | ||||||
|  |                   The first Item is how the MediaItem *should* be displayed, other Items are alternative versions the player may use. | ||||||
|  |                 type: array | ||||||
|  |                 items: | ||||||
|  |                 - properties: | ||||||
|  |                     display_type: | ||||||
|  |                       description: 'Used to determine how the media should be displayed. See GWMediaPlayer.EDisplayType' | ||||||
|  |                       type: string | ||||||
|  |                     uri: { "$ref": "#/properties/songs/items/properties/sources/items/properties/uri" } | ||||||
|  |                     type: { type: string, format: mimetype } | ||||||
|  |                     size: { type: string } | ||||||
| ``` | ``` | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user