我希望发出POST请求以在我的JIRA服务器上创建问题。我能够使用邮递员和基本身份验证成功请求,但我想使用承载方法。
这是我的curl命令:
curl --request POST--header 'Authorization: Bearer <token>'--header 'Accept: application/json'--header 'Content-Type: application/json'--data '{ "fields": { "project": {"key": "key"}, "summary": "Bug notification", "description": "THis is a test notification from cmd", "issuetype": {"name": "Bug"},"components": [{ "id": "0000"}], "priority": { "id": "2"}}}'--url 'https://server.atlassian.net/rest/api/2/issue'
有人可以指导我如何获得令牌,我已经梳理了很多文档,似乎没有什么比这更合适了吗?