-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ab225a1
commit 9ee9e5d
Showing
6 changed files
with
70 additions
and
59 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
from enum import Flag, auto | ||
|
||
_headers = { | ||
"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.142 Safari/537.36", | ||
"x-csrftoken": "a", | ||
"x-requested-with": "XMLHttpRequest", | ||
"referer": "https://scratch.mit.edu", | ||
} | ||
|
||
_cookies = { | ||
"scratchcsrftoken" : "a", | ||
"scratchlanguage" : "en", | ||
"scratchpolicyseen": "true", | ||
"accept": "application/json", | ||
"Content-Type": "application/json", | ||
} | ||
|
||
def get_headers(): | ||
return _headers.copy() | ||
|
||
def get_cookies(): | ||
return _cookies.copy() | ||
|
||
class Browser(Flag): | ||
FIREFOX = auto() | ||
CHROME = auto() | ||
EDGE = auto() | ||
SAFARI = auto() | ||
CHROMIUM = auto() | ||
EDGE_DEV = auto() | ||
VIVALDI = auto() | ||
ANY = auto() |
This file was deleted.
Oops, something went wrong.
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
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
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