not able to find Case comment relatedlist in the prompt builder.
#Trailhead Challenges
1 answer
Hi @Dhirendra verma You can use Case Comments in Prompt Builder, but if the CaseComments related list is missing, please check a few things.
Try these steps:
- Go to Setup → Object Manager → Case → Page Layouts.
- Open the Case page layout and check whether the Case Comments related list is added.
- In Prompt Builder, confirm that your prompt template uses Case as its input object.
- Click Insert Resource → Case and look for CaseComments under related lists.
- Also verify that your user has Read access to the Case Comment records.
Salesforce's Trailhead example uses this related list:
{!$RelatedList:Case.CaseComments.Records}
If it's still not showing:
You can use a Template-Triggered Prompt Flow as an alternative.
- Use Get Records on the Case Comment object.
- Filter using Parent ID = current Case ID.
- Loop through the comments and collect their CommentBody values.
- Use Add Prompt Instructions to pass the comments into the prompt template.
Useful Salesforce Documentation:
- Quick Start: Prompt Builder – Case Comments
- Build a Field Generation Prompt Template Using Flow
- Grounding with Related List Merge Fields
Related Trailblazer Discussion:
Check the Case page layout first. Prompt Builder only displays supported related lists available on the relevant page layout. If CaseComments still doesn't appear, the Flow approach is a good alternative.
Hope this helps!