Karve app icon

Karve

Authentication bearer-token.http

Bearer token .http file example

Send a JWT or OAuth access token exactly as the API receives it: in an Authorization header.

bearer-token.http

@baseUrl = https://api.example.com
@token = replace-with-access-token

### List the current user's projects
GET {{baseUrl}}/projects
Accept: application/json
Authorization: Bearer {{token}}

Variables to replace

baseUrl
The API origin. Replace api.example.com with the service you are testing.
token
A safe placeholder for the access token. Prefer a git-ignored .env value for real credentials.

Expected response

A successful API commonly returns 200 OK with a JSON collection. An expired or invalid token usually returns 401 Unauthorized; a valid token without the required permission may return 403 Forbidden.

Related examples and guides

Learn the full syntax in the .http file format guide, manage secrets with variables and environments, or see how to run .http files on Windows.

Launch Summer Sale

Run this request without leaving Windows.

Karve opens .http files as a native workspace: edit the plain text, press Run, inspect the response, and keep the file in Git.

15-day free trial · No account · No subscription · No metered requests

25% off until Sep 1