Code Monkey home page Code Monkey logo

vyltr's Introduction

Vyltr โ€” Vultr API Wrapper ๐Ÿฌ

XO code style Build Status

An API wrapper for the Vultr API.

Note: this is a work in progress.

Usage

Documentation is available here.

Example

const Vultr = require('vyltr');

// Pass API Token as parameter.
const v = new Vultr('VULTR_API_TOKEN');

const list = async () => {
  try {
    // List available Vultr plans
    const list = await v.plan.list();

    // Returns an array of PlanModel objects
    console.log(list);
  } catch (err) {
    console.log(err);
  }
}

list();

Outputs:

[ PlanModel {
    VPSPLANID: '87',
    name: '512 MB RAM,125 GB SATA,1.00 TB BW',
    vcpu_count: '1',
    ram: '512',
    disk: '125',
    bandwidth: '1.00',
    price_per_month: '5.00',
    windows: false,
    plan_type: 'SATA',
    available_locations: [ 1, 5, 7 ] },
  PlanModel {
    VPSPLANID: '88',
    name: '1024 MB RAM,250 GB SATA,2.00 TB BW',
    vcpu_count: '1',
    ram: '1024',
    disk: '250',
    bandwidth: '2.00',
    price_per_month: '10.00',
    windows: false,
    plan_type: 'SATA',
    available_locations: [ 1 ] },
  PlanModel {
    VPSPLANID: '89',
    name: '2048 MB RAM,500 GB SATA,3.00 TB BW',
    vcpu_count: '1',
    ram: '2048',
    disk: '500',
    bandwidth: '3.00',
    price_per_month: '20.00',
    windows: false,
    plan_type: 'SATA',
    available_locations: [ 1 ] },

    ...
]

Progress

  • server
    • list
    • reboot
    • start
    • stop
    • create
  • block storage
    • list
    • attach
    • create
    • delete
    • detach
    • set label
    • resize
  • regions
    • list all
    • list available
  • dns
    • list records
    • create domain
    • delete domain
    • create record
    • update record
    • delete record
  • operating systems
    • list
  • plans
    • list

Contributing

  1. Clone the repo
  2. Make a new local branch
  3. Change what you'd like
  4. Write some tests
  5. Make a Pull Request!

โœŒ๏ธ

vyltr's People

Contributors

hugomd avatar nathanmalishev avatar daawesomep avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.