BizKitHub
DocsAPI ReferenceCustomer/api/v1/customer/sync-password-hash
postCustomerPublic API v1

/api/v1/customer/sync-password-hash

Overwrite the password hash of an existing customer (looked up by e-mail, case-insensitively) with a bcrypt hash computed by a legacy system, so password changes made there keep working until the cutover. Never creates a customer and sends no e-mail; active customer sessions are revoked. Disabled unless the organisation sets the configuration key customer_password_hash_sync_enabled to true.

List of error codes:

Code Message
E001 Password hash sync failed.
E002 Password hash sync is not enabled for this organisation.
E003 Password hash must be a bcrypt hash ($2a$, $2b$ or $2y$).
E004 Customer account does not exist.
E005 changedAt must be an ISO 8601 date-time that is not in the future.
customerpostApiV1CustomerSync-password-hash

Parameters

1 query · JSON body

Query parameters

· 1
apiKeystringRequired

Your BizKitHub API key (passed as GET parameter).

Key format: A 32-character string matching: ^(PROD|DEV_|ROOT)[A-Za-z0-9]{28}$
Prefixes: PROD (production key), DEV_ (individual developer), ROOT (system key with no limits). Learn more

ExamplePRODPGrFxpGEtrOZfuWhnoJohUYBXuOE

Request body

application/json
emailstringRequired

Contact email address.

The system validates the input as a standard email address and automatically applies normalization and canonicalization.

All API responses return the normalized form, and each email address is unique per organisation within the system.

Phone-only contacts: Since 2026-06-10 a contact may exist without an e-mail when it was registered only by phone (e.g. imports of phone-only records). Responses that expose such contacts use API_EMAIL_NULLABLE instead, where this field can be null. Endpoints that accept e-mail as input still require a valid value here — phone-only creation goes through admin-only import / BFF flows.

passwordHashstringRequired

bcrypt hash ($2a$, $2b$ or $2y$) computed by the source system. Never send a plaintext password.

Example$2y$10$N9qo8uLOickgx2ZMRZoMyeIjZAgcfl7p92ldGxad68LJZdL17lhWy
changedAtstringOptional

When the password was changed in the source system. If BKH already has a newer password, the hash is ignored (result "stale").

Example2026-11-02T14:30:00Z

Response schema

1 status code documented

200Success
object | object
One of 2:
Variant 1
success"true"Required
result"updated" | "unchanged" | "stale"Required
Variant 2
success"false"Required
errorCodestringRequired
ExamplesE001E002E003E004E005
messagestringRequired
ExamplesPassword hash sync failed.Password hash sync is not enabled for this organisation.Password hash must be a bcrypt hash ($2a$, $2b$ or $2y$).Customer account does not exist.changedAt must be an ISO 8601 date-time that is not in the future.

Response example

application/json
{
  "success": true
}

Request example

POST /api/v1/customer/sync-password-hash

post
curl -X POST "https://api.bizkithub.com/api/v1/customer/sync-password-hash?apiKey=PRODPGrFxpGEtrOZfuWhnoJohUYBXuOE" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
  "email": "[email protected]",
  "passwordHash": "$2y$10$N9qo8uLOickgx2ZMRZoMyeIjZAgcfl7p92ldGxad68LJZdL17lhWy",
  "changedAt": "2026-11-02T14:30:00Z"
}'

Need an API key?

All BizKitHub public API endpoints require authentication via API key.

Get API Key