Documentation
¶
Index ¶
- Constants
- Variables
- func CreateFolderTask(ctx context.Context, folderID string, update TaskUpdate, resp *ResponseTasks) (err error)
- func CreateTaskAttachment(ctx context.Context, taskID string, filename string, body io.ReadCloser) error
- func CreateTaskComment(ctx context.Context, taskID string, text string, response *ResponseComments) (err error)
- func DownloadAttachment(ctx context.Context, attachID string) (body io.ReadCloser, err error)
- func GetAccount(ctx context.Context, response *ResponseAccount) (err error)
- func GetApprovals(ctx context.Context, values url.Values, response *ResponseApprovals) (err error)
- func GetBookings(ctx context.Context, values url.Values, response *ResponseBookings) (err error)
- func GetComments(ctx context.Context, response *ResponseComments) (err error)
- func GetContact(ctx context.Context, contactID string, response *ResponseUsers) (err error)
- func GetContacts(ctx context.Context, response *ResponseUsers) (err error)
- func GetCustomField(ctx context.Context, customFieldID string, response *ResponseCustomFields) (err error)
- func GetCustomFields(ctx context.Context, response *ResponseCustomFields) (err error)
- func GetFolder(ctx context.Context, folderId string, response *ResponseFolders) error
- func GetFolderAttachments(ctx context.Context, folderID string, response *ResponseAttachments) (err error)
- func GetFolders(ctx context.Context, response *ResponseFolders) error
- func GetGroup(ctx context.Context, groupID string, response *ResponseGroups) (err error)
- func GetGroups(ctx context.Context, response *ResponseGroups) (err error)
- func GetInvitation(ctx context.Context, contactID string, response *ResponseInvitations) (err error)
- func GetInvitations(ctx context.Context, response *ResponseInvitations) (err error)
- func GetJobRole(ctx context.Context, id string, response *ResponseJobRoles) error
- func GetJobRoles(ctx context.Context, values url.Values, response *ResponseJobRoles) (err error)
- func GetSpaceFolders(ctx context.Context, spaceId string, response *ResponseFolders) error
- func GetSubFolders(ctx context.Context, folderId string, response *ResponseFolders) error
- func GetTaskAttachments(ctx context.Context, taskID string, response *ResponseAttachments) (err error)
- func GetTasks(ctx context.Context, values url.Values, response *ResponseTasks) (err error)
- func GetTimeLogs(ctx context.Context, response *ResponseTimeLogs) error
- func GetUser(ctx context.Context, userId string, response *ResponseUsers) error
- func GetWorkSchedule(ctx context.Context, scheduleID string, response *ResponseWorkSchedules) (err error)
- func GetWorkSchedules(ctx context.Context, values url.Values, response *ResponseWorkSchedules) (err error)
- func GetWorkflows(ctx context.Context, response *ResponseWorkflows) (err error)
- func Request(ctx context.Context, method string, url string, reader io.ReadCloser, ...) (body io.ReadCloser, header http.Header, err error)
- func UpdateTask(ctx context.Context, taskID string, update TaskUpdate, resp *ResponseTasks) (err error)
- type Account
- type AccountCustomField
- type Approval
- type Attachment
- type Booking
- type BookingDates
- type BookingEffortAllocation
- type Comment
- type Customfield
- type Decisions
- type Dependence
- type EffortAllocation
- type Field
- type Fields
- type Folder
- type Group
- type Invitation
- type JobRole
- type Metadata
- type Metadatas
- type Profile
- type Project
- type ResponseAccount
- type ResponseApprovals
- type ResponseAttachments
- type ResponseBookings
- type ResponseComments
- type ResponseCustomFields
- type ResponseDependence
- type ResponseFolders
- type ResponseGroups
- type ResponseInvitations
- type ResponseJobRoles
- type ResponseTasks
- type ResponseTimeLogs
- type ResponseUsers
- type ResponseWorkSchedules
- type ResponseWorkflows
- type ResponsibleAllocation
- type Subscription
- type Task
- type TaskDate
- type TaskUpdate
- type TimeLog
- type User
- type WorkSchedule
- type Workflow
Constants ¶
View Source
const (
CommentsPath = "/comments"
)
Variables ¶
View Source
var GetApproval = getApprovals(approvalPath)
View Source
var GetCategoryTimeLogs = getTimeLogs(categoryTimelogsPath)
GetCategoryTimeLogs GetCategoryTimeLogs Get all timelog records with specific timelog category.
View Source
var GetContactTimeLogs = getTimeLogs(contactTimelogsPath)
GetContactTimeLogs Get all timelog records that were created by the user.
View Source
var GetFolderApproval = getApprovals(folderApprovalsPath)
View Source
var GetFolderComments = getComments(folderCommentsPath)
View Source
var GetFolderTasks = getTasks(folderTasksPath)
View Source
var GetFolderTimeLogs = getTimeLogs(folderTimelogsPath)
GetFolderTimeLogs Get all timelog records for a folder.
View Source
var GetSpaceTasks = getTasks(spaceTasksPath)
View Source
var GetTask = getTasks(taskPath)
View Source
var GetTaskComments = getComments(taskCommentsPath)
View Source
var GetTaskTimeLogs = getTimeLogs(taskTimelogsPath)
GetTaskTimeLogs Get all timelog records for a task.
View Source
var GetTaskrApproval = getApprovals(taskApprovalsPath)
View Source
var GetTimeLog = getTimeLogs(timelogPath)
GetTimeLog Get timelog record by IDs.
Functions ¶
func CreateFolderTask ¶ added in v0.0.6
func CreateFolderTask(ctx context.Context, folderID string, update TaskUpdate, resp *ResponseTasks) (err error)
func CreateTaskAttachment ¶
func CreateTaskComment ¶
func DownloadAttachment ¶
func GetAccount ¶
func GetAccount(ctx context.Context, response *ResponseAccount) (err error)
func GetApprovals ¶
func GetBookings ¶
func GetComments ¶
func GetComments(ctx context.Context, response *ResponseComments) (err error)
func GetContact ¶
func GetContact(ctx context.Context, contactID string, response *ResponseUsers) (err error)
func GetContacts ¶
func GetContacts(ctx context.Context, response *ResponseUsers) (err error)
func GetCustomField ¶
func GetCustomField(ctx context.Context, customFieldID string, response *ResponseCustomFields) (err error)
func GetCustomFields ¶
func GetCustomFields(ctx context.Context, response *ResponseCustomFields) (err error)
func GetFolder ¶
func GetFolder(ctx context.Context, folderId string, response *ResponseFolders) error
GetFolder by id //https://developers.wrike.com/api/v4/folders-projects/#get-folder
func GetFolderAttachments ¶
func GetFolderAttachments(ctx context.Context, folderID string, response *ResponseAttachments) (err error)
func GetFolders ¶
func GetFolders(ctx context.Context, response *ResponseFolders) error
func GetGroup ¶
func GetGroup(ctx context.Context, groupID string, response *ResponseGroups) (err error)
func GetInvitation ¶
func GetInvitation(ctx context.Context, contactID string, response *ResponseInvitations) (err error)
func GetInvitations ¶
func GetInvitations(ctx context.Context, response *ResponseInvitations) (err error)
func GetJobRole ¶
func GetJobRole(ctx context.Context, id string, response *ResponseJobRoles) error
func GetJobRoles ¶
func GetSpaceFolders ¶
func GetSpaceFolders(ctx context.Context, spaceId string, response *ResponseFolders) error
func GetSubFolders ¶
func GetSubFolders(ctx context.Context, folderId string, response *ResponseFolders) error
func GetTaskAttachments ¶
func GetTaskAttachments(ctx context.Context, taskID string, response *ResponseAttachments) (err error)
func GetTimeLogs ¶
func GetTimeLogs(ctx context.Context, response *ResponseTimeLogs) error
func GetWorkSchedule ¶
func GetWorkSchedule(ctx context.Context, scheduleID string, response *ResponseWorkSchedules) (err error)
func GetWorkSchedules ¶
func GetWorkflows ¶
func GetWorkflows(ctx context.Context, response *ResponseWorkflows) (err error)
func Request ¶
func Request(ctx context.Context, method string, url string, reader io.ReadCloser, head map[string]string) (body io.ReadCloser, header http.Header, err error)
Request Request
func UpdateTask ¶ added in v0.0.6
func UpdateTask(ctx context.Context, taskID string, update TaskUpdate, resp *ResponseTasks) (err error)
Types ¶
type Account ¶
type Account struct { ID string `json:"id"` Name string `json:"name"` DateFormat string `json:"dateFormat"` FirstDayOfWeek string `json:"firstDayOfWeek"` WorkDays []string `json:"workDays"` RootFolderID string `json:"rootFolderId"` RecycleBinID string `json:"recycleBinId"` CreatedDate time.Time `json:"createdDate"` Subscription Subscription `json:"subscription"` Metadata Metadatas `json:"metadata"` CustomFields []AccountCustomField `json:"customFields"` JoinedDate time.Time `json:"joinedDate"` }
type AccountCustomField ¶
type AccountCustomField struct { ID string `json:"id"` AccountID string `json:"accountId"` Title string `json:"title"` Type string `json:"type"` Settings struct { InheritanceType string `json:"inheritanceType"` DecimalPlaces int `json:"decimalPlaces"` UseThousandsSeparator bool `json:"useThousandsSeparator"` Aggregation string `json:"aggregation"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` Settings0 struct { InheritanceType string `json:"inheritanceType"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` Settings1 struct { InheritanceType string `json:"inheritanceType"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` }
type Approval ¶
type Approval struct { TaskID string `json:"taskId,omitempty"` AuthorID string `json:"authorId"` Title string `json:"title"` Description string `json:"description"` UpdatedDate time.Time `json:"updatedDate"` DueDate string `json:"dueDate"` Decisions []Decisions `json:"decisions"` ReviewID string `json:"reviewId"` AttachmentIds []string `json:"attachmentIds"` Type string `json:"type"` AutoFinishOnApprove bool `json:"autoFinishOnApprove"` AutoFinishOnReject bool `json:"autoFinishOnReject"` Finished bool `json:"finished"` ID string `json:"id"` Status string `json:"status"` FolderID string `json:"folderId,omitempty"` }
type Attachment ¶
type Attachment struct { ID string `json:"id"` AuthorID string `json:"authorId"` Name string `json:"name"` CreatedDate time.Time `json:"createdDate"` Version int `json:"version"` Type string `json:"type"` ContentType string `json:"contentType"` Size int `json:"size"` TaskID string `json:"taskId,omitempty"` CurrentAttachmentID string `json:"currentAttachmentId,omitempty"` FolderID string `json:"folderId,omitempty"` }
type Booking ¶
type Booking struct { ID string `json:"id"` FolderID string `json:"folderId"` ResponsibleID string `json:"responsibleId"` BookingDates BookingDates `json:"bookingDates"` EffortAllocation BookingEffortAllocation `json:"effortAllocation"` }
type BookingDates ¶
type BookingEffortAllocation ¶
type BookingEffortAllocation struct { ResponsibleAllocation []ResponsibleAllocation `json:"responsibleAllocation"` Mode string `json:"mode"` TotalEffort int `json:"totalEffort"` }
type Customfield ¶
type Customfield struct { ID string `json:"id"` AccountID string `json:"accountId"` Title string `json:"title"` Type string `json:"type"` Settings struct { InheritanceType string `json:"inheritanceType"` DecimalPlaces int `json:"decimalPlaces"` UseThousandsSeparator bool `json:"useThousandsSeparator"` Aggregation string `json:"aggregation"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` Settings0 struct { InheritanceType string `json:"inheritanceType"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` Settings1 struct { InheritanceType string `json:"inheritanceType"` ReadOnly bool `json:"readOnly"` } `json:"settings,omitempty"` }
type Dependence ¶
type EffortAllocation ¶
type EffortAllocation struct {
// contains filtered or unexported fields
}
type Invitation ¶
type Invitation struct { ID string `json:"id"` AccountID string `json:"accountId"` Email string `json:"email"` Status string `json:"status"` InviterUserID string `json:"inviterUserId"` InvitationDate time.Time `json:"invitationDate"` ResolvedDate time.Time `json:"resolvedDate"` Role string `json:"role"` External bool `json:"external"` FirstName string `json:"firstName,omitempty"` LastName string `json:"lastName,omitempty"` }
type Project ¶
type Project struct { AuthorID string `json:"authorId"` OwnerIds []string `json:"ownerIds"` Status string `json:"status"` CustomStatusID string `json:"customStatusId"` StartDate string `json:"startDate"` EndDate string `json:"endDate"` CreatedDate string `json:"createdDate"` CompletedDate string `json:"completedDate"` }
type ResponseAccount ¶
type ResponseApprovals ¶
type ResponseAttachments ¶
type ResponseAttachments struct { Kind string `json:"kind"` Data []Attachment `json:"data"` }
type ResponseBookings ¶
type ResponseComments ¶
type ResponseCustomFields ¶
type ResponseCustomFields struct { Kind string `json:"kind"` Data []Customfield `json:"data"` }
type ResponseDependence ¶
type ResponseDependence struct { Kind string `json:"kind"` Data []Dependence `json:"data"` }
type ResponseFolders ¶
type ResponseGroups ¶
type ResponseInvitations ¶
type ResponseInvitations struct { Kind string `json:"kind"` Data []Invitation `json:"data"` }
type ResponseJobRoles ¶
type ResponseTasks ¶
type ResponseTimeLogs ¶
type ResponseUsers ¶
type ResponseWorkSchedules ¶
type ResponseWorkSchedules struct { Kind string `json:"kind"` Data []WorkSchedule `json:"data"` }
type ResponseWorkflows ¶
type ResponsibleAllocation ¶
type ResponsibleAllocation struct { UserID string `json:"userId"` DailyAllocation []interface{} `json:"dailyAllocation"` }
type Subscription ¶
type Task ¶
type Task struct { ID string `json:"id"` AccountID string `json:"accountId"` Title string `json:"title"` Description string `json:"description"` BriefDescription string `json:"briefDescription"` ParentIds []string `json:"parentIds"` SuperParentIds []interface{} `json:"superParentIds"` ResponsibleIds []string `json:"responsibleIds"` Status string `json:"status"` Importance string `json:"importance"` CreatedDate time.Time `json:"createdDate"` UpdatedDate time.Time `json:"updatedDate"` Dates TaskDate `json:"dates"` Scope string `json:"scope"` AuthorIds []string `json:"authorIds"` CustomStatusID string `json:"customStatusId"` HasAttachments bool `json:"hasAttachments"` Permalink string `json:"permalink"` Priority string `json:"priority"` FollowedByMe bool `json:"followedByMe"` FollowerIds []string `json:"followerIds"` SuperTaskIds []interface{} `json:"superTaskIds"` SubTaskIds []string `json:"subTaskIds"` DependencyIds []string `json:"dependencyIds"` Metadata Metadatas `json:"metadata"` CustomFields Fields `json:"customFields"` }
type TaskUpdate ¶ added in v0.0.6
type TaskUpdate struct { Title string `json:"title"` Description *string `json:"description"` Status *string `json:"status"` СustomStatus *string `json:"customStatus"` Importance *string `json:"importance"` Dates *TaskDate `json:"dates"` BillingType string `json:"billingType"` Parents []string `json:"parents"` Responsibles []string `json:"responsibles"` Followers []string `json:"followers"` Follow bool `json:"follow"` PriorityBefore *string `json:"priorityBefore"` PriorityAfter *string `json:"priorityAfter"` SuperTasks *string `json:"superTasks"` Metadata Metadatas `json:"metadata"` CustomFields Fields `json:"customFields"` EffortAllocation *EffortAllocation `json:"effortAllocation"` }
func (TaskUpdate) ToRequest ¶ added in v0.0.6
func (t TaskUpdate) ToRequest() (r string, err error)
type TimeLog ¶
type TimeLog struct { ID string `json:"id"` TaskID string `json:"taskId"` UserID string `json:"userId"` CategoryID string `json:"categoryId,omitempty"` Hours int `json:"hours"` CreatedDate time.Time `json:"createdDate"` UpdatedDate time.Time `json:"updatedDate"` TrackedDate string `json:"trackedDate"` Comment string `json:"comment"` }
type User ¶
type User struct { ID string `json:"id"` FirstName string `json:"firstName"` LastName string `json:"lastName"` Type string `json:"type"` Profiles []Profile `json:"profiles"` AvatarURL string `json:"avatarUrl"` Timezone string `json:"timezone"` Locale string `json:"locale"` Deleted bool `json:"deleted"` Me bool `json:"me"` Phone string `json:"phone"` }
type WorkSchedule ¶
type Workflow ¶
type Workflow struct { ID string `json:"id"` Name string `json:"name"` Standard bool `json:"standard"` Hidden bool `json:"hidden"` CustomStatuses []struct { ID string `json:"id"` Name string `json:"name"` StandardName bool `json:"standardName"` Color string `json:"color"` Standard bool `json:"standard"` Group string `json:"group"` Hidden bool `json:"hidden"` } `json:"customStatuses"` }
Click to show internal directories.
Click to hide internal directories.