adding dependent scripts
This commit is contained in:
parent
ad26252269
commit
9239d79bd8
13
scripts/loggorilla.py
Normal file
13
scripts/loggorilla.py
Normal file
@ -0,0 +1,13 @@
|
||||
import datetime
|
||||
|
||||
def prcss(loc, msg):
|
||||
print(f"[loggorilla][{datetime.datetime.now()}][\033[32mprcss\033[39m][\033[95m{loc}\033[39m] {msg}", flush=True)
|
||||
|
||||
def accss(loc, msg):
|
||||
print(f"[loggorilla][{datetime.datetime.now()}][\033[36maccss\033[39m][\033[95m{loc}\033[39m] {msg}", flush=True)
|
||||
|
||||
def fyinf(loc, msg):
|
||||
print(f"[loggorilla][{datetime.datetime.now()}][\033[93mfyinf\033[39m][\033[95m{loc}\033[39m] {msg}", flush=True)
|
||||
|
||||
def error(loc, msg):
|
||||
print(f"[loggorilla][{datetime.datetime.now()}][\033[31merror\033[39m][\033[95m{loc}\033[39m] {msg}", flush=True)
|
14
scripts/synthesai.py
Normal file
14
scripts/synthesai.py
Normal file
@ -0,0 +1,14 @@
|
||||
import requests
|
||||
|
||||
def generate(auth, payload):
|
||||
url = "https://api.synthesia.io/v2/videos"
|
||||
headers = { "Authorization" : auth, "accept" : "application/json", "content-type" : "application/json" }
|
||||
response = requests.post(url, json=payload, headers=headers)
|
||||
return response
|
||||
|
||||
def retrieve(auth, video_id):
|
||||
url = f"https://api.synthesia.io/v2/videos/{video_id}"
|
||||
headers = { "Authorization": auth, "accept": "application/json" }
|
||||
response = requests.get(url, headers=headers)
|
||||
return response
|
||||
|
Loading…
Reference in New Issue
Block a user