GET
/auth/current-user
curl \
-X GET http://localhost:3003/api/dev/auth/current-user \
-H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
# Headers
Cross-Origin-Embedder-Policy: require-corp
Cross-Origin-Opener-Policy: same-origin
Cross-Origin-Resource-Policy: same-origin
Origin-Agent-Cluster: ?1
Referrer-Policy: no-referrer
Strict-Transport-Security: max-age=15552000; includeSubDomains
X-Content-Type-Options: nosniff
X-DNS-Prefetch-Control: off
X-Download-Options: noopen
X-Frame-Options: SAMEORIGIN
X-Permitted-Cross-Domain-Policies: none
X-XSS-Protection: 0
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
Retry-After: 517.157
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 96
X-RateLimit-Reset: Mon Oct 30 2023 02:46:38 GMT+0100 (Central European Standard Time)
x-powered-by: TUNISIAN RED CRESSCENT
Content-Type: application/json; charset=utf-8
Content-Length: 2566
ETag: W/"a06-jUNStbd1HDIgfeIqAiQrWEI7ByY"
Date: Mon, 30 Oct 2023 01:38:01 GMT
Connection: keep-alive
Keep-Alive: timeout=5
# Payload
{
"code": 200,
"user": {
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"name": "Mohamed Hassen",
"lastName": "JAHHA",
"email": "mohamedhassen.jahha@assistdigital.com",
"DoC": "2023-04-17T07:46:10.000Z",
"avatar": "/media/2bc45102-9487-4e87-8dd6-87f03e34752c.png",
"phoneCode": "216",
"phone": "58076667",
"isActive": true,
"isVerified": true,
"profile": "AL",
"role": null,
"lastActive": "2023-10-30T01:36:40.512Z",
"isOtpEnabled": false,
"isOtpVerified": true,
"committeeID": "af7c1fe6-d669-414e-b066-e9733f0de7a8",
"Committee": {
"committeeID": "af7c1fe6-d669-414e-b066-e9733f0de7a8",
"nameArabe": "الهيئة المركزية",
"type": "NAT",
"nameLatin": "Comité central",
"dateOfEst": "1956-11-07T00:00:00.000Z",
"VAT": "33049Y/N/P/N/000",
"address": "19, Rue d'Angleterre",
"region": "Tunis",
"city": "Tunis",
"postalCode": 1000,
"isActive": true,
"primaryEmail": "contact@croissant-rouge.tn",
"secondaryEmail": null,
"primaryPhone": "+21671325572",
"secondaryPhone": "+21671320630"
},
"LoginActivity": [
{
"loginActivityID": 1,
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"ip": ":1",
"continent": null,
"countryCode": null,
"browser": "Other",
"os": "Other",
"device": "Other",
"lat": null,
"lon": null,
"country": null,
"city": null,
"region": null,
"isp": null,
"createdAt": "2023-10-04T05:03:20.399Z"
},
{
"loginActivityID": 2,
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"ip": ":1",
"continent": null,
"countryCode": null,
"browser": "Other",
"os": "Other",
"device": "Other",
"lat": null,
"lon": null,
"country": null,
"city": null,
"region": null,
"isp": null,
"createdAt": "2023-10-04T05:05:23.254Z"
},
{
"loginActivityID": 3,
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"ip": ":1",
"continent": null,
"countryCode": null,
"browser": "Other",
"os": "Other",
"device": "Other",
"lat": null,
"lon": null,
"country": null,
"city": null,
"region": null,
"isp": null,
"createdAt": "2023-10-04T05:11:10.348Z"
},
{
"loginActivityID": 4,
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"ip": ":1",
"continent": null,
"countryCode": null,
"browser": "Other",
"os": "Other",
"device": "Other",
"lat": null,
"lon": null,
"country": null,
"city": null,
"region": null,
"isp": null,
"createdAt": "2023-10-04T05:11:13.609Z"
},
{
"loginActivityID": 5,
"userID": "57dd5610-5896-4cf3-9f58-2e7e77feb888",
"ip": ":1",
"continent": null,
"countryCode": null,
"browser": "Other",
"os": "Other",
"device": "Other",
"lat": null,
"lon": null,
"country": null,
"city": null,
"region": null,
"isp": null,
"createdAt": "2023-10-04T05:12:14.383Z"
}
],
"otpAuthUrl": "otpauth://totp/Mohamed%20Hassen?secret=NNZHIPTDFQUE2JJ2ERLSCZDZONZU2YJX&issuer=SWIFT%20TRC",
"otpBase32": "NNZHIPTDFQUE2JJ2ERLSCZDZONZU2YJX",
"passwordlessBase32": "MNGGOJDIIA7T6I25LVKVGMBMGYRXOVBY",
"permissions": "[]"
}
}
Response examples (200)
# Headers
Cross-Origin-Embedder-Policy: require-corp
Cross-Origin-Opener-Policy: same-origin
Cross-Origin-Resource-Policy: same-origin
Origin-Agent-Cluster: ?1
Referrer-Policy: no-referrer
Strict-Transport-Security: max-age=15552000; includeSubDomains
X-Content-Type-Options: nosniff
X-DNS-Prefetch-Control: off
X-Download-Options: noopen
X-Frame-Options: SAMEORIGIN
X-Permitted-Cross-Domain-Policies: none
X-XSS-Protection: 0
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
Retry-After: 517.157
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 96
X-RateLimit-Reset: Mon Oct 30 2023 02:46:38 GMT+0100 (Central European Standard Time)
x-powered-by: TUNISIAN RED CRESSCENT
Content-Type: application/json; charset=utf-8
Content-Length: 2566
ETag: W/"a06-jUNStbd1HDIgfeIqAiQrWEI7ByY"
Date: Mon, 30 Oct 2023 01:38:01 GMT
Connection: keep-alive
Keep-Alive: timeout=5
# Payload
{}