"readme":"# npm-registry-client\n\nThe code that npm uses to talk to the registry.\n\nIt handles all the caching and HTTP calls.\n\n## Usage\n\n```javascript\nvar RegClient = require('npm-registry-client')\nvar client = new RegClient(options)\n\nclient.get(\"npm\", \"latest\", 1000, function (er, data, raw, res) {\n // error is an error if there was a problem.\n // data is the parsed data object\n // raw is the json string\n // res is the response from couch\n})\n```\n\n# Options\n\n* `registry` **Required** {String} URL to the registry\n* `cache` **Required** {String} Path to the cache folder\n* `alwaysAuth` {Boolean} Auth even for GET requests.\n* `auth` {String} A base64-encoded `username:password`\n* `email` {String} User's email address\n* `tag` {String} The default tag to use when publishing new packages.\n Default = `\"latest\"`\n* `ca` {String} Cerficate signing authority certificates to trust.\n* `strictSSL` {Boolean} Whether or not to be strict with SSL\n certificates. Default = `true`\n* `userAgent` {String} User agent header to send. Default =\n `\"node/{process.version}\"`\n* `log` {Object} The logger to use. Defaults to `require(\"npmlog\")`if\nthatworks,otherwiselogsaredisabled.\n\n#client.request(method,where,[what],[etag],[nofollow],cb)\n\n*`method`{String}HTTPmethod\n*`where`{String}Pathtorequestontheserver\n*`what`{Stream|Buffer|String|Object}Therequestbody.Objects\nthatarenotBuffersorStreamsareencodedasJSON.\n*`etag`{String}ThecachedETag\n*`nofollow`{Boolean}Preventfollowing302/301responses\n*`cb`{Function}\n*`error`{Error|null}\n*`data`{Object}theparseddataobject\n*`raw`{String}thejson\n*`res`{ResponseObject}responsefromcouch\n\nMakearequesttotheregistry.Alltheothermethodsarewrappers\naroundthis.one.\n\n#client.adduser(username,password,email,cb)\n\n*`username`{String}\n*`password`{String}\n*`email`{String}\n*`cb`{Function}\n\nAddauseraccounttotheregistry,orverifythecredentials.\n\n#client.get(url,[timeout],[nofollow],[staleOk],cb)\n\n*`url`{String}Theurlpathtofetch\n*`timeout`{Number}Numberofsecondsoldthatacachedcopymustbe\nbeforeanewrequestwillbemade.\n*`nofollow`{Boolean}Donotfollow301/302responses\n*`staleOk`{Boolean}Ifthere'scacheddataavailable,thenreturnthat\ntothecallbackquickly,andupdatethecachethebackground.\n\nFetchesdatafromtheregistryviaaGETrequest,savingitin\nthecachefolderwiththeETag.\n\n#client.publish(data,tarball,[readme],cb)\n\n*`data`{Object}Packagedata\n*`tarball`{String|Stream}Filenameorstreamofthepackagetarball\n*`readme`{String}ContentsoftheREADMEmarkdownfile\n*`cb`{Function}\n\nPublishapackagetotheregistry.\n\nNotethatthisdoesnotcreatethetarballfromafolder.However,it\ncanacceptagzippedtarstreamorafilenametoatarball.\n\n#client.star(package,starred,cb)\n\n*`package`{String}Nameofthepackagetostar\n*`starred`{Boolean}Truetostarthepackage,falsetounstarit.\n*`cb`{Function}\n\nStarorunstarapackage.\n\nNotethattheuserdoesnothavetobethepackageownertostaror\nunstarapackage,thoughotherwritesdorequirethattheuserbethe\npackageowner.\n\n#client.tag(project,version,tag,cb)\n\n*`project`{String}Projectname\n*`version`{String}Versiontotag\n*`tag`{String}Tagnametoapply\n*`cb`{Function}\n\nMarkaversioninthe`dist-tags`hash,sothat`pkg@tag`\nwillfetchthespecifiedversion.\n\n#client.unpublish(name,[ver],cb)\n\n*`name`{String}packagename\n*`ver`{String}versiontounpublish.Leaveblanktounpublishall\nversions.\n*`cb`{Function}\n\nRemoveaversionofapackage(orallversions)fromtheregistry.When\nthelastversionusunpublished,theentiredocumentisremovedfromthe\ndatabase.\n\n#client.upload(where,file,[etag],[nofollow],cb)\n\n*`where`{String}URLpathtouploadto\n*`file`{String|Stream}Eitherthefile