Skip to content

Instantly share code, notes, and snippets.

@sharoonthomas
Created September 8, 2016 20:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sharoonthomas/31554afe673e1273031870813e37c969 to your computer and use it in GitHub Desktop.
Save sharoonthomas/31554afe673e1273031870813e37c969 to your computer and use it in GitHub Desktop.
Fulfil.IO Javascript/Node API

API Overview

Get a Fulfil client instance to .

var fulfil = require('fulfil');
var fulfilClient = require('fulfil').client('<subdomain>', '<api-key>');

Get a specific resource

var productModel = fulfilClient.model('product.product');

Create a new record

productModel.create([
  {template: 1, variant_name: 'Apple iPhone 6'}
])
.then(function(ids) {
  // The ids would be a list of ids
})
}).catch(function(err) {
  // Deal with an error
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment