0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Agentforce Actions エラーの考察(Idが正しくない?)

Last updated at Posted at 2025-02-12

UNKNOWN_EXCEPTION
. Cannot invoke "common.udd.EntityInfo.getPrimaryKeyField()" because the return value of "common.api.soap.Entity.getEntityInfo()" is null.

image.png

私も今日同じエラーが発生しました。
私のシナリオでは、コンテキスト変数内の MessagingSession レコードをフローまたはプロンプトに渡す必要があります。

アクション入力の定義は
MessageSession: コンテキスト変数では常に MessagingSession レコードを使用します。
このAgentforceユーザーにオブジェクトアクセスを許可します

image.png

エージェント ビルダーでテストすると、あなたと同じエラーが発生しました。
image.png

{
    "actionName": "Customer_Sentiment_Analysis",
    "actionId": "172H1000000CaV9",
    "plannerId": "",
    "isSuccess": false,
    "duration": 1431,
    "rawInput": "{\"Input:Questions\":\"no\",\"Input:MessagingSession\":{\"data\":{\"Id\":\"12345\"},\"id\":\"12345\",\"title\":\"Session Title\",\"sObjectInfo\":{\"apiName\":\"MessagingSession\"}}}",
    "rawOutput": "null",
    "outputErrors": [
        {
            "statusCode": "INVALID_RUNTIME_VALUE",
            "message": "incorrect input param: Incorrect input parameter id: 12345"
        }
    ]
}

エラー メッセージに記載されているように、根本的な原因は入力パラメータの形式が正しくないことです。Agentforce は、ダミー値「12345」を MessageSession Id として渡します。

これは、エージェント ビルダーでは実際のセッションが作成されないためです。API 経由でのみテストされます。

そこで、このエージェントをアクティブ化し、ポータルでテストしました。
すると、物事が適切に動作するようになります。

Thank you for your message. 

I will analyze the customer's conversation associated with MessagingSession ID: 0MwH1000000067DKAQ. 

Please allow me a moment to review the details.

したがって、私のシナリオの根本的な原因は、単にエージェント ビルダーにレコードが作成されていないことです。入力レコードが無効です。

エージェントをアクティブ化し、適切なチャネルでテストしたところ、正常に動作しました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?