Scopes confusion

When I list all my scopes I have for instance:

$ boundary scopes list

Scope information:
ID: o_2Ihc0JeIew
Version: 1

ID: o_QxAVxWnADj
Version: 1
Name: Generated org scope
Description: Provides an initial org scope in Boundary

I wanted to work with targets, so I tried this scope since it was created from the start and could see it by running boundary scopes list. I ran this:

boundary targets list -scope-id o_QxAVxWnADj

But it would only throw:

Error from controller when performing list on targets:
Error information:
Code: InvalidArgument
Message: Improperly formatted identifier.
Status: 400

Field-specific Errors:
Name: -scope-id
Error: This field is required to have a properly formatted project scope id.

So checking my documentation from when I did init on my database, I received this information:

Initial org scope information:
Name: Generated org scope
Scope ID: o_QxAVxWnADj
Type: org

Initial project scope information:
Name: Generated project scope
Scope ID: p_sbPjQro4zZ <-- How can I find this one from the boundary cli client? Because this one works as -scope-id
Type: project

Hi there!

What’s happening is that the CLI command is defaulting -scope-id to global so when you run boundary scopes list it’s equivalent to boundary scopes list -scope-id global which will show you orgs underneath global. You can then run the command with the org scope: boundary scopes list -scope-id o_QxAVxWnADj to get a listing of projects underneath that org.

The error message is a little opaque – we plan on doing a lot of error cleanup in the near term and will continue to tweak error messages when/where we see pain points for users.

1 Like