PUT
/
security
/
merchantUsers
/
close
cURL
curl -X PUT "https://dev.api.onekhusa.com/sandbox/v1/security/merchantUsers/close" \
  --header "Authorization: Bearer your-jwt-token" \
  --header "Content-Type: application/json" \
  --header "Accept-Language: en" \
  -d '{
    "merchantAccountNumber": 67485577,
    "userId": "4f5c00c2-6d19-4fd5-9f25-989bb1d6e9ef",
    "changedBy": "ops.admin@example.com",
    "reasonId": 301,
    "comments": "Account closed at merchant request"
  }'
"User account status has been changed successfully"

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer Token, Where accessToken is the access token used to authenticate the request.

Headers

Accept-Language
string
default:en

Preferred language for the response

Body

application/json

Request payload for closing a merchant user

merchantAccountNumber
integer
required

Merchant account that owns the user

Example:

67485577

userId
string
required

Identifier of the merchant user account to close

Example:

"4f5c00c2-6d19-4fd5-9f25-989bb1d6e9ef"

changedBy
string
required

Email or identifier of the operator performing the closure

Example:

"ops.admin@example.com"

reasonId
integer | null

Reference ID explaining why the status changed

Example:

301

comments
string | null

Free-form notes to include in the status change audit trail

Example:

"Account closed at merchant request"

Response

200 - application/json

Success - Merchant user closed

value
string
required
Example:

"User account status has been changed successfully"

statusCode
integer
Example:

0