Skip to content

A simple bash script to make /GET requests against the SD API without having to worry about JWTs ⚡🔩⚡

Notifications You must be signed in to change notification settings

philipjscott/sd-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sd-api

A simple bash script to make /GET requests against the SD API without having to worry about JWTs.

Depends on jq

Installation

$ sudo ./install.sh

This will put sd-api in /usr/local/bin.

In addition, you need the following code to your ~/.bashrc or ~/zshrc or ~/.profile, etc.:

# This is just an example; you'll need to set them to point to YOUR Screwdriver instance

export SD_INSTANCE=https://api.screwdriver.cd/
export SD_NAMESPACE=v4
export SD_ACCESS_TOKEN=SECRET
. sd-api

. sd-api will set $SD_JWT so you won't need to fetch a JWT for each request.

How to get a Screwdriver Access Token

  1. Go to "User Settings"

step1

  1. Provide a name and description, then click "add"

step2

Usage

sd-api only supports /GETs right now; it takes the URI as an argument. Do not begin the URI with a /

$ sd-api stats

About

A simple bash script to make /GET requests against the SD API without having to worry about JWTs ⚡🔩⚡

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages