@celtra/circleci-v2
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

CircleCI V2 JS client

Javascript client generated from OpenAPI specifications available at https://circleci.com/docs/api/v2/index.html

Usage

import {createClient, getWorkflowById} from '@celtra/circleci-v2'

const client = createClient('myToken')

const workflow = await client.GET('/workflow/{id}', ({
    params: {
        path: {
            id: 'abcd',
        },
    },
}))

if (workflow.error !== undefined) {
    throw new Error(`Couldn't fetch workflow due to: ${workflow.error.message}`)
}

expect(workflow.data.id).toBe('abcd')

Readme

Keywords

none

Package Sidebar

Install

npm i @celtra/circleci-v2

Weekly Downloads

267

Version

1.0.3

License

MIT

Unpacked Size

352 kB

Total Files

6

Last publish

Collaborators

  • dejancjs
  • celtra-sysadmin