date format

Skip to first unread message

matt quadros

Aug 22, 2023, 12:15:45 AM8/22/23
to MBTA Developers

I just pulled some transit reliability data, and I'm seeing the service date listed as "1685505600000", rather than "20230521", and I'm having difficulty converting the format. Any advice on how to work with this format?

   "features": [
         "attributes": {
            "service_date": 1685505600000,
            "gtfs_route_id": "Red",
            "gtfs_route_short_name": "NA",
            "gtfs_route_long_name": "Red Line",
            "gtfs_route_desc": "Rapid Transit",
            "route_category": "Red Line",
            "mode_type": "Rail",
            "peak_offpeak_ind": "PEAK",
            "metric_type": "Passenger Wait Time",
            "otp_numerator": 107340.143684546,
            "otp_denominator": 114782.841904052,
            "cancelled_numerator": 0,
            "ObjectId": 1

Jay Greenspan

Aug 22, 2023, 10:14:43 AM8/22/23
That looks like a Unix epoch timestamp. For a conversion, see:
Any programming language will include functions to convert to a more readable date/time format. 


You received this message because you are subscribed to the Google Groups "MBTA Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit

matt quadros

Aug 22, 2023, 8:24:16 PM8/22/23
to MBTA Developers
Thank you! This solved it - it's epoch timestamp in milliseconds!
Reply all
Reply to author
0 new messages