clubhouse

package module
v2.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2021 License: MIT Imports: 11 Imported by: 0

README

clubhouse-go

A Go Package for the Clubhouse API

This repo has been forked from https://github.com/djthorpe/clubhouse-go, as that repo has been archived but is missing (at least) some important structs.

Feel free to send PR's here, as long as they're accompanied by reasonable test cases. eg help keep this thing stable.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CHFile

type CHFile struct {
	ContentType  string    `json:"content_type"`
	CreatedAt    time.Time `json:"created_at"`
	Description  string    `json:"description"`
	Filename     string    `json:"filename"`
	ID           int64     `json:"id"`
	MentionIds   []string  `json:"mention_ids"`
	Name         string    `json:"name"`
	Size         int64     `json:"size"`
	StoryIds     []int64   `json:"story_ids"`
	ThumbnailURL string    `json:"thumbnail_url"`
	UpdatedAt    time.Time `json:"updated_at"`
	UploaderID   string    `json:"uploader_id"`
	URL          string    `json:"url"`
}

A CHFile is any document uploaded to your Clubhouse. Files attached from a third-party service can be accessed using the Linked Files endpoint.

type CHUpdateFile

type CHUpdateFile struct {
	CreatedAt   time.Time `json:"created_at"`
	Description string    `json:"description"`
	ExternalID  string    `json:"external_id"`
	Name        string    `json:"name"`
	UpdatedAt   time.Time `json:"updated_at"`
	UploaderID  string    `json:"uploader_id"`
}

CHUpdateFile is the body used for ch.FileUpdate()

type Category

type Category struct {
	Archived   bool      `json:"archived"`
	Color      string    `json:"color"`
	CreatedAt  time.Time `json:"created_at"`
	EntityType string    `json:"entity_type"`
	ExternalID int64     `json:"external_id"`
	ID         int64     `json:"id"`
	Name       string    `json:"name"`
	Type       string    `json:"type"`
	UpdatedAt  time.Time `json:"updated_at"`
}

type Clubhouse

type Clubhouse struct {
	Token  string
	Client *http.Client
	Debug  bool
}

Clubhouse is a struct containing the token, and the http.Client used for sending the data to the clubhouse API.

func New

func New(token string) *Clubhouse

New creates a new instance of the Clubhouse object that is used to send data to ClubHouse

func (*Clubhouse) CommentCreate

func (ch *Clubhouse) CommentCreate(newComment CreateComment, storyID int64) (Comment, error)

CommentCreate allows you to create a Comment on any Story. Calls POST https://api.clubhouse.io/api/v1/stories/{storyID}/comments

func (*Clubhouse) CommentDelete

func (ch *Clubhouse) CommentDelete(storyID int64, commentID int64) error

CommentDelete deletes a comment from any story. Calls DELETE https://api.clubhouse.io/api/v1/stories/{storyID}/comments/{commentID}

func (*Clubhouse) CommentGet

func (ch *Clubhouse) CommentGet(storyID int64, commentID int64) (Comment, error)

CommentGet is used to get Comment information. Calls GET https://api.clubhouse.io/api/v1/stories/{storyID}/comments/{commentID}

func (*Clubhouse) CommentUpdate

func (ch *Clubhouse) CommentUpdate(updatedComment UpdateComment, storyID int64, commentID int64) (Comment, error)

CommentUpdate replaces the text of the existing Comment. Calls PUT https://api.clubhouse.io/api/v1/stories/{storyID}/comments/{commentID}

func (*Clubhouse) CreateLabel

func (ch *Clubhouse) CreateLabel(newLabel CreateLabel) (LabelWithCounts, error)

func (*Clubhouse) CreateLinkedFiles

func (ch *Clubhouse) CreateLinkedFiles(newLinkedFile CreateLinkedFile) (LinkedFile, error)

func (*Clubhouse) CreateMultipleStories

func (ch *Clubhouse) CreateMultipleStories(newStories []CreateStory) ([]Story, error)

func (*Clubhouse) CreateProject

func (ch *Clubhouse) CreateProject(newProject CreateProject) (Project, error)

