etag, if-match, and if-none-match
Many of the file system items (files or folders) that can be requested via the
API return an etag value for the item.
For example, a file resource returns an etag in the JSON response.
etag can be used as the value of a if-match or if-none-match
header to either ensure a resource hasn’t changed since the etag value was
received, or to prevent unnecessary downloads for items that haven’t changed.
For example, to fetch the same file only if it has changed, pass in the etag
value in a if-none-match header.
Ensure consistent changes
Theif-match header allows your application to ensure that no changes are
made to items when another application or a user has made changes to the item
since your application last inspected it. This helps ensure that
changes aren’t lost when two applications or users are changing items at the
same time.
The following endpoints support this header.
The response of these APIs calls depends on the existence of the item,
and whether the
etag value matches the most recent version.
Prevent unnecessary request downloads
Theif-none-match header allows your application to ensure that no information
is downloaded for items that have not changed since your application last
inspected it. This helps ensure no unnecessary information is downloaded,
speeding up your application and saving on bandwidth.
The response of these APIs calls depends on the existence of the item,
and whether the
etag value matches the most recent version.
