Representing TM1 data

The OData standard provides a uniform, commonly accepted method of interacting with data by using a REST interface.

By using OData, API requests and responses are understood regardless of the endpoint that your application communicates with. The TM1 data model is available to consumers through the TM1 REST API as an Entity Data Model (EDM) that conforms to the OData Version 4 protocol.

An EDM is described by using Common Schema Definition Language (CSDL). CSDL uses an XML representation to describe the TM1 entity data model that is available from the TM1 OData service. To use the TM1 REST API, you must understand how TM1 data is represented in EDM schema. You must also understand how the EDM hierarchy is represented.

For example, the View entity is described in the CSDL as an abstract entity. The NativeView and MDXView are based on the View entity. Because the View entity is abstract, it cannot be addressed directly, similar to conventions in an object-oriented paradigm.

      <EntityType Name="View" Abstract="true" tm1:Plural="Views" tm1:Since="10.2.2.0">
        <Key>
          <PropertyRef Name="Name"/>
        </Key>
        <Property Name="Name" Type="Edm.String" Nullable="false">
        </Property>
        <Property Name="Attributes" Type="ibm.tm1.api.v1.Attributes">
        </Property>
        <NavigationProperty Name="LocalizedAttributes" Type="Collection(ibm.tm1.api.v1.LocalizedAttributes)" ContainsTarget="true">
        </NavigationProperty>
        <NavigationProperty Name="Cube" Type="ibm.tm1.api.v1.Cube" Partner="Views">
        </NavigationProperty>
        <tm1:ResourceAttribute Name="view" AttributeType="const weak_ref&lt;View&gt;" ParamType="const weak_ref&lt;View&gt;" ByReference="true" IsPointer="true"/>
        <tm1:ContainedBy Name="Cube" Type="ibm.tm1.api.v1.Cube" Partner="Views"/>
      </EntityType>