---
schema_version: "1"
id: 1514cf892d044b7bd785c9624e8c12c396ce8bc577a458b73bad1b7f0c20af3c
title: ConnectApi.ContentCapability
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/apexref/apex_connectapi_output_content_capability.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_connectapi_output_content_capability.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: 685e52490656f43f0011715b50a9d8289aab9dd7dd2f18c4e9970553dfb8060d
description: If a comment has this capability, it has a file attachment.
---
# ConnectApi.ContentCapability

If a comment has this capability, it has a file attachment.

Subclass of [ConnectApi.FeedElementCapability](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_connectapi_output_feed_element_capability.htm "A feed element capability, which defines the characteristics of a feed element.").

For files attached to a feed post (instead of a comment) in version 36.0 and later, use [ConnectApi.FilesCapability](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_connectapi_output_multiple_content_capability.htm "If a feed element has this capability, it has one or more file attachments.").

If content is deleted from a feed element after it’s posted or if the access to the content is changed to private, the ConnectApi.ContentCapability exists, however most of its properties are null.

<table class="featureTable sort_table" summary="">




          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader vertical-align-top " id="d916119e65">Property Name</th>

              <th class="featureTableHeader vertical-align-top " id="d916119e68">Type</th>

              <th class="featureTableHeader vertical-align-top " id="d916119e71">Description</th>

              <th class="featureTableHeader vertical-align-top " id="d916119e74">Available Version</th>

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">checksum</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="checksum"><a name="checksum"><!-- --></a>MD5 checksum for the file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">contentUrl</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="contentUrl"><a name="contentUrl"><!-- --></a>URL of the content for links and Google
                  docs.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">description</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="description"><a name="description"><!-- --></a>Description of the attachment.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">downloadUrl</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="downloadUrl"><a name="downloadUrl"><!-- --></a>URL to the content.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">fileExtension</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="fileExtension"><a name="fileExtension"><!-- --></a>Extension of the file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">fileSize</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="fileSize"><a name="fileSize"><!-- --></a>Size of the file in bytes. If size cannot be
                  determined, returns <samp class="codeph apex_code">Unknown</samp>.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">fileType</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="fileType"><a name="fileType"><!-- --></a>Type of file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">hasPdfPreview</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">Boolean</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="hasPdfPreview"><a name="hasPdfPreview"><!-- --></a><samp class="codeph apex_code"><span class="keyword">true</span></samp> if the file has a PDF preview available,
                  <samp class="codeph apex_code"><span class="keyword">false</span></samp>
                  otherwise.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">id</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="id"><a name="id"><!-- --></a>18-character ID of the content.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">isInMyFileSync</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">Boolean</td>

              <td class="entry" headers="d916119e71" data-title="Description">
                <samp class="codeph nolang">true</samp> if the file is synced
                with Salesforce Files Sync; <samp class="codeph nolang">false</samp> otherwise.
              </td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">mimeType</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="mimeType"><a name="mimeType"><!-- --></a>MIME type of the file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">renditionUrl</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="renditionUrl"><a name="renditionUrl"><!-- --></a>URL to the rendition resource for the file.
                  Renditions are processed asynchronously and may not be available
                  immediately after the file has been uploaded.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">renditionUrl240By180</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="renditionUrl240By180"><a name="renditionUrl240By180"><!-- --></a>URL to the 240x180 size rendition
                  resource for the file. Renditions are processed asynchronously
                  and may not be available immediately after the file has been
                  uploaded.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">renditionUrl720By480</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="renditionUrl720By480"><a name="renditionUrl720By480"><!-- --></a>URL to the 720x480 size rendition
                  resource for the file. Renditions are processed asynchronously
                  and may not be available immediately after the file has been
                  uploaded.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">sharingOption</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type"><a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/connectAPI_enums.htm#FileSharingOption_enum"><samp class="codeph apex_code">ConnectApi.​FileSharingOption</samp></a></td>

              <td class="entry" headers="d916119e71" data-title="Description">Sharing option of the file. Values are:<ul class="ul bulletList">
                  <li class="li">
                    <samp class="codeph apex_code">Allowed</samp>—Resharing of the file is allowed.
                  </li>
                  <li class="li">
                    <samp class="codeph apex_code">Restricted</samp>—Resharing of the file is restricted.
                  </li>
                </ul>
              </td>

              <td class="entry" headers="d916119e74" data-title="Available Version">35.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">textPreview</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="textPreview"><a name="textPreview"><!-- --></a>Text preview of the file if available,
                  <samp class="codeph apex_code"><span class="keyword">null</span></samp> otherwise. The
                  maximum number of characters is 200.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">thumb120By90​RenditionStatus</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="thumb120By90RenditionStatus"><a name="thumb120By90RenditionStatus"><!-- --></a>The status of the rendering
                  of the 120x90 pixel sized preview image of the file. Should be
                  either Processing, Failed, Success, or Na if
                  unavailable.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">thumb240By180​RenditionStatus</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="thumb240By180RenditionStatus"><a name="thumb240By180RenditionStatus"><!-- --></a>The status of the rendering
                  of the 240x180 pixel sized preview image of the file. Should be
                  either Processing, Failed, Success, or Na if
                  unavailable.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">thumb720By480​RenditionStatus</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="thumb720By480RenditionStatus"><a name="thumb720By480RenditionStatus"><!-- --></a>The status of the rendering
                  of the 720x480 pixel sized preview image of the file. Should be
                  either Processing, Failed, Success, or Na if
                  unavailable.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">title</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="title"><a name="title"><!-- --></a>Title of the file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

            <tr>
              <td class="entry" headers="d916119e65" data-title="Property Name"><samp class="codeph apex_code">versionId</samp></td>

              <td class="entry" headers="d916119e68" data-title="Type">String</td>

              <td class="entry" headers="d916119e71" data-title="Description"><span class="ph" id="versionId"><a name="versionId"><!-- --></a>Version ID of the file.</span></td>

              <td class="entry" headers="d916119e74" data-title="Available Version">32.0</td>

            </tr>

          </tbody>

        </table>

#### See Also

- [ConnectApi.CommentCapabilities](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_connectapi_output_comment_capabilities.htm "A set of capabilities on a comment.")