Jira sites differ. Spaces, issue types, statuses, priorities, resolutions, roles, and custom fields can vary between environments. DevOp.Jira.Client keeps those details discoverable through typed APIs so application code does not have to guess.
Atlassian's UI increasingly uses the word Space, while Jira REST APIs and JQL still use project. The client exposes client.Spaces for the user-facing concept and still calls Jira project APIs under the hood.
var spaces = await client.Spaces.GetAllAsync();
var space = await client.Spaces.GetAsync("PROJ");
In JQL, the generated query still uses Jira's project field.
var issues = await client.Issues.Query()
.ForSpace("PROJ")
.ToListAsync();
var currentUser = await client.Users.GetCurrentAsync();
var assignable = await client.Users.GetAssignableAsync("PROJ", query: "alex");
Use account IDs for user operations where Jira Cloud requires them.
Issue-related metadata is available from issue and metadata services.
var issueTypes = await client.Issues.GetSpaceIssueTypesAsync("PROJ");
var statuses = await client.Issues.GetSpaceStatusesAsync("PROJ");
var priorities = await client.Metadata.GetPrioritiesAsync();
var resolutions = await client.Metadata.GetResolutionsAsync();
var fields = await client.Metadata.GetFieldsAsync();
Use these APIs when automation should adapt to a Jira site instead of hardcoding every ID or field key.
var role = await client.Metadata.GetSpaceRoleAsync("PROJ", roleId: 10002);
Roles are site and space specific. Discover them in Jira or through metadata before depending on role IDs in automation.
Jira custom fields use site-specific keys such as customfield_12345. Configure a stable application name once and use that name in code.
services.AddJiraClient(options =>
{
options.BaseUrl = new Uri("https://your-domain.atlassian.net");
options.Email = "[email protected]";
options.ApiToken = "your-api-token";
options.CustomFieldMappings["Customer"] = "customfield_12345";
options.CustomFieldMappings["Team"] = "customfield_67890";
});
Then query using the stable name.
var customerIssues = await client.Issues.Query()
.ForCustomField("Customer", "ACME")
.ToListAsync();
Mapped values are available through Issue.Properties.
When a field key is not known ahead of time, resolve it from Jira metadata.
var customerFieldKey = await client.Metadata.ResolveCustomFieldKeyAsync("Customer");
This is useful for setup tools, diagnostics, and validation checks that need to confirm a Jira site is configured correctly.
If your Jira site has a dedicated team custom field, configure JiraClientOptions.TeamFieldKey. The mapped value appears on Issue.Team when available.
Customer or Team.