使用JIRA REST API POST时我会发送什么JSON?

时间:2014-02-08 13:43:25

标签: json post jira jira-rest-api

我正在使用 /rest/api/2/screens/{screenId}/tabs/{tabId}/fields 将字段POST到JIRA的标签中,但我无法弄清楚我应该如何构建我正在发布的JSON。

我收到此错误消息,这非常难以理解(并且Google提供的帮助很少): string(298) "{"errorMessages":["Unrecognized field \"id\" (Class com.atlassian.jira.rest.v2.issue.AddFieldBean), not marked as ignorable\n at [Source: org.apache.catalina.connector.CoyoteInputStream@5383f8a; line: 1, column: 8] (through reference chain: com.atlassian.jira.rest.v2.issue.AddFieldBean[\"id\"])"]}"

以下是我目前发送的JSON: '{"id":"customfield_11930","name":"1st Review Ready"}';

1 个答案:

答案 0 :(得分:0)

我找到了正确的JSON结构:{“fieldId”:“id”}