Import Issue from Json for existing project.

Hello. Exploring opportunities Import external projects and Import from Json particularly.

I have a question - I can Import Issue from Json file, for existing project.

My json:

{
 "issues": [
        {
          "project":{"key":"MYPROJECT"},
          "priority": "Major",
          "description": "Some nice description?",
          "status": "Registered",
          "reporter": "Bob",
          "labels": [
            "impossible",
            "to",
            "test"
          ],
          "externalId": "1",
          "summary": "My chore for today",
          "assignee": "Bob"
        }
      ]
}

Resulting Exception:

java.lang.RuntimeException: org.codehaus.jackson.map.exc.UnrecognizedPropertyException: Unrecognized field "issues" (Class com.atlassian.jira.plugins.importer.sample.SampleData), not marked as ignorable


2 answers

I found that issues needs to be a child of project.  If the project is already there, it won't be imported but the system needs to know what project to load the issue to.  The below example worked for me.

{

    "projects": [

        {

            "name": "Requirements Management",

            "key": "RM",

            "issues": [

                {

                    "externalId": "159",

                    "issueType": "Story",

                    "summary": "RM Main Page - Commenting",

                    "status": "New Request",

                    "priority": "Medium",

                    "reporter": "Brian Larson",

                    "created": "2012-11-13T8:08:06.161+0100",

                    "description": "some txt"

                }

            ]

        }

    ]

}

Hello,

I have the same problem, it seems the importing plug-in is very broken?

Cheers

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

182 views 1 17
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you