Versions in this module Expand all Collapse all v0 v0.11.0 Apr 1, 2026 Changes in this version + const GhTokenEnv v0.10.0 Jan 11, 2026 v0.9.0 Jan 4, 2026 v0.8.0 Jan 1, 2026 v0.7.0 Dec 30, 2025 v0.6.0 Dec 29, 2025 Changes in this version + const HolonTokenEnv type Client + func (c *Client) FetchWorkflowLogs(ctx context.Context, detailsURL string) ([]byte, error) v0.5.0 Dec 29, 2025 v0.4.0 Dec 29, 2025 Changes in this version + const DefaultBaseURL + const DefaultTimeout + const HolonRepoName + const HolonRepoOwner + const LegacyTokenEnv + const TokenEnv + const VersionCheckCacheFile + const VersionCheckCacheTTL + const VersionCheckEnvVar + func GetTokenFromEnv() (string, bool) + func IsAuthenticationError(err error) bool + func IsNotFoundError(err error) bool + func IsRateLimitError(err error) bool + func IsRetryableError(err error) bool + func IsValidGitHubRef(ref string) bool + type APIError struct + Errors []APIErrorDetail + Message string + RateLimit *RateLimitInfo + StatusCode int + func (e *APIError) Error() string + type APIErrorDetail struct + Code string + Field string + Message string + Resource string + type ActorInfo struct + AppSlug string + Login string + Source string + Type string + type CheckRun struct + AppSlug string + CheckSuiteID int64 + CompletedAt *time.Time + Conclusion string + DetailsURL string + HeadSHA string + ID int64 + Name string + Output CheckRunOutput + StartedAt *time.Time + Status string + type CheckRunOutput struct + Summary string + Text string + Title string + type CheckRunsResponse struct + CheckRuns []CheckRun + TotalCount int + type Client struct + func NewClient(token string, opts ...ClientOption) *Client + func NewClientFromEnv(opts ...ClientOption) (*Client, error) + func (c *Client) CreateIssue(ctx context.Context, owner, repo, title, body string, labels []string) (string, error) + func (c *Client) CreateIssueComment(ctx context.Context, owner, repo string, issueNumber int, body string) (int64, error) + func (c *Client) CreatePullRequest(ctx context.Context, owner, repo string, newPR *NewPullRequest) (*PRInfo, error) + func (c *Client) CreatePullRequestComment(ctx context.Context, owner, repo string, prNumber int, body string, ...) (int64, error) + func (c *Client) Do(req *http.Request, result interface{}) (*ClientResponse, error) + func (c *Client) EditIssueComment(ctx context.Context, owner, repo string, commentID int64, body string) error + func (c *Client) FetchCheckRuns(ctx context.Context, owner, repo, ref string, maxResults int) ([]CheckRun, error) + func (c *Client) FetchCombinedStatus(ctx context.Context, owner, repo, ref string) (*CombinedStatus, error) + func (c *Client) FetchIssueComments(ctx context.Context, owner, repo string, issueNumber int) ([]IssueComment, error) + func (c *Client) FetchIssueInfo(ctx context.Context, owner, repo string, issueNumber int) (*IssueInfo, error) + func (c *Client) FetchLatestHolonRelease(ctx context.Context, owner, repo string) (*ReleaseInfo, error) + func (c *Client) FetchLatestRelease(ctx context.Context, owner, repo string) (*ReleaseInfo, error) + func (c *Client) FetchPRDiff(ctx context.Context, owner, repo string, prNumber int) (string, error) + func (c *Client) FetchPRInfo(ctx context.Context, owner, repo string, prNumber int) (*PRInfo, error) + func (c *Client) FetchReviewThreads(ctx context.Context, owner, repo string, prNumber int, unresolvedOnly bool) ([]ReviewThread, error) + func (c *Client) GetCurrentUser(ctx context.Context) (*ActorInfo, error) + func (c *Client) GetRateLimitStatus() (RateLimitStatus, error) + func (c *Client) GetToken() string + func (c *Client) GitHubClient() *github.Client + func (c *Client) ListIssueComments(ctx context.Context, owner, repo string, issueNumber int) ([]IssueComment, error) + func (c *Client) ListPullRequestComments(ctx context.Context, owner, repo string, prNumber int) ([]*github.PullRequestComment, error) + func (c *Client) ListPullRequests(ctx context.Context, owner, repo string, state string) ([]*PRInfo, error) + func (c *Client) NewRequest(ctx context.Context, method, url string, body io.Reader) (*http.Request, error) + func (c *Client) SetBaseURL(baseURL string) + func (c *Client) SetToken(token string) + func (c *Client) UpdatePullRequest(ctx context.Context, owner, repo string, prNumber int, title, body string) (*PRInfo, error) + type ClientOption func(*Client) + func WithBaseURL(baseURL string) ClientOption + func WithHTTPClient(client *http.Client) ClientOption + func WithRateLimitTracking(enabled bool) ClientOption + func WithRetryConfig(config *RetryConfig) ClientOption + func WithTimeout(timeout time.Duration) ClientOption + type ClientResponse struct + func (r *ClientResponse) Close() error + func (r *ClientResponse) DecodeJSON(v interface{}) error + func (r *ClientResponse) ReadAll() ([]byte, error) + type CombinedStatus struct + SHA string + State string + Statuses []Status + TotalCount int + type IssueComment struct + Author string + Body string + CommentID int64 + CreatedAt time.Time + URL string + UpdatedAt time.Time + type IssueInfo struct + Assignee string + Author string + Body string + CreatedAt time.Time + Labels []string + Number int + Repository string + State string + Title string + URL string + UpdatedAt time.Time + type ListOptions struct + Direction string + Page int + PerPage int + Since time.Time + Sort string + State string + func DefaultListOptions() *ListOptions + func (lo *ListOptions) ApplyToURL(baseURL string) string + type NewPullRequest struct + Base string + Body string + Head string + MaintainerCanModify bool + Title string + type PRInfo struct + Author string + BaseRef string + BaseSHA string + Body string + CreatedAt time.Time + HeadRef string + HeadSHA string + MergeCommit string + Number int + Repository string + State string + Title string + URL string + UpdatedAt time.Time + type PageResult struct + Error error + HasMore bool + Items interface{} + Response *Response + type Paginator struct + func NewPaginator(client *Client, opts *ListOptions) *Paginator + func (p *Paginator) FetchAll(ctx context.Context, urlStr string) ([]interface{}, error) + func (p *Paginator) FetchPage(ctx context.Context, urlStr string, page int) (*PageResult, error) + func (p *Paginator) FetchPageChan(ctx context.Context, url string) <-chan *PageResult + func (p *Paginator) SetMaxResults(max int) + type RateLimitInfo struct + Limit int + Remaining int + Reset int64 + Used int + type RateLimitStatus struct + Limit int + Remaining int + Reset time.Time + Used int + type RateLimitTracker struct + func NewRateLimitTracker() *RateLimitTracker + func (r *RateLimitTracker) GetStatus() RateLimitStatus + func (r *RateLimitTracker) Update(resp *http.Response) + func (r *RateLimitTracker) WaitForRateLimitReset(ctx context.Context) error + type Recorder struct + func NewRecorder(t *testing.T, name string) (*Recorder, error) + func (r *Recorder) HTTPClient() *http.Client + func (r *Recorder) IsRecording() bool + func (r *Recorder) Mode() recorderMode + func (r *Recorder) Stop() error + type Ref struct + BaseBranch string + Kind RefType + Number int + Owner string + Repo string + func ParseRef(target string) (*Ref, error) + func (r *Ref) String() string + type RefType int + const RefTypeIssue + const RefTypePR + const RefTypeRepo + type ReleaseInfo struct + Draft bool + HTMLURL string + Name string + Prerelease bool + PublishedAt time.Time + TagName string + func CheckForUpdates(ctx context.Context, currentVersion string) (*ReleaseInfo, bool, error) + type Reply struct + Author string + Body string + CommentID int64 + CreatedAt time.Time + InReplyToID int64 + URL string + UpdatedAt time.Time + type Response struct + Count int + FirstPage int + LastPage int + NextPage int + PrevPage int + RateLimit *RateLimitStatus + TotalCount int + type RetryConfig struct + BaseDelay time.Duration + MaxAttempts int + MaxDelay time.Duration + RetryOn []int + func DefaultRetryConfig() *RetryConfig + func (rc *RetryConfig) GetDelay(attempt int) time.Duration + func (rc *RetryConfig) ShouldRetry(statusCode int) bool + type ReviewThread struct + Author string + Body string + CommentID int64 + CreatedAt time.Time + DiffHunk string + InReplyToID int64 + Line int + Path string + Position int + Replies []Reply + Resolved bool + Side string + StartLine int + StartSide string + URL string + UpdatedAt time.Time + type SolveRef struct + Number int + Owner string + Repo string + Type SolveRefType + func ParseSolveRef(ref string, defaultRepo string) (*SolveRef, error) + func (r *SolveRef) String() string + func (r *SolveRef) URL() string + type SolveRefType int + const SolveRefTypeIssue + const SolveRefTypePR + type Status struct + Context string + CreatedAt time.Time + Description string + ID int64 + State string + TargetURL string + UpdatedAt time.Time v0.3.0 Dec 29, 2025 v0.2.0 Dec 28, 2025