![]() |
|
Hacxx Database Article Generator - SOURCE CODE - Printable Version +- Sinisterly (https://sinister.li) +-- Forum: Coding (https://sinister.li/Forum-Coding) +--- Forum: Coding (https://sinister.li/Forum-Coding--71) +--- Thread: Hacxx Database Article Generator - SOURCE CODE (/Thread-Hacxx-Database-Article-Generator-SOURCE-CODE) |
Hacxx Database Article Generator - SOURCE CODE - hacxx - 03-29-2023 Code: <script>
// My modification
var database = prompt("Write the website name:", "");
// Define the API endpoint and parameters
const endpoint = 'https://api.openai.com/v1/engine/chat';
const prompt = 'write me a article about '+database+' database leaked';
const apiKey = 'YOUR_API_KEY';
// Define the HTTP request options
const requestOptions = {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${apiKey}`,
},
body: JSON.stringify({
'prompt': prompt,
'temperature': 0.5,
'max_tokens': 50,
'stop': '\n',
}),
};
// Make the HTTP request using the Fetch API
fetch(endpoint, requestOptions)
.then(response => response.json())
.then(data => {
// Handle the response data
console.log(data);
})
.catch(error => {
// Handle any errors that occurred
console.error(error);
});
</script>RE: Hacxx Database Article Generator - SOURCE CODE - ch_ynnnn - 11-30-2023 how to use this? do I need a some sort of software to execute this code? |