L
L
levnikrot2021-03-02 22:50:33
Node.js
levnikrot, 2021-03-02 22:50:33

Why can't I download the file?

Unable to upload file to Dubox cloud storage.

const axios = require('axios');

const ndus = 'Y-8Nf8TteHuiV9iU5_e37YPWvXs4zPpfsQ2PUswh'

let options = {
    headers: {
        'Cookie': `ndus=${ndus}`,
        'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8',
        'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.198 Safari/537.36',
    }
}

const urlGetList = 'https://www.dubox.com/api/list?order=time&desc=1&showempty=0&web=1&page=1&num=100&dir=%2F&t=0.5983731623146096&channel=dubox&web=1&app_id=250528&clienttype=0&bdstoken=23c6897893f7917efdad00c329474b70'
const urlPrecreate = 'https://www.dubox.com/api/precreate?channel=dubox&web=1&app_id=250528&clienttype=0&bdstoken=628a8283d23cda6db67d3c4db80d0be4'

axios.get(urlGetList, options).then(res =>{
    console.log(res.data);
}); // Получаем каталог (все работает)

axios.post(urlPrecreate, JSON.stringify({
    path: '/FactoryGame-WindowsNoEditor.sig',
    autoinit: 1,
    target_path: '/',
    block_list: ["5910a591dd8fc18c32a8f3df4fdc1761"],
    local_mtime: 1609094708
}), options).then(res =>{
    console.log(res.data);
}) // Пытаемся отправить запрос на предварительное создание (выдает ошибку)


I don't know why, but when I try to send a pre-creation request, I get an error. I even completely copied the request, it still gives an error

603e946e2a334277806433.jpeg

But there are no problems with getting the catalog.

603e96312cf55338229810.jpeg

How can I upload a file there? And is it possible?

dubox login details
Email: [email protected]
Password: [email protected]

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question