First, install the lyzr-agent-api
package:
For more detailed installation instructions, refer to the installation guide on PyPI.
To start using the API, initialize the AgentAPI
client with your Lyzr API key:
The environment is a fundamental building block of the Lyzr Agent API. It defines the modules, features, tools available, and other configurations for your agent.For more,click here.
This function updates the configuration of an existing environment by passing in the environment ID (env_id
) and a JSON body containing the new environment settings (json_body
).
This function retrieves a list of all available environments. It returns the details of each environment, allowing you to view their configurations and statuses.
Once the environment is set up, create an agent within that environment. The agent uses the environment ID to operate and can be customized with a system prompt and a description:
This function updates the configuration of an existing agent by providing the agent ID (agent_id
) and a JSON body containing the new settings (json_body
). It allows you to modify an agent’s behavior or properties dynamically.
This function retrieves a list of all available agents. It returns the details and configurations of each agent, allowing you to review and manage them.
This function deletes an agent by specifying its agent_id
.
After creating the agent, you can initiate a chat session with it. Provide the user ID, agent ID, and a message to start the conversation:
Get Task Status and Response
First, install the lyzr-agent-api
package:
For more detailed installation instructions, refer to the installation guide on PyPI.
To start using the API, initialize the AgentAPI
client with your Lyzr API key:
The environment is a fundamental building block of the Lyzr Agent API. It defines the modules, features, tools available, and other configurations for your agent.For more,click here.
This function updates the configuration of an existing environment by passing in the environment ID (env_id
) and a JSON body containing the new environment settings (json_body
).
This function retrieves a list of all available environments. It returns the details of each environment, allowing you to view their configurations and statuses.
Once the environment is set up, create an agent within that environment. The agent uses the environment ID to operate and can be customized with a system prompt and a description:
This function updates the configuration of an existing agent by providing the agent ID (agent_id
) and a JSON body containing the new settings (json_body
). It allows you to modify an agent’s behavior or properties dynamically.
This function retrieves a list of all available agents. It returns the details and configurations of each agent, allowing you to review and manage them.
This function deletes an agent by specifying its agent_id
.
After creating the agent, you can initiate a chat session with it. Provide the user ID, agent ID, and a message to start the conversation:
Get Task Status and Response