Skip to main content

Version

Every time you publish an agent in Logic, a new version of that agent is created. This allows you to keep track of changes and improvements made to the agent over time. Each version has a unique version ID that can be used to reference it.
Learn more about agent versions in the Agent Versions section.
When you make an agent execution, you can specify the version of the agent you want to call. This is useful when you need to call a specific version of an agent after it has been updated. To specify the version of an agent, you can add the version parameter to the URL of the execution request. The parameter should be set to the version ID you want to use.

How to Find the Version ID of an Agent

agent-versions You can find the version ID of an agent in the Logic API dashboard. Each agent has a list of versions, and you can select the version you want to use. You can also use the Logic API to list all versions of an agent using the GET /agents/{id}/versions endpoint. This will return a list of all versions of the agent, along with their version IDs.

Example with version

Below are examples in several languages showing how to specify the version when calling an agent execution.
curl -X POST 'https://api.logic.inc/v1/agents/{agent_id}/executions?version={version_id}'
    -H "Authorization: Bearer $LOGIC_API_TOKEN"
    -H "Content-Type: application/json"
    -d '{
        /* your input JSON here */
    }'