JSPM

  • Created
  • Published
  • Downloads 128
  • Score
    100M100P100Q58304F
  • License MIT

Terraform Cloud API wrapper

Package Exports

  • terraform-cloud

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (terraform-cloud) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

terraform-cloud

A typescript Terraform Cloud API wrapper.

This is a work in progress, if you want to contribute feel free to integrate a new endpoint.

Instalation

yarn add terraform-cloud # With Yarn
npm install terraform-cloud # With NPM

Usage

import { TerraformCloudApi } from 'terraform-cloud'

// Set a your terraform cloud API token
const terraformClient = new TerraformCloudApi('terraform-api-token')

// Make an API call

// Get Account Information
const account = terraformClient.getAccount()

// Get Run information by run id (ex: 'run-xis032ss)
const run = terraformClient.getRun('run-id')

Current implementation

  • Account details
  • Runs by workspace
  • Run by ID

TODO

  • Workspace by ID
  • Workspaces
  • ...