function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Eric BowdenEric Bowden 

How to retrieve the list of record types

Is there a Chatter API call I can use to retrieve the list of record types which may serve as the parent Record Summary for a feed item post?

 

The documentation states that the Type attribute for a Record Summary is the Type of record, such as CustomObject, ContentDocument

, and so on.

 

Some examples for Record Summary types that I've seen have been Account and Report.  I believe there are around 18 record types.

 

I'm looking to display a different icon in my application for each record type, so I'll need to know ahead of time the list of possible record types.

 

An even better option would be a Chatter API call I could execute which would give me the 16x16 icon associated with each type of record.

Best Answer chosen by Admin (Salesforce Developers) 
Jia HuJia Hu
Do you mean the Object type where the Feed can be posted?

If this is right, use your Eclipse,
open the salesforce.schema
open FeedItem
open Fields
open ParentId -> Type Data -> Reference To

Then you will see the Object list.

All Answers

Eric BowdenEric Bowden

Having a hard coded list of record types would also be acceptable.

Jia HuJia Hu
Do you mean the Object type where the Feed can be posted?

If this is right, use your Eclipse,
open the salesforce.schema
open FeedItem
open Fields
open ParentId -> Type Data -> Reference To

Then you will see the Object list.
This was selected as the best answer
Eric BowdenEric Bowden

That did it, thanks!!

 

I hadn't used the Force.com IDE for eclipse before.  For those not familar, you can download a one step installer here - http://wiki.developerforce.com/page/Force.com_IDE_Installation.  Once the installer finished, I created a new Force.com project (file-new) and then opened the schema, following Jia Hu's instructions.