This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.
A contenttag is a token generated by the server that represents the state of the contents of a collection (depth=1,noroot). Every time the contents or properties of a resource within the collection changes, the contenttag Field on the collection is updated to reflect the change. The contenttag Field is supported on every collection resource that can be replicated. Two contenttags are guarenteed to be binary comparable. The client can store the contenttag on a collection for future comparisons.
The contenttag provides an efficient way for the client to check if a collection has changed since the last time it synchronized. The client can use the PROPFIND Method or the SEARCH Method to fetch the contenttag Field on the collection from the server and then compare the value against its previously obtained value from the server.
The contenttag also allows for a way to check for collection hierarchy changes or for a collection whose contents have changed. The client should use the PROPFIND Method or the SEARCH Method to fetch the contenttag Field of every collection in the hierarchy and then compare them against the previously obtained contenttag values from the server without the collblob or repl XML Element.
A contenttag can also be used in an If Header to make sure that an operation (especially a DELETE Method request) on a collection will only happen if the contents of the collection have not changed. As such, it can be used in an If Header anywhere that resourcetag or repl-uid are allowed.