Skip to content

Problem parsing get_library results #3435

Answered by OzGav
IdahoSnakeHouse asked this question in Q&A
Discussion options

You must be logged in to vote

Actually I have seen this before. It exceeds my knowledge to know why but items needs to be in quotes. I do this stuff in the template tester in the dev tools so you can paste the following in and then adjust for the exact output you want

{% set search_results = {
  "items": [
    {
      "media_type": "artist",
      "uri": "library://artist/1186",
      "name": "10 cc",
      "version": "",
      "image": null
    },
    {
      "media_type": "artist",
      "uri": "library://artist/1091",
      "name": "2 Heads",
      "version": "",
      "image": null
    },
    {
      "media_type": "artist",
      "uri": "library://artist/728",
      "name": "2 in a Room",
      "version": "",
    …

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@IdahoSnakeHouse
Comment options

@OzGav
Comment options

Answer selected by IdahoSnakeHouse
@IdahoSnakeHouse
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants