Bug: REST API does not support proper ISO8601 formatted dates

Eleven41
Contributor
Contributor

I am attempting to record an invoice payment as per

 

https://developer.paypal.com/docs/api/invoicing/#invoices_record-payment

 

In the documentation, the "date" is mentioned as being ISO8601 format, as per 

 

https://tools.ietf.org/html/rfc3339#section-5.6

 

However, no correctly formatted ISO8601 formatted date is accepted.

 

Any attempt to use an ISO8601 formatted date receives the following error message: only date-time value with 'yyyy-MM-dd HH:mm:ss z' format is allowed. Atleast that clues me in that spaces are preferred over a "T" between the date and time.

 

However, using "Z" to indicate UTC timezone is not accepted.

 

Basically, the only date format accepted is a PST/PDT timezone offsetted date. A UTC date is not accepted. Not only that, the time zone portion must be either "PST" or "PDT", not "-7", "-8", etc. This does not adhere to the ISO8601 format which does not support timezone names, only offset values, according to the very docs your documentation links to.

 

Please update your REST API to support ISO8601 dates.

 

OR

 

Properly document the format of your accepted dates.

Login to Me Too
3 REPLIES 3

notchrischen
New Community Member

One of many PayPal documentation inconsistencies... and this is with their *new* apis.

Login to Me Too

notchrischen
New Community Member

Not sure if using the "PayPal style iso8601" with a PST time zone date works here, but it doesn't seem to work with other API calls that require a date in this format. Seems to be no way to add a time zone except by manually offsetting the time.

Login to Me Too

TigerSoftware
Contributor
Contributor

I couldn't create any invoices with a due date util I added a PST at the end.   This is a really terrible api implementation.  By far one of the worst that I have encountered when working with several apis.

 

 

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.