Files
itflow/api/v1/require_get_method.php
Marcus Hill e55622827d Add support for client-specific API keys
Refactoring API. Added a contact update endpoint.
Small misc changes.
2022-04-15 17:43:06 +01:00

13 lines
338 B
PHP

<?php
if($_SERVER['REQUEST_METHOD'] !== "GET"){
header("HTTP/1.1 405 Method Not Allowed");
$return_arr['success'] = "False";
$return_arr['message'] = "Can only send GET requests to this endpoint.";
echo json_encode($return_arr);
exit();
}
// Wildcard client ID for most SELECT queries
if($client_id == 0){
$client_id = "%";
}