shopify-node
Advanced tools
Comparing version 0.2.4 to 1.0.0
{ | ||
"name": "shopify-node", | ||
"description": "A NodeJS connector for Shopify OAuth2", | ||
"version": "0.2.4", | ||
"author": { | ||
"name": "uh-sem-blee, Co. | typefoo", | ||
"email": "hello@typefoo.com" | ||
"version": "1.0.0", | ||
"description": "", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"maintainers": [ | ||
{ | ||
"name": "jjosef", | ||
"email": "john@typefoo.com" | ||
} | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/typefoo/shopify-node" | ||
"url": "git+https://github.com/npm/deprecate-holder.git" | ||
}, | ||
"devDependencies": { | ||
"prompt": ">= 0.2.11" | ||
}, | ||
"main": "./lib/shopify", | ||
"engines": { | ||
"node": ">= 0.10.0" | ||
}, | ||
"readmeFilename": "README.md", | ||
"author": "", | ||
"license": "ISC", | ||
"bugs": { | ||
"url": "https://github.com/typefoo/shopify-node/issues" | ||
"url": "https://github.com/npm/deprecate-holder/issues" | ||
}, | ||
"license": "MIT" | ||
"homepage": "https://github.com/npm/deprecate-holder#readme" | ||
} |
@@ -1,98 +0,5 @@ | ||
# Shopify Node | ||
# Deprecated Package | ||
npm install shopify-node | ||
This package is no longer supported and has been deprecated. To avoid malicious use, npm is hanging on to the package name. | ||
You can run the test by cloning this repo and running: | ||
npm install | ||
node test/test | ||
For setting up: | ||
var shopifyObj = require('shopify-node'); | ||
var shopify = new shopifyObj({ | ||
shop_name: 'typefoo', | ||
id: '639e5b59d03a4135d4f4cd176d8b0d0c', | ||
secret: '07e3e4d5711054ead625ac7356552660', | ||
redirect: 'http://localhost:9000/#/oauth' | ||
// scope: 'write_products', as an example. The default scope has access to all. | ||
// For more on scopes: http://docs.shopify.com/api/tutorials/oauth | ||
}); | ||
var url = shopify.createURL(); | ||
After you have obtained the 'code' (either via your redirect or elsewhere): | ||
var code = ''; // put the short-time auth code in here. | ||
shopify.getAccessToken(code, function(err, access_token) { | ||
console.log(err); | ||
console.log(access_token); | ||
}); | ||
If you have saved your access token in some sort of session or cookie data, you can skip the authorization request: | ||
var shopify = new shopifyObj({ | ||
shop_name: 'typefoo', | ||
id: '639e5b59d03a4135d4f4cd176d8b0d0c', | ||
secret: '07e3e4d5711054ead625ac7356552660', | ||
redirect: 'http://localhost:9000/#/oauth', | ||
access_token: '' // your access token to be used | ||
}); | ||
Once authorized, you can perform typical REST services (http://docs.shopify.com/api/ for reference): | ||
// GET | ||
shopify.get('/admin/orders.json', function(err, resp) { | ||
if(err) { | ||
return console.log(err); | ||
} | ||
console.log(resp); | ||
}); | ||
// POST | ||
var postData = { | ||
product: { | ||
title: 'Burton Custom Freestlye 151', | ||
body_html: '<strong>Good snowboard!</strong>', | ||
vendor: 'Burton', | ||
product_type: 'Snowboard', | ||
variants: [ | ||
{ | ||
option1: 'First', | ||
price: '10.00', | ||
sku: 123 | ||
}, | ||
{ | ||
option1: 'Second', | ||
price: '20.00', | ||
sku: '123' | ||
} | ||
] | ||
} | ||
}; | ||
shopify.post('/admin/products.json', postData, function(err, resp) { | ||
if(err) { | ||
return console.log(err); | ||
} | ||
console.log(resp); | ||
}); | ||
// PUT | ||
shopify.put('/admin/products/1234.json', postData, function(err, resp) { | ||
if(err) { | ||
return console.log(err); | ||
} | ||
console.log(resp); | ||
}); | ||
// DELETE | ||
shopify.delete('/admin/products/1234.json', function(err, resp) { | ||
if(err) { | ||
return console.log(err); | ||
} | ||
console.log(resp); | ||
}); | ||
Built in Carolina & Ohio. www.typefoo.com | ||
Please contact support@npmjs.com if you have questions about this package. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Empty package
Supply chain riskPackage does not contain any code. It may be removed, is name squatting, or the result of a faulty package publish.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No contributors or author data
MaintenancePackage does not specify a list of contributors or an author in package.json.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
0
1
675
2
0
6
3