2.1.0 • Published 9 years ago

montagedata v2.1.0

Weekly downloads
107
License
-
Repository
github
Last release
9 years ago

==================

Javascript Montage

A Javascript wrapper for the Montage API

Installation

Install dependencies::

npm install

Run tests::

gulp test

Compile to ES5::

gulp build

Compile for the browser::

webpack

Usage

From a script tag::

Create a client object::

import {Client, Query} from 'montagedata'

//generate a token var client = new Client({ username: "YOUR_USERNAME", password: "YOUR_PASSWORD", api_version: 1, //default domain: "test" //Your Montage subdomain url: "" //full url to montage api, for testing });

client.auth().then(response => { var token = response.token.value; });

//client with only a token (recommended) var client = new Client({ token: "YOUR_TOKEN", domain: "test" //Your Montage subdomain });

File Uploads

Pass a FormData object like so::

client.files(formData).then(function(response){ console.log(response) })

Using a client::

var query = new Query() .where({"rating__gt": 4}) .limit(10) .order("rating", -1); client.documents("movies", query).then(movies => { console.log(movies); });

2.1.0

9 years ago

0.5.2

10 years ago

0.5.1

10 years ago

0.5.0

10 years ago

0.4.0

10 years ago

0.3.1

10 years ago

0.3.0

10 years ago

0.1.8

10 years ago

0.1.7

10 years ago

0.1.6

10 years ago

0.1.5

10 years ago

0.1.4

10 years ago

0.1.3

10 years ago

0.1.2

10 years ago

0.1.1

10 years ago

0.1.0

10 years ago

0.0.10

10 years ago

0.0.9

10 years ago

0.0.8

10 years ago

0.0.7

10 years ago

0.0.6

10 years ago

0.0.5

10 years ago

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago