Unified Catalog Entity Creation and Modification¶
Both the CLI and MCP can call owl.catalog.entity_create and owl.catalog.entity_modify. First upgrade the accompanying CLI, Registry, and the AIAPI/Backend that provide the catalog write interface, then sync the catalog. Actual available capabilities and permissions are subject to the target site; verify the target and the content to be changed before write operations.
Preparing the Type, Team, and Entity¶
owl sync
owl exec owl.catalog.entity_type_query -p '{"page_size":20,"page_index":1}'
owl exec owl.workspace.member.group_list -p '{"search":"Platform"}'
owl exec owl.catalog.entity_query -p '{"entity_type":"service","name":"checkout-api"}'
Read the schemaDefine and customProperties of the selected type and fill in the type's required properties; the top-level name cannot substitute for the independent properties required by the type. Dynamic attributes and relations are validated by the backend.
entity_query must provide entity_type. name is an exact match, while search performs a fuzzy search on name, display name, or URN, and the two are mutually exclusive; urn and filters can be used for further filtering. filters uses catalog field syntax, not SQL/DQL; when both name and filters.name are passed, they must be consistent.
The team tool returns group_uuid, name, and member_count, without pagination; owl.member.group_list is a compatibility alias. The owning team attributes.owner uses the returned team name, not the UUID or a personal name; the value format is determined by the type definition. Free Plan workspaces do not provide team queries.
Creating and Partially Modifying¶
Creation requires request_id (UUID), entity_type, and name; display_name, attributes, and relation_modes are optional. name is up to 1024 characters, a non-empty display_name is up to 256 characters, and name is used when omitted. Duplicate identities or entities with the same type and name will not be overwritten.
Modification requires request_id and the complete urn returned by the query; only submit the display_name, attributes, and relation_modes you explicitly intend to modify. You cannot rename name, change the type, or write across workspaces, and you should not write back the queried item as a whole. The display name uses the top-level display_name.
Unsubmitted fields are retained; objects are merged recursively, ordinary arrays are replaced as a whole, empty objects do not mean clearing, and null is not a deletion instruction. Manual writes may change the provider and lifecycle.
Only submit relation fields actually declared by the type. When modifying depends_on, component_of, or components, each submitted field must specify relation_modes: add appends with deduplication, replace replaces as a whole, and replace with an empty array clears; creation defaults to replace. Relation targets must be real URNs in the current workspace and cannot reference the entity itself; components is not a common attribute for all entity types.
Write Results and Pending Confirmation¶
Generate a UUID for each new operation and persist the tool, full parameters, and identity/workspace context. Do not save credentials. Use -f json with the CLI to view the full business result; process exit code 0, HTTP 200, or the outer success field alone does not prove a successful write.
A successful result must contain data.write_state=confirmed, the corresponding request_id, and the entity URN. changed=false can indicate a successful no-change operation; replayed=true does not mean the write was re-executed. confirmed means entity read-back and audit task delivery are complete, and does not mean the audit has been finally ingested into the database.
| Status | Handling |
|---|---|
| pending / audit_pending | Keep the original UUID, tool, parameters, and identity/workspace, and continue confirmation per protocol; do not generate a new UUID to write again. |
| audit_unknown | Stop automatic confirmation, keep the UUID, URN, and trace ID, and ask the administrator to verify the audit status. |
| Timeout, non-JSON, or identity mismatch | The result is uncertain; first verify the actual state, and do not infer "not written". |
| CATALOG_REQUEST_CONFLICT / CATALOG_WRITE_BUSY | Restore the original operation record or complete an existing pending confirmation operation; do not bypass with a different UUID. |
| rejected / entity_changed_before_retry | Re-read the current entity to avoid overwriting modifications from other entry points; the corrected new operation must be reconfirmed. |
Only when can_retry_write=true is returned can subsequent calls possibly resend the business write; comply with retry_after_ms (up to 30000 milliseconds) and a maximum of 6 total submissions, still reusing the original UUID and parameters. Other pending states only perform confirmation. audit_unknown should not be automatically retried.
Backend state is retained for 7 days per workspace, actual account, and request_id. After the retention period expires, the state is lost, or the identity/workspace changes, first query and verify; do not treat the old UUID as a permanent deduplication guarantee. A single Owl call does not automatically poll or resend business writes.