Skip to content

gkeep-openapi/javascript-sdk

Repository files navigation

gkeep_api

GkeepApi - JavaScript client for gkeep_api Gkeep API This SDK is automatically generated by the Swagger Codegen project:

  • API version: 1.0.0
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.v3.generators.javascript.JavaScriptClientCodegen

Installation

npm

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

Then install it via:

npm install gkeep_api --save

git

If the library is hosted at a git repository, e.g. https://github.com/gkeep-openapi/javascript-sdk then install it via:

    npm install gkeep-openapi/javascript-sdk --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.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

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

var GkeepApi = require('gkeep_api');

var api = new GkeepApi.UserAuthorizationApi()
var body = new GkeepApi.UserCredentials(); // {UserCredentials} A JSON object containing user credentials info

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.authorize(body, callback);

Documentation for API Endpoints

All URIs are relative to https://staging-transport.smart-gamma.com

Class Method HTTP request Description
GkeepApi.UserAuthorizationApi authorize POST /api/login_check
GkeepApi.V1Api getCountriesList GET /api/v1/countries/by
GkeepApi.V1Api getTankTypeList GET /api/v1/tank/types/by
GkeepApi.V1Api getUserGroupList GET /api/v1/user/allowed/groups
GkeepApi.V1Api getVehicleBrandList GET /api/v1/vehicle/brands
GkeepApi.V1Api getVehicleFuelTypesList GET /api/v1/vehicle/fuel-types
GkeepApi.V1Api getVehicleModelList GET /api/v1/vehicle/models
GkeepApi.V1Api getVehicleNationalTypeList GET /api/v1/vehicle/national-types
GkeepApi.V1Api getVehiclePropertiesList GET /api/v1/vehicle/properties
GkeepApi.V1Api getVehicleTypeList GET /api/v1/vehicle/types
GkeepApi.V1Api getVehicleVersionList GET /api/v1/vehicle/versions
GkeepApi.V2Api createUserProfile POST /api/v2/user-profiles
GkeepApi.V2Api createVehicleCategory POST /api/v2/vehicles/categories
GkeepApi.V2Api deleteUserProfile DELETE /api/v2/user-profiles/{profileId}
GkeepApi.V2Api deleteVehicleCategory DELETE /api/v2/vehicles/categories/{categoryId}
GkeepApi.V2Api enableVehicleMaintenance PUT /api/v2/vehicles/maintenance/{vehicleId}
GkeepApi.V2Api getAlertList GET /api/v2/alerts
GkeepApi.V2Api getAlertsStatus GET /api/v2/alerts/status
GkeepApi.V2Api getCurrentUserProfile GET /api/v2/user-profiles
GkeepApi.V2Api getFleetStatus GET /api/v2/fleet/status
GkeepApi.V2Api getNotificationSettings GET /api/v2/user-profiles/notification-settings
GkeepApi.V2Api getRelatedUserProfiles GET /api/v2/user-profiles/{levelName}
GkeepApi.V2Api getUserProfile GET /api/v2/user-profiles/{profileId}
GkeepApi.V2Api getVehicleCategory GET /api/v2/vehicles/categories/{categoryId}
GkeepApi.V2Api getVehicleCategoryList GET /api/v2/vehicles/categories
GkeepApi.V2Api getVehicleStatus GET /api/v2/vehicles/{vehicleId}/status
GkeepApi.V2Api getVehicles GET /api/v2/vehicles
GkeepApi.V2Api getVehiclesDailyStats GET /api/v2/vehicles/{vehicleId}/daily-statistics
GkeepApi.V2Api getVehiclesFrameHistory GET /api/v2/vehicles/{vehicleId}/frame-history
GkeepApi.V2Api getVehiclesRefuels GET /api/v2/vehicles/{vehicleId}/refuels
GkeepApi.V2Api getVehiclesStoppedConsumptions GET /api/v2/vehicles/{vehicleId}/stopped-consumptions
GkeepApi.V2Api refreshApiToken PUT /api/v2/user-profiles/tokens/refresh
GkeepApi.V2Api updateNotificationSettings PUT /api/v2/user-profiles/notification-settings
GkeepApi.V2Api updateUserProfile PUT /api/v2/user-profiles/{profileId}
GkeepApi.V2Api updateVehicle PUT /api/v2/vehicles/{vehicleId}
GkeepApi.V2Api updateVehicleCategory PUT /api/v2/vehicles/categories/{categoryId}

Documentation for Models

Documentation for Authorization

bearerAuth

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published