Adding date and time to the same request

If you’re trying to get an ISO8601-formatted datetime, you can just use get_the_date() as it’ll actually return the date and time a post was published.

So something like get_the_date( 'c' ) should get you the date and time, formatted how you want them (per your comment).