Documentation ¶
Index ¶
- Constants
- type AddPermissionPayload
- type AddPermissionResponse
- type ApiError
- type CellParam
- type Client
- func (c *Client) AddPermission(docId string, payload AddPermissionPayload) (AddPermissionResponse, error)
- func (c *Client) CreateDocument(payload CreateDocumentPayload) (CreateDocumentResponse, error)
- func (c *Client) DeleteDocument(id string) (DeleteDocumentResponse, error)
- func (c *Client) DeletePermission(docId, permissionId string) (DeletePermissionResponse, error)
- func (c *Client) DeleteRow(docId string, tableIdOrName string, rowIdOrName string) (DeleteRowResponse, error)
- func (c *Client) DeleteRows(docId string, tableIdOrName string, deleteRowsParams DeleteRowsParameters) (DeleteRowsResponse, error)
- func (c *Client) GetACLMetadata(docId string) (GetACLResponse, error)
- func (c *Client) GetColumn(docId string, tableIdOrName string, columnIdOrName string) (GetColumnResponse, error)
- func (c *Client) GetControl(docId string, controlIdOrName string) (GetControlResponse, error)
- func (c *Client) GetDoc(id string) (GetDocumentResponse, error)
- func (c *Client) GetDocumentCategories() (GetDocumentCategoriesResponse, error)
- func (c *Client) GetFormula(docId string, formulaIdOrName string) (GetFormulaResponse, error)
- func (c *Client) GetMutationStatus(requestId string) (MutationStatusResponse, error)
- func (c *Client) GetPage(docId string, pageIdOrName string) (GetPageResponse, error)
- func (c *Client) GetTable(docId string, tableIdOrName string) (GetTableResponse, error)
- func (c *Client) GetTableRow(docId string, tableIdOrName string, rowIdOrName string, ...) (GetRowResponse, error)
- func (c *Client) GetUserInfo() (UserInfoResponse, error)
- func (c *Client) GetView(docId string, viewIdOrName string) (GetViewResponse, error)
- func (c *Client) InsertRows(docId string, tableIdOrName string, disableParsing bool, ...) (InsertRowsResponse, error)
- func (c *Client) ListACLs(docId string, paginationPayload PaginationPayload) (ListACLResponse, error)
- func (c *Client) ListColumns(docId string, tableIdOrName string, payload ListColumnsPayload) (ListColumnsResponse, error)
- func (c *Client) ListControls(docId string, payload ListControlsPayload) (ListControlsResponse, error)
- func (c *Client) ListDocuments(payload ListDocumentsPayload) (ListDocumentsResponse, error)
- func (c *Client) ListFormulas(docId string, payload ListFormulasPayload) (ListFormulasResponse, error)
- func (c *Client) ListPages(docId string, paginationPayload PaginationPayload) (ListPagesResponse, error)
- func (c *Client) ListTableRows(docId string, tableIdOrName string, listRowsParams ListRowsParameters) (ListRowsResponse, error)
- func (c *Client) ListTables(docId string, payload ListTablesPayload) (ListTablesResponse, error)
- func (c *Client) ListViewColumns(docId string, viewIdOrName string, paginationPayload PaginationPayload) (ListColumnsResponse, error)
- func (c *Client) ListViewRows(docId string, viewIdOrName string, viewRowsParams ListViewRowsParameters) (ListViewRowsResponse, error)
- func (c *Client) ListViews(docId string, paginationPayload PaginationPayload) (ListViewsResponse, error)
- func (c *Client) PublishDocument(documentId string, payload PublishDocumentPayload) (PublishDocumentResponse, error)
- func (c *Client) PushButton(docId string, tableIdOrName string, rowIdOrName string, columnIdOrName string) (PushButtonResponse, error)
- func (c *Client) ResolveBrowserLink(browserLinkParams ResolveBrowserLinkParameters) (ResolveBrowserLinkResponse, error)
- func (c *Client) UnpublishDocument(documentId string) error
- func (c *Client) UpdatePage(docId string, pageIdOrName string, pagePayload UpdatePagePayload) (RequestResponse, error)
- func (c *Client) UpdateRow(docId string, tableIdOrName string, rowIdOrName string, disableParsing bool, ...) (UpdateRowResponse, error)
- type Column
- type ColumnFormat
- type ColumnReference
- type Control
- type ControlReference
- type CreateDocumentPayload
- type CreateDocumentResponse
- type DeleteDocumentResponse
- type DeletePermissionResponse
- type DeleteRowResponse
- type DeleteRowsParameters
- type DeleteRowsResponse
- type DocCategory
- type DocPublished
- type DocSize
- type Document
- type ErrorResponse
- type Formula
- type FormulaReference
- type GetACLResponse
- type GetColumnResponse
- type GetControlResponse
- type GetDocumentCategoriesResponse
- type GetDocumentResponse
- type GetFormulaResponse
- type GetPageResponse
- type GetRowParameters
- type GetRowResponse
- type GetTableResponse
- type GetViewResponse
- type Icon
- type Image
- type InsertRowsParameters
- type InsertRowsResponse
- type InternalError
- type InvalidRequestError
- type InvalidTokenError
- type ListACLResponse
- type ListColumnsPayload
- type ListColumnsResponse
- type ListControlsPayload
- type ListControlsResponse
- type ListDocumentsPayload
- type ListDocumentsResponse
- type ListFormulasPayload
- type ListFormulasResponse
- type ListPagesPayload
- type ListPagesResponse
- type ListRowsParameters
- type ListRowsResponse
- type ListTablesPayload
- type ListTablesResponse
- type ListViewRowsParameters
- type ListViewRowsResponse
- type ListViewsParameters
- type ListViewsResponse
- type MutationStatusResponse
- type Page
- type PageReference
- type PaginationPayload
- type PaginationResponse
- type Permission
- type Principal
- type PublishDocumentPayload
- type PublishDocumentResponse
- type PushButtonResponse
- type RateLimitError
- type RequestResponse
- type ResolveBrowserLinkParameters
- type ResolveBrowserLinkResponse
- type Resource
- type ResourceDeletedError
- type ResourceNotFoundError
- type Row
- type RowParam
- type RowQueryParams
- type Table
- type TableFilter
- type TableReference
- type UnauthorizedError
- type UpdatePagePayload
- type UpdateRowParameters
- type UpdateRowResponse
- type UserInfoResponse
- type View
Constants ¶
View Source
const BaseUrl = "https://coda.io/apis/v1"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddPermissionPayload ¶
type AddPermissionResponse ¶
type AddPermissionResponse struct{}
type CellParam ¶
type CellParam struct { Column string `json:"column"` Value interface{} `json:"value"` }
type Client ¶
func DefaultClient ¶
func (*Client) AddPermission ¶
func (c *Client) AddPermission(docId string, payload AddPermissionPayload) (AddPermissionResponse, error)
func (*Client) CreateDocument ¶
func (c *Client) CreateDocument(payload CreateDocumentPayload) (CreateDocumentResponse, error)
func (*Client) DeleteDocument ¶
func (c *Client) DeleteDocument(id string) (DeleteDocumentResponse, error)
func (*Client) DeletePermission ¶
func (c *Client) DeletePermission(docId, permissionId string) (DeletePermissionResponse, error)
func (*Client) DeleteRows ¶
func (c *Client) DeleteRows(docId string, tableIdOrName string, deleteRowsParams DeleteRowsParameters) (DeleteRowsResponse, error)
func (*Client) GetACLMetadata ¶
func (c *Client) GetACLMetadata(docId string) (GetACLResponse, error)
func (*Client) GetControl ¶
func (c *Client) GetControl(docId string, controlIdOrName string) (GetControlResponse, error)
func (*Client) GetDocumentCategories ¶
func (c *Client) GetDocumentCategories() (GetDocumentCategoriesResponse, error)
func (*Client) GetFormula ¶
func (c *Client) GetFormula(docId string, formulaIdOrName string) (GetFormulaResponse, error)
func (*Client) GetMutationStatus ¶
func (c *Client) GetMutationStatus(requestId string) (MutationStatusResponse, error)
func (*Client) GetPage ¶
func (c *Client) GetPage(docId string, pageIdOrName string) (GetPageResponse, error)
func (*Client) GetTable ¶
func (c *Client) GetTable(docId string, tableIdOrName string) (GetTableResponse, error)
func (*Client) GetTableRow ¶
func (c *Client) GetTableRow(docId string, tableIdOrName string, rowIdOrName string, getRowParams GetRowParameters) (GetRowResponse, error)
func (*Client) GetUserInfo ¶
func (c *Client) GetUserInfo() (UserInfoResponse, error)
func (*Client) GetView ¶
func (c *Client) GetView(docId string, viewIdOrName string) (GetViewResponse, error)
func (*Client) InsertRows ¶
func (c *Client) InsertRows(docId string, tableIdOrName string, disableParsing bool, insertRowParams InsertRowsParameters) (InsertRowsResponse, error)
func (*Client) ListACLs ¶
func (c *Client) ListACLs(docId string, paginationPayload PaginationPayload) (ListACLResponse, error)
func (*Client) ListColumns ¶
func (c *Client) ListColumns(docId string, tableIdOrName string, payload ListColumnsPayload) (ListColumnsResponse, error)
func (*Client) ListControls ¶
func (c *Client) ListControls(docId string, payload ListControlsPayload) (ListControlsResponse, error)
func (*Client) ListDocuments ¶
func (c *Client) ListDocuments(payload ListDocumentsPayload) (ListDocumentsResponse, error)
func (*Client) ListFormulas ¶
func (c *Client) ListFormulas(docId string, payload ListFormulasPayload) (ListFormulasResponse, error)
func (*Client) ListPages ¶
func (c *Client) ListPages(docId string, paginationPayload PaginationPayload) (ListPagesResponse, error)
func (*Client) ListTableRows ¶
func (c *Client) ListTableRows(docId string, tableIdOrName string, listRowsParams ListRowsParameters) (ListRowsResponse, error)
func (*Client) ListTables ¶
func (c *Client) ListTables(docId string, payload ListTablesPayload) (ListTablesResponse, error)
func (*Client) ListViewColumns ¶
func (c *Client) ListViewColumns(docId string, viewIdOrName string, paginationPayload PaginationPayload) (ListColumnsResponse, error)
func (*Client) ListViewRows ¶
func (c *Client) ListViewRows(docId string, viewIdOrName string, viewRowsParams ListViewRowsParameters) (ListViewRowsResponse, error)
func (*Client) ListViews ¶
func (c *Client) ListViews(docId string, paginationPayload PaginationPayload) (ListViewsResponse, error)
func (*Client) PublishDocument ¶
func (c *Client) PublishDocument(documentId string, payload PublishDocumentPayload) (PublishDocumentResponse, error)
func (*Client) PushButton ¶
func (*Client) ResolveBrowserLink ¶
func (c *Client) ResolveBrowserLink(browserLinkParams ResolveBrowserLinkParameters) (ResolveBrowserLinkResponse, error)
func (*Client) UnpublishDocument ¶
func (*Client) UpdatePage ¶
func (c *Client) UpdatePage(docId string, pageIdOrName string, pagePayload UpdatePagePayload) (RequestResponse, error)
func (*Client) UpdateRow ¶
func (c *Client) UpdateRow(docId string, tableIdOrName string, rowIdOrName string, disableParsing bool, updateRowParams UpdateRowParameters) (UpdateRowResponse, error)
type Column ¶
type Column struct { ColumnReference IsDisplay bool `json:"display"` IsCalculated bool `json:"calculated"` Format ColumnFormat `json:"format"` Parent TableReference `json:"parent"` }
type ColumnFormat ¶
type ColumnReference ¶
type Control ¶
type Control struct { ControlReference ControlType string `json:"controlType"` Value interface{} `json:"value"` }
type ControlReference ¶
type ControlReference struct { Id string `json:"id"` Type string `json:"type"` Href string `json:"href"` Name string `json:"name"` Parent PageReference `json:"parent"` }
type CreateDocumentPayload ¶
type CreateDocumentResponse ¶
type CreateDocumentResponse struct {
Document
}
type DeleteDocumentResponse ¶
type DeleteDocumentResponse struct{}
type DeletePermissionResponse ¶
type DeletePermissionResponse struct{}
type DeleteRowResponse ¶
type DeleteRowsParameters ¶
type DeleteRowsParameters struct {
RowIds []string `json:"rowIds"`
}
type DeleteRowsResponse ¶
type DocCategory ¶
type DocCategory struct {
Name string `json:"name"`
}
type DocPublished ¶
type Document ¶
type Document struct { Id string `json:"id"` Type string `json:"type"` Href string `json:"href"` BrowserLink string `json:"browserLink"` Name string `json:"name"` Owner string `json:"email"` OwnerName string `json:"ownerName"` CreatedAt string `json:"createdAt"` UpdatedAt string `json:"updatedAt"` Icon Icon `json:"icon"` DocSize DocSize `json:"docSize"` SourceDoc struct { Id string `json:"id"` Type string `json:"type"` BrowserLink string `json:"browserLink"` Href string `json:"href"` } Published DocPublished `json:"published"` }
type ErrorResponse ¶
type Formula ¶
type Formula struct { FormulaReference Value interface{} `json:"value"` }
type FormulaReference ¶
type FormulaReference struct { Id string `json:"id"` Type string `json:"type"` Href string `json:"href"` Name string `json:"name"` Parent PageReference `json:"parent"` }
type GetACLResponse ¶
type GetACLResponse struct {}
type GetColumnResponse ¶
type GetColumnResponse struct {
Column
}
type GetControlResponse ¶
type GetControlResponse struct {
Control
}
type GetDocumentCategoriesResponse ¶
type GetDocumentCategoriesResponse struct {
Categories []DocCategory `json:"items"`
}
type GetDocumentResponse ¶
type GetDocumentResponse struct {
Document
}
type GetFormulaResponse ¶
type GetFormulaResponse struct {
Formula
}
type GetPageResponse ¶
type GetPageResponse struct {
Page
}
type GetRowParameters ¶
type GetRowParameters struct {
UseColumnNames bool `json:"useColumnNames" url:"useColumnNames"`
}
type GetRowResponse ¶
type GetRowResponse struct {
Row
}
type GetTableResponse ¶
type GetTableResponse struct {
Table
}
type GetViewResponse ¶
type GetViewResponse struct {
View
}
type InsertRowsParameters ¶
type InsertRowsResponse ¶
type InsertRowsResponse struct {
RequestId string `json:"requestId"`
}
type InternalError ¶ added in v1.1.1
type InternalError struct {
// contains filtered or unexported fields
}
func (InternalError) Error ¶ added in v1.1.1
func (e InternalError) Error() string
type InvalidRequestError ¶
type InvalidRequestError struct {
// contains filtered or unexported fields
}
Standard Bad Request 400 Error
func (InvalidRequestError) Error ¶
func (e InvalidRequestError) Error() string
type InvalidTokenError ¶
type InvalidTokenError struct {
// contains filtered or unexported fields
}
Invalid API Token
func (InvalidTokenError) Error ¶
func (e InvalidTokenError) Error() string
type ListACLResponse ¶
type ListACLResponse struct { Permissions []Permission `json:"items"` PaginationResponse }
type ListColumnsPayload ¶
type ListColumnsPayload struct { VisibleOnly bool `url:"visibleOnly,omitempty"` PaginationPayload }
type ListColumnsResponse ¶
type ListColumnsResponse struct { Columns []Column `json:"items"` PaginationResponse }
type ListControlsPayload ¶
type ListControlsPayload struct { SortBy string `json:"sortBy" url:"sortBy,omitEmpty"` PaginationPayload }
type ListControlsResponse ¶
type ListControlsResponse struct { Controls []ControlReference `json:"items"` PaginationResponse }
type ListDocumentsPayload ¶
type ListDocumentsPayload struct { IsOwner bool `url:"isOwner,omitempty"` Query string `url:"query,omitempty"` SourceDocument string `url:"sourceDoc,omitempty"` IsStarred bool `url:"isStarred,omitempty"` InGallery bool `url:"inGallery,omitempty"` WorkspaceId string `url:"workspaceId,omitempty"` FolderId string `url:"folderId,omitempty"` PaginationPayload }
type ListDocumentsResponse ¶
type ListDocumentsResponse struct { Documents []Document `json:"items"` PaginationResponse }
type ListFormulasPayload ¶
type ListFormulasPayload struct { SortBy string `json:"sortBy" url:"sortBy,omitempty"` PaginationPayload }
type ListFormulasResponse ¶
type ListFormulasResponse struct { Formulas []FormulaReference `json:"items"` PaginationResponse }
type ListPagesPayload ¶
type ListPagesResponse ¶
type ListPagesResponse struct { Pages []Page `json:"items"` PaginationResponse }
type ListRowsParameters ¶
type ListRowsParameters struct { Query string `json:"query" url:"query"` SortBy string `json:"sortBy" url:"sortBy"` UseColumnNames bool `json:"useColumnNames" url:"useColumnNames"` ValueFormat string `json:"valueFormat" url:"valueFormat"` VisibleOnly bool `json:"visibleOnly" url:"visibleOnly"` PaginationPayload }
type ListRowsResponse ¶
type ListRowsResponse struct { Rows []Row `json:"items"` PaginationResponse }
type ListTablesPayload ¶
type ListTablesPayload struct { SortBy string `url:"sortBy,omitempty"` TableTypes string `url:"tableTypes,omitempty"` PaginationPayload }
type ListTablesResponse ¶
type ListTablesResponse struct { Tables []TableReference `json:"items"` PaginationResponse }
type ListViewRowsParameters ¶
type ListViewRowsParameters struct { Query string `json:"query" url:"query"` SortBy string `json:"sortBy" url:"sortBy"` UseColumnNames bool `json:"useColumnNames" url:"useColumnNames"` ValueFormat string `json:"valueFormat" url:"valueFormat"` PaginationPayload }
type ListViewRowsResponse ¶
type ListViewRowsResponse struct { Rows []Row `json:"items"` PaginationResponse }
type ListViewsParameters ¶
type ListViewsParameters struct { TableType string `url:"tableTypes"` PaginationPayload }
type ListViewsResponse ¶
type ListViewsResponse struct { Views []View `json:"items"` PaginationResponse }
type MutationStatusResponse ¶
type MutationStatusResponse struct {
IsCompleted bool `json:"completed"`
}
type Page ¶
type Page struct { PageReference Children []PageReference `json:"children"` Subtitle string `json:"subtitle"` Icon Icon `json:"icon"` Image Image `json:"image"` Parent PageReference `json:"parent"` }
type PageReference ¶
type PaginationPayload ¶
type PaginationResponse ¶
type Permission ¶
type PublishDocumentPayload ¶
type PublishDocumentResponse ¶
type PublishDocumentResponse struct {
RequestId string `json:"requestId"`
}
type PushButtonResponse ¶
type RateLimitError ¶
type RateLimitError struct {
// contains filtered or unexported fields
}
Rate Limit Error
func (RateLimitError) Error ¶
func (e RateLimitError) Error() string
type RequestResponse ¶
type ResourceDeletedError ¶
type ResourceDeletedError struct {
// contains filtered or unexported fields
}
func (ResourceDeletedError) Error ¶
func (e ResourceDeletedError) Error() string
type ResourceNotFoundError ¶
type ResourceNotFoundError struct {
// contains filtered or unexported fields
}
func (ResourceNotFoundError) Error ¶
func (e ResourceNotFoundError) Error() string
type Row ¶
type Row struct { Id string `json:"id"` Type string `json:"type"` Href string `json:"href"` Name string `json:"name"` Index int `json:"index"` BrowserLink string `json:"browserLink"` CreatedAt string `json:"createdAt"` UpdatedAt string `json:"updatedAt"` Values map[string]interface{} `json:"values"` Parent struct { Id string `json:"id"` Type string `json:"type"` Href string `json"href"` } `json:"parent"` }
type RowQueryParams ¶
type RowQueryParams struct {
DisableParsing bool `url:"disableParsing"`
}
type Table ¶
type Table struct { TableReference DisplayColumn Column `json:"displayColumn"` RowCount int `json:"rowCount"` Sorts []struct { Column Column `json:"column"` Direction string `json:"direction"` } `json:"sorts"` Layout string `json:"layout"` CreatedAt string `json:"createdAt"` UpdatedAt string `json:"updatedAt"` ParentTable TableReference `json:"parentTable"` Filter TableFilter `json:"filter"` }
type TableFilter ¶
type TableReference ¶
type UnauthorizedError ¶
type UnauthorizedError struct {
// contains filtered or unexported fields
}
func (UnauthorizedError) Error ¶
func (e UnauthorizedError) Error() string
type UpdatePagePayload ¶
type UpdateRowParameters ¶
type UpdateRowParameters struct {
Row RowParam `json:"row"`
}
type UpdateRowResponse ¶
type UserInfoResponse ¶
type View ¶
type View struct { Id string `json:"id"` Type string `json:"type"` Href string `json:"href"` Name string `json:"name"` BrowserLink string `json:"browserLink"` DisplayColumn Column `json:"displayColumn"` RowCount int `json:"rowCount"` Sorts []struct { Column Column `json:"column"` Direction string `json:"direction"` } Layout string `json:"layout"` CreatedAt string `json:"createdAt"` UpdatedAt string `json:"updatedAt"` }
Click to show internal directories.
Click to hide internal directories.