# Discogs (pone mod) no longer works

**URL:** https://community.mp3tag.de/t/discogs-pone-mod-no-longer-works/65730
**Category:** Web Sources Discussion
**Created:** [August 26, 2024, 3:12pm UTC](https://community.mp3tag.de/t/discogs-pone-mod-no-longer-works/65730 "2024-08-26T15:12:48Z")
**Posts on this page:** 1
**Showing post:** 10

<div class="post-metadata">

### Author: ![ms6676749](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/m/b4bc9f/32.png) [@ms6676749](https://community.mp3tag.de/u/ms6676749)
#### Post date: [September 2, 2024, 2:28am UTC](https://community.mp3tag.de/t/discogs-pone-mod-no-longer-works/65730/10 "2024-09-02T02:28:08Z")

</div>

Likewise, I was sad when pone's discogs script stopped working due to the recent changes in discog's api output, which led me to scrap my heavily modified version. I used Florian's discogs.inc as my base (thanks @Florian!) to bring back some of the information I liked to include in my tags. Unfortunately, I'm not too familiar with working JSON arrays (e.g., `extraartists`), but I think I'm getting a hang of it from looking at Florian's work in parsing the `tracklist` array. Ultimately, I do not have much time due to work and adopted pone's approach, which involves untangling the JSON formatting for `extraartists` to scrape the data needed for my preferred credits field.

Here's an example that I tacked on my discogs.inc for Credits and Notes fields (these get merged into the Comment tagfield by a separate custom cleanup action):

```auto
# Credits
outputto "CREDITS"
gotoline 1
regexpreplace "(?:^.*\"extraartists\"\:\[)(.*$)" "$1"
ifnot "{\"id"
	say "Credits ▼"
	saynewline
	saynewline
	
	regexpreplace "}$" "\],"
	regexpreplace "\,\"(images|thumb)\"\:.*?\]" ""
	regexpreplace "\,$" ""
	regexpreplace ",\"id\":\d+,\"resource_url\":\".*?\"" ""
	regexpreplace "\]$" ""
	regexpreplace ",({\"name)" "\r\n$1"
	replace ",\"tracks\":\"\"" ""
	replace ",\"anv\":\"\",\"join\":\"\"" ""
	replace "{" ""
	replace "}" ""
	regexpreplace "\r?\n" ""
	regexpreplace "(\"role\":\"[^\"]+\")(\"name\")" "$1<<NEWLINE>>$2"
	regexpreplace "\"name\":\"(.*?)\",\"role\":\"(.*?)\"" "$2 - $1"
	regexpreplace "<<NEWLINE>>" "\r\n"
	regexpreplace " \(\d+\)" ""
	sayrest
endif

# Notes
outputto "NOTES"
gotoline 1
regexpreplace "(?:^.*\")(notes\"\:\".*?)(\"\,\"released_formatted.*$)" "$1"
ifnot "{\"id"
	say "Notes ▼"
	saynewline
	saynewline
	
	replace "notes\":\"" ""
	sayrest
endif

```

Of course, this is just a beginning, which will need updates as I come across various edge cases.

 ![Untitled](https://community.mp3tag.de/uploads/default/original/3X/5/f/5fc4aba128a88ff47fe05fb06f60417e05941b4d.jpeg)

---

_[View the full topic](https://community.mp3tag.de/t/discogs-pone-mod-no-longer-works/65730)._