func (*Clubhouse) CreateStory

func (ch *Clubhouse) CreateStory(newStory CreateStory) (Story, error)
func (ch *Clubhouse) CreateStoryLink(newCreateStoryLink CreateStoryLink) (StoryLink, error)

func (*Clubhouse) CreateTask

func (ch *Clubhouse) CreateTask(newTask CreateTask, storyID int64) (Task, error)

func (*Clubhouse) DeleteLabel

func (ch *Clubhouse) DeleteLabel(labelID int64) error

func (*Clubhouse) DeleteLinkedFile

func (ch *Clubhouse) DeleteLinkedFile(fileID int64) error

func (*Clubhouse) DeleteProject

func (ch *Clubhouse) DeleteProject(projectID int64) error

func (*Clubhouse) DeleteStory

func (ch *Clubhouse) DeleteStory(storyID int64) error
func (ch *Clubhouse) DeleteStoryLink(storyLinkID int64) error

func (*Clubhouse) DeleteTask

func (ch *Clubhouse) DeleteTask(storyID int64, taskID int64) error

func (*Clubhouse) Download

func (ch *Clubhouse) Download(method, src, path string) (string, error)

Download downloads a URL to a path, which can be either an existing folder or a file within an existing folder

func (*Clubhouse) EpicCreate

func (ch *Clubhouse) EpicCreate(newEpic CreateEpic) (Epic, error)

EpicCreate allows you to create a new Epic in Clubhouse. Calls POST https://api.clubhouse.io/api/v1/epics/

func (*Clubhouse) EpicDelete

func (ch *Clubhouse) EpicDelete(epicID int64) error

EpicDelete can be used to delete the Epic. The only required parameter is Epic ID. Calls DELETE https://api.clubhouse.io/api/v1/epics/{epicID}

func (*Clubhouse) EpicGet

func (ch *Clubhouse) EpicGet(epicID int64) (Epic, error)

EpicGet returns information about the selected Epic. calls GET https://api.clubhouse.io/api/v1/epics/{epicID} to retrieve the specified epicID

func (*Clubhouse) EpicList

func (ch *Clubhouse) EpicList() ([]Epic, error)

EpicList returns a list of all Epics and their attributes. Calls GET https://api.clubhouse.io/api/v1/epics/

func (*Clubhouse) EpicUpdate

func (ch *Clubhouse) EpicUpdate(updatedEpic UpdateEpic, epicID int64) (Epic, error)

EpicUpdate can be used to update numerous fields in the Epic. The only required parameter is Epic ID, which can be found in the Clubhouse UI. calls PUT https://api.clubhouse.io/api/v1/epics/{epicID} and updates it with the data in the UpdateEpic object.

func (*Clubhouse) FileDelete

func (ch *Clubhouse) FileDelete(fileID int64) error

FileDelete can be used to delete any previously attached File. Calls DELETE https://api.clubhouse.io/api/v1/files/{fileID}

func (*Clubhouse) FileGet

func (ch *Clubhouse) FileGet(fileID int64) (CHFile, error)

FileGet returns information about the selected File. Calls GET https://api.clubhouse.io/api/v1/files/{fileID}

func (*Clubhouse) FileList

func (ch *Clubhouse) FileList() ([]CHFile, error)

FileList returns a list of all Files and related attributes in your Clubhouse. Calls GET https://api.clubhouse.io/api/v1/files

func (*Clubhouse) FileUpdate

func (ch *Clubhouse) FileUpdate(updatedFile CHUpdateFile, fileID int64) (CHFile, error)

FileUpdate can used to update the properties of a file uploaded to Clubhouse. Calls PUT https://api.clubhouse.io/api/v1/files/{fileID}

func (*Clubhouse) GetLinkedFile

func (ch *Clubhouse) GetLinkedFile(fileID int64) (LinkedFile, error)

func (*Clubhouse) GetMember

func (ch *Clubhouse) GetMember(memberID int64) (Member, error)

func (*Clubhouse) GetProject

func (ch *Clubhouse) GetProject(projectID int64) (Project, error)

func (*Clubhouse) GetStory

