Skip to content

Instantly share code, notes, and snippets.

@anuragts
Last active March 5, 2024 12:58
Show Gist options
  • Save anuragts/3032df0b387aefc863c3102640cf9642 to your computer and use it in GitHub Desktop.
Save anuragts/3032df0b387aefc863c3102640cf9642 to your computer and use it in GitHub Desktop.
how to fetch crackeddevsapi
import axios from 'axios';
const API_KEY:string = '9488653d.....' // YOUR CRACKEDDEVS API KEY HERE
const LIMIT:number = 2 // No of jobs to fetch , can remove ?limit from url to get all jobs
const ACTIVE = true
export async function crackeddevs() {
const response = await axios.get(
`https://api.crackeddevs.com/api/get-jobs?limit=${LIMIT}&active=${ACTIVE}`,
{
headers: {
'api-key': `${API_KEY}`, // API KEY HERE
},
}
);
console.log(response.data); // get the data from the response
return response.data;
};
crackeddevs() // function call
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment