Working with child fields

My log looks something like this.
"request": {
"hostip": "10.7.37.74",
"enduserip": "",
}

Obviously "enduserip": "" is not a valid IP address. I would like to delete the field in this case.

This syntax isn't being considered valid by logstash.
mutate{
remove_field => ["request"]["enduserip"]
}

Any suggestions?

mutate {
  remove_field => ["[request][enduserip]"]
}

That worked, thanks!

Does the same syntax hold true for renaming a child field?

(my google foo on these topic's is highly lacking)

Yes.

https://www.elastic.co/guide/en/logstash/current/event-dependent-configuration.html#logstash-config-field-references