func (ch *Clubhouse) GetStory(storyID int64) (Story, error)
func (ch *Clubhouse) GetStoryLink(storyLinkID int64) (StoryLink, error)

func (*Clubhouse) GetTask

func (ch *Clubhouse) GetTask(storyID int64, taskID int64) (Task, error)

func (*Clubhouse) GetTeam

func (ch *Clubhouse) GetTeam(teamID int64) (Team, error)

func (*Clubhouse) ListCategories

func (ch *Clubhouse) ListCategories() ([]Category, error)

func (*Clubhouse) ListLabels

func (ch *Clubhouse) ListLabels() ([]LabelWithCounts, error)

func (*Clubhouse) ListLinkedFiles

func (ch *Clubhouse) ListLinkedFiles() ([]LinkedFile, error)

func (*Clubhouse) ListMembers

func (ch *Clubhouse) ListMembers() ([]Member, error)

func (*Clubhouse) ListMilestones

func (ch *Clubhouse) ListMilestones() ([]Milestone, error)

func (*Clubhouse) ListProjects

func (ch *Clubhouse) ListProjects() ([]Project, error)

func (*Clubhouse) ListStories

func (ch *Clubhouse) ListStories(projectID int64) ([]Story, error)

func (*Clubhouse) ListTeams

func (ch *Clubhouse) ListTeams() ([]Team, error)

func (*Clubhouse) ListWorkflow

func (ch *Clubhouse) ListWorkflow() ([]Workflow, error)

func (*Clubhouse) SetDebug

func (ch *Clubhouse) SetDebug(debug bool) *Clubhouse

Set the debug value

func (*Clubhouse) UpdateLabel

func (ch *Clubhouse) UpdateLabel(updatedLabel UpdateLabel, labelID int64) (LabelWithCounts, error)

func (*Clubhouse) UpdateLinkedFile

func (ch *Clubhouse) UpdateLinkedFile(updatedFile UpdateLinkedFile, fileID int64) (LinkedFile, error)

func (*Clubhouse) UpdateMultipleStories

func (ch *Clubhouse) UpdateMultipleStories(updatedStories []UpdateStory) ([]Story, error)

func (*Clubhouse) UpdateProject

func (ch *Clubhouse) UpdateProject(updatedProject UpdateProject, projectID int64) (Project, error)

func (*Clubhouse) UpdateStory

func (ch *Clubhouse) UpdateStory(updatedStory UpdateStory, storyID int64) (Story, error)

func (*Clubhouse) UpdateTask

func (ch *Clubhouse) UpdateTask(updatedTask UpdateTask, storyID int64, taskID int64) (Task, error)

type Comment

type Comment struct {
	AuthorID   string    `json:"author_id"`
	CreatedAt  time.Time `json:"created_at"`
	ID         int64     `json:"id"`
	MentionIds []string  `json:"mention_ids"`
	Position   int64     `json:"position"`
	StoryID    int64     `json:"story_id"`
	Text       string    `json:"text"`
	UpdatedAt  time.Time `json:"updated_at"`
}

A Comment is any note added within the Comment field of a Story.

type CreateComment

type CreateComment struct {
	AuthorID   string    `json:"author_id,omitempty"`
	CreatedAt  time.Time `json:"created_at,omitempty"`
	ExternalID string    `json:"external_id,omitempty"`
	Text       string    `json:"text"`
	UpdatedAt  time.Time `json:"updated_at,omitempty"`
}

CreateComment is the body used for ch.CommentCreate() Required fields are: CreateComment.Text

type CreateEpic

type CreateEpic struct {
	CreatedAt   time.Time `json:"created_at,omitempty"`
	Deadline    time.Time `json:"deadline,omitempty"`
	Description string    `json:"description,omitempty"`
	ExternalID  string    `json:"external_id,omitempty"`
	FollowerIds []string  `json:"follower_ids,omitempty"`
	Name        string    `json:"name"`
	OwnerIds    []string  `json:"owner_ids,omitempty"`
	State       string    `json:"state,omitempty"`
	UpdatedAt   time.Time `json:"updated_at,omitempty"`
}

