Loading tutorials
@InvocableMethod annotation: what it does, the rules the compiler enforces, and the parts of the contract that affect an Agentforce agent. It assumes you can write basic Apex (classes, collections, SOQL) and know what sharing and field-level security mean. It also assumes y6 min read@InvocableMethod annotation. This chapter covers the objects that go into and come out o5 min read@InvocableMethod with request and response wrapper classes, as covered in the previous chapters. It also assumes you know what an a7 min read@InvocableMethod and on @InvocableVariable request and response types. Here you will learn why an invocable method takes a list, what the platform expects you to return,6 min read@InvocableMethod with request and response types. It covers how to make an Agentforce action see only the data the run5 min read@InvocableMethod with request and response wrapper classes, and that your method already handles a list of requests in one pass. You should also be comfortable with Database.update and its allOrNone flag. Here you will decide what your action returns wh5 min read@InvocableMethod with request and response wrapper classes, and that you know the bulk pattern from the earlier chapters: one pass over the list of requests, with no SOQL or DML inside the loop. Here you add the part that leaves Salesforce: a call to a6 min read@IsTest, Test.startTest(), Assert methods), that you have read the earlier chapters on @InvocableMethod, bulkification, and security, and that you have the GetOpenCasesAction class from 5 min read@InvocableMethod, request and response wrapper types, and descriptions on every @InvocableVariable. The examples use the GetOpenCasesAction class from those chapters. You also need an org6 min read@InvocableMethod with request and response classes, bulkify it, run it in user mode, and register it in Agent Builder. The earlier chapters covered those mechanics. This chapter covers the design decisions that make an action easy for an agent to use c8 min read