Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How can I know a jira project's projectTemplateKey?

I found a document: https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-projects/#api-rest-api-3-project-get which has rest api to create jira project , and projectTemplateKey in request body.
When I create a jira project by rest api, I want an existed jira project as template.
How can I know the existed jira project's projectTemplateKey?

1 answer

1 accepted

0 votes
Answer accepted
Prince Nyeche Community Leader Nov 12, 2020

Hi @Ronaldo Huang 

Welcome to community, I think you're referring to the shared template API.

/rest/project-templates/1.0/createshared/{projectId} 

Where ProjectId is the id of the existing project.

However that API is not official if you're using Cloud, so I wouldn't rely on it so much but you can test it to see if it works for you!

Wow! It really works.

But I'm confused that why that API is not official? ^_^

@Prince Nyeche 

Wow! It really works.

But I'm confused that why that API is not official? ^_^

Prince Nyeche Community Leader Nov 12, 2020

It's because, most of the time users wouldn't really want to create a project based of another Project from an API perspective. Likewise if the API is not documented on Atlassian developer pages it isn't official. which means it can stop working at any time without any prior notification to you the user. 

Like Ronaldo Huang likes this

@Prince Nyeche 

Oh, I see. I hope it never stop working. It's useful for me. ^_^

Hello,

@Ronaldo Huang 

Could you tell me how you made the api work and what value you put between the keys please.

@Victor Daniel Tobon Carrizosa 

The request body is:

{

"key":"",

"name":"",

"projectTypeKey":"",

"lead":"",

"description":""

}

@Ronaldo Huang 

 

The body is clear to me, in fact I can generate a project automatically, but I want to obtain the templey of my project so that when I create it, that is always used as I can obtain them.

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you