New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

node-shopify

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-shopify - npm Package Compare versions

Comparing version 4.0.1 to 4.1.0

5

lib/index.d.ts

@@ -39,2 +39,7 @@ import { Result } from 'node-result';

getProductsCount(): Promise<Result<Error, number>>;
getProductListings(): Promise<import("node-result").ResultOK<object[]>>;
getProductListingIds(): Promise<import("node-result").ResultOK<number[]>>;
createProductListing(productId: number): Promise<import("node-result").ResultOK<object>>;
getProductListing(productId: number): Promise<import("node-result").ResultOK<object>>;
deleteProductListing(productId: number): Promise<Result<Error, null>>;
}

@@ -181,2 +181,32 @@ "use strict";

}
async getProductListings() {
const url = '/admin/api/2021-01/product_listings.json';
const { data: { product_listings } } = (await this.instance.get(url)).unwrap();
return node_result_1.ResultOk(product_listings);
}
async getProductListingIds() {
const url = '/admin/api/2021-01/product_listings/product_ids.json';
const { data: { product_ids } } = (await this.instance.get(url)).unwrap();
return node_result_1.ResultOk(product_ids);
}
async createProductListing(productId) {
const url = `/admin/api/2021-01/product_listings/${productId}.json`;
const payload = {
product_listing: {
product_id: productId
}
};
const { data: { product_listing } } = (await this.instance.put(url, payload)).unwrap();
return node_result_1.ResultOk(product_listing);
}
async getProductListing(productId) {
const url = `/admin/api/2021-01/product_listings/${productId}.json`;
const { data: { product_listing } } = (await this.instance.get(url)).unwrap();
return node_result_1.ResultOk(product_listing);
}
async deleteProductListing(productId) {
const url = `/admin/api/2021-01/product_listings/${productId}.json`;
(await this.instance.delete(url)).unwrap();
return node_result_1.ResultOk(null);
}
}

@@ -267,2 +297,17 @@ __decorate([

], Shopify.prototype, "getProductsCount", null);
__decorate([
node_result_1.tryCatchWrapperAsync
], Shopify.prototype, "getProductListings", null);
__decorate([
node_result_1.tryCatchWrapperAsync
], Shopify.prototype, "getProductListingIds", null);
__decorate([
node_result_1.tryCatchWrapperAsync
], Shopify.prototype, "createProductListing", null);
__decorate([
node_result_1.tryCatchWrapperAsync
], Shopify.prototype, "getProductListing", null);
__decorate([
node_result_1.tryCatchWrapperAsync
], Shopify.prototype, "deleteProductListing", null);
exports.Shopify = Shopify;

2

package.json
{
"name": "node-shopify",
"version": "4.0.1",
"version": "4.1.0",
"description": "shopify",

@@ -5,0 +5,0 @@ "keywords": [

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