Giter VIP home page Giter VIP logo

bk-plugin-client-go's Introduction

BK-PLUGIN-CLIENT-GO

蓝鲸插件 go 语言对接SDK。通过该SDK,你可以实现:

  • 获取插件列表
  • 获取插件详情
  • 执行插件
  • 查询插件状态
  • 获取插件日志

环境变量

USE_PLUGIN_SERVICE = 0 or 1 是否开启sdk 服务
PLUGIN_SERVICE_APIGW_APP_CODE = 调用身份的app_code
PLUGIN_SERVICE_APIGW_APP_SECRET = 调用身份的 app_seret
APIGW_ENVIRONMENT = 环境, prod or stage
APIGW_NETWORK_PROTOCAL = 协议 https or http
APIGW_URL_SUFFIX = APIGW的前缀地址
BKAPP_INVOKE_PAAS_RETRY_NUM = 失败重试次数

使用样例

client := api.GetClient("plugin-demo")
// 查询插件列表
results, _ := client.GetPluginList(1, 2)
// 获取插件app详情, client初始化需要传入 plugin_code 才能获取详情
client.GetPluginAppDetail()
// 获取插件元数据
client.GetPluginMeta()
// 执行插件
client.Invoke(version, data)
// 获取插件状态
client.GetSchedule(trace_id)
// 获取插件日志
GetPluginLogs(traceId string, scrollId interface{})

bk-plugin-client-go's People

Contributors

hanshuaikang avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.