EventUuid 項目を含むイベントの作成
EventUuid 項目は、イベントメッ���ージを一意に識別するためのものです。コールバック結果で返されたイベントと公開コールのイベントを照合するために使用されます。各イベントオブジェクトで EventUuid 項目値が生成されるようにするには、SObjectType.newSObject(recordTypeId, loadDefaults) Apex メソッドを使用してイベントオブジェクトを作成します。
1Order_Event__e event = (Order_Event__e)Order_Event__e.sObjectType.newSObject(null, true);
2
3// The EventUuid value is returned after object creation
4System.debug('EventUuid: ' + event.EventUuid);
5
6// Debug output
7// EventUuid: 19bd382e-8964-43de-ac01-d5d82dd0bf78