OneAgent remote configuration management API - POST a job preview
You can generate a preview before performing the actual configuration change.
The preview tells you:
How many entities are currently configured as described in the payload
How many entities will be configured this way when the reconfiguration request is sent
The request consumes an application/json
payload.
POST | ManagedDynatrace for Government | https://{your-domain}/e/{your-environment-id}/api/v2/oneagents/remoteConfigurationManagement/preview |
SaaS | https://{your-environment-id}.live.dynatrace.com/api/v2/oneagents/remoteConfigurationManagement/preview | |
Environment and Cluster ActiveGate (default port 9999) | https://{your-activegate-domain}:9999/e/{your-environment-id}/api/v2/oneagents/remoteConfigurationManagement/preview |
Authentication
To execute this request, you need an access token with oneAgents.write
scope.
To learn how to obtain and use it, see Tokens and authentication.
Parameters
Parameter | Type | Description | In | Required |
---|---|---|---|---|
body | RemoteConfigurationManagementOperationOneAgentRequest | JSON body of the request, containing remote configuration management job definition. | body | required |
Request body objects
The RemoteConfigurationManagementOperationOneAgentRequest
object
Remote configuration management operation creation request.
Element | Type | Description | Required |
---|---|---|---|
entities | string[] | A list of entities IDs for which remote configuration management is to be executed. | required |
operations | RemoteConfigurationManagementOperation[] | A list of remote configuration management operations to be executed. | required |
The RemoteConfigurationManagementOperation
object
Definition of a single remote configuration management operation.
Element | Type | Description | Required |
---|---|---|---|
attribute | string | The attribute which is affected by the operation.
| required |
operation | string | The operation performed on given attribute.
| required |
value | string | The value which should be assigned to given attribute. | optional |
Request body JSON model
This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.
1{2 "entities": [3 "HOST-D454A967666E7970",4 "HOST-811760CFF2A5E872"5 ],6 "operations": [7 {8 "attribute": "networkZone",9 "operation": "set",10 "value": "exampleNetworkZoneName"11 }12 ]13}
Response
Response codes
Code | Type | Description |
---|---|---|
200 | RemoteConfigurationManagementPreviewList | Success |
400 | RemoteConfigurationManagementValidationResult | Failed. The input is invalid. |
422 | - | Endpoint was executed for not supported operation type |
Response body objects
The RemoteConfigurationManagementPreviewList
object
A list of remote configuration management jobs previews.
Element | Type | Description |
---|---|---|
previews | RemoteConfigurationManagementJobPreview[] | A list of remote configuration management jobs previews. |
The RemoteConfigurationManagementJobPreview
object
A preview of remote configuration management job.
Element | Type | Description |
---|---|---|
alreadyConfiguredEntitiesCount | integer | The number of entities that are currently configured as defined by remote configuration management operation. |
attribute | string | The attribute which is affected by the operation.
|
operation | string | The operation performed on given attribute.
|
targetEntitiesCount | integer | The number of entities that will be configured as defined by remote configuration management after it is completed. |
value | string | The value which should be assigned to given attribute. |
Response body JSON model
1{2 "previews": [3 {4 "alreadyConfiguredEntitiesCount": 1,5 "attribute": "networkZone",6 "operation": "set",7 "targetEntitiesCount": 2,8 "value": "exampleNetworkZoneName"9 }10 ]11}