cap_app_api

1.0.0-rc.1 • Public • Published

cap_app_api

CapAppApi - JavaScript client for cap_app_api CapApp services. This SDK is automatically generated by the Swagger Codegen project:

  • API version: 1.0.0.rc-01
  • Package version: 1.0.0.rc-01
  • Build package: io.swagger.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install cap_app_api --save

git

If the library is hosted at a git repository, e.g. https://github.com/GIT_USER_ID/GIT_REPO_ID then install it via:

    npm install GIT_USER_ID/GIT_REPO_ID --save

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Getting Started

Please follow the installation instruction and execute the following JS code:

var CapAppApi = require('cap_app_api');

var defaultClient = CapAppApi.ApiClient.instance;

// Configure OAuth2 access token for authorization: capapp_auth
var capapp_auth = defaultClient.authentications['capapp_auth'];
capapp_auth.accessToken = "YOUR ACCESS TOKEN"

var api = new CapAppApi.BookingApi()

var bookings = new CapAppApi.Bookings(); // {Bookings} The bookings for the week.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.updateWeek(bookings, callback);

Documentation for API Endpoints

All URIs are relative to https://endpoints-dot-capappw.appspot.com/v1

Class Method HTTP request Description
CapAppApi.BookingApi updateWeek POST /bookings/update Update a set of bookings for this week. Add if new.
CapAppApi.UserApi getUser GET /user/me User profile
CapAppApi.UserApi loginUser POST /user/login Login a user and add the user if new.

Documentation for Models

Documentation for Authorization

capapp_auth

  • Type: OAuth
  • Flow: implicit
  • Authorization URL: Not used
  • Scopes:
    • capapp: Perform actions on behalf of the CapApp organization.
    • user: Perform actions on behalf of an individual user.

Readme

Keywords

none

Package Sidebar

Install

npm i cap_app_api

Weekly Downloads

2

Version

1.0.0-rc.1

License

Unlicense

Unpacked Size

84 kB

Total Files

35

Last publish

Collaborators

  • dermotobrien