api

package
v0.0.0-...-7d3b672 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteConnection

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

@Summary delete a slack connection @Description Delete a slack connection @Tags plugins/slack @Success 200 {object} models.SlackConnection @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/slack/connections/{connectionId} [DELETE]

func GetConnection

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

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

func Init

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

func ListConnections

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

func PatchConnection

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

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

func PostConnections

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

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

func TestConnection

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

@Summary test slack connection @Description Test slack Connection. endpoint: https://open.slack.cn/open-apis/ @Tags plugins/slack @Param body body models.SlackConn true "json body" @Success 200 {object} SlackTestConnResponse "Success" @Failure 400 {string} errcode.Error "Bad Request" @Failure 500 {string} errcode.Error "Internal Error" @Router /plugins/slack/test [POST]

Types

type SlackBlueprintPlan

type SlackBlueprintPlan [][]struct {
	Plugin  string   `json:"plugin"`
	Options struct{} `json:"options"`
}

type SlackPipelinePlan

type SlackPipelinePlan [][]struct {
	Plugin  string   `json:"plugin"`
	Options struct{} `json:"options"`
}

type SlackTestConnResponse

type SlackTestConnResponse struct {
	shared.ApiBody
	Connection *models.SlackConn
}

Jump to

Keyboard shortcuts

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