https://github.com/johnbwoodruff/digitalocean-js
JavaScript library for the DigitalOcean API
https://github.com/johnbwoodruff/digitalocean-js
digitalocean nodejs typescript
Last synced: about 1 year ago
JSON representation
JavaScript library for the DigitalOcean API
- Host: GitHub
- URL: https://github.com/johnbwoodruff/digitalocean-js
- Owner: johnbwoodruff
- License: mit
- Created: 2017-08-06T21:36:15.000Z (almost 9 years ago)
- Default Branch: main
- Last Pushed: 2024-07-12T04:03:59.000Z (almost 2 years ago)
- Last Synced: 2025-04-02T07:08:46.448Z (about 1 year ago)
- Topics: digitalocean, nodejs, typescript
- Language: TypeScript
- Homepage: https://johnbwoodruff.github.io/digitalocean-js/
- Size: 1.75 MB
- Stars: 93
- Watchers: 3
- Forks: 13
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# DigitalOcean JS
[](https://github.com/johnbwoodruff/digitalocean-js/actions/workflows/main.yml) [](https://www.npmjs.com/package/digitalocean-js) [](https://www.npmjs.com/package/digitalocean-js) [](https://www.npmjs.com/package/digitalocean-js)
JavaScript library for the DigitalOcean API. For use in Node or the browser.
## Goals
This library was built with a few goals in mind:
- Be able to use in a Node or Browser environment with no difference in usage.
- Use Promises instead of callbacks so clients can make use of `async`/`await`.
- Be built in TypeScript so consumers of the library can benefit from excellent intellisense with the TypeScript definitions.
- Provide solid documentation including examples for usage.
## Usage
To use the library, install from the npm repository.
```shell
$ npm install --save digitalocean-js
# Alternatively install with yarn
$ yarn add digitalocean-js
```
Simply import the client and initialize it with your API token:
```js
import { DigitalOcean } from 'digitalocean-js';
const client = new DigitalOcean('my-api-token');
```
To see all the services available, check out the [documentation](https://johnbwoodruff.github.io/digitalocean-js/).