Fetches a single comment using its foreignId. Optionally returns the parent comment if it exists and withParent=true is passed. This is useful when using a custom identifier set by the client, instead of the internal comment ID.
Query Parameters
string
required
The external reference ID used to identify a comment
string
If true, includes the parent comment in the response
Response
object
Show Comment object
string
Unique comment identifier
string
External reference ID
string
Comment content
string
Creation timestamp
object
Parent comment object (null if no parent or withParent not set)
Error Responses
Missing or Invalid Foreign ID - 400 Bad Request
{ "error": "Missing valid reference ID in request query", "code": "comment/invalid-request"}
Not Found - 404 Not Found
{ "error": "Comment not found", "code": "comment/not-found"}
Server Error - 500 Internal Server Error
{ "error": "Internal server error.", "code": "comment/server-error", "details": "[error message]"}
Notes
Requires a valid foreignId to locate the comment.
Set withParent=true to include the parent comment.
Returns parentComment: null if there is no parent or it’s not requested.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Sublay Documentation","colors":{"primary":"#D22F55","light":"#F06789","dark":"#9E1E3E"},"logo":{"light":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-dark.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=b95cabb32c98884aa4bca294b07238cc","dark":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-light.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=871e10ec08b164c26f260e845b44c5c5"},"favicon":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/favicon.svg?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=4988ad1acfb2c3909d214fd1ea72e5d8","api":{"playground":{"display":"none"},"mdx":{"auth":{"method":"bearer"},"server":"https://api.sublay.io"}},"navbar":{"links":[{"href":"https://dash.sublay.io","label":"Dashboard"}]},"footer":{"socials":{"github":"https://github.com/sublay-io"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"replyke","hasAudioNarration":false,"actualSubdomain":"replyke","customDomains":["docs.sublay.io"],"gitSource":{"type":"github","owner":"sublay-io","repo":"monorepo","deployBranch":"v8","contentDirectory":"docs","isPrivate":false,"mountPath":"","label":""},"entitlements":{},"buildId":"6af74153a071dcdd90feee77","clientVersion":"0.0.4142","searchFilterCounts":[{"language":"default","tag":"API Reference","count":521},{"language":"default","tag":"Hooks Reference","count":486},{"language":"default","tag":"SDK Reference","count":145},{"language":"default","tag":"Components","count":92},{"language":"default","tag":"Modules","count":84},{"language":"default","tag":"Spaces","count":68},{"language":"default","tag":"Data Models","count":55},{"language":"default","tag":"Models","count":55},{"language":"default","tag":"Workspaces","count":50},{"language":"default","tag":"JS SDK","count":44}]},"assistantConfig":{"enableStarterQuestions":false},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"v6/api-reference/comments/fetch-comment-by-foreign-id","slug":"/v6/api-reference/comments/fetch-comment-by-foreign-id","pageMetadata":{"title":"Get Comment by Foreign ID","api":"GET /api/v6/:projectId/comments/by-foreign-id","description":"Fetch a comment using its external foreign ID","href":"/v6/api-reference/comments/fetch-comment-by-foreign-id"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Fetch a comment using its external foreign ID\"\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`,hr:`hr`,li:`li`,p:`p`,pre:`pre`,span:`span`,ul:`ul`,..._provideComponents(),...props.components},{Accordion,AccordionGroup,CodeBlock,Expandable,Heading,ParamField,ResponseField}=_components;if(!Accordion)_missingMdxReference(`Accordion`,true);if(!AccordionGroup)_missingMdxReference(`AccordionGroup`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Expandable)_missingMdxReference(`Expandable`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Fetches a single comment using its `,_jsx(_components.code,{children:`foreignId`}),`. Optionally returns the parent comment if it exists and `,_jsx(_components.code,{children:`withParent=true`}),` is passed. This is useful when using a custom identifier set by the client, instead of the internal comment ID.`]}),`\n`,_jsx(Heading,{level:`2`,id:`query-parameters`,children:`Query Parameters`}),`\n`,_jsx(ParamField,{query:`foreignId`,type:`string`,required:true,id:`param-foreign-id`,children:_jsx(_components.p,{children:`The external reference ID used to identify a comment`})}),`\n`,_jsx(ParamField,{query:`withParent`,type:`string`,id:`param-with-parent`,children:_jsxs(_components.p,{children:[`If `,_jsx(_components.code,{children:`true`}),`, includes the parent comment in the response`]})}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(ResponseField,{name:`comment`,type:`object`,id:`param-comment`,children:_jsxs(Expandable,{title:`Comment object`,children:[_jsx(ResponseField,{name:`id`,type:`string`,id:`param-id`,children:_jsx(_components.p,{children:`Unique comment identifier`})}),_jsx(ResponseField,{name:`foreignId`,type:`string`,id:`param-foreign-id-1`,children:_jsx(_components.p,{children:`External reference ID`})}),_jsx(ResponseField,{name:`content`,type:`string`,id:`param-content`,children:_jsx(_components.p,{children:`Comment content`})}),_jsx(ResponseField,{name:`createdAt`,type:`string`,id:`param-created-at`,children:_jsx(_components.p,{children:`Creation timestamp`})})]})}),`\n`,_jsx(ResponseField,{name:`parentComment`,type:`object`,id:`param-parent-comment`,children:_jsxs(_components.p,{children:[`Parent comment object (null if no parent or `,_jsx(_components.code,{children:`withParent`}),` not set)`]})}),`\n`,_jsx(Heading,{level:`2`,id:`error-responses`,children:`Error Responses`}),`\n`,_jsxs(AccordionGroup,{children:[_jsx(Accordion,{title:`Missing or Invalid Foreign ID - 400 Bad Request`,id:`missing-or-invalid-foreign-id-400-bad-request`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Missing valid reference ID in request query\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"code\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"comment/invalid-request\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),_jsx(Accordion,{title:`Not Found - 404 Not Found`,id:`not-found-404-not-found`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Comment not found\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"code\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"comment/not-found\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),_jsx(Accordion,{title:`Server Error - 500 Internal Server Error`,id:`server-error-500-internal-server-error`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Internal server error.\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"code\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"comment/server-error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"details\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"[error message]\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`notes`,children:`Notes`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Requires a valid `,_jsx(_components.code,{children:`foreignId`}),` to locate the comment.`]}),`\n`,_jsxs(_components.li,{children:[`Set `,_jsx(_components.code,{children:`withParent=true`}),` to include the parent comment.`]}),`\n`,_jsxs(_components.li,{children:[`Returns `,_jsx(_components.code,{children:`parentComment: null`}),` if there is no parent or it’s not requested.`]}),`\n`]})]})}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":"Get Comment by Foreign ID","api":"GET /api/v6/:projectId/comments/by-foreign-id","description":"Fetch a comment using its external foreign ID","href":"/v6/api-reference/comments/fetch-comment-by-foreign-id"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Query Parameters","slug":"query-parameters","depth":2,"children":[]},{"title":"Response","slug":"response","depth":2,"children":[]},{"title":"Error Responses","slug":"error-responses","depth":2,"children":[]},{"title":"Notes","slug":"notes","depth":2,"children":[]}],"codeExamples":{},"endpoint":{"title":"Get Comment by Foreign ID","path":"/api/v6/:projectId/comments/by-foreign-id","servers":[{"url":"https://api.sublay.io"}],"method":"get","request":{"security":[{"title":"Bearer Auth","parameters":{"header":{"Authorization":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token."}},"query":{},"cookie":{}}}],"parameters":{"query":{"foreignId":{"schema":[{"type":"string","description":"The external reference ID used to identify a comment","required":true}]},"withParent":{"schema":[{"type":"string","description":"If `true` , includes the parent comment in the response"}]}},"header":{},"cookie":{},"path":{}},"body":{}},"response":{"200":{"application/json":{"schemaArray":[{"type":"object","properties":{"comment":[{"type":"object","properties":{"id":[{"type":"string","description":"Unique comment identifier"}],"foreignId":[{"type":"string","description":"External reference ID"}],"content":[{"type":"string","description":"Comment content"}],"createdAt":[{"type":"string","description":"Creation timestamp"}]}}],"parentComment":[{"type":"object","properties":{},"description":"Parent comment object (null if no parent or `withParent` not set)"}]}}],"examples":{"example":{"value":{"comment":{"id":"\u003cstring>","foreignId":"\u003cstring>","content":"\u003cstring>","createdAt":"\u003cstring>"},"parentComment":{}}}}}}},"deprecated":false}},"jsLinks":[],"subdomain":"replyke","siteName":"Sublay Documentation","title":"Get Comment by Foreign ID - Sublay Documentation","navMaps":{"firstHrefInVersion":{"8.0.0":{"href":"/v8/api-reference/comments/fetch-comment-by-foreign-id","matchLevel":1},"7.0.0":{"href":"/v7/api-reference/comments/fetch-comment-by-foreign-id","matchLevel":1},"6.0.0":{"href":"/v6/api-reference/comments/fetch-comment-by-foreign-id","matchLevel":0}},"firstHrefInLanguage":{}},"lastModified":"2026-04-13T17:14:49.610Z","originalFileLocation":"v6/api-reference/comments/fetch-comment-by-foreign-id.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=\"Fetch a comment using its external foreign ID\">\u003cmeta data-mint-head name=\"application-name\" content=\"Sublay Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_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/replyke/a1LNRWO56FGzWHgw/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Get Comment by Foreign ID - Sublay Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Fetch a comment using its external foreign ID\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Sublay Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://replyke.mintlify.site/_mintlify/api/og/v2?division=Comment+Endpoints\u0026amp;title=Get+Comment+by+Foreign+ID\u0026amp;description=Fetch+a+comment+using+its+external+foreign+ID\u0026amp;theme=1f560c5aaf3e1f0507c7e36a\u0026amp;signature=d32c5f9fa84d1f9976f14ae80bfa9a38a583ea13a9becaae2c6ac3504cd3529d\">\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=\"Get Comment by Foreign ID - Sublay Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Fetch a comment using its external foreign ID\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://replyke.mintlify.site/_mintlify/api/og/v2?division=Comment+Endpoints\u0026amp;title=Get+Comment+by+Foreign+ID\u0026amp;description=Fetch+a+comment+using+its+external+foreign+ID\u0026amp;theme=1f560c5aaf3e1f0507c7e36a\u0026amp;signature=d32c5f9fa84d1f9976f14ae80bfa9a38a583ea13a9becaae2c6ac3504cd3529d\">\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/replyke/a1LNRWO56FGzWHgw/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Sublay Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#D22F55\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/v6/api-reference/comments/fetch-comment-by-foreign-id.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.sublay.io/#organization\",\"name\":\"Sublay Documentation\",\"url\":\"https://docs.sublay.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-dark.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=b95cabb32c98884aa4bca294b07238cc\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.sublay.io#website\",\"name\":\"Sublay Documentation\",\"url\":\"https://docs.sublay.io\",\"publisher\":{\"@id\":\"https://docs.sublay.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id#webpage\",\"url\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id\",\"name\":\"Get Comment by Foreign ID\",\"description\":\"Fetch a comment using its external foreign ID\",\"dateModified\":\"2026-04-13T17:14:49.610Z\",\"isPartOf\":{\"@id\":\"https://docs.sublay.io#website\"},\"breadcrumb\":{\"@id\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Comment Endpoints\",\"item\":\"https://docs.sublay.io/v6/api-reference/comments/create-comment\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Get Comment by Foreign ID\",\"item\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id#apireference\",\"headline\":\"Get Comment by Foreign ID\",\"name\":\"Get Comment by Foreign ID\",\"description\":\"Fetch a comment using its external foreign ID\",\"url\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id\",\"mainEntityOfPage\":{\"@id\":\"https://docs.sublay.io/v6/api-reference/comments/fetch-comment-by-foreign-id#webpage\"},\"dateModified\":\"2026-04-13T17:14:49.610Z\",\"publisher\":{\"@id\":\"https://docs.sublay.io/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.sublay.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Sublay Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Sublay Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/v6/api-reference/comments/fetch-comment-by-foreign-id.md","siteName":"Sublay Documentation","nav":{"global":null,"versions":[{"version":"8.0.0","tag":"Beta","pages":[{"title":"8.0.0","href":"/v8/api-reference/comments/fetch-comment-by-foreign-id"}]},{"version":"7.0.0","default":true,"pages":[{"title":"7.0.0","href":"/v7/api-reference/comments/fetch-comment-by-foreign-id"}]},{"version":"6.0.0","tabs":[{"tab":"Overview","pages":[{"title":"Overview","href":"/v6"}]},{"tab":"SDK Reference","pages":[{"title":"SDK Reference","href":"/v6/sdk/getting-started"}]},{"tab":"Components","pages":[{"title":"Components","href":"/v6/components/overview"}]},{"tab":"Hooks Reference","pages":[{"title":"Hooks Reference","href":"/v6/hooks/overview"}]},{"tab":"API Reference","groups":[{"group":"Getting Started","pages":[{"title":"Getting Started","href":"/v6/api-reference/getting-started"},{"title":"Authentication","href":"/v6/api-reference/authentication"}]},{"group":"Auth Endpoints","pages":[{"title":"Sign In","api":"POST /api/v6/:projectId/auth/sign-in","href":"/v6/api-reference/auth/sign-in"},{"title":"Sign Up","api":"POST /api/v6/:projectId/auth/sign-up","href":"/v6/api-reference/auth/sign-up"},{"title":"Sign Out","api":"POST /api/v6/:projectId/auth/sign-out","href":"/v6/api-reference/auth/sign-out"},{"title":"Request New Access Token","api":"POST /api/v6/:projectId/auth/request-new-access-token","href":"/v6/api-reference/auth/request-new-access-token"},{"title":"Verify External User","api":"POST /api/v6/:projectId/auth/verify-external-user","href":"/v6/api-reference/auth/verify-external-user"},{"title":"Change Password","api":"POST /api/v6/:projectId/auth/change-password","href":"/v6/api-reference/auth/change-password"}]},{"group":"User Endpoints","pages":[{"title":"Fetch User","api":"GET /api/v6/:projectId/users/:userId","href":"/v6/api-reference/users/fetch-user"},{"title":"Fetch User By Foreign Id","api":"GET /api/v6/:projectId/users/by-foreign-id","href":"/v6/api-reference/users/fetch-user-by-foreign-id"},{"title":"Fetch User Suggestions","api":"GET /api/v6/:projectId/users/suggestions","href":"/v6/api-reference/users/fetch-user-suggestions"},{"title":"Check Username Availability","api":"GET /api/v6/:projectId/users/check-username","href":"/v6/api-reference/users/check-username-availability"},{"title":"Update User","api":"PATCH /api/v6/:projectId/users/:userId","href":"/v6/api-reference/users/update-user"}]},{"group":"User Follow Operations","pages":[{"title":"User Follow Operations Overview","href":"/v6/api-reference/users/follows/overview"},{"title":"Create Follow","api":"POST /api/v6/:projectId/users/:userId/follow","href":"/v6/api-reference/users/follows/create-follow"},{"title":"Delete Follow","api":"DELETE /api/v6/:projectId/users/:userId/follow","href":"/v6/api-reference/users/follows/delete-follow"},{"title":"Fetch Follow Status","api":"GET /api/v6/:projectId/users/:userId/follow","href":"/v6/api-reference/users/follows/fetch-follow-status"},{"title":"Fetch Followers","api":"GET /api/v6/:projectId/users/:userId/followers","href":"/v6/api-reference/users/follows/fetch-followers"},{"title":"Fetch Followers Count","api":"GET /api/v6/:projectId/users/:userId/followers-count","href":"/v6/api-reference/users/follows/fetch-followers-count"},{"title":"Fetch Following","api":"GET /api/v6/:projectId/users/:userId/following","href":"/v6/api-reference/users/follows/fetch-following"},{"title":"Fetch Following Count","api":"GET /api/v6/:projectId/users/:userId/following-count","href":"/v6/api-reference/users/follows/fetch-following-count"}]},{"group":"Follow Endpoints","pages":[{"title":"Overview","href":"/v6/api-reference/follows/overview"},{"title":"Fetch Following","api":"GET /api/v6/:projectId/follows/following","href":"/v6/api-reference/follows/fetch-following"},{"title":"Fetch Followers","api":"GET /api/v6/:projectId/follows/followers","href":"/v6/api-reference/follows/fetch-followers"},{"title":"Fetch Following Count","api":"GET /api/v6/:projectId/follows/following-count","href":"/v6/api-reference/follows/fetch-following-count"},{"title":"Fetch Followers Count","api":"GET /api/v6/:projectId/follows/followers-count","href":"/v6/api-reference/follows/fetch-followers-count"},{"title":"Delete Follow","api":"DELETE /api/v6/:projectId/follows/:followId","href":"/v6/api-reference/follows/delete-follow"}]},{"group":"User Connection Operations","pages":[{"title":"User Connection Operations Overview","href":"/v6/api-reference/users/connections/overview"},{"title":"Request Connection","api":"POST /api/v6/:projectId/users/:userId/connection","href":"/v6/api-reference/users/connections/request-connection"},{"title":"Fetch Connection Status","api":"GET /api/v6/:projectId/users/:userId/connection","href":"/v6/api-reference/users/connections/fetch-connection-status"},{"title":"Fetch Connections By User Id","api":"GET /api/v6/:projectId/users/:userId/connections","href":"/v6/api-reference/users/connections/fetch-connections-by-user-id"},{"title":"Fetch Connections Count By User Id","api":"GET /api/v6/:projectId/users/:userId/connections-count","href":"/v6/api-reference/users/connections/fetch-connections-count-by-user-id"},{"title":"Remove Connection By User Id","api":"DELETE /api/v6/:projectId/users/:userId/connection","href":"/v6/api-reference/users/connections/remove-connection-by-user-id"}]},{"group":"Connection Endpoints","pages":[{"title":"Connection Operations Overview","href":"/v6/api-reference/connections/overview"},{"title":"Get Current User Connections","api":"GET /api/v6/:projectId/connections","href":"/v6/api-reference/connections/fetch-connections"},{"title":"Get Current User Connections Count","api":"GET /api/v6/:projectId/connections/count","href":"/v6/api-reference/connections/fetch-connections-count"},{"title":"Get Sent Pending Requests","api":"GET /api/v6/:projectId/connections/pending/sent","href":"/v6/api-reference/connections/fetch-sent-pending-connections"},{"title":"Get Received Pending Requests","api":"GET /api/v6/:projectId/connections/pending/received","href":"/v6/api-reference/connections/fetch-received-pending-connections"},{"title":"Accept Connection Request","api":"PATCH /api/v6/:projectId/connections/:connectionId/accept","href":"/v6/api-reference/connections/accept-connection"},{"title":"Decline Connection Request","api":"PATCH /api/v6/:projectId/connections/:connectionId/decline","href":"/v6/api-reference/connections/decline-connection"},{"title":"Remove Connection","api":"DELETE /api/v6/:projectId/connections/:connectionId","href":"/v6/api-reference/connections/remove-connection"}]},{"group":"Entity Endpoints","pages":[{"title":"Create Entity","api":"POST /api/v6/:projectId/entities","href":"/v6/api-reference/entities/create-entity"},{"title":"Get Single Entity","api":"GET /api/v6/:projectId/entities/:entityId","href":"/v6/api-reference/entities/fetch-entity"},{"title":"Get Entity by Foreign ID","api":"GET /api/v6/:projectId/entities/by-foreign-id","href":"/v6/api-reference/entities/fetch-entity-by-foreign-id"},{"title":"Get Entity by Short ID","api":"GET /api/v6/:projectId/entities/by-short-id","href":"/v6/api-reference/entities/fetch-entity-by-short-id"},{"title":"Fetch Entities","api":"GET /api/v6/:projectId/entities","href":"/v6/api-reference/entities/fetch-many-entities"},{"title":"Update Entity","api":"PATCH /api/v6/:projectId/entities/:entityId","href":"/v6/api-reference/entities/update-entity"},{"title":"Upvote Entity","api":"PATCH /api/v6/:projectId/entities/:entityId/upvote","href":"/v6/api-reference/entities/upvote-entity"},{"title":"Downvote Entity","api":"PATCH /api/v6/:projectId/entities/:entityId/downvote","href":"/v6/api-reference/entities/downvote-entity"},{"title":"Remove Upvote from Entity","api":"PATCH /api/v6/:projectId/entities/:entityId/remove-upvote","href":"/v6/api-reference/entities/remove-entity-upvote"},{"title":"Remove Downvote from Entity","api":"PATCH /api/v6/:projectId/entities/:entityId/remove-downvote","href":"/v6/api-reference/entities/remove-entity-downvote"},{"title":"Increment Entity Views","api":"PATCH /api/v6/:projectId/entities/:entityId/increment-views","href":"/v6/api-reference/entities/increment-entity-views"},{"title":"Delete Entity","api":"DELETE /api/v6/:projectId/entities/:entityId","href":"/v6/api-reference/entities/delete-entity"}]},{"group":"Comment Endpoints","pages":[{"title":"Create Comment","api":"POST /api/v6/:projectId/comments","href":"/v6/api-reference/comments/create-comment"},{"title":"Get Comment","api":"GET /api/v6/:projectId/comments/:commentId","description":"Fetch a single comment by its ID","href":"/v6/api-reference/comments/fetch-comment"},{"title":"Get Comment by Foreign ID","api":"GET /api/v6/:projectId/comments/by-foreign-id","href":"/v6/api-reference/comments/fetch-comment-by-foreign-id"},{"title":"Get Comments","api":"GET /api/v6/:projectId/comments","description":"Fetch a paginated list of comments with filtering and sorting options","href":"/v6/api-reference/comments/fetch-many-comments"},{"title":"Update Comment","api":"PATCH /api/v6/:projectId/comments/:commentId","href":"/v6/api-reference/comments/update-comment"},{"title":"Upvote Comment","api":"PATCH /api/v6/:projectId/comments/:commentId/upvote","href":"/v6/api-reference/comments/upvote-comment"},{"title":"Downvote Comment","api":"PATCH /api/v6/:projectId/comments/:commentId/downvote","href":"/v6/api-reference/comments/downvote-comment"},{"title":"Remove Upvote from Comment","api":"PATCH /api/v6/:projectId/comments/:commentId/remove-upvote","href":"/v6/api-reference/comments/remove-comment-upvote"},{"title":"Remove Downvote from Comment","api":"PATCH /api/v6/:projectId/comments/:commentId/remove-downvote","href":"/v6/api-reference/comments/remove-comment-downvote"},{"title":"Delete Comment","api":"DELETE /api/v6/:projectId/comments/:commentId","href":"/v6/api-reference/comments/delete-comment"}]},{"group":"List Endpoints","pages":[{"title":"Create Sub-List","api":"POST /api/v6/:projectId/lists/:listId/sub-lists","href":"/v6/api-reference/lists/create-new-list"},{"title":"Get Root List","api":"GET /api/v6/:projectId/lists/root","href":"/v6/api-reference/lists/fetch-root-list"},{"title":"Get Sub-Lists","api":"GET /api/v6/:projectId/lists/:listId/sub-lists","href":"/v6/api-reference/lists/fetch-sub-lists"},{"title":"Check if Entity is Saved","api":"GET /api/v6/:projectId/lists/is-entity-saved","href":"/v6/api-reference/lists/is-entity-saved"},{"title":"Update List","api":"PATCH /api/v6/:projectId/lists/:listId","href":"/v6/api-reference/lists/update-list"},{"title":"Add Entity to List","api":"PATCH /api/v6/:projectId/lists/:listId/add-entity","href":"/v6/api-reference/lists/add-entity-to-list"},{"title":"Remove Entity from List","api":"PATCH /api/v6/:projectId/lists/:listId/remove-entity","href":"/v6/api-reference/lists/remove-entity-from-list"},{"title":"Delete List","api":"DELETE /api/v6/:projectId/lists/:listId","href":"/v6/api-reference/lists/delete-list"}]},{"group":"App Notification Endpoints","pages":[{"title":"Get App Notifications","api":"GET /api/v6/:projectId/app-notifications","href":"/v6/api-reference/app-notifications/fetch-notifications"},{"title":"Count Unread Notifications","api":"GET /api/v6/:projectId/app-notifications/count","href":"/v6/api-reference/app-notifications/count-unread-notification"},{"title":"Mark Notification as Read","api":"PATCH /api/v6/:projectId/app-notifications/:notificationId/mark-as-read","href":"/v6/api-reference/app-notifications/mark-notification-as-read"}]},{"group":"Storage Endpoints","pages":[{"title":"Upload File","api":"POST /api/v6/:projectId/storage","href":"/v6/api-reference/storage/upload-file"}]},{"group":"Moderation Endpoints","pages":[{"title":"Submit a Report","api":"POST /api/v6/:projectId/reports","href":"/v6/api-reference/moderation/create-report"}]},{"group":"Crypto Endpoints","pages":[{"title":"Sign Testing JWT","api":"POST /api/v6/:projectId/crypto/sign-testing-jwt","href":"/v6/api-reference/crypto/sign-testing-jwt"}]}]},{"tab":"Data Models","pages":[{"title":"Data Models","href":"/v6/data-models/user"}]}],"global":{"anchors":[{"anchor":"Dashboard","icon":"gauge","href":"https://dash.sublay.io"}]}}]},"basePath":"","title":"Get Comment by Foreign ID - Sublay Documentation","buildId":"dpl_G2Qd45vZZ7MkBiGF9yYx8ZsbbKXX","deploymentId":"dpl_G2Qd45vZZ7MkBiGF9yYx8ZsbbKXX","dynamics":["c2aa737661","2b790eda92","b0f84f53ff"],"chunks":["OpenApiReferenceProvider-NXj-Rqjv.js","utils-m0thOP-_.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-D13EKcfm.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema--XTdfsEb.js","snippetPresets-D3s4lmAH.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-ChURybxL.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-DL8CiXq2.js","shallow-DI2-YB2E.js","getApiPlaygroundDisplay-DxbW7b_y.js","CodeSnippet-CiNYS0pP.js","CodeSnippets-BT87bThu.js","Page-DSpdRuhM.js","getPastedJson-F_g_IrFQ.js","icon-CCIG5BAs.js","MethodPill-DY3E0jwx.js","DuplicateIcon-BN88xnEg.js","createIcon-VCCc5HO5.js","DynamicMarkdown-CaSwclgK.js","SectionHeading-DXV8nWhc.js","axios-vUo_bRtp.js"]}