Browse API documentation
API REFERENCEv1

Retrieve credential identity

Check which company, permissions and scopes belong to your credential.

On this page
GET/api/auth/public/v1/whoami

Requires Read permission. Read the implementation guide →

How to use this endpoint

Use this after configuring a credential to confirm which company and access it belongs to. It requires Read permission and returns credential metadata, without the secret or candidate data. It does not grant additional scopes. Verify jobs:read and applications:write in the returned scopes before building a careers flow; a successful identity request alone does not establish those capabilities.

Authentication

Send both headers from your server. An app key or application token alone does not authorize a request.

http
X-Karwa-App-Key: <APP_KEY>
Authorization: Bearer <SECRET_KEY>

Parameters

This endpoint has no path, query or additional header parameters.

Request body

No request body is required.

Request example

Set KARWA_API_BASE to your HTTPS gateway origin followed by /api/auth/public/v1. Local development uses http://localhost:8000/api/auth/public/v1. Replace job, posting, question and token values where shown.

bash
curl --fail-with-body "$KARWA_API_BASE/whoami" \
  -H "X-Karwa-App-Key: $KARWA_APP_KEY" \
  -H "Authorization: Bearer $KARWA_SECRET_KEY"

Response

200 · application/json · Successful Response

organization_idintegerRequired
Identifier of the company that owns this credential. It cannot be overridden by a caller.
company_namestringRequired
Display name of the company or hiring brand associated with this posting or credential.
key_idintegerRequired
Identifier of the authenticated credential. It is not the app key or secret.
purposestringRequired
Credential purpose metadata. New credentials support both website and integration use; permissions and scopes determine access. Allowed: "public_api", "integration", "both".
permissionsarray<string>Required
Read and/or write permissions granted to the credential.
scopesarray<string>
Specific operations granted to the credential, such as jobs:read and applications:write.
json · example response
{
  "organization_id": 1,
  "company_name": "Example Company",
  "key_id": 1,
  "purpose": "both",
  "permissions": [
    "read",
    "write"
  ],
  "scopes": [
    "jobs:read",
    "applications:write"
  ]
}

Errors and recovery

401
Invalid credential or application session
403
Missing permission, scope or plan access
404
Posting unavailable
422
Validation Error
429
Rate limited; observe Retry-After
json · example error response
{
  "detail": "Invalid API key"
}

Inspect the HTTP status before using the body. Validation detail can be a string or an array. For submission timeouts, retain the same Idempotency-Key. For 429 responses, wait for Retry-After. See error handling and quotas →