New in 2.4: Test runs you can trust See what's new →

Basic auth test

Auth test: an endpoint protected by HTTP Basic auth.

Example request

Return protected data behind Basic auth. Full reference and a Send button.

cURL
curl -X GET "https://api.testingapis.com/api/AuthTest/secure-data" \
  -H "Authorization: Basic QWRtaW46QWRtaW5AMTIzNA=="
Run in Studio
Response · 200 OK
{"message": "Authentication successful", "data": "This is protected data"}