mirror of
https://github.com/xtekky/gpt4free.git
synced 2024-12-24 03:23:49 +03:00
11 lines
216 B
Python
11 lines
216 B
Python
|
import json
|
||
|
|
||
|
from g4f.api import create_app
|
||
|
|
||
|
app = create_app()
|
||
|
|
||
|
with open("openapi.json", "w") as f:
|
||
|
data = json.dumps(app.openapi())
|
||
|
f.write(data)
|
||
|
|
||
|
print(f"openapi.json - {round(len(data)/1024, 2)} kbytes")
|