INTERACT FORUM

More => Old Versions => JRiver Media Center 28 for Windows => Topic started by: DrKNo on December 14, 2021, 05:52:15 pm

Title: [MCWS] library.CreateField throws an error
Post by: DrKNo on December 14, 2021, 05:52:15 pm
I'm trying to use MCWS to automatically create fields in order to synchronize fields between installations - AFAIK there is no other way to do that right now. However, calling CreateFields always fails for me. This is an example call that I think should be legal:

http://192.168.178.22:52199/MCWS/v1/Library/CreateField?Name=MUSICBRAINZ_ALBUMID&Type=string

This throws a 500 Internal Server Error Code.

Additionally, may I request two things:

Thank you for your consideration.
Title: Re: [MCWS] library.CreateField throws an error
Post by: Hendrik on December 14, 2021, 06:09:43 pm
The MCWS command will only error if either the name is missing, or the field already exists, as far as I can see.
Title: Re: [MCWS] library.CreateField throws an error
Post by: DrKNo on December 14, 2021, 06:19:08 pm
Huh, apparently I needed to restart JRiver on the target machine to make it turn up in the list using preferences (at least it turned up after I fired it up again after your comment). Thank you, hendrik!

Any chance on my requests? Right now the MCWS call doesn't get me far on my quest :)
Title: Re: [MCWS] library.CreateField throws an error
Post by: DrKNo on December 14, 2021, 06:24:32 pm
Additionally, maybe one could use a more fitting error code in this case? 500 makes it sound like the problem lies with MC, while this really is a user error. One could maybe use 409 Conflict?