jira

package
v0.52.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2025 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JiraToStruct

func JiraToStruct[T any](client *Client, dom fdomain.Domain, issueKey string) (T, error)

JiraToStruct is the main function that domains use to convert JIRA issues to config structs It loads the specified domain's JIRA schema and maps the issue fields

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client represents a JIRA API client

func NewClient

func NewClient(baseURL, username, token string) (*Client, error)

NewClient creates a new JIRA client with the provided authentication token

func NewClientFromDomain

func NewClientFromDomain(dom fdomain.Domain) (*Client, error)

NewClientFromDomain creates a JIRA client using domain configuration and environment variables

func (*Client) GetIssue

func (c *Client) GetIssue(issueKey string, fields []string) (*JiraIssue, error)

GetIssue fetches a JIRA issue by key. If fields is empty, Jira returns all default fields.

type JiraIssue

type JiraIssue struct {
	Key    string         `json:"key"`
	Fields map[string]any `json:"fields"`
}

JiraIssue represents a JIRA issue response

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL