Output only. The time at which the document was created.
This value increases monotonically when a document is deleted then
recreated. It can also be compared to values from other documents and
the read_time of a query.
Field names matching the regular expression __.*__ are reserved. Reserved
field names are forbidden except in certain documented contexts. The field
names, represented as UTF-8, must not exceed 1,500 bytes and cannot be
empty.
Field paths may be used in other contexts to refer to structured fields
defined here. For map_value, the field path is represented by a
dot-delimited (.) string of segments. Each segment is either a simple
field name (defined below) or a quoted field name. For example, the
structured field "foo" : { map_value: { "x&y" : { string_value: "hello"
}}} would be represented by the field path foo.`x&y` .
A simple field name contains only characters a to z, A to Z,
0 to 9, or _, and must not start with 0 to 9. For example,
foo_bar_17.
A quoted field name starts and ends with ` and
may contain any character. Some characters, including ` , must be
escaped using a \. For example, `x&y` represents x&y and
`bak\`tik` represents bak`tik.
Output only. The time at which the document was last changed.
This value is initially set to the create_time then increases
monotonically with each change to the document. It can also be
compared to values from other documents and the read_time of a query.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThe \u003ccode\u003eDocument\u003c/code\u003e class in the Firestore v1 API represents a Firestore document and implements multiple interfaces, including \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe latest version of the \u003ccode\u003eDocument\u003c/code\u003e class is 3.10.0, with previous versions ranging from 3.9.0 down to 2.3.0, all available through the provided links.\u003c/p\u003e\n"],["\u003cp\u003eA Firestore document has a size limit of 1 MiB - 4 bytes and includes properties like \u003ccode\u003eCreateTime\u003c/code\u003e, \u003ccode\u003eUpdateTime\u003c/code\u003e, \u003ccode\u003eFields\u003c/code\u003e, and \u003ccode\u003eName\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eFields\u003c/code\u003e property in a document is a map of keys representing the field name and their corresponding value, reserved field names are forbidden, and they have rules for the format and length of field names.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eCreateTime\u003c/code\u003e and \u003ccode\u003eUpdateTime\u003c/code\u003e properties, both of type \u003ccode\u003eTimestamp\u003c/code\u003e, are output only fields tracking when a document was created and last changed respectively, also allowing comparisons between other documents and queries.\u003c/p\u003e\n"]]],[],null,["# Firestore v1 API - Class Document (3.10.0)\n\nVersion latestkeyboard_arrow_down\n\n- [3.10.0 (latest)](/dotnet/docs/reference/Google.Cloud.Firestore.V1/latest/Google.Cloud.Firestore.V1.Document)\n- [3.9.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.9.0/Google.Cloud.Firestore.V1.Document)\n- [3.8.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.8.0/Google.Cloud.Firestore.V1.Document)\n- [3.7.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.7.0/Google.Cloud.Firestore.V1.Document)\n- [3.6.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.6.0/Google.Cloud.Firestore.V1.Document)\n- [3.5.1](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.5.1/Google.Cloud.Firestore.V1.Document)\n- [3.4.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.4.0/Google.Cloud.Firestore.V1.Document)\n- [3.3.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.3.0/Google.Cloud.Firestore.V1.Document)\n- [3.2.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.2.0/Google.Cloud.Firestore.V1.Document)\n- [3.1.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.1.0/Google.Cloud.Firestore.V1.Document)\n- [3.0.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/3.0.0/Google.Cloud.Firestore.V1.Document)\n- [2.5.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/2.5.0/Google.Cloud.Firestore.V1.Document)\n- [2.4.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/2.4.0/Google.Cloud.Firestore.V1.Document)\n- [2.3.0](/dotnet/docs/reference/Google.Cloud.Firestore.V1/2.3.0/Google.Cloud.Firestore.V1.Document) \n\n public sealed class Document : IMessage\u003cDocument\u003e, IEquatable\u003cDocument\u003e, IDeepCloneable\u003cDocument\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Firestore v1 API class Document.\n\nA Firestore document.\n\nMust not exceed 1 MiB - 4 bytes. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e Document \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Document](/dotnet/docs/reference/Google.Cloud.Firestore.V1/latest/Google.Cloud.Firestore.V1.Document), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Document](/dotnet/docs/reference/Google.Cloud.Firestore.V1/latest/Google.Cloud.Firestore.V1.Document), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Document](/dotnet/docs/reference/Google.Cloud.Firestore.V1/latest/Google.Cloud.Firestore.V1.Document), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Firestore.V1](/dotnet/docs/reference/Google.Cloud.Firestore.V1/latest/Google.Cloud.Firestore.V1)\n\nAssembly\n--------\n\nGoogle.Cloud.Firestore.V1.dll\n\nConstructors\n------------\n\n### Document()\n\n public Document()\n\n### Document(Document)\n\n public Document(Document other)\n\nProperties\n----------\n\n### CreateTime\n\n public Timestamp CreateTime { get; set; }\n\nOutput only. The time at which the document was created.\n\nThis value increases monotonically when a document is deleted then\nrecreated. It can also be compared to values from other documents and\nthe `read_time` of a query.\n\n### Fields\n\n public MapField\u003cstring, Value\u003e Fields { get; }\n\nThe document's fields.\n\nThe map keys represent field names.\n\nField names matching the regular expression `__.*__` are reserved. Reserved\nfield names are forbidden except in certain documented contexts. The field\nnames, represented as UTF-8, must not exceed 1,500 bytes and cannot be\nempty.\n\nField paths may be used in other contexts to refer to structured fields\ndefined here. For `map_value`, the field path is represented by a\ndot-delimited (`.`) string of segments. Each segment is either a simple\nfield name (defined below) or a quoted field name. For example, the\nstructured field `\"foo\" : { map_value: { \"x&y\" : { string_value: \"hello\"\n}}}` would be represented by the field path ``foo.`x&y` ``.\n\nA simple field name contains only characters `a` to `z`, `A` to `Z`,\n`0` to `9`, or `_`, and must not start with `0` to `9`. For example,\n`foo_bar_17`.\n\nA quoted field name starts and ends with ``` `` and\nmay contain any character. Some characters, including ``` ``, must be\nescaped using a `\\`. For example, ```x&y` `` represents `x&y` and\n```bak\\`tik` `` represents ``bak`tik``.\n\n### Name\n\n public string Name { get; set; }\n\nThe resource name of the document, for example\n`projects/{project_id}/databases/{database_id}/documents/{document_path}`.\n\n### UpdateTime\n\n public Timestamp UpdateTime { get; set; }\n\nOutput only. The time at which the document was last changed.\n\nThis value is initially set to the `create_time` then increases\nmonotonically with each change to the document. It can also be\ncompared to values from other documents and the `read_time` of a query."]]