---
# System prepended metadata

title: Bitbe-dev

---

# Các ENV
- Host: ...





# Logic Verify Email
Call API /get-me để check user đã verify email chưa
verifiedStatus: ['NOT_VERIFIED', 'WAITING', 'VERIFIED']

Sample CURL
```
curl --location 'https://api.coindicehub.com/auth/get-me' \
--header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjYsInVzZXJOYW1lIjoibG9uZ2RhbyIsImxvZ2luVHlwZSI6IkxvY2FsIiwiaWF0IjoxNzA4MDY3MjE0LCJleHAiOjE3MDgxNTM2MTR9.4Cq-slnghP6f-Wx-9FjSHqMwGM5fv46pkh6M-IyfWRs'
```


Khi User click gửi verify thì call API /send-verify-email để hệ thống gửi token về email của User
Sample CURL
```
curl --location --request POST 'https://api.coindicehub.com/auth/send-verify-email' \
--header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjYsInVzZXJOYW1lIjoibG9uZ2RhbyIsImxvZ2luVHlwZSI6IkxvY2FsIiwiaWF0IjoxNzA4MDY3MjE0LCJleHAiOjE3MDgxNTM2MTR9.4Cq-slnghP6f-Wx-9FjSHqMwGM5fv46pkh6M-IyfWRs'
```


Khi có token thì dùng API /do-verify-email + token trong email để verify
Sample CURL
```
curl --location 'https://api.coindicehub.com/auth/do-verify-email' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjYsInVzZXJOYW1lIjoibG9uZ2RhbyIsImxvZ2luVHlwZSI6IkxvY2FsIiwiaWF0IjoxNzA4MDY3MjE0LCJleHAiOjE3MDgxNTM2MTR9.4Cq-slnghP6f-Wx-9FjSHqMwGM5fv46pkh6M-IyfWRs' \
--data '{
    "verifyToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjExLCJpYXQiOjE3MDgwNjI1NTMsImV4cCI6MTcwODA2Mjg1M30.6WOq_nc1r5g2lGeESGfBssObuDs0fGK0sC3nv1Z5WYg"
}'
```
