@appveen/odp-apis

1.0.1 • Public • Published

odp-apis

A Library to integrate ODP into any application.

Examples

const ODP = require('@appveen/odp-apis');

const API = new ODP({
    host: HOST,
    username: USERNAME,
    password: PASSWORD
});
API.login().then(())=>{
    console.log(API.loginData);
    const employeeCrud = API.crud('api/c/Adam/employee');
    employeeCrud.count()
    employeeCrud.get()
    employeeCrud.list()
    employeeCrud.post()
    employeeCrud.put()
    employeeCrud.delete()
}).catch(console.error);

Features

  • API.loginData will contain the login data.
  • Heartbeats and Token Refresh is internally handled.
  • API.loginData.token will always give you the latest valid token.
  • API.crud() will return multiple methods to do curd operation.

Dependencies (5)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i @appveen/odp-apis

    Weekly Downloads

    2

    Version

    1.0.1

    License

    ISC

    Unpacked Size

    21 kB

    Total Files

    7

    Last publish

    Collaborators

    • appveen