1.0.1 • Published 2 years ago
bh-node-api v1.0.1
BlogHunch Node SDK
BlogHunch Node API helps you to easily access the API to fetch posts, pages etc.
Features
- Fetch publication details.
- Fetch all posts and pages.
- Fetch SEO asscoiated to single posts or pages.
Installation
BlogHunch Node.js SDK v10+ to run.
Install the dependencies and devDependencies and start the server.
npm install bh-node-api
How to use
import { getAllPosts, getPost } from 'bh-node-api'
Get all posts:
const posts = await getAllPosts(apiKey, publicationDomain or publicationSubdomain)
Get single post:
const post = await getPost(apiKey, publicationDomain or publicationSubdomain, slug)
License
MIT