Common Methods error?

I'm using some of the methods in Common Methods | Hubitat Documentation

Most appear to work fine, for example, getSunriseAndSunset returns:
{"sunrise":"2024-05-30T12:24:00+0000","sunset":"2024-05-31T03:51:00+0000"}
as expected.

But one: timeToday
is causing an error:
{"error":true,"type":"java.lang.Exception","message":"An unexpected error occurred."}

and two:
getTomorrowsSunrise
getTodaysSunset

Don't return any information at all.

Are they implemented?

Thanks.

Works for me. Perhaps not well documented.

        case "sunrise":
            String sunrise = outputFormat.format(getTodaysSunrise())
            return [value: sunrise, dataType: "Date"]
            break
        case "sunset":
            String sunset = outputFormat.format(getTodaysSunset())
            return [value: sunset, dataType: "Date"]
            break
        case "sunriseTomorrow":
            String sunriseTomorrow = outputFormat.format(getTomorrowsSunrise())
            return [value: sunriseTomorrow, dataType: "Date"]
            break
        case "sunsetTomorrow":
            String sunsetTomorrow = outputFormat.format(getTomorrowsSunset())
            return [value: sunsetTomorrow, dataType: "Date"]
            break

I think this is the required import:
import java.text.SimpleDateFormat

Thanks. I added that import. Unfortunately, same issues.

These are all the imports defined in my app.

import groovy.transform.Field
import java.text.SimpleDateFormat
import java.util.Date
import java.time.LocalDate
import java.time.LocalDateTime
import java.text.ParseException
import java.util.regex.Pattern

I'm on a very recent version: 2.3.9.136

My code accessing those two.

What are you expecting timeToday to return? Sounds a bit like now().

Thanks. Tried those too. I just get a blank response.

Oddly getSunriseAndSunset works perfectly.

I just updated my prior response.

"What are you expecting timeToday to return? Sounds a bit like now()."

I'm hoping it gives me the local time on the hub. I'm writing a custom (off hub) app, and I need to make sure the app's time is the same as the hub's time.

I do remember having an issue with one of the calls but I didn't really need it. I think this one was probably it. But the other two work for me:
getTomorrowsSunrise
getTodaysSunset

Thank you. I think I figured it out. I think the property I was using was incorrect. I'll play with it some more. Much appreciated.