Skip to content

fix: Cloud 401/404 and empty lists should be readable #652

Description

@margaretjgu

cloud_api_error dumps the raw body (Cloud API error 404: {"errors":[…]}). Empty list returns [] with no hint.

  • Parse errors[].message (and code if present) into error.message
  • 401/403: name Cloud API key vs project ES key confusion, plus the console API keys URL
  • 404 on a project/deployment: name list for that product line
  • Empty list on projects * list / list-deployments: stderr one-liner with the matching create command (stdout stays [] under --json)

Do not replace #636. This is Cloud body shape and empty-account UX.

Acceptance: mock 404 with {"errors":[{"message":"project not found"}]} prints that message, not the raw JSON blob. Empty list with --json is still []. Human mode prints the create hint on stderr.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

cloudElastic CloudenhancementNew feature or request

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions