Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

contentstack

Package Overview
Dependencies
Maintainers
1
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

contentstack

The Built.io Contentstack Javascript SDK

  • 0.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
48K
decreased by-24.63%
Maintainers
1
Weekly downloads
 
Created
Source

contentstack.io logo

##Javascript SDK for Built.io Contentstack ##Prerequisite You need to install node.js v0.10.22 or later to use the Built.io Contentstack SDK. ## Installation You might need administrator privileges to perform this installation. ```bash $ npm install contentstack ``` To require the SDK module in your application use the following command. ```bash $ var contentstack = require('contentstack'); ``` ## Basic Structure The structure followed by SDK logically resembles the site structure on Built.io Contentstack. Once you have done the basic setup explained in the Installation section, you get a Built.io Contentstack object, which can be used to initialize different modules. The initialization process for each module is explained below. ###Site To initialize a site, you need to provide the required keys and values associated with them. ```bash var site = contentstack.Site({"site_api_key":"abcdef1234567890","access_token":9876543210qwerty","environment":"development"}); ``` Let us take an example where we try to obtain all entries of the form my_form. ```bash var entry = site.Form('my_form').Query(); entry //add query methods here .find() .then(function(data){ //data will contain entries from the form my_form; },function(err){ //displays a detailed error in case of failure; }); ``` Let us take another example where we try to obtain only a specific entry from the form my_form. ```bash var entry = site.Form('my_form').Entry(uid); entry //add query methods here .fetch() .then(function(data){ //data will contain entries from the form my_form; },function(err){ //displays a detailed error in case of failure; }); ``` -----

License

MIT Copyright © 2014 raw engineering, inc.

FAQs

Package last updated on 16 Jul 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc