API - Add client create endpoint

This commit is contained in:
Marcus Hill
2024-02-04 14:51:58 +00:00
parent 8a9a4fd97e
commit 102481d09f
3 changed files with 116 additions and 2 deletions

View File

@@ -9,6 +9,6 @@ if ($_SERVER['REQUEST_METHOD'] !== "POST") {
// Client ID must be specific for INSERT/UPDATE/DELETE queries
// If this API key allows any client, set $client_id to the one specified, else leave it
if ($client_id == 0) {
if ($client_id == 0 && isset($_POST['client_id'])) {
$client_id = intval($_POST['client_id']);
}
}