Socket
Socket
Sign inDemoInstall

ebay-promised

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ebay-promised - npm Package Compare versions

Comparing version 1.3.0 to 1.4.0

README.md

2

lib/definitions/globals.js
// Generated by CoffeeScript 1.9.1
module.exports = ["authToken", "cert", "devName", 'serviceName', 'appId', "sandbox", "site", "app", "raw", "perPage"];
module.exports = ["authToken", "cert", "devName", 'serviceName', 'appId', "sandbox", "site", "app", "raw", "perPage", "callsPerEpoc", "epoc"];

@@ -42,3 +42,5 @@ // Generated by CoffeeScript 1.9.1

raw: false,
perPage: 100
perPage: 100,
callsPerEpoc: 3,
epoc: 1000
}

@@ -79,4 +81,15 @@ };

function Ebay() {
this.wrappedRequest = limit(request).to(3).per(1000);
function Ebay(options) {
var i, len, ref, setting;
if (options == null) {
options = {};
}
ref = Object.keys(options);
for (i = 0, len = ref.length; i < len; i++) {
setting = ref[i];
if (this.respondsTo(setting)) {
this[setting](options[setting]);
}
}
this.__request__ = limit(this.__request__.bind(this)).to(this.callsPerEpoc()).per(this.epoc());
this;

@@ -93,2 +106,7 @@ }

Ebay.prototype.reset = function() {
this.__fields__ = defaults.__fields__;
return this;
};
Ebay.prototype.endpoint = function() {

@@ -131,3 +149,3 @@ if (!endpoints[this.serviceName()]) {

Ebay.prototype.__build__ = function(pageNumber) {
var body, doc, xml;
var body, doc;
if (pageNumber == null) {

@@ -146,5 +164,3 @@ pageNumber = 1;

doc[(this.op()) + "Request xmlns=\"urn:ebay:apis:eBLBaseComponents\""] = _.extend.apply(_, body);
debug(this.endpoint());
xml = o2x(doc);
return xml;
return o2x(doc);
};

@@ -167,3 +183,4 @@

}
req = this.wrappedRequest.post({
debug("starting request...");
req = request.post({
url: this.endpoint(),

@@ -170,0 +187,0 @@ body: this.__build__(page),

@@ -127,3 +127,2 @@ // Generated by CoffeeScript 1.9.1

parsed = {};
debug("[normalizingResponse] ...");
root = results[(this.op()) + "Response"];

@@ -130,0 +129,0 @@ keys = Lazy(Object.keys(root));

{
"name": "ebay-promised",
"version": "1.3.0",
"version": "1.4.0",
"description": "promise wrapped Ebay requests with sensible response parsers",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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