alexa-skills-kitask-cli

Uploading manifest file failing


After making some changes in a JSON manifest file, I was trying to update it following the Amazon documentation:

ask smapi update-skill-manifest -g development -s amzn1.ask.skill.xxxx --manifest "skillManifest.json" --debug

I kept getting this error: enter image description here

The error was not pointing to what the error was but my guess was that it was related to the parameters, but that was strange as I was following the documentation to letter.

I then tried, instead of passing the json file, to cat the content of the file, which would be either:

For Powershell: --manifest "$(type skillmanifest.json)"

For Linux: --manifest "$(cat skillmanifest.json)"

I still kept getting the same error.


Solution

  • Firstly, for debugging and getting a more accurate error, I checked my ASK-CLi version, which was outdated.

    After updating ASK to the latest version I was still getting the same error. At that point it started including an error object, which was saying: enter image description here

    When looking into Parsing error due to invalid body. and INVALID_REQUEST_PARAMETER through the error codes, it just said the body of the request cannot be parsed.

    After research and playing around, the problem was the manifest parameter, changing it to "file:FILENAME" solved the issue:

     --manifest "file:skillmanifest.json"
    

    The documentation is not stating this but it seems necessary for it to go through.

    I hope this helps someone out there avoid spending a full day troubleshooting.