api

package
v0.0.0-...-1fa52ee Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2024 License: Apache-2.0, BSD-2-Clause, ISC, + 1 more Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateScopeConfig

func CreateScopeConfig(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

CreateScopeConfig create scope config for Trello @Summary create scope config for Trello @Description create scope config for Trello @Tags plugins/trello @Accept application/json @Param scopeConfig body models.TrelloScopeConfig true "scope config" @Success 200 {object} models.TrelloScopeConfig @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scope-configs [POST]

func DeleteConnection

func DeleteConnection(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

@Summary delete a trello connection @Description Delete a trello connection @Tags plugins/trello @Success 200 {object} models.TrelloConnection @Failure 400 {string} errcode.Error "Bad Request" @Failure 409 {object} services.BlueprintProjectPairs "References exist to this connection" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections/{connectionId} [DELETE]

func DeleteScope

DeleteScope delete plugin data associated with the scope and optionally the scope itself @Summary delete plugin data associated with the scope and optionally the scope itself @Description delete data associated with plugin scope @Tags plugins/trello @Param connectionId path int true "connection ID" @Param scopeId path int true "scope ID" @Param delete_data_only query bool false "Only delete the scope data, not the scope itself" @Success 200 @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 409 {object} api.ScopeRefDoc "References exist to this scope" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scopes/{scopeId} [DELETE]

func DeleteScopeConfig

func DeleteScopeConfig(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

DeleteScopeConfig delete a scope config @Summary delete a scope config @Description delete a scope config @Tags plugins/trello @Param id path int true "id" @Param connectionId path int true "connectionId" @Success 200 @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scope-configs/{id} [DELETE]

func GetConnection

func GetConnection(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

@Summary get trello connection detail @Description Get trello connection detail @Tags plugins/trello @Success 200 {object} models.TrelloConnection @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections/{connectionId} [GET]

func GetScope

GetScope get one Trello board @Summary get one Trello board @Description get one Trello board @Tags plugins/trello @Param connectionId path int false "connection ID" @Param boardId path string false "board ID" @Success 200 {object} models.TrelloBoard @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scopes/{boardId} [GET]

func GetScopeConfig

func GetScopeConfig(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

GetScopeConfig return one scope config @Summary return one scope config @Description return one scope config @Tags plugins/trello @Param id path int true "id" @Success 200 {object} models.TrelloScopeConfig @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scope-configs/{id} [GET]

func GetScopeConfigList

func GetScopeConfigList(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

GetScopeConfigList return all scope configs @Summary return all scope configs @Description return all scope configs @Tags plugins/trello @Param pageSize query int false "page size, default 50" @Param page query int false "page size, default 1" @Success 200 {object} []models.TrelloScopeConfig @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scope-configs [GET]

func GetScopeList

GetScopeList get Trello boards @Summary get Trello boards @Description get Trello boards @Tags plugins/trello @Param connectionId path int false "connection ID" @Param searchTerm query string false "search term for scope name" @Param pageSize query int false "page size, default 50" @Param page query int false "page size, default 1" @Success 200 {object} []models.TrelloBoard @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scopes/ [GET]

func Init

func Init(br context.BasicRes, p plugin.PluginMeta)

func ListConnections

func ListConnections(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

@Summary get all trello connections @Description Get all trello connections @Tags plugins/trello @Success 200 {object} []models.TrelloConnection @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections [GET]

func MakePipelinePlanV200

func MakePipelinePlanV200(
	subtaskMetas []plugin.SubTaskMeta,
	connectionId uint64,
	scope []*coreModels.BlueprintScope,
) (coreModels.PipelinePlan, []plugin.Scope, errors.Error)

func PatchConnection

func PatchConnection(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

@Summary patch trello connection @Description Patch trello connection @Tags plugins/trello @Param body body models.TrelloConnection true "json body" @Success 200 {object} models.TrelloConnection @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections/{connectionId} [PATCH]

func PostConnections

func PostConnections(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

@Summary create trello connection @Description Create trello connection @Tags plugins/trello @Param body body models.TrelloConnection true "json body" @Success 200 {object} models.TrelloConnection @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections [POST]

func PutScope

PutScope create or update trello board @Summary create or update trello board @Description Create or update trello board @Tags plugins/trello @Accept application/json @Param connectionId path int false "connection ID" @Param scope body ScopeReq true "json" @Success 200 {object} []models.TrelloBoard @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scopes [PUT]

func TestConnection

func TestConnection(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

TestConnection test trello connection @Summary test trello connection @Description Test trello Connection @Tags plugins/trello @Param body body models.TrelloConn true "json body" @Success 200 {object} TrelloTestConnResponse "Success" @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/test [POST]

func TestExistingConnection

func TestExistingConnection(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

TestExistingConnection test trello connection options @Summary test trello connection @Description Test trello Connection @Tags plugins/trello @Param connectionId path int true "connection ID" @Success 200 {object} TrelloTestConnResponse "Success" @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/trello/connections/{connectionId}/test [POST]

func UpdateScope

UpdateScope patch to trello board @Summary patch to trello board @Description patch to trello board @Tags plugins/trello @Accept application/json @Param connectionId path int false "connection ID" @Param boardId path string false "board ID" @Param scope body models.TrelloBoard true "json" @Success 200 {object} models.TrelloBoard @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scopes/{boardId} [PATCH]

func UpdateScopeConfig

func UpdateScopeConfig(input *plugin.ApiResourceInput) (*plugin.ApiResourceOutput, errors.Error)

UpdateScopeConfig update scope config for Trello @Summary update scope config for Trello @Description update scope config for Trello @Tags plugins/trello @Accept application/json @Param id path int true "id" @Param scopeConfig body models.TrelloScopeConfig true "scope config" @Success 200 {object} models.TrelloScopeConfig @Failure 400 {object} shared.ApiBody "Bad Request" @Failure 500 {object} shared.ApiBody "Internal Error" @Router /plugins/trello/connections/{connectionId}/scope-configs/{id} [PATCH]

Types

type ScopeReq

type ScopeReq api.ScopeReq[models.TrelloBoard]

type ScopeRes

type ScopeRes struct {
	models.TrelloBoard
}

type TrelloTaskOptions

type TrelloTaskOptions tasks.TrelloOptions

type TrelloTestConnResponse

type TrelloTestConnResponse struct {
	shared.ApiBody
	Connection *models.TrelloConn
}

Jump to

Keyboard shortcuts

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