Giter Site home page Giter Site logo

node-saasgrid's Introduction

saasgrids

crms - JavaScript client for saasgrids Saasgrids CRM grid 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.languages.JavascriptClientCodegen

Installation

npm

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

Then install it via:

npm install saasgrids --save
Local development

To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json (and this README). Let's call this JAVASCRIPT_CLIENT_DIR. Then run:

npm install

Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR:

npm link

Finally, switch to the directory you want to use your saasgrids from, and run:

npm link /path/to/<JAVASCRIPT_CLIENT_DIR>

You should now be able to require('saasgrids') in javascript files from the directory you ran the last command above from.

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, that's to say your javascript file where you actually use this library):

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 crms = require('saasgrids');

var defaultClient = crms.ApiClient.instance;

// Configure HTTP basic authorization: basicAuth
var basicAuth = defaultClient.authentications['basicAuth'];
basicAuth.username = 'YOUR USERNAME'
basicAuth.password = 'YOUR PASSWORD'

var api = new crms.AccountsApi()

var userId = "userId_example"; // {String} User instance id returned from saasgrids after authorization

var body = new crms.Account(); // {Account} Account object that needs to be created

api.createAccount(userId, body).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Documentation for API Endpoints

All URIs are relative to https://api.saasgrids.com/apis/crms/

Class Method HTTP request Description
crms.AccountsApi createAccount POST /{userId}/accounts Creates a new account
crms.AccountsApi deleteAccountById DELETE /{userId}/account/{accountId} Delete account by Id
crms.AccountsApi getAccountById GET /{userId}/account/{accountId} Get account by Id
crms.AccountsApi getAccountFilters GET /{userId}/accounts/filters Get all account filters
crms.AccountsApi getAccountsByFilter GET /{userId}/accounts/filters/{filterId} Get all accounts by filter
crms.AccountsApi getAllAccounts GET /{userId}/accounts Get all accounts
crms.AccountsApi updateAccountById PUT /{userId}/account/{accountId} Update account by Id
crms.AppointmentsApi createAppointment POST /{userId}/appointments Creates a new appointment
crms.AppointmentsApi deleteAppointmentsById DELETE /{userId}/appointments/{appointmentId} Delete appointments by Id
crms.AppointmentsApi getAllAppointments GET /{userId}/appointments Get all appointments
crms.AppointmentsApi getAppointmentById GET /{userId}/appointments/{appointmentId} Get appointment by Id
crms.AppointmentsApi updateAppointmentById PUT /{userId}/appointments/{appointmentId} Update appointment by Id
crms.CallsApi createCall POST /{userId}/calls Creates a new call
crms.CallsApi deleteCallById DELETE /{userId}/calls/{callId} Delete call by Id
crms.CallsApi getAllCalls GET /{userId}/calls Get all calls
crms.CallsApi getCallById GET /{userId}/calls/{callId} Get call by Id
crms.CallsApi updateCallById PUT /{userId}/calls/{callId} Update call by Id
crms.ContactsApi createContact POST /{userId}/contacts Creates a new contact
crms.ContactsApi deleteContactById DELETE /{userId}/contacts/{contactId} Delete contact by Id
crms.ContactsApi getContactByFilter GET /{userId}/contacts/filters/{filterId} Get all contacts by filter
crms.ContactsApi getContactById GET /{userId}/contacts/{contactId} Get contact by Id
crms.ContactsApi getContactFilters GET /{userId}/contacts/filters Get all contact filters
crms.ContactsApi getContactProperties GET /{userId}/contacts/properties Get all contact properties
crms.ContactsApi getContacts GET /{userId}/contacts Get contacts
crms.ContactsApi getContactsByEmail GET /{userId}/contacts/email/{email} Get all contacts by email
crms.ContactsApi updateContactById PUT /{userId}/contacts/{contactId} Update contact by Id
crms.DealsApi createDeals POST /{userId}/deals Creates a new deals
crms.DealsApi deleteDealById DELETE /{userId}/deal/{dealId} Delete deal by Id
crms.DealsApi getAllDeal GET /{userId}/deals Get all deal
crms.DealsApi getDealById GET /{userId}/deal/{dealId} Get deal by Id
crms.DealsApi updateDealById PUT /{userId}/deal/{dealId} Update deal by Id
crms.EmailsApi createEmail POST /{userId}/emails Creates a new email
crms.EmailsApi deleteEmailById DELETE /{userId}/emails/{emailObjectId} Delete email by Id
crms.EmailsApi getAllEmails GET /{userId}/emails Get all emails
crms.EmailsApi getEmailById GET /{userId}/emails/{emailObjectId} Get email by Id
crms.EmailsApi updateEmailById PUT /{userId}/emails/{emailObjectId} Update email by Id
crms.LeadsApi createLead POST /{userId}/leads Creates a new lead
crms.LeadsApi deleteLeadById DELETE /{userId}/leads/{leadId} Delete lead by Id
crms.LeadsApi getAllLeads GET /{userId}/leads Get all leads
crms.LeadsApi getLeadById GET /{userId}/leads/{leadId} Get lead by Id
crms.LeadsApi getLeadFilters GET /{userId}/leads/filters Get all lead filters
crms.LeadsApi getLeadsByFilter GET /{userId}/leads/filters/{filterId} Get all leads by filter
crms.LeadsApi updateLeadById PUT /{userId}/leads/{leadId} Update lead by Id
crms.NotesApi createNote POST /{userId}/notes Creates a new note
crms.NotesApi deleteNoteById DELETE /{userId}/note/{noteId} Delete note by Id
crms.NotesApi getAllNotes GET /{userId}/notes Get all notes
crms.NotesApi getNoteById GET /{userId}/note/{noteId} Get note by Id
crms.NotesApi updateNoteById PUT /{userId}/note/{noteId} Update note by Id
crms.TasksApi createTask POST /{userId}/tasks Creates a new task
crms.TasksApi deleteTaskById DELETE /{userId}/tasks/{taskId} Delete task by Id
crms.TasksApi getAllTasks GET /{userId}/tasks Get all tasks
crms.TasksApi getTaskById GET /{userId}/tasks/{taskId} Get task by Id
crms.TasksApi updateTaskById PUT /{userId}/tasks/{taskId} Update task by Id
crms.UsersApi getUsers GET /{userId}/users/{email} Get all users

Documentation for Models

Documentation for Authorization

basicAuth

  • Type: HTTP basic authentication

node-saasgrid's People

Contributors

gokultp avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

dakotamccarty

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.