> For the complete documentation index, see [llms.txt](https://docs.advantys.com/workflowgen-guide-administration/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.advantys.com/workflowgen-guide-administration/applications-de-workflow/openai/openaiaddmessage.md). Agents can also search and read this documentation through its [MCP server](https://docs.advantys.com/workflowgen-guide-administration/~gitbook/mcp).

# OPENAIADDMESSAGE

## Aperçu

L'application de workflow **OPENAIADDMESSAGE** vous permet de mettre à jour l'historique des messages d'une conversation pour y ajouter des interactions utilisateurs ou d'outils. Il est aussi possible de mettre à jour l'historique directement depuis un sous-processus.

## Paramètres requis

<table data-full-width="true"><thead><tr><th width="202" valign="top">Paramètre</th><th width="76" valign="top">Type</th><th width="125" valign="top">Direction</th><th valign="top">Description</th></tr></thead><tbody><tr><td valign="top"><code>CONTENT</code></td><td valign="top">TEXT</td><td valign="top">IN</td><td valign="top">L'historique des messages au format JSON. La structure de référence est celle de la documentation d'OpenAI pour l'objet <code>messages</code> <a href="https://platform.openai.com/docs/api-reference/chat/create#chat-create-messages">https://platform.openai.com/docs/api-reference/chat/create#chat-create-messages</a></td></tr><tr><td valign="top"><code>ROLE</code></td><td valign="top">TEXT</td><td valign="top">IN</td><td valign="top">Le rôle à associer au message; les valeurs possibles sont <code>user</code>, <code>system</code>, <code>assistant</code>, <code>tool</code> ou <code>developer</code></td></tr></tbody></table>

## Paramètres facultatifs

<table data-full-width="true"><thead><tr><th width="302" valign="top">Paramètre</th><th width="118" valign="top">Type</th><th width="125" valign="top">Direction</th><th valign="top">Description</th></tr></thead><tbody><tr><td valign="top"><code>MESSAGE_HISTORY</code></td><td valign="top">TEXT</td><td valign="top">INOUT</td><td valign="top">L'historique des messages à mettre à jour</td></tr><tr><td valign="top"><code>TOOL_CALL_ID</code></td><td valign="top">TEXT</td><td valign="top">IN</td><td valign="top">Dans le cas où le <code>ROLE</code> est <code>tool</code>, il s'agit de l'identifiant de l'outil</td></tr><tr><td valign="top"><code>ASSISTANT_TOOL_CALL</code></td><td valign="top">TEXT</td><td valign="top">IN</td><td valign="top">Dans le cas où le <code>ROLE</code> est <code>assistant</code> et que vous souhaitez ajouter une liste d'outil à appeler, il s'agit de la liste des outils</td></tr><tr><td valign="top"><code>REQUEST_ID</code></td><td valign="top">NUMERIC</td><td valign="top">IN</td><td valign="top">Dans le cas où l'historique est mis à jour depuis un autre processus, il s'agit du numéro de la demande à mettre à jour</td></tr><tr><td valign="top"><code>REQUEST_DATA_NAME</code></td><td valign="top">TEXT</td><td valign="top">IN</td><td valign="top">Dans le cas où l'historique est mis à jour depuis un autre processus, il s'agit du nom de la donnée à mettre à jour</td></tr></tbody></table>
