2020-04-29 04:43:27 +00:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
var request = require('../');
|
|
|
|
request({
|
|
|
|
url: 'https://postb.in/1588134650162-6019286897499?hello=world'
|
2020-04-29 05:00:26 +00:00
|
|
|
//headers: { 'user-agent': false } // remove
|
|
|
|
//headers: { 'user-agent': 'test/1.0' } // overwrite
|
2020-04-29 04:43:27 +00:00
|
|
|
//userAgent: 'test/1.1' // not presently implemented
|
|
|
|
})
|
|
|
|
.then(function(resp) {
|
|
|
|
console.log(resp.body);
|
|
|
|
})
|
|
|
|
.catch(function(err) {
|
|
|
|
console.error(err);
|
|
|
|
});
|