Documentation
¶
Index ¶
- Constants
- type Client
- func (c *Client) AddIssue(issue *Issue, notifiedUsers []*User) (*Issue, error)
- func (c *Client) AddIssueContext(ctx context.Context, issue *Issue, notifiedUsers []*User) (*Issue, error)
- func (c *Client) AddPullRequest(pullRequest *PullRequest, notifiedUsers []*User) (*PullRequest, error)
- func (c *Client) AddPullRequestContext(ctx context.Context, pullRequest *PullRequest, notifiedUsers []*User) (*PullRequest, error)
- func (c *Client) DeleteIssue(issueKeyOrId string) (*Issue, error)
- func (c *Client) DeleteIssueContext(ctx context.Context, issueKeyOrId string) (*Issue, error)
- func (c *Client) GetAllIssues() ([]*Issue, error)
- func (c *Client) GetAllIssuesContext(ctx context.Context) ([]*Issue, error)
- func (c *Client) GetAllPullRequests(projectIdOrKey, repositoryIdOrName string) ([]*PullRequest, error)
- func (c *Client) GetAllPullRequestsContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string) ([]*PullRequest, error)
- func (c *Client) GetIssue(issueKeyOrId string) (*Issue, error)
- func (c *Client) GetIssueComments(issueIdOrKey string, query url.Values) ([]*Comment, error)
- func (c *Client) GetIssueCommentsContext(ctx context.Context, issueIdOrKey string, query url.Values) ([]*Comment, error)
- func (c *Client) GetIssueContext(ctx context.Context, issueKeyOrId string) (*Issue, error)
- func (c *Client) GetIssueTypes(projectIdOrKey string) ([]*IssueType, error)
- func (c *Client) GetIssueTypesContext(ctx context.Context, projectIdOrKey string) ([]*IssueType, error)
- func (c *Client) GetIssues(query url.Values) ([]*Issue, error)
- func (c *Client) GetIssuesContext(ctx context.Context, query url.Values) ([]*Issue, error)
- func (c *Client) GetIssuesCount(query url.Values) (int64, error)
- func (c *Client) GetIssuesCountContext(ctx context.Context, query url.Values) (int64, error)
- func (c *Client) GetMyself() (*User, error)
- func (c *Client) GetMyselfContext(ctx context.Context) (*User, error)
- func (c *Client) GetNotifications(query url.Values) ([]*Notification, error)
- func (c *Client) GetNotificationsContext(ctx context.Context, query url.Values) ([]*Notification, error)
- func (c *Client) GetPriorities() ([]*Priority, error)
- func (c *Client) GetPrioritiesContext(ctx context.Context) ([]*Priority, error)
- func (c *Client) GetProject(projectKeyOrId string) (*Project, error)
- func (c *Client) GetProjectContext(ctx context.Context, projectKeyOrId string) (*Project, error)
- func (c *Client) GetProjectStatuses(projectIdOrKey string) ([]*ProjectStatus, error)
- func (c *Client) GetProjectStatusesContext(ctx context.Context, projectIdOrKey string) ([]*ProjectStatus, error)
- func (c *Client) GetProjects(query url.Values) ([]*Project, error)
- func (c *Client) GetProjectsContext(ctx context.Context, query url.Values) ([]*Project, error)
- func (c *Client) GetPullRequest(projectIdOrKey, repositoryIdOrName string, number int64) (*PullRequest, error)
- func (c *Client) GetPullRequestComments(projectKeyOrId, repositoryNameOrId, number string, query url.Values) ([]*Comment, error)
- func (c *Client) GetPullRequestCommentsContext(ctx context.Context, projectKeyOrId, repositoryNameOrId string, number string, ...) ([]*Comment, error)
- func (c *Client) GetPullRequestContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, number int64) (*PullRequest, error)
- func (c *Client) GetPullRequests(projectIdOrKey, repositoryIdOrName string, query url.Values) ([]*PullRequest, error)
- func (c *Client) GetPullRequestsContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, ...) ([]*PullRequest, error)
- func (c *Client) GetPullRequestsCount(projectIdOrKey, repositoryIdOrName string, query url.Values) (int64, error)
- func (c *Client) GetPullRequestsCountContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, ...) (int64, error)
- func (c *Client) GetRepositories(projectKeyOrId string, query url.Values) ([]*Repository, error)
- func (c *Client) GetRepositoriesContext(ctx context.Context, projectKeyOrId string, query url.Values) ([]*Repository, error)
- func (c *Client) GetRepository(projectKeyOrId, repositoryNameOrId string) (*Repository, error)
- func (c *Client) GetRepositoryContext(ctx context.Context, projectKeyOrId, repositoryNameOrId string) (*Repository, error)
- func (c *Client) GetSpace() (*Space, error)
- func (c *Client) GetSpaceContext(ctx context.Context) (*Space, error)
- func (c *Client) GetUsers() ([]*User, error)
- func (c *Client) GetUsersContext(ctx context.Context) ([]*User, error)
- func (c *Client) GetWiki(wikiId uint64) (*Wiki, error)
- func (c *Client) GetWikiContext(ctx context.Context, wikiId uint64) (*Wiki, error)
- func (c *Client) GetWikis(projectIdOrKey string, query url.Values) ([]*Wiki, error)
- func (c *Client) GetWikisContext(ctx context.Context, projectIdOrKey string, query url.Values) ([]*Wiki, error)
- func (c *Client) SetHTTPClient(hc HTTPClient)
- func (c *Client) UpdateIssue(issue *Issue, notifiedUsers []*User, comment string) (*Issue, error)
- func (c *Client) UpdateIssueContext(ctx context.Context, issue *Issue, notifiedUsers []*User, comment string) (*Issue, error)
- func (c *Client) UpdatePullRequest(pullRequest *PullRequest, notifiedUsers []*User, comment string) (*PullRequest, error)
- func (c *Client) UpdatePullRequestContext(ctx context.Context, pullRequest *PullRequest, notifiedUsers []*User, ...) (*PullRequest, error)
- type HTTPClient
Constants ¶
const ( V2IssuesPath = "/api/v2/issues" V2IssuesCountPath = "/api/v2/issues/count" )
const ( V2SpacePath = "/api/v2/space" V2SpaceActivitiesPath = "/api/v2/space/activities" V2SpaceImagePath = "/api/v2/space/image" V2SpaceNotificationPath = "/api/v2/space/notification" V2SpaceDiskUsagePath = "/api/v2/space/diskUsage" V2SpaceAttachmentPath = "/api/v2/space/attachment" )
const (
V2NotificationsPath = "/api/v2/notifications"
)
const (
V2PrioritiesPath = "/api/v2/priorities"
)
const (
V2ProjectsPath = "/api/v2/projects"
)
const (
V2UsersPath = "/api/v2/users"
)
const (
V2WikisPath = "/api/v2/wikis"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client provides API access.
func (*Client) AddIssue ¶
AddIssue adds new issue.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/add-issue/#add-issue
func (*Client) AddIssueContext ¶
func (c *Client) AddIssueContext(ctx context.Context, issue *Issue, notifiedUsers []*User) (*Issue, error)
AddIssueContext accepts context.
func (*Client) AddPullRequest ¶
func (c *Client) AddPullRequest(pullRequest *PullRequest, notifiedUsers []*User) (*PullRequest, error)
AddPullRequest Adds pull requests.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/add-pull-request/#add-pull-request
func (*Client) AddPullRequestContext ¶
func (c *Client) AddPullRequestContext(ctx context.Context, pullRequest *PullRequest, notifiedUsers []*User) (*PullRequest, error)
AddPullRequestContext accepts context.
func (*Client) DeleteIssue ¶
DeleteIssue deletes issue.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/delete-issue/#delete-issue
func (*Client) DeleteIssueContext ¶
DeleteIssueContext accepts context.
func (*Client) GetAllIssues ¶ added in v0.2.0
GetAllIssues returns all issues.
func (*Client) GetAllIssuesContext ¶ added in v0.2.0
GetAllIssuesContext accepts context.
func (*Client) GetAllPullRequests ¶ added in v0.2.0
func (c *Client) GetAllPullRequests(projectIdOrKey, repositoryIdOrName string) ([]*PullRequest, error)
GetAllPullRequests returns all pull requests.
func (*Client) GetAllPullRequestsContext ¶ added in v0.2.0
func (c *Client) GetAllPullRequestsContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string) ([]*PullRequest, error)
GetAllPullRequestsContext accepts context.
func (*Client) GetIssue ¶
GetIssue returns information about issue.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-issue/#get-issue
func (*Client) GetIssueComments ¶
GetIssueComments returns list of comments in issue.
https://developer.nulab.com/docs/backlog/api/2/get-comment-list/#get-comment-list
func (*Client) GetIssueCommentsContext ¶
func (*Client) GetIssueContext ¶
GetIssueContext accepts context.
func (*Client) GetIssueTypes ¶
GetIssueTypes returns list of Issue Types in the project.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-issue-type-list/#get-issue-type-list
func (*Client) GetIssueTypesContext ¶
func (c *Client) GetIssueTypesContext(ctx context.Context, projectIdOrKey string) ([]*IssueType, error)
GetIssueTypesContext accepts context.
func (*Client) GetIssues ¶
GetIssues returns list of issues.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-issue-list/#get-issue-list
func (*Client) GetIssuesContext ¶
GetIssuesContext accepts context.
func (*Client) GetIssuesCount ¶
GetIssuesCount returns number of issues.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/count-issue/#count-issue
func (*Client) GetIssuesCountContext ¶
GetIssuesCountContext accepts context.
func (*Client) GetMyself ¶
GetMyself returns own information about user.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-own-user/#get-own-user
func (*Client) GetMyselfContext ¶
GetMyselfContext accepts context.
func (*Client) GetNotifications ¶
GetNotifications returns own notifications.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-notification/#get-notification
func (*Client) GetNotificationsContext ¶
func (c *Client) GetNotificationsContext(ctx context.Context, query url.Values) ([]*Notification, error)
GetNotificationsContext accepts context.
func (*Client) GetPriorities ¶
GetPriorities returns list of priorities.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-priority-list/#get-priority-list
func (*Client) GetPrioritiesContext ¶
GetPrioritiesContext accepts context.
func (*Client) GetProject ¶
GetProject returns information about project.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-project/#get-project
func (*Client) GetProjectContext ¶
GetProjectContext accepts context.
func (*Client) GetProjectStatuses ¶
GetProjectStatuses returns list of status in the project.
For more details, see the API document.
func (*Client) GetProjectStatusesContext ¶
func (c *Client) GetProjectStatusesContext(ctx context.Context, projectIdOrKey string) ([]*ProjectStatus, error)
GetProjectStatuses accepts context.
func (*Client) GetProjects ¶
GetProjects returns list of projects.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-project-list/#get-project-list
func (*Client) GetProjectsContext ¶
GetProjectsContext accepts context.
func (*Client) GetPullRequest ¶
func (c *Client) GetPullRequest(projectIdOrKey, repositoryIdOrName string, number int64) (*PullRequest, error)
GetPullRequest returns pull reuqest.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-pull-request/#get-pull-request
func (*Client) GetPullRequestComments ¶
func (*Client) GetPullRequestCommentsContext ¶
func (*Client) GetPullRequestContext ¶
func (c *Client) GetPullRequestContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, number int64) (*PullRequest, error)
GetPullRequestContext accepts context.
func (*Client) GetPullRequests ¶
func (c *Client) GetPullRequests(projectIdOrKey, repositoryIdOrName string, query url.Values) ([]*PullRequest, error)
GetPullRequests returns list of pull requests.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-pull-request-list/#get-pull-request-list
func (*Client) GetPullRequestsContext ¶
func (c *Client) GetPullRequestsContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, query url.Values) ([]*PullRequest, error)
GetPullRequestsContext accepts context.
func (*Client) GetPullRequestsCount ¶
func (c *Client) GetPullRequestsCount(projectIdOrKey, repositoryIdOrName string, query url.Values) (int64, error)
GetPullRequestsCount returns number of pull requests.
For more details, see the API document.
func (*Client) GetPullRequestsCountContext ¶
func (c *Client) GetPullRequestsCountContext(ctx context.Context, projectIdOrKey, repositoryIdOrName string, query url.Values) (int64, error)
GetPullRequestsCountContext accepts context.
func (*Client) GetRepositories ¶
GetRepositories returns list of Git repositories.
For more details, see the API document.
func (*Client) GetRepositoriesContext ¶
func (c *Client) GetRepositoriesContext(ctx context.Context, projectKeyOrId string, query url.Values) ([]*Repository, error)
GetRepositoriesContext accepts context.
func (*Client) GetRepository ¶
GetRepository returns Git repository.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-git-repository/
func (*Client) GetRepositoryContext ¶
func (c *Client) GetRepositoryContext(ctx context.Context, projectKeyOrId, repositoryNameOrId string) (*Repository, error)
getRepositoryContext accepts context.
func (*Client) GetSpace ¶
GetSpace returns information about your space.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-space/#get-space
func (*Client) GetSpaceContext ¶
GetSpaceContext accepts context.
func (*Client) GetUsers ¶
GetUsers returns list of users in your space.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-user-list/#get-user-list
func (*Client) GetUsersContext ¶
GetUsersContext accepts context.
func (*Client) GetWiki ¶
GetWiki returns information about Wiki page.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-wiki-page/
func (*Client) GetWikiContext ¶
GetWikiContext accepts context.
func (*Client) GetWikis ¶
GetWikis returns list of Wiki pages.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/get-wiki-page-list/#get-wiki-page-list
func (*Client) GetWikisContext ¶
func (c *Client) GetWikisContext(ctx context.Context, projectIdOrKey string, query url.Values) ([]*Wiki, error)
GetWikisContext accepts context.
func (*Client) SetHTTPClient ¶
func (c *Client) SetHTTPClient(hc HTTPClient)
SetHTTPClient sets default HTTP client.
func (*Client) UpdateIssue ¶
UpdateIssue updates information about issue.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/update-issue/#update-issue
func (*Client) UpdateIssueContext ¶
func (c *Client) UpdateIssueContext(ctx context.Context, issue *Issue, notifiedUsers []*User, comment string) (*Issue, error)
UpdateIssueContext accepts context.
func (*Client) UpdatePullRequest ¶
func (c *Client) UpdatePullRequest(pullRequest *PullRequest, notifiedUsers []*User, comment string) (*PullRequest, error)
UpdatePullRequest updates pull requests.
For more details, see the API document.
https://developer.nulab.com/docs/backlog/api/2/update-pull-request/#update-pull-request