Atoms consist of a small set of primitive types e.g. string, bool, number etc., records are structs and sequences are arrays consisting of atoms, records or sequences. The database engine of Azure Cosmos DB is capable of efficiently translating and projecting the data models onto the ARS based data model.
Azure Cosmos DB supports 5 different APIs and each supports different data models to use document, key/value, wide column and graph based data.
Core or SQL API - Default API in Cosmos DB and provides a view of the data similar to No-SQL data store. Allows you to query hierarchical data using SQL Query language. If you have prior experience with SQL, you can use the familiar SQL commands and clauses.
MongoDB API - Allows MongoDB clients to interact with the data as if they are running against MongoDB database. Data is stored in the format similar to Core SQL. Azure Cosmos DB's API for MongoDB is currently compatible with 3.2 version of the MongoDB.
Cassendra API - Allows to query data using Cassendra Query Language (CQL). Data will appear to be a partitioned row store. Like MongoDB API, existing clients can connect to Azure Cosmos DB and only the connection string needs to be updated.
Azure Cosmos DB supports familiar CQL commands and clauses.
- CREATE KEYSPACE
- CREATE TABLE
- ALTER TABLE
- BATCH (Only unlogged commands are supported)
Gremlin API - Provides graph based view of the data. Graph based data is transferring the data into nodes and its relationships into edges. Normally traversal language is used to query a graph database, and Azure Cosmos DB supports Apache Tinkerpop's Gremlin language.