# Update rules in a JRM payload Replaces URL rules, group rules, and block message in a JRM payload. Published profiles cannot be updated. ## Endpoint `PUT /bsp/api/v1/bmp/jrm/{jrm_profile_id}/jrm_payloads/{jrm_payload_id}` ## Request URL `https://{server-hostname}:8383/bsp/api/v1/bmp/jrm/{jrm_profile_id}/jrm_payloads/{jrm_payload_id}` ## Scope `BrowserManager.CREATE` ## Header `Authorization: d92d4xxxxxxxxxxxxx15f52` ## Request Parameters ### Request Headers - **Content-Type** `string` — Mandatory — `application/json` - **Accept** `string` — Mandatory — `application/json` ### Path Parameters - **jrm_payload_id** `string` — Mandatory JRM Payload ID from [Get JRM Profile](https://www.manageengine.com/products/desktop-central/help/api/onpremise/java-manager-get-jrm-profile.html) response (`config_data_item_id` field). - **jrm_profile_id** `string` — Mandatory JRM Profile ID from [List JRM Profiles](https://www.manageengine.com/products/desktop-central/help/api/onpremise/java-manager-list-jrm-profiles.html) response (`jrm_profile_id` field). ### Request Body Complete replacement of all payload rules. Include ONLY `urls` OR `groups` (not both). Any existing rules will be fully replaced. Do not send empty arrays for `urls` or `groups`; omit the key entirely if not used. The `block_message` field is only available when `action=0` (Block). `application/json` `JSON object` Java rules payload. Pick URL or Group from the dropdown. - **jrm_payloads** — Optional Rule set. ## Examples ### URL Rules #### Sample Request ```curl curl --request PUT \ --url https://appdomain/bsp/api/v1/bmp/jrm/{jrm_profile_id}/jrm_payloads/{jrm_payload_id} \ --header 'Accept: application/json' \ --header 'Authorization: d92d4xxxxxxxxxxxxx15f52' \ --header 'Content-Type: application/json' \ --data '{"jrm_payloads":{"urls":[{"action":0,"webdomain_ids":["3"]}],"block_message":"Blocked by policy"}}' ``` #### Sample Request Body — URL Rules Replace with URL allow rule: ```json { "jrm_payloads": { "urls": [ { "java_version": "1.8.0_01", "action": 1, "webdomain_ids": [ "3" ] } ] } } ``` Replace with URL block rule: ```json { "jrm_payloads": { "urls": [ { "action": 0, "webdomain_ids": [ "3" ] } ], "block_message": "Blocked by policy" } } ``` ## Response Parameters ### HTTP Code 200 Response Body — `application/json` `JSON object` Response after modifying an existing payload. - **payloads** `JSON array` The updated payload reflecting your changes. ### HTTP Code 400 Response Body — `application/json` `JSON object` - **errorcode** `string` Error identifier (e.g., `IAM0006` for invalid field value). - **errormsg** `string` Describes which field or value is invalid. ### HTTP Code 401 Response Body — `application/json` `JSON object` - **errorCode** `long` Unauthorized error code returned when authentication credentials are missing, expired, or invalid (`authentication=required`). - **errorMsg** `string` Authentication failure reason. ### HTTP Code 403 Response Body — `application/json` `JSON object` - **errorCode** `long` Forbidden error code returned when the authenticated user does not have the required `uem-roles` (e.g., `DataEncryption_Admin` or `DataEncryptionRecoveryKey_Admin`). - **errorMsg** `string` Message indicating insufficient privileges to access this resource. ### HTTP Code 429 Response Body — `application/json` `JSON object` - **errorCode** `long` Rate limit error code returned when the API call threshold (configured via threshold/duration in security XML) is exceeded; client is locked out for lock-period minutes. - **errorMsg** `string` Rate limit exceeded message with retry guidance. ### HTTP Code 500 Response Body — `application/json` `JSON object` - **errormsg** `string` Description of the server-side error. ## Possible Response Codes - `200` — HTTP code - `400` — HTTP code - `401` — HTTP code - `403` — HTTP code - `429` — HTTP code - `500` — HTTP code ## Sample Responses ### HTTP 200 Updated payload: ```json { "payloads": [ { "payload_type": "64101", "block_message": "Blocked by policy", "jrm_details": [ { "config_data_item_id": "971", "urls": [ { "java_version": "", "action": "0", "id": "3", "url": "localhost" } ], "groups": [] } ], "default_rias": false, "config_label": "JAVA_RULES_MANAGER" } ] } ``` ### HTTP 400 Invalid payload: ```json { "errorcode": "IAM0003", "errormsg": "Invalid request." } ``` Invalid Java version: ```json { "errorCode": "IAM0025", "url": "/bsp/api/v1/bmp/jrm/{jrm_profile_id}/jrm_payloads/{jrm_payload_id}", "errorMsg": "java_version is an invalid parameter format." } ``` Empty array: ```json { "errorCode": "IAM0022", "url": "/bsp/api/v1/bmp/jrm/{jrm_profile_id}/jrm_payloads/{jrm_payload_id}", "errorMsg": "Array size exceeds limit." } ``` ### HTTP 401 Unauthorized: ```json { "errorCode": "IAM0001", "errorMsg": "Authentication key is invalid. Please regenerate the key and try again." } ``` ### HTTP 403 Forbidden: ```json { "errorCode": "FORBIDDEN", "errorMsg": "You do not have permission to access this resource" } ``` ### HTTP 429 Rate limit exceeded: ```json { "errorCode": "RATE_LIMIT_EXCEEDED", "errorMsg": "You have exceeded the maximum number of API calls. Please try again later." } ``` ### HTTP 500 Server error: ```json { "errormsg": "Internal Server error, Please try again in a moment." } ``` ## Rate Limits ![](https://www.zohowebstatic.com/sites/zweb/images/people/ico-help.png) **Duration:** 1 minute | **Threshold:** 60 | **Lock period:** 5 minutes Duration — Time window for the threshold. Threshold — Number of API calls allowed within the specified duration. Lock Period — Wait time before consecutive API requests.