npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

sellix-api-wrapper

v1.0.7

Published

A Complete NodeJS wrapper for the Sellix API

Downloads

6

Readme

sellix-api-wrapper

A complete NodeJS wrapper for the Sellix.io API.

Description

The purpose of this wrapper is to easily implement the Sellix API into your project and retrieve realtime data about your shop, restock and modify your products, view and reply to queries, and more.

Requirements

In order to use the API calls, you need your API Key from the Sellix.io website. Find your key on the security page.

Installation

npm i sellix-api-wrapper

Usage

const Sellix = require('sellix-api-wrapper');
const API = new Sellix.API('YOUR_API_KEY')

API.getAllOrders().then(res=>{
  console.log(res);
});

API.createCoupon("COUPON15OFF",15,-1,{"69571749194","695317319"}).then(res=>{
  console.log(res);
});

API.editProduct("demo65ab9133",{"Serials":["L1IELQ5","39131031"]}).then(res=>{
  console.log(res);
});

API Endpoints

Orders

getAllOrders()

Fetches all orders sorted by creation date.

getOrder(id)

Fetches a specific order by ID.

Products

getAllProducts()

Fetches all products sorted by creation date.

getProduct(id)

Fetches a specific product by ID.

createProduct(title, description, price, gateways, type, discount_value, custom_fields)

Creates a product with the given fields. Use custom_fields to declare non-required arguments.
See Sellix Documentation on Product Arguments

API.createProduct("Product Title","New Product Desc",10.99,["STRIPE","BITCOIN"],"serials",0.0,{"crypto_confirmations_needed":2,"delivery_text":"Enjoy your product"}).then(res=>{
console.log(res);
});

editProduct(id, custom_fields)

Edits a specific product by ID. Use custom_fields to declare the arguments to edit.
See Sellix Documentation on Product Arguments

API.editProduct("95619023",{"Title":"New Title","Price":25.99,"Serials":["AU9103PQE","GQOU3QLWE"]}).then(res=>{
console.log(res);
})

deleteProduct(id)

Deletes a specific product by ID.

Queries

getAllQueries()

Fetches all queries sorted by creation date.

getQuery(id)

Fetches a specific query by ID.

replyQuery(id, reply)

Replies to a specific query by ID.

API.replyQuery("demo2ab29431","Have you tried reinstalling?").then(res=>{
  console.log(res);
});

closeQuery(id)

Closes a specific query by ID.

reopenQuery(id)

Reopens a specific query by ID.

Coupons

getAllCoupons()

Fetches all coupons sorted by creation date.

getCoupon(id)

Fetches a specific coupon by ID.

createCoupon(code, discount_value, max_uses, products_bound)

Creates a coupon with the given fields.

API.createCoupon("COUPON15",15,-1,{"695841804","695841805"}).then(res=>{
  console.log(res);
});

editCoupon(id, custom_fields)

Edits a coupon by ID. Use custom_fields to declare the arguments to edit.
See Sellix Documentation on Coupon Arguments

API.editCoupon("demo6a3b178",{"code":"COUPON5","discount_value":5,"max_uses":5}).then(res=>{
  console.log(res);
});

deleteCoupon(id)

Deletes a specific coupon by ID.

Feedback

getAllFeedback()

Fetches all feedback sorted by creation date.

getFeedback(id)

Fetches a specific feedback by ID.

replyFeedback(id, reply)

Replies to a specific feedback by ID.

API.replyFeedback("demo1a83b7","Thanks for the feedback!").then(res=>{
  console.log(res);
});

Blacklist

getAllBlacklist()

Fetches all blacklist sorted by creation date.

getBlacklist(id)

Fetches a specific blacklist by ID.

createBlacklist(type, data, note)

Creates a blacklist using the given fields. Type must be 'email', 'ip', or 'country'. Data is blocked data. Note is optional.

API.createBlacklist("email","[email protected]","Banned from shop").then(res=>{
  console.log(res);
});

updateBlacklist(id, type, data, note)

Updates a specific blacklist by ID. See above for arguments.

API.updateBlacklist("demo6abc1f4","ip","273.314.1.31").then(res=>{
  console.log(res);
});

deleteBlacklist(id)

Deletes a specific blacklist by ID.

Payments (WIP)

createPayment(title, product_id, quantity, gateway, value, confirmations, email, custom_fields)

Creates a payment with the given fields. Use custom_fields to declare non-required arguments.
Visit Sellix Documentation on Creating Payments

deletePayment(id)

Deletes a payment by id.