Jira API authorisation error

Warren Levy Community Champion May 09, 2017

I have both VBA and C# code which calls the Jira REST API. All was working succesfully until the change to Atlassian account (for us in May 2017). Since then I cannot get past the authorisation error "Specified value has invalid HTTP Header characters".

The C# code that I'm using is below (which was working perfectly), where the credentials are base64 encoding of "email:password" for a valid authenticated user :

        public string RunQuery(string query, string argument = null, string data = null, string method = "GET")
                m_BaseUrl = query;
                HttpWebRequest newRequest = WebRequest.Create(m_BaseUrl) as HttpWebRequest;
                newRequest.ContentType = "application/json";
                newRequest.Method = method;

                if (data != null)
                    using (StreamWriter writer = new StreamWriter(newRequest.GetRequestStream()))

                string base64Credentials = GetEncodedCredentials();
                newRequest.Headers.Add("Authorization: ", "Basic " + base64Credentials);

                HttpWebResponse response = newRequest.GetResponse() as HttpWebResponse;

                string result = string.Empty;
                using (StreamReader reader = new StreamReader(response.GetResponseStream()))
                    result = reader.ReadToEnd();

                newRequest = null;
                response = null;

                return result;

Any help would be greatly appreciated

1 answer

We also had applications returning this error this morning.

Normal service seems to have resumed now.

I suggest testing again.

Warren Levy Community Champion May 09, 2017

Wow, 10 minutes ago it wasn't working, but it is now.


it came back at the same time as support.atlassian.com came back....

Suggest an answer

Log in or Join to answer
Community showcase
Maarten Cautreels
Posted Thursday in Off-topic

Friday Fun: What's your favourite beer/drink

As a Belgian, beer-lover and home brewer, beer is one of my great passions. I love the fact that with just a few ingredients (usually just water, hop and malt) you can create so many different tastes...

285 views 38 9
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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot