New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

digital-ocean-api-v2

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

digital-ocean-api-v2 - npm Package Compare versions

Comparing version 0.2.1 to 0.3.0

LICENSE

9

lib/factory.js

@@ -11,4 +11,9 @@ var _ = require('lodash');

for (; argIndex < model.requiredResourceIdCount; argIndex++) {
model.path = model.path.replace(/(\$.*)(?:\/|$)/, arguments[argIndex]);
model.path = model.path.replace(/(\$[A-Za-z_]*)/, arguments[argIndex]);
}
var pageString = '';
if ((arguments[argIndex] || {}).page) {
pageString = '?page=' + arguments[argIndex].page
argIndex++;
}
/*

@@ -23,3 +28,3 @@ last argument is treated as body and populated

method: model.method,
path: model.path,
path: model.path + pageString,
body: body

@@ -26,0 +31,0 @@ });

###account
- [getUserInformation](https://developers.digitalocean.com/documentation/v2/#get-user-information)
`api.account.getUserInformation()`
###actions

@@ -3,0 +8,0 @@ - [listAllActions](https://developers.digitalocean.com/documentation/v2#list-all-actions)

{
"name": "digital-ocean-api-v2",
"version": "0.2.1",
"description": "",
"version": "0.3.0",
"description": "Digital Ocean API (v2) library",
"main": "index.js",

@@ -13,3 +13,3 @@ "scripts": {

"lodash": "^3.10.1",
"parsed-digital-ocean-api-documentation": "^2.0.0",
"parsed-digital-ocean-api-documentation": "^2.1.0",
"request-promise": "^1.0.2"

@@ -16,0 +16,0 @@ },

@@ -5,4 +5,8 @@ # digital-ocean-api-v2

This library is more or less generated automatically from the excellent [Digital Ocean API documentation](https://developers.digitalocean.com/documentation/v2). A rather messy [parser](./lib/parser.js) converts that page into [parsed-schema.json](./parsed-schema.json), and a small [factory](./lib/factory.js) turns those descriptions into functions, which [index](./index.js) piles onto an object, yielding:
```bash
npm install digital-ocean-api-v2
```
This library is more or less generated automatically from the excellent [Digital Ocean API documentation](https://developers.digitalocean.com/documentation/v2). A [parser](https://github.com/itsjoesullivan/parsed-digital-ocean-api-documentation/blob/parser/parser.js) converts that page into [parsed-digital-ocean-api-documentation](https://github.com/itsjoesullivan/parsed-digital-ocean-api-documentation), and a small [factory](./lib/factory.js) turns those descriptions into functions, which [index](./index.js) piles onto an object, yielding:
```javascript

@@ -14,3 +18,3 @@ var DigitalOceanAPI = require('digital-ocean-api-v2');

It's in beta while function signature stuff is thought through. There are a couple things that look like typos in the documentation that probably shouldn't be reflected in the API (no referer please).
It's in beta while function signature stuff is thought through. There are a couple things that look like typos in the documentation that probably shouldn't be reflected in the API (referer, anyone?).

@@ -17,0 +21,0 @@ Each method returns a promise. For a list of methods, see [./methods.md](./methods.md)

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc