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

Fix url for clone endpoint #54

Merged
merged 1 commit into from
Mar 17, 2025
Merged

Fix url for clone endpoint #54

merged 1 commit into from
Mar 17, 2025

Conversation

aktech
Copy link
Contributor

@aktech aktech commented Mar 17, 2025

Looks like the url was incorrect in the API docs.

Not working

curl --connect-timeout 6000 \
  --max-time 5000 \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{
    "name": "macos-sequoia-vanilla_latest",
    "newName": "cloned-vm"
  }' \
  http://localhost:3000/lume/vms/macos-sequoia-vanilla_latest/clone
Not found%

Working

curl --connect-timeout 6000 \
  --max-time 5000 \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{
    "name": "macos-sequoia-vanilla_latest",
    "newName": "cloned-vm"
  }' \
  http://localhost:3000/lume/vms/clone
{"message":"VM cloned successfully","source":"macos-sequoia-vanilla_latest","destination":"cloned-vm"}%

TODO for later: It would great to add auto-generated docs via something like swagger.

@f-trycua f-trycua merged commit f6a008b into trycua:main Mar 17, 2025
2 checks passed
@f-trycua
Copy link
Contributor

Swagger makes sense to me. It would be useful to generate bindings for other languages.

@aktech
Copy link
Contributor Author

aktech commented Mar 17, 2025

Swagger makes sense to me. It would be useful to generate bindings for other languages.

That would be excellent. There are tools, that do that automatically like https://www.speakeasy.com/ (disclaimer: I haven't used it, but sounds interesting)

@aktech aktech deleted the fix-clone-url branch March 17, 2025 15:31
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