Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce REST API Endpoints for Agents #7350

Merged
merged 4 commits into from
Sep 18, 2023
Merged

Introduce REST API Endpoints for Agents #7350

merged 4 commits into from
Sep 18, 2023

Conversation

tmichaeldb
Copy link
Contributor

Description

See Agent design doc for more context.

To support agents on the backend, we need to be able to perform CRUD operations on them from the frontend. This PR introduces the following endpoints:

  • GET /projects/<project_name>/agents (Gets all agents in a project created by the user)
  • GET /projects/<project_name>/agents/<agent_name> (Gets an agent in a project by name)
  • PUT /projects/<project_name>/agents/<agent_name> (Updates an agent in a project, creating it if it doesn’t already exist)
  • POST /projects/<project_name>/agents (Creates a new agent in a project)
  • DELETE /projects/<project_name>/agents/<agent_name> (Deletes an agent in a project by name)

Closes #7221

Type of change

  • ⚡ New feature (non-breaking change which adds functionality)
  • 📄 This change requires a documentation update

Verification Process

To ensure the changes are working as expected:

  • Test Location: tests/api/http/agents_test.py
  • Verification Steps: python -m pytest .\tests\api\http\agents_test.py

Checklist:

  • My code follows the style guidelines(PEP 8) of MindsDB.
  • I have appropriately commented on my code, especially in complex areas.
  • Necessary documentation updates are either made or tracked in issues.
  • Relevant unit and integration tests are updated or added.

@tmichaeldb tmichaeldb self-assigned this Sep 15, 2023
@tmichaeldb tmichaeldb added the enhancement New feature or request label Sep 15, 2023
@tmichaeldb tmichaeldb changed the title Agents api Introduce REST API Endpoints for Agents Sep 15, 2023
Copy link
Contributor

@yuhuishi-convect yuhuishi-convect left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🆗

@tmichaeldb tmichaeldb merged commit f96ab98 into staging Sep 18, 2023
12 checks passed
@dylanketterer dylanketterer mentioned this pull request Sep 22, 2023
@tmichaeldb tmichaeldb linked an issue Oct 18, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add REST API Endpoints for Agents
2 participants