{"name":"popsicle-retry","version":"3.2.0","description":"Enable request retries for Popsicle","main":"dist/index.js","files":["dist/","typings.json","LICENSE"],"scripts":{"lint":"tslint \"src/**/*.ts\"","build":"rm -rf dist/ && tsc","test-spec":"blue-tape test/index.js | tap-spec","test-cov":"istanbul cover --print none blue-tape -- test/index.js | tap-spec","test":"npm run lint && npm run build && npm run test-cov","prepublish":"typings install && npm run build"},"repository":{"type":"git","url":"git://github.com/blakeembrey/popsicle-retry.git"},"keywords":["popsicle","retry","fail","5xx","error","http"],"author":{"name":"Blake Embrey","email":"hello@blakeembrey.com","url":"http://blakeembrey.me"},"license":"Apache-2.0","bugs":{"url":"https://github.com/blakeembrey/popsicle-retry/issues"},"homepage":"https://github.com/blakeembrey/popsicle-retry","devDependencies":{"blue-tape":"^0.2.0","bluebird":"^3.2.2","express":"^4.13.4","istanbul":"^0.4.2","popsicle":"^6.1.0","tap-spec":"^4.1.1","tslint":"^3.1.1","typescript":"^1.7.3","typings":"^1.2.0"},"dependencies":{"any-promise":"^1.1.0","xtend":"^4.0.1"},"gitHead":"1e3add5d5e075e936bed52231fa76ef09e025b9e","_id":"popsicle-retry@3.2.0","_shasum":"0007c1e58c063e482ba20a44d2b05851dc7c7242","_from":".","_npmVersion":"3.9.3","_nodeVersion":"6.2.1","_npmUser":{"name":"blakeembrey","email":"hello@blakeembrey.com"},"dist":{"shasum":"0007c1e58c063e482ba20a44d2b05851dc7c7242","tarball":"http://registry-npm.ywwl.com/popsicle-retry/download/popsicle-retry-3.2.0.tgz","integrity":"sha512-DCkH/BKBpPMyE/eZ4JYocoh+XdZKpGBZsWYxQnSl4ryHLaykC+5HA9bMsLijNsVpOR2Bw5r4K/JAoFKnNT9X+A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDq2Rf6c4Sw/EFxgEljFNBVB97vjqAzd06cXwIfzjy2DQIgfnuSWZ3LbkbXw0zt3yJ2zGAgoKGgmaqQzPLierJ81c4="}],"size":3541,"noattachment":false,"key":"/popsicle-retry/-/popsicle-retry-3.2.0.tgz"},"maintainers":[{"name":"blakeembrey","email":"hello@blakeembrey.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/popsicle-retry-3.2.0.tgz_1466012043706_0.5140440159011632"},"directories":{},"readme":"# Popsicle Retry\n\n[![NPM version][npm-image]][npm-url]\n[![NPM downloads][downloads-image]][downloads-url]\n[![Build status][travis-image]][travis-url]\n[![Test coverage][coveralls-image]][coveralls-url]\n\n> Enable request retry for Popsicle.\n\n## Installation\n\n```\nnpm install popsicle-retry --save\n```\n\n## Usage\n\n```js\nimport { retry } from \"popsicle-retry\";\n\nconst send = retry(transport);\nconst res = await send(req);\n```\n\n### Methods\n\n- **retry(fn, shouldRetry?)** Wraps a request function with retry support. Accepts a second function that returns a delay, or `-1` (default is `retries()`).\n- **retryAllowed(error?, request?)** Check if a request should be retried. Defaults to `5xx` and unavailable errors.\n- **retries(count?, isRetryAllowed?)** An exponential back-off function, defaulting to 3 retries.\n\n## License\n\nApache 2.0\n\n[npm-image]: https://img.shields.io/npm/v/popsicle-retry.svg?style=flat\n[npm-url]: https://npmjs.org/package/popsicle-retry\n[downloads-image]: https://img.shields.io/npm/dm/popsicle-retry.svg?style=flat\n[downloads-url]: https://npmjs.org/package/popsicle-retry\n[travis-image]: https://img.shields.io/travis/serviejs/popsicle-retry.svg?style=flat\n[travis-url]: https://travis-ci.org/serviejs/popsicle-retry\n[coveralls-image]: https://img.shields.io/coveralls/serviejs/popsicle-retry.svg?style=flat\n[coveralls-url]: https://coveralls.io/r/serviejs/popsicle-retry?branch=master\n","publish_time":1466012044411,"_cnpm_publish_time":1466012044411,"dist-tags":{"latest":"4.1.0"}}