解析JSON的400个问题

编程入门 行业动态 更新时间:2024-10-28 20:20:58
本文介绍了解析JSON的400个问题-使用OAuth的GitHub API和POSTMAN的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想通过GitHub API在我的私有仓库中创建一个文件. developer.github/v3/repos/contents /#create-a-file

I want to create a file in my private Repo via the GitHub API. developer.github/v3/repos/contents/#create-a-file

PUT /repos/:owner/:repo/contents/:path

我正在使用Postman进行测试,并且已经通过OAuth进行了授权.

I'm using Postman for testing and also already authorized via OAuth.

api.github/repos/user/reponame/contents/test.txt?message=Myfirstmessage&content=SGVsbG8gV29ybGQgaW4gQmFzZTY0IQ==

错误消息是:问题解析JSON"

The error message is: "Problems parsing JSON"

但是问题到底出在哪里?

But where exactly is the problem?

推荐答案

我认为您必须使用body / binary中的choose file.我在github上创建问题时遇到了同样的问题.将属性放在body / raw / json中可以解决此问题.

I think you have to use choose file from body / binary. I've just had the same problem with creating an issue on github. Putting attributes in body / raw / json solved the problem.

更多推荐

解析JSON的400个问题

本文发布于:2023-10-29 09:27:49,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1539331.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:JSON

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!