Constructor de peticiones HTTP
Construye peticiones HTTP de forma visual y genera código JavaScript con Fetch, sin necesidad de cURL.
Cabeceras de la petición
Cuerpo de la petición (sin procesar)
Wrapper nativo de fetch()
fetch("https://api.example.com/v1/auth/login", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer token123",
},
body: JSON.stringify({
"username": "admin",
"password": "supersecurepassword"
}),
})
.then((response) => response.json())
.then((data) => console.log(data));