public static LogResult editLog(final String geocode, final LogEntry logEntry) {

        if (StringUtils.isBlank(logEntry.serviceLogId)) {
            return generateLogError("Need a serviceLogId to edit a log entry");
        }

        final String logId = logEntry.serviceLogId;

        //https://www.geocaching.com/live/geocache/GCxyz/log/GLabc/edit
        //1.) Call log edit page and get a valid CSRF Token
        final String csrfToken = getCsrfToken();
        if (csrfToken == null) {
            return generateLogError("Log Post: unable to extract CSRF Token");
        }

        //2,) Fill Log Entry object and PUT it
        final GCWebLogRequest logEntryRequest = createLogRequest(logEntry, null);

        try (GCWebLogResponse response = websiteReq().uri("/api/live/v1/logs/geocacheLog/" + logId)
            .method(HttpRequest.Method.PUT)
            .headers(HTML_HEADER_CSRF_TOKEN, csrfToken)
            .bodyJson(logEntryRequest)
            .requestJson(GCWebLogResponse.class).blockingGet()) {

            if (response.logReferenceCode == null) {
                return generateLogError("EditLog: problem with server, request JSON=[" + HttpRequest.getJsonBody(logEntryRequest) +
                    "], response=[" + response + "]");
            }

            return LogResult.ok(response.logReferenceCode);
        }

    }
Provides methods to handle all aspects of creating, editing and deleting Log entries for GC.com (both caches and trackables)
main/src/main/java/cgeo/geocaching/connector/gc/GCLogAPI.java