Register
POST
Route Register :
localhost:8080/Register
This section explains the "Route Register" which allows the creation of a new entity by sending a JSON payload containing a BearerToken, a Name, and a Prompt to describe the entity. Upon successful registration, a response is received with a success message "Connexion réussie" and a status code of 200, along with a private JWT token for authentication purposes.
Body :
{
"API_KEY": "VDCAjPZ8jhDmXfsSufW2oZyU8SFZi48dRhA8zyKUjSRU3T1aBZ7E8FFIjdEM2X1d",
"Name": "NPC01",
"Prompt": "NPC01 is a gentleman robot, he serves the royal family."
}Success Response :
{
"message": "Connexion réussie",
"status": 200,
"private": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE3MzA3MTM2NjksInVzZXJfaWQiOiJhbGJlcnQifQ.eiwQqdvU6hWzTLWiVC9PGGXvDrjaqXgxHerX3ROz_Jo"
}Curl exemple :
curl --location 'localhost:8080/Register' \
--header 'Content-Type: application/json' \
--data '{
"API_KEY": "VDCAjPZ8jhDmXfsSufW2oZyU8SFZi48dRhA8zyKUjSRU3T1aBZ7E8FFIjdEM2X1d",
"Name": "NPC01",
"Prompt": "NPC01 is a gentleman robot, he serves the royal family."
}'Last updated