Add system user for a customer

Get a customer’s Company ID from the companies list, then create a system user (platform admin) for that company by sending the Company ID in the request. Reseller-only — use a credential with Client Role = Reseller. System users can log in to the Keepnet platform and manage that company; scoping by Company ID ensures the user is created under the correct customer.


POST /api/companies/search

Get the customer’s Company ID by calling this endpoint; use the resourceId of the desired company in the next step.

Retrieves a paginated list of all companies you manage with license details. Each item includes resourceId — use it as the Company ID for scoped requests. Test it: Authorize with Client ID/Secret, then Send — request body is pre-filled.

Retrieves a list of all companies

post
chevron-right
lockRequired scopes
This endpoint requires the following scopes:
  • : API
Authorizations
OAuth2clientCredentialsRequired

Client ID and Client Secret from Company → Company Settings → REST API. Enter credentials to auto-fetch token.

Token URL:
Body
pageNumberintegerRequiredExample: 1
pageSizeintegerRequiredExample: 10
orderBystringRequiredExample: CreateTime
ascendingbooleanRequiredExample: false
isTargetUserCountExceededLimitbooleanOptional

If true, only companies exceeding license limit are returned

Example: false
Responses
chevron-right
200

OK

application/json
statusstringOptional
messagestring · nullableOptional
validationMessagesstring[] · nullableOptional
post
/api/companies/search
200

OK

From the response, pick the company (e.g. by name) and note its resourceId. Example: "resourceId": "xC5kfGz7w2Nz" → use xC5kfGz7w2Nz as Company ID when calling POST /api/system-users.


POST /api/system-users

Create a system user for that company by sending the Company ID in the X-KEEPNET-Company-Id header. Without it, the user may be created in the wrong context or the request may fail.

Creates a new system user. As a Reseller, send X-KEEPNET-Company-Id: <companyResourceId> with the customer’s Company ID from the companies search response. Body: email, firstName, lastName, phoneNumber (required), and optional roleResourceIdList, statusId. Test it: Endpoints → SystemUserCreates a new system user — use dummy data (H8d) and set the header to a Company ID from companies/search.

Create a new system user

post
chevron-right
lockRequired scopes
This endpoint requires the following scopes:
  • : API
Authorizations
OAuth2clientCredentialsRequired

Client ID and Client Secret from Company → Company Settings → REST API. Enter credentials to auto-fetch token.

Token URL:
Body
firstNamestring · min: 1 · max: 40Required
lastNamestring · min: 1 · max: 40Required
emailstring · min: 1 · max: 320Required
phoneNumberstring · min: 1 · max: 20Required
statusIdinteger · int32Optional
roleResourceIdListstring[] · nullableOptional
companyResourceIdstring · nullableOptional
Responses
chevron-right
200

OK

application/json
statusstringOptional
messagestring · nullableOptional
validationMessagesstring[] · nullableOptional
post
/api/system-users
200

OK

Example request headers:

Example body (dummy data):


Common errors

  • 403 Forbidden — Credential is not Reseller, or the Company ID is not one you manage. Set Client Role = Reseller. Roles and permissions →

  • 401 Unauthorized — Missing or invalid token. Request a new token via POST /connect/token.

  • 404 Not Found / 400 Bad Request — Invalid Company ID or missing required body fields (email, firstName, lastName, phoneNumber). Verify Company ID from POST /api/companies/search and check Endpoints → SystemUser for the request body schema.

Related: Scope API requests to a customer → for how Company ID is used across endpoints. Add target users for a customer → for the same flow with target users instead of system users.

Last updated