This commit is contained in:
belle 2023-08-27 21:49:43 -04:00
parent 59dafaf223
commit 3baa250cc3
2 changed files with 8 additions and 7 deletions

View file

@ -10,15 +10,16 @@ export async function Slack() {
formData.append('date_range', '30d')
let slackData = await fetch(
'https://hackclub.slack.com/api/team.stats.timeSeries',
"https://hackclub.slack.com/api/team.stats.timeSeries",
{
method: 'POST',
body: formData,
method: "POST",
body: `--orpheus\r\nContent-Disposition: form-data; name="token"\r\n\r\n${SLACK_API_TOKEN}\r\n--orpheus\r\nContent-Disposition: form-data; name="date_range"\r\n\r\n30d\r\n--orpheus\r\nContent-Disposition: form-data;`,
headers: {
Cookie: process.env.SLACK_API_COOKIE
}
"content-type": "multipart/form-data; boundary=orpheus",
cookie: SLACK_API_COOKIE,
},
}
).then(r => r.json())
).then((r) => r.json());
if (!slackData || !slackData.stats) {
console.warn(`No slack data: ${JSON.stringify(slackData)}`)

View file

@ -410,7 +410,7 @@ const Page = () => {
<Meta
as={Head}
title="Hackers Wanted"
description="A love letter to those that want the world to be better, more magical, more free"
description="A love letter to those that want the world to be better, more magical, more free."
image="https://cloud-perha612p-hack-club-bot.vercel.app/0dither_it_img_5673.jpg"
/>
<Nav