Closed footnote closed 9 years ago
This route as well /v1/posts
This seems like it was already being returned. I added the sort order in commit afcdec4 because you asked for it on another issue. Can you confirm this is an issue?
@ShadiFares
Check the format of createDate parameter, please check to convert to unix timestamp to be able to use 1 method for all dates and time
What is currently being returned for you? We typically use JSON date objects which have built in conversation methods in most languages.
Perhaps a screenshot of what is being returned for you as well as the route and username/token you are using will help us debug if you are still encountering this issue.
@ShadiFares
The expectation is to get the date like this 1443398069 (Timestamp Format) as we used to do in Quipics
The date marked up in the attached screenshot should be in tiemstamp format like this one and the other routes too, any date that is returned in any route should be returned in Unix format 1443398069
The date in the attached screenshot is the date in the response header. Your application shouldn't be using anything in the header for displaying to the user.
Also the format in the very first screenshot is the official ISO_8601 date spec https://en.wikipedia.org/wiki/ISO_8601. I think you can convert the ISO_8601 to a date in iOS using Swift as follows. I am sure there is an Objective-C equivalent.
let dateFormatter = NSDateFormatter()
let enUSPosixLocale = NSLocale(localeIdentifier: "en_US_POSIX")
dateFormatter.locale = enUSPosixLocale
dateFormatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ssZZZZZ"
let iso8601String = dateFormatter.stringFromDate(NSDate())
@footnote @ShadiFares let me know if this solved the issue.
@footnote please followup with this.
GET /v1/users/{userId}/posts