appshark-sdk
v1.0.2
Published
Readme
appshark-sdk
Import:
import Appshark from 'appshark-sdk';
const appshark = new Appshark({
apiUrl: '<API_DOMAIN>/api/v1/',
apiKey: '<API_KEY>'
});Methods:
Config
GET: get your Appshark instance Config :
appshark.config.get()
.then(response => console.log(response.data));Inquiries
POST: save an Inquiry in your Appshark instance:
appshark.inquiries.post({
firstname: 'Pepe',
lastname: 'Potamo',
email: '[email protected]',
content: 'Hi!'
}).then(response => console.log(response.data));Menus
GET: get Menus in your Appshark instance:
appshark.menus.get()
.then(response => console.log(response.data));Pages
GET: get Pages in your Appshark instance:
appshark.pages.get({
q: 'home', // query to look for
p: 5, // page number
limit: 10, // result limits
}).then(response => console.log(response.data));