CreateEpic is the object passed to Clubhouse API to create an epic. Required fields are: CreateEpic.Name

type CreateLabel

type CreateLabel struct {
	ExternalID string `json:"external_id,omitempty"`
	Name       string `json:"name"`
}

type CreateLinkedFile

type CreateLinkedFile struct {
	ContentType  string `json:"content_type"`
	Description  string `json:"description"`
	Name         string `json:"name"`
	Size         int64  `json:"size"`
	StoryID      int64  `json:"story_id,omitempty"`
	ThumbnailURL string `json:"thumbnail_url,omitempty"`
	Type         string `json:"type"`
	UploaderID   string `json:"uploader_id"`
	URL          string `json:"url"`
}

type CreateProject

type CreateProject struct {
	Abbreviation string    `json:"abbreviation"`
	Color        string    `json:"color"`
	CreatedAt    time.Time `json:"created_at"`
	Description  string    `json:"description"`
	ExternalID   string    `json:"external_id"`
	FollowerIds  []string  `json:"follower_ids"`
	Name         string    `json:"name"`
	UpdatedAt    time.Time `json:"updated_at"`
}

type CreateStory

type CreateStory struct {
	Comments        []CreateComment   `json:"comments"`
	CreatedAt       *time.Time        `json:"created_at,omitempty"`
	Deadline        *time.Time        `json:"deadline,omitempty"`
	Description     string            `json:"description"`
	EpicID          int64             `json:"epic_id,omitempty"`
	Estimate        int64             `json:"estimate"`
	ExternalID      string            `json:"external_id"`
	FileIds         []int64           `json:"file_ids"`
	FollowerIds     []string          `json:"follower_ids"`
	Labels          []CreateLabel     `json:"labels"`
	LinkedFileIds   []int64           `json:"linked_file_ids"`
	Name            string            `json:"name"`
	OwnerIds        []string          `json:"owner_ids"`
	ProjectID       int64             `json:"project_id"`
	RequestedByID   string            `json:"requested_by_id"`
	StoryLinks      []CreateStoryLink `json:"story_links"`
	StoryType       string            `json:"story_type"`
	Tasks           []CreateTask      `json:"tasks"`
	UpdatedAt       *time.Time        `json:"updated_at,omitempty"`
	WorkflowStateID int64             `json:"workflow_state_id"`
}
type CreateStoryLink struct {
	ObjectID  int64  `json:"object_id"`
	SubjectID int64  `json:"subject_id"`
	Verb      string `json:"verb"`
}

type CreateTask

type CreateTask struct {
	Complete    bool      `json:"complete"`
	CreatedAt   time.Time `json:"created_at"`
	Description string    `json:"description"`
	ExternalID  string    `json:"external_id"`
	OwnerIds    []string  `json:"owner_ids"`
	UpdatedAt   time.Time `json:"updated_at"`
}

type Epic

type Epic struct {
	Archived            bool              `json:"archived"`
	Comments            []ThreadedComment `json:"comments"`
	Completed           bool              `json:"completed"`
	CompletedAt         time.Time         `json:"completed_at"`
	CompletedAtOverride time.Time         `json:"completed_at_override"`
	CreatedAt           time.Time         `json:"created_at"`
	Deadline            time.Time         `json:"deadline"`
	Description         string            `json:"description"`
	EpicStateID         int64             `json:"epic_state_id"`
	ExternalID          int64             `json:"external_id"`
	FollowerIds         []string          `json:"follower_ids"`
	ID                  int64             `json:"id"`
	Labels              []Label           `json:"labels"`
	MentionIds          []string          `json:"mention_ids"`
	MilestoneID         int64             `json:"milestone_id"`
	Name                string            `json:"name"`
	OwnerIds            []string          `json:"owner_ids"`
	Position            int64             `json:"position"`
	ProjectIds          []int64           `json:"project_ids"`
	RequestedByID       string            `json:"requested_by_id"`
	Started             bool              `json:"started"`
	StartedAt           time.Time         `json:"started_at"`
	StartedAtOverride   time.Time         `json:"started_at_override"`
	State               string            `json:"state"`
	UpdatedAt           time.Time         `json:"updated_at"`
}

