Skip to content

Verify client endpoint

Alvin Cheng edited this page Apr 23, 2023 · 3 revisions

Description

This is the verify client endpoint, this endpoint will be used to verify the legitimacy of the client operating Chill&chat by checking the key field on the request. Furthermore, this endpoint returns '200' on success and '400' on failure. Please note that the code stores this endpoint's sources at /src/endpoints/VerifyClient.ts. Here is an example below.

Example

fetch("http://<URL>/api/verify-client?key=<YOUR_API_KEY>")
  .then((res) => {
    console.log(res);
  })
  .catch((err) => {
    console.error(err);
  });
Clone this wiki locally