Some checks failed
Create and publish a Docker image / build-and-push-image (push) Failing after 2m23s
51 lines
923 B
Python
51 lines
923 B
Python
from fastapi import FastAPI
|
|
|
|
app = FastAPI()
|
|
|
|
|
|
@app.put("/v2/deployments/me/hosts")
|
|
async def put_hosts():
|
|
return {}
|
|
|
|
|
|
@app.put("/v2/profiles/me")
|
|
async def put_profile():
|
|
return {}
|
|
|
|
|
|
@app.get("/v2/deployments/me")
|
|
async def get_deployments():
|
|
return {"data": {}}
|
|
|
|
|
|
@app.get("/v2/licenses/me")
|
|
async def get_licenses():
|
|
return {
|
|
"data": {
|
|
"id": "114514",
|
|
"key": "114514",
|
|
"status": "active",
|
|
"plan": {
|
|
"name": "ENTERPRISE",
|
|
},
|
|
"valid_from": 0,
|
|
"valid_until": -1,
|
|
}
|
|
}
|
|
|
|
|
|
@app.get("/v2/subscriptions/me/sessions/portal")
|
|
@app.get("/v2/subscriptions/me/sessions/checkout")
|
|
async def get_sessions():
|
|
return {
|
|
"data": {
|
|
"url": "https://www.baidu.com",
|
|
}
|
|
}
|
|
|
|
|
|
# https://license.signoz.io routes
|
|
@app.get("//api/v1/usage")
|
|
async def get_usage():
|
|
return {}
|