An Epic is a collection of stories that together might make up a release, a milestone, or some other large initiative that your organization is working on.

type Label

type Label struct {
	Archived   bool      `json:"archived"`
	Color      string    `json:"color"`
	CreatedAt  time.Time `json:"created_at"`
	EntityType string    `json:"entity_type"`
	ExternalID int64     `json:"external_id"`
	ID         int64     `json:"id"`
	Name       string    `json:"name"`
	UpdatedAt  time.Time `json:"updated_at"`
}

type LabelWithCounts

type LabelWithCounts struct {
	Archived   bool      `json:"archived"`
	Color      string    `json:"color"`
	CreatedAt  time.Time `json:"created_at"`
	EntityType string    `json:"entity_type"`
	ExternalID int64     `json:"external_id"`
	ID         int64     `json:"id"`
	Name       string    `json:"name"`
	Stats      struct {
		NumEpics              int64 `json:"num_epics"`
		NumPointsCompleted    int64 `json:"num_points_completed"`
		NumPointsInProgress   int64 `json:"num_points_in_progress"`
		NumPointsTotal        int64 `json:"num_points_total"`
		NumStoriesCompleted   int64 `json:"num_stories_completed"`
		NumStoriesInProgress  int64 `json:"num_stories_in_progress"`
		NumStoriesTotal       int64 `json:"num_stories_total"`
		NumStoriesUnestimated int64 `json:"num_stories_unestimated"`
	}
	UpdatedAt time.Time `json:"updated_at"`
}

type LinkedFile

type LinkedFile struct {
	ContentType  string    `json:"content_type"`
	CreatedAt    time.Time `json:"created_at"`
	Description  string    `json:"description"`
	ID           int64     `json:"id"`
	MentionIds   []string  `json:"mention_ids"`
	Name         string    `json:"name"`
	Size         int64     `json:"size"`
	StoryIds     []int64   `json:"story_ids"`
	ThumbnailURL string    `json:"thumbnail_url"`
	Type         string    `json:"type"`
	UpdatedAt    time.Time `json:"updated_at"`
	UploaderID   string    `json:"uploader_id"`
	URL          string    `json:"url"`
}

type Member

type Member struct {
	ID                   string        `json:"id"`
	CreatedAt            time.Time     `json:"created_at"`
	CreatedWithoutInvite bool          `json:"created_without_invite"`
	Disabled             bool          `json:"disabled"`
	GroupIds             []interface{} `json:"group_ids"`
	Profile              Profile       `json:"profile"`
	Role                 string        `json:"role"`
	State                string        `json:"state"`
	UpdatedAt            time.Time     `json:"updated_at"`
}

type Milestone

type Milestone struct {
	Categories          []Category `json:"categories"`
	Completed           bool       `json:"completed"`
	CompletedAt         time.Time  `json:"completed_at"`
	CompletedAtOverride time.Time  `json:"completed_at_override"`
	CreatedAt           time.Time  `json:"created_at"`
	Description         string     `json:"description"`
	EntityType          string     `json:"entity_type"`
	ID                  int64      `json:"id"`
	Name                string     `json:"name"`
	Position            int64      `json:"position"`
	Started             bool       `json:"started"`
	StartedAt           time.Time  `json:"started_at"`
	StartedAtOverride   time.Time  `json:"started_at_override"`
	State               string     `json:"state"`
	UpdatedAt           time.Time  `json:"updated_at"`
}

type Profile

type Profile struct {
	Deactivated            bool   `json:"deactivated"`
	EmailAddress           string `json:"email_address"`
	GravatarHash           string `json:"gravatar_hash"`
	Membername             string `json:"membername"`
	MentionName            string `json:"mention_name"`
	Name                   string `json:"name"`
	TwoFactorAuthActivated bool   `json:"two_factor_auth_activated"`
}

type Project

