mirror of
https://github.com/cheveguerra/bot-whatsapp.git
synced 2026-04-18 03:29:15 +00:00
docs: 🔥 added netlify
This commit is contained in:
19
packages/docs/src/services/github.ts
Normal file
19
packages/docs/src/services/github.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* GET API from Github
|
||||
* @returns
|
||||
*/
|
||||
export const fetchGithub = async (token: string) => {
|
||||
const data = await fetch(
|
||||
`https://api.github.com/repos/codigoencasa/bot-whatsapp/contributors`,
|
||||
{
|
||||
method: 'GET',
|
||||
headers: {
|
||||
Accept: 'application/vnd.github+json',
|
||||
'X-GitHub-Api-Version': '2022-11-28',
|
||||
Authorization: `Bearer ${token}`,
|
||||
},
|
||||
}
|
||||
)
|
||||
const listUsers = data.json()
|
||||
return listUsers
|
||||
}
|
||||
Reference in New Issue
Block a user