Company logo
  • Empleos
  • Bootcamp
  • Acerca de nosotros
  • Para profesionales
    • Inicio
    • Empleos
    • Cursos y retos
    • Preguntas
    • Profesores
    • Bootcamp
  • Para empresas
    • Inicio
    • Nuestro proceso
    • Planes
    • Pruebas
    • Nómina
    • Blog
    • Calculadora

0

56
Vistas
how to delete multiple folders using google drive api in javascript with axios?

I am trying to delete multiple files of google drive using google drive api but it give 404 error

axios.delete('https://www.googleapis.com/drive/v3/files',{
         params:{
             fileId:'1nJddic7Gc_x8NQBzwOPhglwfYI-_Ms5E,1nJddic7Gc_x8NQBzwOPhglwfYI-_Ms5E',
              supportsTeamDrives: 'false',
         },
         headers: {
            authorization: `Bearer ${accessToken}`
            }
        })
        .then(res=>{    console.log(res.data)   })
        .catch(err=>{    console.log(err)   })
7 months ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You have to pass the fileId as path parameter:

axios.delete('https://www.googleapis.com/drive/v3/files/1nJddic7Gc_x8NQBzwOPhglwfYI-_Ms5E,1nJddic7Gc_x8NQBzwOPhglwfYI-_Ms5E', {
  headers: {
    authorization: `Bearer ${accessToken}`
  }
})
.then(res => { console.log(res.data); })
.catch(err => { console.log(err); });
7 months ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar empleo Planes Nuestro proceso Comercial
Legal
Términos y condiciones Política de privacidad
© 2023 PeakU Inc. All Rights Reserved.