500 Error In: /2.0/repositories/{account}/{project}/pipelines_config/variables/{UUID}

Hello,

 

I'm using curl to just poke around the 2.0 API, specifically trying to get a single variable. I'm trying:

```
curl --user [username]:[password] 'https://api.bitbucket.org/2.0/repositories/[my_account]/test-project/pipelines_config/variables/{[uuid]}'

```

But I receive an HTML page (booooo, this was a JSON API) 

```
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title>Error 500 Internal Server Error</title>
</head>
<body><h2>HTTP ERROR 500</h2>
<p>Problem accessing /rest/1.0/accounts/%7B[redacted]%7D/repositories/%7B[redacted]%7D/variables/[supplied uuid]. Reason:
<pre> Internal Server Error</pre></p>
</body>
</html>
```

Where the variables are replaced with my values, including the square brackets. I've confirmed the UUID is a valid UUID for my project and contains curly braces.

 

I am able to run:

```
curl --user [username]:[password] 'https://api.bitbucket.org/2.0/repositories/[my_account]/test-project/pipelines_config/variables/'

```

And see all the variables, but querying a specific one doesn't work. 

 

Reference documentation of endpoint: https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Busername%7D/%7Brepo_slug%7D/pipelines_config/variables/%7Bvariable_uuid%7D

1 answer

This widget could not be displayed.

Hi Seth, 

Thank you for reaching out to us. 

Can you please try and make a GET request using the following format: 

https://api.bitbucket.org/2.0/repositories/AccountName/repo_slug/pipelines_config/variables/%7BUUID%7D  

no brackets around UUID please or quotations. 

I have tested this request on my account and it works like a charm. 

I'll also respond to your Support ticket now.

Cheers.

Yana

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Aug 21, 2018 in Bitbucket

Branch Management with Bitbucket

As a project manager, I have discovered that different developers want to bring their previous branching method with them when they join the team. Some developers are used to performing individual wo...

1,191 views 8 10
Read article

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