type Project struct {
	Abbreviation string    `json:"abbreviation"`
	Archived     bool      `json:"archived"`
	Color        string    `json:"color"`
	CreatedAt    time.Time `json:"created_at"`
	Description  string    `json:"description"`
	FollowerIds  []string  `json:"follower_ids"`
	ID           int64     `json:"id"`
	Name         string    `json:"name"`
	NumPoints    int64     `json:"num_points"`
	NumStories   int64     `json:"num_stories"`
	UpdatedAt    time.Time `json:"updated_at"`
	TeamID       int64     `json:"team_id"`
}

type SearchStory

type SearchStory struct {
	Archived           bool      `json:"archived,omitempty"`
	CreatedAtEnd       time.Time `json:"created_at_end,omitempty"`
	CreatedAtStart     time.Time `json:"created_at_start,omitempty"`
	EpicID             int64     `json:"epic_id,omitempty"`
	EpicIds            []int64   `json:"epic_ids,omitempty"`
	Estimate           int64     `json:"estimate,omitempty"`
	LabelName          string    `json:"label_name,omitempty"`
	OwnerID            string    `json:"owner_id,omitempty"`
	OwnerIds           []string  `json:"owner_ids,omitempty"`
	ProjectID          int64     `json:"project_id,omitempty"`
	ProjectIds         []int64   `json:"project_ids,omitempty"`
	RequestedByID      string    `json:"requested_by_id,omitempty"`
	StoryType          string    `json:"story_type,omitempty"`
	Text               string    `json:"text,omitempty"`
	UpdatedAtEnd       time.Time `json:"updated_at_end,omitempty"`
	UpdatedAtStart     time.Time `json:"updated_at_start,omitempty"`
	WorkflowStateID    int64     `json:"workflow_state_id,omitempty"`
	WorkflowStateTypes []string  `json:"workflow_state_types,omitempty"`
}

type State

type State struct {
	Color       string `json:"color"`
	CreatedAt   string `json:"created_at"`
	Description string `json:"description"`
	ID          int64  `json:"id"`
	Name        string `json:"name"`
	NumStories  int64  `json:"num_stories"`
	Position    int64  `json:"position"`
	Type        string `json:"type"`
	UpdatedAt   string `json:"updated_at"`
	Verb        string `json:"verb"`
}

type Story

type Story struct {
	Archived        bool        `json:"archived"`
	Comments        []Comment   `json:"comments"`
	CreatedAt       time.Time   `json:"created_at"`
	Deadline        string      `json:"deadline"`
	Description     string      `json:"description"`
	EpicID          int64       `json:"epic_id"`
	Estimate        int64       `json:"estimate"`
	FileIds         []int64     `json:"file_ids"`
	FollowerIds     []string    `json:"follower_ids"`
	ID              int64       `json:"id"`
	Labels          []Label     `json:"labels"`
	LinkedFileIds   []int64     `json:"linked_file_ids"`
	Name            string      `json:"name"`
	OwnerIds        []string    `json:"owner_ids"`
	Position        int64       `json:"position"`
	ProjectID       int64       `json:"project_id"`
	RequestedByID   string      `json:"requested_by_id"`
	StoryLinks      []StoryLink `json:"story_links"`
	StoryType       string      `json:"story_type"`
	Tasks           []Task      `json:"tasks"`
	UpdatedAt       time.Time   `json:"updated_at"`
	WorkflowStateID int64       `json:"workflow_state_id"`
}
type StoryLink struct {
	CreatedAt time.Time `json:"created_at"`
	ID        int64     `json:"id"`
	ObjectID  int64     `json:"object_id"`
	SubjectID int64     `json:"subject_id"`
	UpdatedAt time.Time `json:"updated_at"`
	Verb      string    `json:"verb"`
}

type Task

type Task struct {
	Complete    bool      `json:"complete"`
	CompletedAt time.Time `json:"completed_at"`
	CreatedAt   time.Time `json:"created_at"`
	Description string    `json:"description"`
	ID          int64     `json:"id"`
	MentionIds  []string  `json:"mention_ids"`
	OwnerIds    []string  `json:"owner_ids"`
	Position    int64     `json:"position"`
	StoryID     int64     `json:"story_id"`
	UpdatedAt   time.Time `json:"updated_at"`
}

type Team

