         let expectation = self.expectation(description: description)
 
         let newExample = "swift-sdk-test-counterexample" + UUID().uuidString
-        conversation.createCounterexample(workspaceID: workspaceID, text: newExample, failure: failWithError) { counterexample in
+        conversation.createCounterexample(workspaceID: workspaceID, text: newExample) {
+            response, error in
+
+            if let error = error {
+                XCTFail("Unexpected error response from service: \(error)")
+                return
+            }
+            guard let counterexample = response?.result else {
+                XCTFail("Missing response value")
+                return
+            }
+
             XCTAssertEqual(counterexample.text, newExample)
             expectation.fulfill()
         }

        let description = "List all the entities in a workspace with includeCount as true."
        let expectation = self.expectation(description: description)

        conversation.listEntities(workspaceID: workspaceID, includeCount: true, includeAudit: true, failure: failWithError) { entities in
            for entity in entities.entities {
                XCTAssertNotNil(entity.entityName)
                XCTAssertNotNil(entity.created)

        let updatedEntityName = "up-" + entityName
        let updatedEntityDescription = "This is a new description for a test entity"
        let updatedEntity = UpdateEntity.init(entity: updatedEntityName, description: updatedEntityDescription)
        conversation.updateEntity(workspaceID: workspaceID, entity: entityName, properties: updatedEntity) {
            response, error in

            if let error = error {
                XCTFail("Unexpected error response from service: \(error)")
                return
            }
            guard let entity = response?.result else {
                XCTFail("Missing response value")
                return
            }

            XCTAssertEqual(entity.entityName, updatedEntityName)
            XCTAssertEqual(entity.description, updatedEntityDescription)
            expectationTwo.fulfill()
        }
        waitForExpectations()
