Apps/AITC: Difference between revisions

Jump to navigation Jump to search
235 bytes removed ,  15 March 2012
Line 114: Line 114:
  {app_document}
  {app_document}


'''NOTE''': consider adding detection of stale version, e.g. if two receipts uploaded at same time.
Optionally, the header <code>X-If-Unmodified-Since</code>, a millisecond timestamp, can be used to prevent conflicting updates. If there's a conflict, a 412 error is returned.
 
If we use ETags then you'd use <code>If-Match: "etag"</code> in the case of updating a record, and <code>If-None-Match: *</code> in the case of adding a new record. (With <code>Last-Modified</code> there does not appear to be a way to add a new record while asserting that an existing record does not exist.)


This could do basic validation of the app document.
This could do basic validation of the app document.
668

edits

Navigation menu