Time subtraction
GET https://postman-echo.com/time/subtract?timestamp=2016-10-10&years=50
A simple GET
request to /time/subtract
to subtract units of time from the specified / current timestamp (as provided in the years
, months
, days
, hours
, minutes
, seconds
, and milliseconds
query parameters).
This endpoint accepts timestamp
, locale
, format
, and strict
query parameters to construct the date time instance to check against.
Responses are provided in JSON format, with a difference
key to indicate the result. The response code is 200
for valid query parameters, and 400
otherwise.
{
difference: "difference between (provided / current) and provided timestamps"
}
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
timestamp | string | ||
years | number |