Knowledge Base Graph

Apply an ontology JSON to a collection

Changed on

Makes the collection's packages the file's: subscribes those it lacks, moves those it holds at another version to the file's version, and removes those the file does not list (a file without a packages key leaves them alone). Creates the classes and relationships the collection does not define yet and overwrites those it does, matched by type_id; classes and relationships the file leaves out stay. A package's class changed in the file is written as the collection's edited version of it; a package's relationships cannot change. All of it applies or none does: a package change that would leave instances of a type out of scope (409, naming the types), a type whose tier differs from the collection's, or any write a type endpoint would refuse fails the whole request with that endpoint's status, its detail led by the type id.

post/api/v0/knowledge-bases/{kb_id}/graph/ontology

Request

Path parameters

kb_idstring uuid required

Request body

format'outerport.kg-ontology'
format_version1
collection_namestring

Response

Successful Response

packages_addedstring[] required
packages_switchedstring[] required
packages_removedstring[] required
entity_types_createdstring[] required
entity_types_updatedstring[] required
relationship_types_createdstring[] required
relationship_types_updatedstring[] required

Changes

    • info

      added the new optional request property ////

    • info

      added the new optional request property ///////

    • info

      added the new optional request property ///////

    • info

      added the new optional request property /////

    • info

      added the new optional request property ////

    • info

      added the new optional request property //

    • info

      added the new optional request property ////

    • info

      added the new optional request property ////

    • info

      added the new optional request property ////

    • info

      request property list-of-types was widened by adding types null to media type application/json

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status