This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { serve } from "https://deno.land/std/http/server.ts"; | |
function error(code: number): Promise<Response> { | |
const response = new Response(null, { | |
status: code, | |
}); | |
return Promise.resolve(response); | |
} | |
function options(): Promise<Response> { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(async () => { | |
const lotteryStatusUrl = 'https://bgme.me/@bgme/105206731005287886'; // 抽奖嘟文URL | |
const lotteryType = 'reblog'; // 抽奖类型:转发(reblog),收藏(favourite) | |
const candidateNumber = 5; // 候选中奖者人数 | |
main(); | |
async function main() { | |
const domain = document.location.hostname; | |
const token = JSON.parse(document.querySelector('#initial-state').text).meta.access_token; |
OlderNewer