Skip to content

Instantly share code, notes, and snippets.

@madhums madhums/res.js
Last active Aug 29, 2015

Embed
What would you like to do?
returned object
function callback (err, res) {
// res.request.href => is this is url of the uploaded file?
}
fs.createReadStream('image-1.png').pipe(client.upload({
container: 'a-container',
remote: 'image-1.png'
}), callback);
// res =>
/*
{ _readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: true,
endEmitted: true,
reading: false,
sync: false,
needReadable: false,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: false,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [ [Function: responseOnEnd], [Function], [Function] ],
close: [ [Function], [Function] ],
data: [Function] },
_maxListeners: undefined,
socket:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 88039,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
connection:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 88039,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
httpVersion: '1.1',
complete: true,
headers:
{ 'last-modified': 'Mon, 22 Sep 2014 13:54:54 GMT',
'content-length': '0',
etag: 'd60c38b56a90f0986c0996b2182f8ace',
'content-type': 'text/html; charset=UTF-8',
'x-trans-id': 'tx58e9e9ba78814fbd84b77-0054202a2diad3',
date: 'Mon, 22 Sep 2014 13:54:54 GMT',
connection: 'close' },
rawHeaders:
[ 'Last-Modified',
'Mon, 22 Sep 2014 13:54:54 GMT',
'Content-Length',
'0',
'Etag',
'd60c38b56a90f0986c0996b2182f8ace',
'Content-Type',
'text/html; charset=UTF-8',
'X-Trans-Id',
'tx58e9e9ba78814fbd84b77-0054202a2diad3',
'Date',
'Mon, 22 Sep 2014 13:54:54 GMT',
'Connection',
'close' ],
trailers: {},
rawTrailers: [],
_pendings: [],
_pendingIndex: 0,
url: '',
method: null,
statusCode: 201,
statusMessage: 'Created',
client:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 88039,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
_consuming: true,
_dumped: false,
httpVersionMajor: 1,
httpVersionMinor: 1,
upgrade: false,
req:
{ domain: null,
_events: { error: [Function], drain: [Function] },
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState: [Object],
readable: false,
domain: null,
_events: [Object],
_maxListeners: undefined,
_writableState: [Object],
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 88039,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions: [Object],
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl: [Object],
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage: [Circular],
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
connection:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState: [Object],
readable: false,
domain: null,
_events: [Object],
_maxListeners: undefined,
_writableState: [Object],
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 88039,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions: [Object],
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl: [Object],
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage: [Circular],
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
agent:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
defaultPort: 443,
protocol: 'https:',
options: [Object],
requests: {},
sockets: [Object],
freeSockets: {},
keepAliveMsecs: 1000,
keepAlive: false,
maxSockets: Infinity,
maxFreeSockets: 256 },
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_headers:
{ 'content-type': 'image/png',
'x-auth-token': 'c82162402dc34a2c91447ce6c7cd0e45',
'user-agent': 'nodejs-pkgcloud/0.9.6',
host: 'storage101.iad3.clouddrive.com',
accept: 'application/json' },
_headerNames:
{ 'content-type': 'content-type',
'x-auth-token': 'x-auth-token',
'user-agent': 'User-Agent',
host: 'host',
accept: 'accept' },
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
request:
{ domain: null,
_events:
{ error: [Object],
complete: [Function],
pipe: [Function],
end: [Object],
data: [Function] },
_maxListeners: undefined,
readable: true,
writable: true,
method: 'PUT',
headers:
{ 'content-type': 'image/png',
'x-auth-token': 'c82162402dc34a2c91447ce6c7cd0e45',
'User-Agent': 'nodejs-pkgcloud/0.9.6',
accept: 'application/json' },
strictSSL: true,
uri:
{ protocol: 'https:',
slashes: true,
auth: null,
host: 'storage101.iad3.clouddrive.com',
port: 443,
hostname: 'storage101.iad3.clouddrive.com',
hash: null,
search: null,
query: null,
pathname: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
href: 'https://storage101.iad3.clouddrive.com/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png' },
callback: [Function],
explicitMethod: true,
localAddress: undefined,
pool: {},
dests: [],
__isRequestRequest: true,
_callback: [Function],
_redirectsFollowed: 0,
maxRedirects: 10,
followRedirect: true,
followAllRedirects: false,
redirects: [],
setHost: true,
originalCookieHeader: undefined,
_jar: undefined,
port: 443,
host: 'storage101.iad3.clouddrive.com',
clientErrorHandler: [Function],
_parserErrorHandler: [Function],
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_json: true,
httpModule:
{ Server: [Object],
createServer: [Function],
globalAgent: [Object],
Agent: [Object],
request: [Function],
get: [Function] },
agentClass: { [Function: Agent] super_: [Object] },
agent:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
defaultPort: 443,
protocol: 'https:',
options: [Object],
requests: {},
sockets: [Object],
freeSockets: {},
keepAliveMsecs: 1000,
keepAlive: false,
maxSockets: Infinity,
maxFreeSockets: 256 },
src:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
writable: false,
readable: false,
paused: false,
autoDestroy: true,
write: [Function],
push: [Function],
queue: [Function],
end: [Function],
destroy: [Function],
pause: [Function],
resume: [Function] },
_started: true,
href: 'https://storage101.iad3.clouddrive.com/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
req:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Object],
connection: [Object],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/large_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
ntick: true,
response: [Circular],
_ended: true,
_callbackCalled: true },
toJSON: [Function: toJSON] }
{ _readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: true,
endEmitted: true,
reading: false,
sync: false,
needReadable: false,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: false,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [ [Function: responseOnEnd], [Function], [Function] ],
close: [ [Function], [Function] ],
data: [Function] },
_maxListeners: undefined,
socket:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 20112,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
connection:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 20112,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
httpVersion: '1.1',
complete: true,
headers:
{ 'last-modified': 'Mon, 22 Sep 2014 13:54:55 GMT',
'content-length': '0',
etag: 'eb763d00560cf243285bbdb0219835e3',
'content-type': 'text/html; charset=UTF-8',
'x-trans-id': 'tx0bf9f8766036465caf936-0054202a2eiad3',
date: 'Mon, 22 Sep 2014 13:54:54 GMT',
connection: 'close' },
rawHeaders:
[ 'Last-Modified',
'Mon, 22 Sep 2014 13:54:55 GMT',
'Content-Length',
'0',
'Etag',
'eb763d00560cf243285bbdb0219835e3',
'Content-Type',
'text/html; charset=UTF-8',
'X-Trans-Id',
'tx0bf9f8766036465caf936-0054202a2eiad3',
'Date',
'Mon, 22 Sep 2014 13:54:54 GMT',
'Connection',
'close' ],
trailers: {},
rawTrailers: [],
_pendings: [],
_pendingIndex: 0,
url: '',
method: null,
statusCode: 201,
statusMessage: 'Created',
client:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState:
{ highWaterMark: 16384,
buffer: [],
length: 0,
pipes: null,
pipesCount: 0,
flowing: true,
ended: false,
endEmitted: false,
reading: true,
sync: false,
needReadable: true,
emittedReadable: false,
readableListening: false,
objectMode: false,
defaultEncoding: 'utf8',
ranOut: false,
awaitDrain: 0,
readingMore: true,
decoder: null,
encoding: null,
resumeScheduled: false },
readable: false,
domain: null,
_events:
{ end: [Object],
finish: [Function: onSocketFinish],
_socketEnd: [Function: onSocketEnd],
error: [Object],
free: [Function: onFree],
close: [Object],
agentRemove: [Function: onRemove],
drain: [Function: ondrain],
secure: [Function] },
_maxListeners: undefined,
_writableState:
{ highWaterMark: 16384,
objectMode: false,
needDrain: false,
ending: true,
ended: true,
finished: true,
decodeStrings: false,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: false,
bufferProcessing: false,
onwrite: [Function],
writecb: null,
writelen: 0,
buffer: [],
pendingcb: 0,
prefinished: true,
errorEmitted: false },
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 20112,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions:
{ secureContext: [Object],
isServer: false,
requestCert: true,
rejectUnauthorized: true,
session: undefined,
NPNProtocols: undefined,
requestOCSP: undefined },
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl:
{ onhandshakestart: [Function],
onhandshakedone: [Function],
onocspresponse: [Function],
onerror: [Function] },
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Circular],
connection: [Circular],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
_consuming: true,
_dumped: false,
httpVersionMajor: 1,
httpVersionMinor: 1,
upgrade: false,
req:
{ domain: null,
_events: { error: [Function], drain: [Function] },
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState: [Object],
readable: false,
domain: null,
_events: [Object],
_maxListeners: undefined,
_writableState: [Object],
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 20112,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions: [Object],
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl: [Object],
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage: [Circular],
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
connection:
{ _connecting: false,
_hadError: false,
_handle: null,
_host: 'storage101.iad3.clouddrive.com',
_readableState: [Object],
readable: false,
domain: null,
_events: [Object],
_maxListeners: undefined,
_writableState: [Object],
writable: false,
allowHalfOpen: false,
destroyed: true,
bytesRead: 277,
_bytesDispatched: 20112,
_pendingData: null,
_pendingEncoding: '',
_tlsOptions: [Object],
_secureEstablished: true,
_securePending: false,
_newSessionPending: false,
_controlReleased: true,
_SNICallback: null,
ssl: [Object],
servername: null,
npnProtocol: undefined,
authorized: true,
authorizationError: null,
encrypted: true,
parser: null,
_httpMessage: [Circular],
read: [Function],
_consuming: true,
server: null,
_requestCert: true,
_rejectUnauthorized: true,
_idleNext: null,
_idlePrev: null,
_idleTimeout: -1 },
agent:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
defaultPort: 443,
protocol: 'https:',
options: [Object],
requests: {},
sockets: [Object],
freeSockets: {},
keepAliveMsecs: 1000,
keepAlive: false,
maxSockets: Infinity,
maxFreeSockets: 256 },
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_headers:
{ 'content-type': 'image/png',
'x-auth-token': 'c82162402dc34a2c91447ce6c7cd0e45',
'user-agent': 'nodejs-pkgcloud/0.9.6',
host: 'storage101.iad3.clouddrive.com',
accept: 'application/json' },
_headerNames:
{ 'content-type': 'content-type',
'x-auth-token': 'x-auth-token',
'user-agent': 'User-Agent',
host: 'host',
accept: 'accept' },
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
read: [Function],
request:
{ domain: null,
_events:
{ error: [Object],
complete: [Function],
pipe: [Function],
end: [Object],
data: [Function] },
_maxListeners: undefined,
readable: true,
writable: true,
method: 'PUT',
headers:
{ 'content-type': 'image/png',
'x-auth-token': 'c82162402dc34a2c91447ce6c7cd0e45',
'User-Agent': 'nodejs-pkgcloud/0.9.6',
accept: 'application/json' },
strictSSL: true,
uri:
{ protocol: 'https:',
slashes: true,
auth: null,
host: 'storage101.iad3.clouddrive.com',
port: 443,
hostname: 'storage101.iad3.clouddrive.com',
hash: null,
search: null,
query: null,
pathname: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
href: 'https://storage101.iad3.clouddrive.com/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png' },
callback: [Function],
explicitMethod: true,
localAddress: undefined,
pool: {},
dests: [],
__isRequestRequest: true,
_callback: [Function],
_redirectsFollowed: 0,
maxRedirects: 10,
followRedirect: true,
followAllRedirects: false,
redirects: [],
setHost: true,
originalCookieHeader: undefined,
_jar: undefined,
port: 443,
host: 'storage101.iad3.clouddrive.com',
clientErrorHandler: [Function],
_parserErrorHandler: [Function],
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_json: true,
httpModule:
{ Server: [Object],
createServer: [Function],
globalAgent: [Object],
Agent: [Object],
request: [Function],
get: [Function] },
agentClass: { [Function: Agent] super_: [Object] },
agent:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
defaultPort: 443,
protocol: 'https:',
options: [Object],
requests: {},
sockets: [Object],
freeSockets: {},
keepAliveMsecs: 1000,
keepAlive: false,
maxSockets: Infinity,
maxFreeSockets: 256 },
src:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
writable: false,
readable: false,
paused: false,
autoDestroy: true,
write: [Function],
push: [Function],
queue: [Function],
end: [Function],
destroy: [Function],
pause: [Function],
resume: [Function] },
_started: true,
href: 'https://storage101.iad3.clouddrive.com/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
req:
{ domain: null,
_events: [Object],
_maxListeners: undefined,
output: [],
outputEncodings: [],
outputCallbacks: [],
writable: true,
_last: true,
chunkedEncoding: true,
shouldKeepAlive: false,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedHeader: {},
_hasBody: true,
_trailer: '',
finished: true,
_hangupClose: false,
socket: [Object],
connection: [Object],
agent: [Object],
socketPath: undefined,
method: 'PUT',
path: '/v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png',
_headers: [Object],
_headerNames: [Object],
_header: 'PUT /v1/MossoCloudFS_260e54e8-8607-42df-b65a-91ee500e669b/fudge/thumb_image-1.png HTTP/1.1\r\ncontent-type: image/png\r\nx-auth-token: c82162402dc34a2c91447ce6c7cd0e45\r\nUser-Agent: nodejs-pkgcloud/0.9.6\r\nhost: storage101.iad3.clouddrive.com\r\naccept: application/json\r\nConnection: close\r\nTransfer-Encoding: chunked\r\n\r\n',
_headerSent: true,
parser: null,
res: [Circular] },
ntick: true,
response: [Circular],
_ended: true,
_callbackCalled: true },
toJSON: [Function: toJSON] }
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.