User:LordSputnik/Unified Metadata Format: Difference between revisions

From MusicBrainz Wiki
Jump to navigationJump to search
(Created page with "Unified Metadata Format is a proposed structure for storing data within and exchanging data between metadata applications. It is based on the [http://en.wikipedia.org/wiki/JSO...")
 
No edit summary
 
(2 intermediate revisions by the same user not shown)
Line 6: Line 6:
* Non-standard names are stored in common metadata formats in a block, so they aren't lost on conversion and can be read back into UMF if needed.
* Non-standard names are stored in common metadata formats in a block, so they aren't lost on conversion and can be read back into UMF if needed.
* Everything is an entity or a basic value (string, integer, date, etc.) - entities always have mappings to MusicBrainz IDs, and sometimes other IDs too.
* Everything is an entity or a basic value (string, integer, date, etc.) - entities always have mappings to MusicBrainz IDs, and sometimes other IDs too.

== Basic Conceptual Types ==
;string
: A sequence of unicode characters.
;integer
: A whole number.
;decimal
: A number which may have a decimal point.
;datetime
: A combination of a date and a time.
;time
: Just a time, with no particular point of reference.
;binary
: A piece of base64 encoded binary data.
;object
: An object containing a collection of keys.
;list
: A list of values.

Each key is associated with a particular type - the value for the key should be of that type.


== Entity Properties ==
== Entity Properties ==
Line 12: Line 32:
;amazon
;amazon
: specifies an Amazon ASIN related to the entity.
: specifies an Amazon ASIN related to the entity.
;image
;
: an image representing the entity.


== Release Properties ==
== Release Properties ==
{| class="wikitable" border="1"
{| class="wikitable" border="1"
!Key!!Description!!ID3 Mapping
!Key!!Description!!Standard Type!!ID3 Mapping
|-
|-
!title
!title
|The title of the release
|The title of the release
|string
|TALB
|TALB
|-
|-
!artist
!artist
|The artists credited on the release
|The artists credited on the release
|string
|TPE2
|TPE2
|}
|}
Line 29: Line 52:
== Recording Properties ==
== Recording Properties ==
{| class="wikitable" border="1"
{| class="wikitable" border="1"
!Key!!Description!!ID3 Mapping
!Key!!Description!!Standard Type!!ID3 Mapping
|-
|-
!title
!title
|The title of the recording
|The title of the recording
|string
|TALB
|TIT2
|-
|-
!artist
!artist
|The artists featured on the recording
|The artists featured on the recording
|string
|TPE2
|TPE1
|}
|}


== Track Properties ==
== Track Properties ==
{| class="wikitable" border="1"
{| class="wikitable" border="1"
!Key!!Description!!ID3 Mapping
!Key!!Description!!Standard Type!!ID3 Mapping
|-
|-
!title
!title
|The title of the track, usually as given on the release
|The title of the track, usually as given on the release
|string
|TALB
|TIT2
|-
|-
!artist
!artist
|The artists performing on the track, as credited on the release
|The artists performing on the track, as credited on the release
|string
|TPE2
|TPE1
|-
|-
!id
!id
|The number or text used to identify the track. Commonly referred to as the track number.
|The number or text used to identify the track. Commonly referred to as the track number.
|string
|TPE2
|TPE2
|-
!position
|The position of the track within the medium.
|integer
|TRCK
|-
!medium
|The number of the medium that the track comes from.
|integer
|TPOS
|}

== Image Properties ==
{| class="wikitable" border="1"
!Key!!Description!!Standard Type!!ID3 Mapping
|-
!mime
|The mimetype of the image file.
|string
|
|-
!data
|The data of the image.
|binary
|
|-
!url
|A URL where the image can be accessed.
|string
|
|}
|}



Latest revision as of 23:56, 5 December 2013

Unified Metadata Format is a proposed structure for storing data within and exchanging data between metadata applications. It is based on the JSON format.

Key Features

  • JSON-based - supports key-value pairs, nesting and lists.
  • A standard set of key names which can be mapped to both MusicBrainz webservice data and tags in common metadata formats.
  • Non-standard names are stored in common metadata formats in a block, so they aren't lost on conversion and can be read back into UMF if needed.
  • Everything is an entity or a basic value (string, integer, date, etc.) - entities always have mappings to MusicBrainz IDs, and sometimes other IDs too.

Basic Conceptual Types

string
A sequence of unicode characters.
integer
A whole number.
decimal
A number which may have a decimal point.
datetime
A combination of a date and a time.
time
Just a time, with no particular point of reference.
binary
A piece of base64 encoded binary data.
object
An object containing a collection of keys.
list
A list of values.

Each key is associated with a particular type - the value for the key should be of that type.

Entity Properties

musicbrainz
specifies a MusicBrainz MBID related to the entity.
amazon
specifies an Amazon ASIN related to the entity.
image
an image representing the entity.

Release Properties

Key Description Standard Type ID3 Mapping
title The title of the release string TALB
artist The artists credited on the release string TPE2

Recording Properties

Key Description Standard Type ID3 Mapping
title The title of the recording string TIT2
artist The artists featured on the recording string TPE1

Track Properties

Key Description Standard Type ID3 Mapping
title The title of the track, usually as given on the release string TIT2
artist The artists performing on the track, as credited on the release string TPE1
id The number or text used to identify the track. Commonly referred to as the track number. string TPE2
position The position of the track within the medium. integer TRCK
medium The number of the medium that the track comes from. integer TPOS

Image Properties

Key Description Standard Type ID3 Mapping
mime The mimetype of the image file. string
data The data of the image. binary
url A URL where the image can be accessed. string

Example

   {
       "release": {
           "title":"Vol. 3: (The Subliminal Verses)",
           "musicbrainz":"cffc2fa1-0bc1-3dc0-b865-d79533d79dbc",
           "discogs":1826346,
           "media":[
               {
                   "tracks":[
                       {
                           "id":0,
                           "recording": {
                               "musicbrainz":"77d7867d-c6ed-406c-9bbb-59756f9f8ded"
                           }
                   ]
               }
           ]
       }
   }