public String getJobCompletionRequestBody(String elasticAgentId, JobIdentifier jobIdentifier, Map<String, String> elasticProfileConfiguration, Map<String, String> clusterProfileConfiguration) {
        JsonObject jsonObject = new JsonObject();

        jsonObject.addProperty("elastic_agent_id", elasticAgentId);
        jsonObject.add("job_identifier", jobIdentifierJson(jobIdentifier));
        jsonObject.add("elastic_agent_profile_properties", mapToJsonObject(elasticProfileConfiguration));
        jsonObject.add("cluster_profile_properties", mapToJsonObject(clusterProfileConfiguration));

        return FORCED_EXPOSE_GSON.toJson(jsonObject);
    }
@Test
    public void shouldJSONizeJobCompletionRequestBody() throws Exception {
        HashMap<String, String> elasticProfileConfiguration = new HashMap<>();
        elasticProfileConfiguration.put("property_name", "property_value");
        HashMap<String, String> clusterProfileConfiguration = new HashMap<>();
        clusterProfileConfiguration.put("property_name", "property_value");
        String actual = new ElasticAgentExtensionConverterV5().getJobCompletionRequestBody("ea1", jobIdentifier, elasticProfileConfiguration, clusterProfileConfiguration);

        String expected = """
                {  "elastic_agent_id":"ea1",  "elastic_agent_profile_properties":{    "property_name":"property_value"  },  "cluster_profile_properties":{    "property_name":"property_value"  },  "job_identifier": {
                    "pipeline_name": "test-pipeline",
                    "pipeline_counter": 1,
                    "pipeline_label": "Test Pipeline",
                    "stage_name": "test-stage",
                    "stage_counter": "1",
                    "job_name": "test-job",
                    "job_id": 100
                  }
                }""";

        assertThatJson(expected).isEqualTo(actual);
    }