I'm trying to upload images using LocalBitcoins API. they say: when uploading files multipart/form-data encoding is also supported. Files encoded as multipart/form-data.
https://localbitcoins.com/api-docs/#contact-post
argument: document
type: File Image attachments encoded with multipart/form-data
I'm sending :
{ url: 'https://localbitcoins.com/api/contact_message_post/69111167/', headers: { 'Content-Type': 'multipart/form-data', 'Apiauth-Key': 'ec8e27xxxxxxxxxxxxxxxxxx4c4c', 'Apiauth-Nonce': 161xxxxxxxxxx000, 'Apiauth-Signature': 'DFxxxx4DBBA8029xxxxxxxxxxxxxxxxxxxxxxxxxx6B73370EAC2A1xx' }, form: { document: FormData { _overheadLength: 146, _valueLength: 487212, _valuesToMeasure: [], writable: false, readable: true, dataSize: 0, maxDataSize: 2097152, pauseStreams: true, _released: false, _streams: [Array], _currentStream: null, _insideLoop: false, _pendingNext: false, _boundary: '--------------------------033526205629422447468137' } } }
2.1m questions
2.1m answers
60 comments
57.0k users