This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

ovh-api-services

17.0.0 • Public • Published

ovh-api-services

Contains all AngularJS $resource for the OVHcloud API.

Downloads Dependencies Dev Dependencies

Install

$ yarn add ovh-api-services

Usage

import angular from 'angular';
import ovhApiServices from 'ovh-api-services';

angular.module('myApp', [ovhApiServices]);

Services

All services must return an AngularJS $resource and can be called by using:

Service Engine Library
v6 APIv6 n/a
Iceberg Iceberg @ovh-ux/ng-ovh-api-wrappers
Aapi 2API n/a

How to get user informations?

OvhApiMe
  .v6()
  .get()
  .$promise
  .then((nichandle) => {
    console.log(nichandle);
    /*
    {
      "firstname": "John",
      "name": "Doe",

    }
    */
  });

How to get a SSH Key detail?

OvhApiMe
  .SshKey()
  .v6()
  .get({
    keyName: 'YOUR_KEY_NAME',
  })
  .$promise
  .then((sshKey) => {
    console.log(sshKey);
    /*
    {
      "keyName": "test",
      "key": "ssh-rsa …",
      "default": false
    }
    */
  });

Structure

The files structure is defined as:

$ tree src/api/
.
└── me
    ├── sshKey
    │   ├── me-sshKey.service.js
    │   └── me-sshKey.v6.service.js
    ├── me.service.js
    └── me.v6.service.js

The directories structure must follow the structure of the API.

Test

$ yarn test

Related

Contributing

Always feel free to help out! Whether it's filing bugs and feature requests or working on some of the open issues, our contributing guide will help get you started.

License

BSD-3-Clause © OVH SAS

Dependents (0)

Package Sidebar

Install

npm i ovh-api-services

Weekly Downloads

1,377

Version

17.0.0

License

BSD-3-Clause

Unpacked Size

6.46 MB

Total Files

9

Last publish

Collaborators

  • antleblanc
  • blary_jp
  • bnjjj
  • cbourgois
  • jisay
  • lizardk
  • marie-j
  • ovh
  • ovh-ux-cds