mirror of
https://github.com/wolfswolke/DeathGarden_API_Rebirth.git
synced 2026-07-16 00:41:03 -05:00
Added more endpoints, added achievmentss, fixed EULA, Fixed PrivacyPolicy.
This commit is contained in:
parent
cef18ade1b
commit
2b68800484
|
|
@ -213,12 +213,12 @@ def consent_eula():
|
|||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to consent eula api call GET")
|
||||
return jsonify({"status": "success", "consent": "true"}) # Don't know. Added as Placeholder.
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"id": "eula", "language": ["de", "en", "es", "es-MX", "fr", "it", "ja", "ko", "nl", "pl",
|
||||
"pt-BR", "ru", "sv", "th", "tr", "zh-Hans", "zh-Hant"],
|
||||
"platform": ["steam", "xbox", "xsx", "switch", "grdk", "stadia"]})
|
||||
"platform": ["steam", "xbox", "xsx", "switch", "grdk", "stadia"]}) # Don't know. Added as Placeholder.
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="general-consent-eula", message=f"Error in consent_eula: {e}")
|
||||
|
||||
|
|
@ -228,11 +228,40 @@ def consent_eula0():
|
|||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to consent eula api call GET")
|
||||
return jsonify({"status": "success", "consent": "true"}) # Don't know. Added as Placeholder.
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"id": "eula", "language": ["de", "en", "es", "es-MX", "fr", "it", "ja", "ko", "nl", "pl",
|
||||
"pt-BR", "ru", "sv", "th", "tr", "zh-Hans", "zh-Hant"],
|
||||
"platform": ["steam", "xbox", "xsx", "switch", "grdk", "stadia"]})
|
||||
"platform": ["steam", "xbox", "xsx", "switch", "grdk", "stadia"]}) # Don't know. Added as Placeholder.
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="general-consent-eula0", message=f"Error in consent_eula0: {e}")
|
||||
|
||||
|
||||
@app.route("/api/v1/consent/privacyPolicy", methods=["GET"])
|
||||
def privacy_policy():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to consent privacyPolicy api call GET")
|
||||
return jsonify({"id":"privacy","language":["de","en","es","es-MX","fr","it","ja","ko","nl","pl","pt-BR","ru",
|
||||
"sv","th","tr","zh-Hans","zh-Hant"],
|
||||
"platform":["steam","xbox","xsx","switch","grdk","ps4","ps5","stadia"]})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="general-privacy-policy", message=f"Error in consent_eula0: {e}")
|
||||
|
||||
|
||||
@app.route("/api/v1/utils/contentVersion/latest/2.5", methods=["GET"])
|
||||
def content_version2_5():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to content version api call GET")
|
||||
return jsonify({
|
||||
"latestSupportedVersion": "te-18f25613-36778-ue4-374f864b"}) # Don't know if this is correct. Just testing.
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="general-content-version2_5", message=f"Error in content_version2_5: {e}")
|
||||
|
|
@ -128,3 +128,77 @@ def crashreporter_check_report():
|
|||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_crashreporter_CheckReport", message=str(e))
|
||||
|
||||
|
||||
@app.route("/metrics/matchmaking/event", methods=["POST"])
|
||||
def metrics_matchmaking_event():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to metrics matchmaking event api call POST")
|
||||
graylog_logger(level="info", handler="logging_matchmaking_Event", message=request.get_json())
|
||||
return jsonify({"status": "success"})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_matchmaking_Event", message=str(e))
|
||||
|
||||
|
||||
@app.route("/api/v1/extensions/progression/playerEndOfMatch", methods=["POST"])
|
||||
def progression_player_end_of_match():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to progression player end of match api call POST")
|
||||
graylog_logger(level="info", handler="logging_playerEndOfMatch", message=request.get_json())
|
||||
return jsonify({"status": "success"})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_playerEndOfMatch", message=str(e))
|
||||
|
||||
|
||||
@app.route("/api/v1/extensions/challenges/executeChallengeProgressionOperationBatch", methods=["POST"])
|
||||
def challenges_execute_challenge_progression_operation_batch():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to challenges execute challenge progression operation batch api call POST")
|
||||
graylog_logger(level="info", handler="logging_executeChallengeProgressionOperationBatch", message=request.get_json())
|
||||
return jsonify({"status": "success"})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_executeChallengeProgressionOperationBatch", message=str(e))
|
||||
|
||||
|
||||
@app.route("/api/v1/queue", methods=["POST"])
|
||||
def queue():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("Responded to queue api call POST")
|
||||
graylog_logger(level="info", handler="logging_queue", message=request.get_json())
|
||||
return jsonify({"status": "success"})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_queue", message=str(e))
|
||||
|
||||
|
||||
@app.route("/api/v1/extensions/challenges/getChallengeProgressionBatch", methods=["POST"])
|
||||
def challenges_get_challenge_progression_batch():
|
||||
get_remote_ip()
|
||||
try:
|
||||
print("DEBUG HEADERS:")
|
||||
print(request.headers)
|
||||
print("##############################################")
|
||||
print("Responded to challenges get challenge progression batch api call POST")
|
||||
graylog_logger(level="info", handler="logging_getChallengeProgressionBatch", message=request.get_json())
|
||||
return jsonify({"status": "success"})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
|
||||
except Exception as e:
|
||||
graylog_logger(level="error", handler="logging_getChallengeProgressionBatch", message=str(e))
|
||||
|
|
|
|||
|
|
@ -176,7 +176,12 @@ def wallet_currencies():
|
|||
def achievements_get():
|
||||
get_remote_ip()
|
||||
try:
|
||||
return jsonify({"status": "success", "achievements": []}) # Don't know. Added as Placeholder.
|
||||
return jsonify({"gameName":"Deathgarden: BLOODHARVEST","achievements":
|
||||
[{"apiname":"EFAB89E6465D1163D62A07B11048F2B6","achieved":1,"unlocktime":1587140058},
|
||||
{"apiname":"2CAEBB354D506D7C43B941BC1DA775A0","achieved":1,"unlocktime":1586792410},
|
||||
{"apiname":"E51981B946BEE3D45C5C41B2FCFF310B","achieved":1,"unlocktime":1586788872},
|
||||
{"apiname":"AAD05B9D46471DC811BBE0BA91916AB7","achieved":1,"unlocktime":1586788872},
|
||||
{"apiname":"BA2D4A5445CB70276A8F5D9E1AFCE080","achieved":1,"unlocktime":1586788872}],"success":True})
|
||||
except TimeoutError:
|
||||
print("Timeout error")
|
||||
return jsonify({"status": "error"})
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user