Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.
If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!
pgutil: metadata set custom returning BadRequest (400): Expected application/json Content-Type
-
Hello, I am having an issue with pgutil when trying to set custom metadata on a file in an Asset Directory.
The request I am making is:
pgutil assets metadata set custom --path=/dev/app/app1.apk --feed=Apps --key=testReleaseNotes --value="release notes value test" --api-key=XWhich for some reason returns:
Server responded with BadRequest (400): Expected application/json Content-TypeI tried using Postman to send a POST request, which works fine and is able to set custom metadata on files. It is just pgutil that appears to be throwing an error.
Is there something I am doing wrong with the pgutil request?
Thanks for the help.
-
Hi @matthew-crowley_4142 ,
What version of ProGet are you using? I know at some point we removed the requirement to specify a content type (maybe ProGet 2023?)
pgutilis really only designed/tested with ProGet 2024+; earlier versions might work, but we just didn't build or test for those APIs. We're open to pull requests if you wanted to take a stab at trying to get it working on old api (maybe it's just a matter of adding the content type header)?Thanks,
Alana -
@atripp Thanks for the response. Seems we are using a quite old version of Proget - Version 2022.25 (Build 9). We are planning to upgrade it in a few months, but didn't think it would cause issues. We might have to wait for an upgrade to our systems to get this fixed then.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login