---
schema_version: "1"
id: 64718190b39aff0df47db474919ec8b48aff103dbfb6653472c0bd74599bb86b
title: ContentAsset
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/object_reference/sforce_api_objects_contentasset.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/sforce_api_objects_contentasset.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: ad39621cde76a074621ff099a93a7294cda19468ba2c07c4d17ebf77c1020d06
description: Represents a Salesforce file that has been converted to an asset file in a custom app in Lightning Experience. Use asset files for org setup and configuration. Asset files can be packaged and referenced by other components. This object is available in API version 38.0 and later.
---
# ContentAsset

Represents a Salesforce file that has been converted to an asset file in a custom app in Lightning Experience. Use asset files for org setup and configuration. Asset files can be packaged and referenced by other components. This object is available in API version 38.0 and later.

![Important](https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/images/icon_note_important.png)

#### Important

Where possible, we changed noninclusive terms to align with our company value of Equality. Because changing terms in our code can break current implementations, we maintained this object’s name.

## Supported Calls

create(), delete(), describeSObjects(), query(), retrieve(), update(), upsert()

## Special Access Rules

- Only admin users can edit or delete ContentAssets.
- Users with file access can create and query ContentAssets.
- It isn’t necessary to create asset files for regular, collaborative use of Salesforce Files. “Assetize” files only when they’re used in setup and configuration situations.
- Neither the file (ContentDocument) nor the asset settings record (ContentAssets) can be deleted if the asset file is referenced by another component.
- ContentAsset doesn’t support search or most recently used (MRU) lists.
- ContentAsset doesn’t support Apex triggers.

## Fields

| Field | Details |
| --- | --- |
| ContentDocumentId | 
Type

reference

Properties

Filter, Group, Nillable, Sort

Description

ID of the document.

This is a relationship field.

Relationship Name

ContentDocument

Relationship Type

Lookup

Refers To

ContentDocument



 |
| DeveloperName | 

Type

string

Properties

Create, Filter, Group, Sort, Update

Description

The unique name of the asset file in the API. ContentAsset.DeveloperName:

- must be 40 characters or fewer
- must begin with a letter
- can contain only underscores and alphanumeric characters
- can’t include spaces
- can’t end with an underscore
- can’t contain 2 consecutive underscores

In managed packages, this field prevents naming conflicts on package installations. With this field, a developer can change the object’s name in a managed package and the changes are reflected in a subscriber’s organization.



 |
| IsVisibleByExternalUsers | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

Indicates whether unauthenticated users can see the asset file.



 |
| Language | 

Type

picklist

Properties

Create, Defaulted on create, Filter, Group, Nillable, Restricted picklist, Sort, Update

Description

The language for this document. This field defaults to the user's language unless the org is multi-language enabled. Specifies the language of the labels returned. The value must be a valid user locale (language and country), such as de\_DE or en\_GB. For more information on locales, see the Language field on the CategoryNodeLocalization object.



 |
| MasterLabel | 

Type

string

Properties

Create, Filter, Group, Sort, Update

Description

The label for the asset file. This internal label doesn’t get translated.



 |
| NamespacePrefix | 

Type

string

Properties

Filter, Group, Nillable, Sort

Description

The namespace prefix associated with this object. Each Developer Edition organization that creates a managed package has a unique namespace prefix. Limit: 15 characters. You can refer to a component in a managed package by using the namespacePrefix\_\_componentName notation.



 |