Tovább a tartalomhoz

Time difference

Ez a tartalom még nem érhető el a jelenlegi nyelven.


Returns the Difference between 2 timestamps.

GET /api/time/time-difference
https://api.cookie-api.com/api/time/time-difference


ParameterTypeRequiredDescription
before unix iso YesTime period start
after unix iso YesTime period end


curl --location 'https://api.cookie-api.com/api/time/time-difference?before=in%203%20minutes&after=2024-07-14T17%3A31%3A04Z' \
--header 'Authorization: API_Key'

{
"days": 0,
"hours": 1,
"human_readable": "0 days, 1 hours, 1 minutes, 3 seconds",
"iso_format": "P0DT1H1M3S",
"microseconds": 3663684364,
"milliseconds": 3663684,
"minutes": 1,
"months": 0,
"nanoseconds": 3663684364000,
"seconds": 3,
"total": {
"days": 0,
"hours": 1,
"minutes": 61,
"seconds": 3663.684364,
"years": 0
},
"years": 0
}