New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

node-storyblok

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-storyblok

Storyblok API interface for Node.js (4+)

latest
Source
npmnpm
Version
2.0.0
Version published
Maintainers
1
Created
Source

node-storyblok

Build Status

Install

npm i node-storyblok

Usage

Class Storyblok

Parameters

  • tokens Object, public and private token
  • (endpoint if using a seperate Storyblok API instance)

Example

const Storyblok = require('node-storyblok');
let sb = new Storyblok({ public: 'public_key_here' });

Method Storyblok#getStory

Parameters

  • [return] Promise, Object story
  • id String, story-id
  • options Object
    • version String, default: Storyblok.MODE_PUBLISHED

Example

let sb = new Storyblok({ public: 'public_key_here' });
sb.getStory('home')
  .then((response) => {
    response.story;
  });

Method Storyblok#getStories

Parameters

  • [return] Promise, Array stories
  • options Object
    • version String, default: Storyblok.MODE_PUBLISHED

Example

let sb = new Storyblok({ public: 'public_key_here' });
sb.getStories()
  .then((response) => {
    response.stories;
  });

Contribution

Fork me on Github

Keywords

storyblok

FAQs

Package last updated on 10 Jul 2018

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