open-index/open-npm huggingface dataset:
npm package: @goodwaygroup/lib-tradedesk
Description: Interact with Tradedesk's API
Author: https://github.com/mrlannigan
Latest version: 1.3.1

# lib-tradedesk

[![Coverage Status](https://coveralls.io/repos/github/GoodwayGroup/lib-tradedesk/badge.svg?branch=master)](https://coveralls.io/github/GoodwayGroup/lib-tradedesk?branch=master) [![CircleCI](https://circleci.com/gh/GoodwayGroup/lib-tradedesk.svg?style=svg)](https://circleci.com/gh/GoodwayGroup/lib-tradedesk)

## Usage

This plugin will interact with The Trade Desk's API. 

View the API's documentation at https://apis.thetradedesk.com/v3/doc

> NOTE: This module uses the [`debug`](https://www.npmjs.com/package/debug) logging tool. Use `DEBUG=tradedesk*` to view debug logging.

```
$ npm install -S @goodwaygroup/lib-tradedesk
```

---

```js
const { TradeDesk } = require('@goodwaygroup/lib-tradedesk');

const ttd = new TradeDesk({
    username: 'testuser@example.com',
    password: 'apasswordthatwontwork'
});

// Promises
ttd.get('/campaign/query/facets')
    .then((res) => res.json())
    .then((body) => console.log(body))
    .catch((err) => {
        console.log(err.stack);
        if (err.response) {
            return err.response.json().then((body) => console.log(body))
        }
    });

// Async/Await
try {
    const res = await ttd.get('/campaign/query/facets');
    console.log(await res.json());
} catch (err) {
    console.log(err.stack);
    if (err.response) {
        console.log(await err.response.json())
    }
}
```


## Configuration Options

> See [Documentation](./docs/api/interfaces/tradedeskoptions.md)

## Full Documentation

> See [Documentation](./docs/api/README.md)

## Running Tests

To run tests, just run the following:

```
npm test
```

All commits are tested on [CircleCI](https://circleci.com/gh/GoodwayGroup/workflows/lib-tradedesk)

## Linting

To run `eslint`:

```
npm run lint
```

To auto-resolve:

```
npm run lint:fix
```

## Contributing

Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.

## Versioning

We use milestones and `npm` version to bump versions. We also employ [git-chglog](https://github.com/git-chglog/git-chglog) to manage the [CHANGELOG.md](CHANGELOG.md). For the versions available, see the [tags on this repository](https://github.com/GoodwayGroup/lib-tradedesk/tags).

To initiate a version change:

```
npm version minor
```

## Authors

* **Julian Lannigan** - *Initial work* - [@mrlannigan](https://github.com/mrlannigan)

See also the list of [contributors](https://github.com/GoodwayGroup/lib-tradedesk/contributors) who participated in this project.

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details

## Acknowledgments

## Sponsors

[![goodwaygroup][goodwaygroup]](https://goodwaygroup.com)

[goodwaygroup]: https://s3.amazonaws.com/gw-crs-assets/goodwaygroup/logos/ggLogo_sm.png "Goodway Group"
npm package: @goofmint/dok-sdk
Description: Dok SDK
Author: goofmint
Latest version: 0.0.3

# DOK SDK

SDK for [DOK](https://www.sakura.ad.jp/koukaryoku-dok/) that is container GPU cloud service.

![CodeRabbit Pull Request Reviews](https://img.shields.io/coderabbit/prs/github/goofmint/dok-js?utm_source=oss&utm_medium=github&utm_campaign=goofmint%2Fdok-js&labelColor=171717&color=FF570A&link=https%3A%2F%2Fcoderabbit.ai&label=CodeRabbit+Reviews)

## Usage

```bash
npm install @goofmint/dok-sdk
```

## Test

```bash
npm test
```

## Supported API

- Tasks
  - [x] Get tasks
  - [x] Get task
  - [ ] Create task
  - [ ] Delete task
  - [ ] Cancel task
  - [ ] Get download URL
  - [ ] Get log stream websocket URL
- Container Registry
  - [ ] Get container registries
  - [ ] Get container registry
  - [ ] Create container registry
  - [ ] Delete container registry
  - [ ] Update container registry
- Artifacts
  - [x] Get artifacts
  - [ ] Get artifact
  - [ ] Get artifact download URL
- Plan
  - [ ] Get plans
- Cost
  - [ ] Get costs
  - [ ] Get cost by plan

## Sample Code

### Initialize DOK client

```ts
import DOK from '@goofmint/dok-sdk';

const dok = new DOK({
  accessToken: process.env.ACCESS_TOKEN,
  accessTokenSecret: process.env.ACCESS_TOKEN_SECRET,
});
```

### Get tasks

```ts
const { tasks, meta } = await dok.tasks();
```

### Get task

```ts
const task = await dok.task(taskId);
```

### Get artifacts

```ts
const { artifacts, meta } = await dok.artifacts();
```

## License

MIT