Skip to content

Use MusicBrainz's API for Data Enrichment (Genres) #3

@mikayelgr

Description

@mikayelgr

We can use the MusicBrainz API to enrich the genres of the songs that we are storing. Example endpoint is https://musicbrainz.org/doc/MusicBrainz_API/Examples#Genre:~:text=68%22%0A%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20end%3A%20null%0A%20%20%20%20%7D%0A%20%20%5D%2C%0A%7D-,Genres%2C%20tags%20and%20ratings,-You%20can%20include:

  {
    id: "db92a151-1ac2-438b-bc43-b82e149ddd50",
    name: "Rick Astley",
    sort-name: "Astley, Rick",
    disambiguation: "English singer, songwriter and radio personality",
    type-id: "b6e035f4-3ce9-331c-97df-83397230b0df",
    type: "Person",
    gender-id: "36d3d30a-839d-3eda-8cb3-29be4384e4a9",
    gender: "Male",
    life-span: {
      end: null,
      ended: false,
      begin: "1966-02-06"
    },
    country: "GB"
    area: {
      id: "8a754a16-0027-3a29-b6d7-2b40ea0481ed",
      name: "United Kingdom",
      sort-name: "United Kingdom",
      disambiguation: "",
      iso-3166-1-codes: ["GB"]
    },
    begin-area: {
      id: "71baf484-64ec-4482-9ad2-225aa3b9a337"
      name: "Newton-le-Willows",
      sort-name: "Newton-le-Willows",
      disambiguation: "",
    },
    end-area: null,
    ipis: ["00159849414"],
    isnis: ["0000000120203276"],
    aliases: [
      {
        name: "Richard Paul Astley",
        sort-name: "Astley, Richard Paul",
        type-id: "d4dcd0c0-b341-3612-a332-c0ce797b25cf",
        type: "Legal name",
        locale: null,
        primary: null,
        begin: null,
        end: null
        ended: false,
      }
    ],
    genres: [
      {
        name: "blue-eyed soul",
        id: "650bda08-20ca-4012-b873-3b68c5768bdf",
        count: 2,
        disambiguation: "",
      },
      {
        name: "dance-pop",
        id: "b739a895-85ed-4ad3-8717-4e9ef5387dd8",
        count: 2,
        disambiguation: "",
      },
      {
        name: "pop",
        id: "911c7bbb-172d-4df8-9478-dbff4296e791",
        count: 2,
        disambiguation: "",
      },
    ],
    tags: [
      {name: "blue-eyed soul", count: 2},
      {name: "british", count: 0}
    ],
    rating: {
      value: 4.5,
      votes-count: 2
    }
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions