The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.
Handling timestamps in Firestore often involves serializing and deserializing them, especially when working with external systems or storing data in formats like JSON. hydrateTimestamp simplifies the process of converting serialized timestamps back into Firestore’s native Timestamp format.
Use hydrateTimestamp to convert a serialized timestamp into a Firestore Timestamp object:
import { hydrateTimestamp } from 'path-to-your-utilities'// Example of a serialized Firestore timestampconst serializedTimestamp = { seconds: 1234567890 }// Convert it back to a Firestore Timestampconst timestamp = hydrateTimestamp(serializedTimestamp)
Use hydrateTimestamp when dealing with serialized Firestore timestamp data to maintain data consistency and integrity.
Always handle potential errors when converting serialized timestamps to avoid unexpected crashes or data issues.
Be aware of the format of your serialized timestamps to ensure compatibility with hydrateTimestamp.
Proper error handling is crucial when using hydrateTimestamp to prevent
issues with invalid or missing timestamp data.
{"docsConfig":{"$schema":"https://mintlify.com/docs.json","theme":"mint","name":"Firebridge","colors":{"primary":"#36656B","light":"#DAF1F4","dark":"#36656B"},"favicon":"/favicon.svg","logo":{"light":"https://mintcdn.com/humancollective/oNaxoG7QbCmsD9Gt/logo/light.svg?fit=max\u0026auto=format\u0026n=oNaxoG7QbCmsD9Gt\u0026q=85\u0026s=19a786e3b49034489f469d223f640a91","dark":"https://mintcdn.com/humancollective/oNaxoG7QbCmsD9Gt/logo/dark.svg?fit=max\u0026auto=format\u0026n=oNaxoG7QbCmsD9Gt\u0026q=85\u0026s=5ab41e88ab90b2cf7147044fcf65c387"},"background":{"decoration":null,"color":{"light":"#f3f8f8","dark":"#1e2a2e"}},"navbar":{"primary":{"type":"button","label":"Github","href":"https://github.com/firebridgekit/Firebridge"}},"footer":{"socials":{"github":"https://github.com/firebridgekit/Firebridge"}},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"humancollective","hasAudioNarration":false,"actualSubdomain":"humancollective","customDomains":["firebridge.dev"],"gitSource":{"type":"github","owner":"firebridgekit","repo":"firebridge","deployBranch":"main","contentDirectory":"docs","isPrivate":false,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6a21a6025634a55fb597136b","collectionId":"35ec6246-3e30-4bc4-b309-ee939fc07198","schemaVersion":"v2"},"entitlements":{},"buildId":"6a21a6025634a55fb597136b:success","clientVersion":"0.0.3965","searchFilterCounts":[{"language":"default","tag":"Cloud","count":26},{"language":"default","tag":"Actions","count":7},{"language":"default","tag":"Timestamps","count":6},{"language":"default","tag":"Metrics","count":5},{"language":"default","tag":"React","count":4},{"language":"default","tag":"Snapshots","count":3},{"language":"default","tag":"Hooks","count":3},{"language":"default","tag":"Execution","count":2},{"language":"default","tag":"Invokeables","count":2},{"language":"default","tag":"Introduction","count":2}]},"assistantConfig":{},"hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"cloud/timestamps/hydrateTimestamp","slug":"/cloud/timestamps/hydrateTimestamp","pageMetadata":{"title":"hydrateTimestamp","description":"The `hydrateTimestamp` utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.","icon":"code","href":"/cloud/timestamps/hydrateTimestamp"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"The \", _jsx(_components.code, {\n children: \"hydrateTimestamp\"\n }), \" utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`introduction`,children:`Introduction`}),`\n`,_jsxs(_components.p,{children:[`Handling timestamps in Firestore often involves serializing and deserializing them, especially when working with external systems or storing data in formats like JSON. `,_jsx(_components.code,{children:`hydrateTimestamp`}),` simplifies the process of converting serialized timestamps back into Firestore’s native Timestamp format.`]}),`\n`,_jsx(Heading,{level:`3`,id:`key-features`,children:`Key Features`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Restores Firestore Timestamps`}),`: Converts serialized timestamp representations back into Firestore Timestamp objects.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Error Handling`}),`: Validates the input and throws an error for invalid or missing serialized timestamps.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Flexible Input Support`}),`: Accepts different serialized timestamp formats for conversion.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`utilization`,children:`Utilization`}),`\n`,_jsx(Heading,{level:`4`,id:`converting-serialized-timestamps`,children:`Converting Serialized Timestamps`}),`\n`,_jsxs(_components.p,{children:[`Use `,_jsx(_components.code,{children:`hydrateTimestamp`}),` to convert a serialized timestamp into a Firestore Timestamp object:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`7`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`hydrateTimestamp`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'path-to-your-utilities'`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Example of a serialized Firestore timestamp`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` serializedTimestamp`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`seconds:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1234567890`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Convert it back to a Firestore Timestamp`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` timestamp`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` hydrateTimestamp`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`serializedTimestamp`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`handling-invalid-timestamps`,children:`Handling Invalid Timestamps`}),`\n`,_jsxs(_components.p,{children:[`If the serialized timestamp is invalid or not provided, `,_jsx(_components.code,{children:`hydrateTimestamp`}),` throws an error, ensuring that only valid timestamps are processed.`]}),`\n`,_jsx(Heading,{level:`2`,id:`best-practices`,children:`Best Practices`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Use `,_jsx(_components.code,{children:`hydrateTimestamp`}),` when dealing with serialized Firestore timestamp data to maintain data consistency and integrity.`]}),`\n`,_jsx(_components.li,{children:`Always handle potential errors when converting serialized timestamps to avoid unexpected crashes or data issues.`}),`\n`,_jsxs(_components.li,{children:[`Be aware of the format of your serialized timestamps to ensure compatibility with `,_jsx(_components.code,{children:`hydrateTimestamp`}),`.`]}),`\n`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Proper error handling is crucial when using `,_jsx(_components.code,{children:`hydrateTimestamp`}),` to prevent\nissues with invalid or missing timestamp data.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"hydrateTimestamp","description":"The `hydrateTimestamp` utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.","icon":"code","href":"/cloud/timestamps/hydrateTimestamp"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Introduction","slug":"introduction","depth":2,"children":[{"title":"Key Features","slug":"key-features","depth":3,"children":[]},{"title":"Utilization","slug":"utilization","depth":3,"children":[]},{"title":"Converting Serialized Timestamps","slug":"converting-serialized-timestamps","depth":4,"children":[]}]},{"title":"Handling Invalid Timestamps","slug":"handling-invalid-timestamps","depth":2,"children":[]},{"title":"Best Practices","slug":"best-practices","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"humancollective","siteName":"Firebridge","title":"hydrateTimestamp - Firebridge","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-01-07T00:45:36.605Z","originalFileLocation":"cloud/timestamps/hydrateTimestamp.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Firebridge\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"hydrateTimestamp - Firebridge\">\u003cmeta data-mint-head property=\"og:description\" content=\"The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Firebridge\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://humancollective.mintlify.app/_mintlify/api/og/v2?division=Timestamps\u0026amp;title=hydrateTimestamp\u0026amp;description=The+%60hydrateTimestamp%60+utility+is+essential+for+converting+serialized+Firestore+timestamps+back+into+Firestore+Timestamp+objects.+This+function+ensures+that+tim\u0026amp;theme=494a5b55d5af8e2e45aa7d13\u0026amp;signature=2ca0d5e4a0febe2728edafcc0c271cd1ac4283d976d69d8c4918ec64f3f13e02\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"hydrateTimestamp - Firebridge\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://humancollective.mintlify.app/_mintlify/api/og/v2?division=Timestamps\u0026amp;title=hydrateTimestamp\u0026amp;description=The+%60hydrateTimestamp%60+utility+is+essential+for+converting+serialized+Firestore+timestamps+back+into+Firestore+Timestamp+objects.+This+function+ensures+that+tim\u0026amp;theme=494a5b55d5af8e2e45aa7d13\u0026amp;signature=2ca0d5e4a0febe2728edafcc0c271cd1ac4283d976d69d8c4918ec64f3f13e02\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/humancollective/6f5gtnvP6iWrC6WE/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Firebridge\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#36656B\">\u003clink data-mint-head rel=\"canonical\" href=\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/cloud/timestamps/hydrateTimestamp.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://firebridge.dev/#organization\",\"name\":\"Firebridge\",\"url\":\"https://firebridge.dev\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/humancollective/oNaxoG7QbCmsD9Gt/logo/light.svg?fit=max\u0026auto=format\u0026n=oNaxoG7QbCmsD9Gt\u0026q=85\u0026s=19a786e3b49034489f469d223f640a91\"}},{\"@type\":\"WebSite\",\"@id\":\"https://firebridge.dev#website\",\"name\":\"Firebridge\",\"url\":\"https://firebridge.dev\",\"publisher\":{\"@id\":\"https://firebridge.dev/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp#webpage\",\"url\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp\",\"name\":\"hydrateTimestamp\",\"description\":\"The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\",\"dateModified\":\"2026-01-07T00:45:36.605Z\",\"isPartOf\":{\"@id\":\"https://firebridge.dev#website\"},\"breadcrumb\":{\"@id\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Cloud\",\"item\":\"https://firebridge.dev/cloud/cloud-installation\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Timestamps\",\"item\":\"https://firebridge.dev/cloud/timestamps/maxTimestamp\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"hydrateTimestamp\",\"item\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp#article\",\"headline\":\"hydrateTimestamp\",\"name\":\"hydrateTimestamp\",\"description\":\"The hydrateTimestamp utility is essential for converting serialized Firestore timestamps back into Firestore Timestamp objects. This function ensures that timestamps stored in serialized formats are correctly restored to their original Firestore Timestamp representation.\",\"url\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp\",\"mainEntityOfPage\":{\"@id\":\"https://firebridge.dev/cloud/timestamps/hydrateTimestamp#webpage\"},\"dateModified\":\"2026-01-07T00:45:36.605Z\",\"publisher\":{\"@id\":\"https://firebridge.dev/#organization\"},\"isPartOf\":{\"@id\":\"https://firebridge.dev#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Firebridge\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Firebridge","nav":{"global":null,"groups":[{"group":"Introduction","pages":[{"title":"Why Firebridge?","href":"/introduction"},{"title":"Get Started","href":"/get-started"}]},{"group":"React","pages":[{"title":"React Installation","icon":"react","href":"/react/react-installation"},{"group":"Hooks","pages":[{"title":"useDocument","icon":"code","href":"/react/hooks/useDocument"},{"title":"useCollection","icon":"code","href":"/react/hooks/useCollection"},{"title":"useCallable","icon":"code","href":"/react/hooks/useCallable"}]}]},{"group":"Cloud","pages":[{"title":"Cloud Installation","icon":"cloud","href":"/cloud/cloud-installation"},{"group":"Invokeables","pages":[{"title":"Callables","icon":"code","href":"/cloud/invokeables/callable"},{"title":"Requestables","icon":"code","href":"/cloud/invokeables/requestable"}]},{"group":"Execution","pages":[{"title":"Batch Execution","icon":"code","href":"/cloud/execution/batch"},{"title":"Parallel Execution","icon":"code","href":"/cloud/execution/parallel"}]},{"group":"Actions","pages":[{"title":"Actions Overview","href":"/cloud/actions/actions-overview"},{"title":"firestoreAdd","icon":"code","href":"/cloud/actions/firestoreAdd"},{"title":"firestoreDelete","icon":"code","href":"/cloud/actions/firestoreDelete"},{"title":"firestoreGet","icon":"code","href":"/cloud/actions/firestoreGet"},{"title":"firestoreSet","icon":"code","href":"/cloud/actions/firestoreSet"},{"title":"firestoreUpdate","icon":"code","href":"/cloud/actions/firestoreUpdate"},{"title":"firestoreMerge","icon":"code","href":"/cloud/actions/firestoreMerge"}]},{"group":"Snapshots","pages":[{"title":"Change Types","icon":"code","href":"/cloud/snapshots/getChangeType"},{"title":"readSnapshot","icon":"code","href":"/cloud/snapshots/readSnapshot"},{"title":"readQuerySnapshot","icon":"code","href":"/cloud/snapshots/readQuerySnapshot"}]},{"group":"Timestamps","pages":[{"title":"maxTimestamp","icon":"code","href":"/cloud/timestamps/maxTimestamp"},{"title":"hydrateAllTimestamps","description":"The `hydrateAllTimestamps` function is a powerful tool for converting all serialized Firestore timestamps within an object back into Firestore Timestamp objects. It is ideal for rehydrating timestamp data in complex objects, ensuring proper timestamp representation in Firestore.","icon":"code","href":"/cloud/timestamps/hydrateAllTimestamps"},{"title":"hydrateTimestamp","icon":"code","href":"/cloud/timestamps/hydrateTimestamp"},{"title":"minTimestamp","description":"The `minTimestamp` utility efficiently finds the earliest timestamp from an array of Firestore timestamps. It's essential for applications where tracking the initial occurrence of an event or the first update is crucial.","icon":"code","href":"/cloud/timestamps/minTimestamp"},{"title":"sortTimestamps","icon":"code","href":"/cloud/timestamps/sortTimestamps"},{"title":"timestampToDate","icon":"code","href":"/cloud/timestamps/timestampToDate"}]},{"group":"Metrics","pages":[{"title":"Metrics Overview","href":"/cloud/metrics/overview"},{"title":"incrementMetric","href":"/cloud/metrics/increment"},{"title":"updateMetric","href":"/cloud/metrics/update"},{"title":"Types Reference","href":"/cloud/metrics/types"},{"title":"Utilities","href":"/cloud/metrics/utilities"}]}]}]},"title":"hydrateTimestamp - Firebridge","buildId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","deploymentId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","dynamics":[],"chunks":[]}