| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Update License Keep Active Option
Controls the keep-active setting for a specific Charge Anywhere device license. When keepActive is set to true, the license will be maintained in an active state to ensure uninterrupted payment processing on that device. Setting it to false signals that the license can be deactivated — for example, when a device is retired or reassigned. The response returns a boolean confirming whether the update was applied.
Endpoint
POST /api/v1/merchant/chargeAnywhere/keepLicenseActive
Authentication
Basic HTTP Authentication required.
Encode username:password in Base64 and pass in the Authorization header:
Authorization: Basic {base64(username:password)}
When to use
Use this endpoint when you need to change the lifecycle state of a specific device license without fully deleting it. This is common when temporarily disabling a terminal (e.g., during equipment maintenance or suspension), or when re-activating a device after a period of inactivity. It is also used as part of the device decommissioning workflow.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | integer (int32) | Yes | Merchant or license record identifier that owns the device license being updated |
| deviceId | integer (int32) | Yes | Identifier of the specific device whose license keep-active setting is being changed |
| keepActive | boolean | Yes | Set to true to keep the license active; false to allow deactivation |
Response
200 OK
| Field | Type | Description |
|---|---|---|
| data | boolean | true if the keep-active setting was successfully updated; false otherwise |
| requestId | integer | Unique request ID for tracking and debugging |
| success | boolean | True if the API call was processed without errors |
| error | string | Error message if the update failed; null on success |
| validationErrors | array | Field-level validation errors, if any |
{
"data": true,
"requestId": 55781,
"success": true,
"error": null,
"validationErrors": []
}Error Codes
| Code | When it happens |
|---|---|
| 400 | One or more required query parameters (id, deviceId, keepActive) are missing or have an invalid type |
| 401 | Invalid or missing Basic Auth credentials |
| 403 | User does not have permission for this operation |
| 404 | No license found for the specified id and deviceId combination |
| 500 | Internal server error while updating the license keep-active option |
Common Mistakes
- Passing string values for
idordeviceId— both must be valid int32 integers - Omitting
keepActivefrom the query string — it is required and must be explicitlytrueorfalse - Confusing
id(the merchant/record identifier) withdeviceId— these are two distinct identifiers;idscopes the request to the correct merchant account, whiledeviceIdtargets the specific device - Calling this endpoint on an already-active license expecting a different behavior — the endpoint is idempotent; setting
keepActive: trueon an already-active license is a no-op
Related Endpoints
GET /api/v1/merchant/chargeAnywhere/licenses— retrieve all licenses for a merchant to find the correctdeviceIdGET /api/v1/merchant/chargeAnywhere/terminals— list all terminals and their identification detailsPOST /api/v1/merchant/chargeAnywhere/terminal— create a new Charge Anywhere terminal
Example
curl -X POST "https://hq.staging.netevia.dev/api/v1/merchant/chargeAnywhere/keepLicenseActive?id=5821&deviceId=391&keepActive=true" \
-H "Authorization: Basic $(echo -n 'username:password' | base64)" \
-H "Content-Type: application/json"