Brain Docs

Reference

Rust SDKInstallationHTTP clientWire client
create_entityget_entityresolve_entitylist_entitiesupdate_entityrename_entitymerge_entitiesunmerge_entitytombstone_entity
ErrorsRetriesPagination
Brain/Docs
✦ ASKBrain on GitHubDashboard
Rust SDKEntitiesrename_entity

rename_entity

Change an entity's canonical name, optionally keeping the old one as an alias.

PURPOSE

Change the canonical name, with an explicit choice about what happens to the old one.

POST/v1/entities/:id/renameBearer API keystable
async fn rename_entity(&self, entity_id: &str, input: &RenameEntityInput) -> Result<EntityDetail, BrainHttpError>
Handshake credentialstable
async fn rename_entity(&self, request: &EntityRenameRequest) -> Result<EntityViewResponse>

Parameters

ParameterTypeRequired
entity_idstringrequired

The entity to rename.

new_canonical_namestringrequired

The new name.

move_to_aliasbooleanoptional

Keep the old canonical name as an alias. Without it the old name stops resolving — which is usually not what a rename means. Set it unless the old name was wrong rather than outdated.

Returns

FieldTypePresence
—EntityDetailalways

The full entity as it now stands.

On the wire

Ids are fixed-width UUID bytes rather than strings, attributes is an opaque attributesBlob, and every request carries a requestId plus an optional actAs. See Wire client.

See also
update_entityresolve_entity

Was this page helpful?

update_entity

Replace an entity's canonical name, aliases and attributes.

merge_entities

Fold one entity into another, with an audit id and a grace period you must read.

On this page

ParametersReturnsOn the wire
Suggest an editOpen in Playground