type Team struct {
	CreatedAt   *time.Time `json:"created_at"`
	Description string     `json:"description"`
	EntityType  string     `json:"entity_type"`
	ID          int64      `json:"id"`
	Name        string     `json:"name"`
	Position    int64      `json:"position"`
	ProjectIDs  []int64    `json:"project_ids"`
	UpdatedAt   *time.Time `json:"updated_at"`
	Workflow    Workflow
	TeamID      int64 `json:"team_id"`
}

type ThreadedComment

type ThreadedComment struct {
	AuthorID   string            `json:"author_id"`
	CreatedAt  time.Time         `json:"created_at"`
	Deleted    bool              `json:"deleted"`
	ID         int64             `json:"id"`
	MentionIds []string          `json:"mention_ids"`
	Position   int64             `json:"position"`
	Text       string            `json:"text"`
	UpdatedAt  time.Time         `json:"updated_at"`
	Comments   []ThreadedComment `json:"comments"`
}

ThreadedComment are comments associated with Epic Discussions

type UpdateComment

type UpdateComment struct {
	Text string `json:"text"`
}

UpdateComment is the body used for ch.CommentUpdate()

type UpdateEpic

type UpdateEpic struct {
	AfterID     int64     `json:"after_id,omitempty"`
	Archived    bool      `json:"archived,omitempty"`
	BeforeID    int64     `json:"before_id,omitempty"`
	Deadline    time.Time `json:"deadline,omitempty"`
	Description string    `json:"description,omitempty"`
	FollowerIds []string  `json:"follower_ids,omitempty"`
	Name        string    `json:"name,omitempty"`
	OwnerIds    []string  `json:"owner_ids,omitempty"`
	State       string    `json:"state,omitempty"`
}

UpdateEpic the body used for ch.EpicUpdate()

type UpdateLabel

type UpdateLabel struct {
	Name string `json:"name"`
}

type UpdateLinkedFile

type UpdateLinkedFile struct {
	Description  string `json:"description"`
	Name         string `json:"name"`
	Size         string `json:"size"`
	ThumbnailURL string `json:"thumbnail_url"`
	Type         string `json:"type"`
	UploaderID   string `json:"uploader_id"`
	URL          string `json:"url"`
}

type UpdateProject

type UpdateProject struct {
	Abbreviation string   `json:"abbreviation"`
	Archived     bool     `json:"archived"`
	Color        string   `json:"color"`
	Description  string   `json:"description"`
	FollowerIds  []string `json:"follower_ids"`
	Name         string   `json:"name"`
}

type UpdateStory

type UpdateStory struct {
	AfterID         int64         `json:"after_id"`
	Archived        bool          `json:"archived"`
	BeforeID        int64         `json:"before_id"`
	Deadline        string        `json:"deadline"`
	Description     string        `json:"description"`
	EpicID          int64         `json:"epic_id"`
	Estimate        int64         `json:"estimate"`
	FileIds         []int64       `json:"file_ids"`
	FollowerIds     []string      `json:"follower_ids"`
	Labels          []CreateLabel `json:"labels"`
	LinkedFileIds   []int64       `json:"linked_file_ids"`
	Name            string        `json:"name"`
	OwnerIds        []string      `json:"owner_ids"`
	ProjectID       int64         `json:"project_id"`
	RequestedByID   string        `json:"requested_by_id"`
	StoryType       string        `json:"story_type"`
	WorkflowStateID int64         `json:"workflow_state_id"`
}

type UpdateTask

type UpdateTask struct {
	AfterID     int64    `json:"after_id"`
	BeforeID    int64    `json:"before_id"`
	Complete    bool     `json:"complete"`
	Description string   `json:"description"`
	OwnerIds    []string `json:"owner_ids"`
}

type Workflow

type Workflow struct {
	CreatedAt      string  `json:"created_at"`
	DefaultStateID int64   `json:"default_state_id"`
	ID             int64   `json:"id"`
	Name           string  `json:"name"`
	States         []State `json:"states"`
	UpdatedAt      string  `json:"updated_at"`
	TeamID         int64   `json:"team_id"`
}

Jump to

Keyboard shortcuts

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