Skip to content

Conversation

SSharma-10
Copy link
Contributor

Implemented the Agent Operations listed in the API spec in doctl:

List Agents
Create an Agent
Retrieve an Existing Agent
Update an Agent
Delete an Agent
Update Agent Status

@danaelhe
Copy link
Member

danaelhe commented May 29, 2025

Looks like tests are failing 🤔

=== NAME  TestRun/doctl/genai/agent/update-visibility/valid_agent_ID_and_visibility_are_provided/updates_agent_visibility_to_public
    genai_agent_updateVisibility_test.go:61: received unknown request: PUT /v2/gen-ai/agents/00000000-0000-4000-8000-000000000000/deployment_visibility HTTP/1.1
        Host: 127.0.0.1:36625
        Accept: application/json
        Accept-Encoding: gzip
        Authorization: ***
        Content-Length: 35
        Content-Type: application/json
        User-Agent: doctl/0.0.0-dev (linux amd64) godo/1.149.0
        
        {"visibility":"VISIBILITY_PUBLIC"}
=== NAME  TestRun/doctl/genai/agent/list/required_flags_are_passed/lists_all_agents
    genai_agent_list_test.go:47: received unknown request: GET /v2/gen-ai/agents?page=1&per_page=200 HTTP/1.1
        Host: 127.0.0.1:34215
        Accept: application/json
        Accept-Encoding: gzip
        Authorization: ***
        User-Agent: doctl/0.0.0-dev (linux amd64) godo/1.149.0

@danaelhe
Copy link
Member

Also, running the integration tests locally (make test_integration) appear to have a mismatch in the display:

                                Diff:
                                --- Expected
                                +++ Actual
                                @@ -1,2 +1,2 @@
                                -ID                                     Name      Region    Project ID                             Model ID                               Created At                   User ID
                                -00000000-0000-4000-8000-000000000000   Agent1    tor1      00000000-0000-4000-8000-000000000000   00000000-0000-4000-8000-000000000000   2023-01-01T00:00:00Z         user1
                                +Id                                      Name      Region    ProjectID                               ModelID                                 CreatedAt                        UserId
                                +00000000-0000-4000-8000-000000000000    Agent1    tor1      00000000-0000-4000-8000-000000000000    00000000-0000-4000-8000-000000000000    2023-01-01 00:00:00 +0000 UTC    user1
                Test:           TestRun/doctl/genai/agent/list/required_flags_are_passed/lists_all_agents

@SSharma-10 SSharma-10 marked this pull request as draft May 30, 2025 08:42
@SSharma-10 SSharma-10 marked this pull request as ready for review June 6, 2025 06:16
@danaelhe
Copy link
Member

danaelhe commented Jun 12, 2025

Running:

delhertani@VG0X2599VX doctl % go run cmd/doctl/main.go --help
doctl is a command line interface (CLI) for the DigitalOcean API.

Usage:
  doctl [command]

Manage DigitalOcean Resources:
  1-click         Display commands that pertain to 1-click applications
  account         Display commands that retrieve account details
  apps            Displays commands for working with apps
  compute         Display commands that manage infrastructure
  databases       Display commands that manage databases
  kubernetes      Displays commands to manage Kubernetes clusters and configurations
  monitoring      Display commands to manage monitoring
  network         Display commands that manage network products
  projects        Manage projects and assign resources to them
  registry        Display commands for working with container registries
  serverless      Develop, test, and deploy serverless functions
  spaces          Display commands that manage DigitalOcean Spaces.
  vpcs            Display commands that manage VPCs

Configure doctl:
  auth            Display commands for authenticating doctl with an account
  version         Show the current version

View Billing:
  balance         Display commands for retrieving your account balance
  billing-history Display commands for retrieving your billing history
  invoice         Display commands for retrieving invoices for your account

Additional Commands:
  completion      Generate the autocompletion script for the specified shell
  genai           Manage GenAI resources
  help            Help about any command

Has "genai" listed under additional commands, should be moved up to the Manage DigitalOcean Resources section.

@danaelhe
Copy link
Member

danaelhe commented Jun 12, 2025

Super small nitpicks but overall looks and works great!! Nice job 👍

@SSharma-10
Copy link
Contributor Author

Running:

delhertani@VG0X2599VX doctl % go run cmd/doctl/main.go --help
doctl is a command line interface (CLI) for the DigitalOcean API.

Usage:
  doctl [command]

Manage DigitalOcean Resources:
  1-click         Display commands that pertain to 1-click applications
  account         Display commands that retrieve account details
  apps            Displays commands for working with apps
  compute         Display commands that manage infrastructure
  databases       Display commands that manage databases
  kubernetes      Displays commands to manage Kubernetes clusters and configurations
  monitoring      Display commands to manage monitoring
  network         Display commands that manage network products
  projects        Manage projects and assign resources to them
  registry        Display commands for working with container registries
  serverless      Develop, test, and deploy serverless functions
  spaces          Display commands that manage DigitalOcean Spaces.
  vpcs            Display commands that manage VPCs

Configure doctl:
  auth            Display commands for authenticating doctl with an account
  version         Show the current version

View Billing:
  balance         Display commands for retrieving your account balance
  billing-history Display commands for retrieving your billing history
  invoice         Display commands for retrieving invoices for your account

Additional Commands:
  completion      Generate the autocompletion script for the specified shell
  genai           Manage GenAI resources
  help            Help about any command

Has "genai" listed under additional commands, should be moved up to the Manage DigitalOcean Resources section.

Updated

Copy link
Member

@danaelhe danaelhe left a comment

Choose a reason for hiding this comment

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

LGTM!

@SSharma-10 SSharma-10 merged commit 1652a0d into main Jun 13, 2025
9 checks passed
@SSharma-10 SSharma-10 deleted the Doctl_GenAIAgent branch June 13, 2025 14:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants