update
Use the update command to update an API object.
Usage
endorctl api update -r [resource] [flags]
Interactive Mode
- Use
--interactive
or-i
to update an object with an interactive code editor.- Define your editor using
export EDITOR=<editor>
where the editor is defined as the command used to edit files. For example,export EDITOR=vi
allows you to edit in vi andexport EDITOR=code
opens the file with the code command in VS Code. - Specify which fields you want to update using the
--field-mask
parameter. If this is not set, endorctl will try to update all fields.
- Define your editor using
Examples
To interactively update a project with the UUID 6549886f0dd828140b4a477b:
endorctl api update -r Project -i --uuid 6549886f0dd828140b4a477b --field-mask meta.tags
To add a tag “CrownJewel” to a project named https://github.com/endorlabs/github-action use the following command:
endorctl api update -r Project \
--name https://github.com/endorlabs/github-action \
--data "{ \"meta\": {\"tags\": [ \"CrownJewel\" ] }}" \
--field-mask 'meta.tags'
Feedback
Was this page helpful?
Thanks for the feedback. Write to us at support@endor.ai to tell us more.
Thanks for the feedback. Write to us at support@endor.ai to tell us more.