Skip to main content
triggerChatGPTWorkspaceAgent queues a published ChatGPT Workspace Agent through its API channel.
automations/trigger-chatgpt-agent.automation.ts
apiTriggerId is the stable agtch_ identifier shown for the agent’s published API channel. input is the message sent to the agent. Optional conversationKey continues the same agent conversation across related events. Optional idempotencyKey prevents a retry of the same event from adding a second trigger. Optional second argument { account } defaults to the project binding. The action returns the apirun_ run ID and ChatGPT conversation URL after ChatGPT accepts the run. Use getChatGPTWorkspaceAgentRun to poll its status. ChatGPT does not currently expose the agent’s response through this API. Connect ChatGPT with a Workspace Agent access token created in ChatGPT workspace settings > Access tokens with the Workspace Agents scope. A workspace administrator must first enable Workspace agents and personal access tokens.