Sreekanth TN
Sreekanth TN

Reputation: 91

How to connect Jira using Atlassian.SDK from .Net application (c#)

I am using Atlassian.SDK Jira SDk to connect Jira from my .NET application . To connect JIRA I have the following calls but it does not connect to Jira properly .I am getting unauthorized access exception

        var  jira = Jira.CreateRestClient("https://xxxxx.atlassian.net", "[email protected]", "xxx@xxx");


        CreateIssue(jira);

    public async void CreateIssue(Jira jira) {

        var issue = jira.CreateIssue("RBT");
        issue.Type = "Bug";
        issue.Priority = "Major";
        issue.Summary = "Issue Summary";

        await issue.SaveChangesAsync();
    }

which is the correct way to establish the connection .Also,How can i query all the created Issues

Upvotes: 2

Views: 2114

Answers (1)

Ian
Ian

Reputation: 711

With the assumption that you are using a Jira cloud instance (based on your instance name), basic authentication using password have been deprecated (see announcement), be sure to use email:apiToken pair when doing basic auth.

Upvotes: 1

Related Questions