#buildkite #organization #api #builds #built #agents

app buildkite-cli

Example Buildkite CLI built with Buildkite Rust library

1 unstable release

0.1.0 Jan 20, 2021

#4 in #buildkite

Apache-2.0

18KB
311 lines

A Rust library for Buildkite API

A Rust binding to the Buildkite V2 API.

Getting Started

First, add following to Cargo.toml:

[dependencies]
buildkite = "0.1.0"

Then use the crate with:

use buildkite;

fn main() {
    let client = buildkite::client::Client::new("BUILDKITE_TOKEN");
}

Examples

Organizations

// List Organizations
client
    .organizations()
    .list();

// Get a sepcific organization
client
    .organizations()
    .get(org_name);

Builds

// List builds for a specific pipeline
client
    .builds()
    .list(org_name, pipeline_name);

Agents

// List agents
client
    .agents()
    .list(org_name)

// Get agent
client
    .agents()
    .get(org_name, agent_id)

License

Licensed under Apache License, Version 2.0

Dependencies

~5–10MB
~182K SLoC