.NET
.NET SDK for CodeMash API
Last updated
Was this helpful?
.NET SDK for CodeMash API
Last updated
Was this helpful?
The database and other services we do provide have on top of it. So each interaction and much more are available using our robust API. (Please check the ).
Even though working with API can be less joyful than having a well-prepared SDK (Software Development Kit) for your programming language. For this reason, we provide ready-to-production Microsoft. NET SDK that allows you to quickly handle tedious tasks and focus more on your app.
Using your preferred editor (Visual Studio, JetBrains Rider, Visual Studio Code, or any other), open your .NET project. Add using one of the following ways:
Visual Studio (For more info on how to install the package in Visual Studio, you can find it .)
Load a project in Solution Explorer, and then select Project > Manage NuGet Packages.
Find CodeMash.Core package and install it.
dotnet CLI (For more info on how to install the package in Visual Studio, you can find it)
You can find the CodeMash npm package
Source code is available at
You can go to the Releases section and download the build version from the release assets.
[Collection] - used on a class to specify the name of a collection that this class represents.
[Field] - used on property inside of a class to specify the name that is used inside a database. That would be a unique name that you see in your dashboard, collection page, field configuration.
The collection attribute allows your requests to the database to be automatically injected with a collection name. The field attribute allows us to correctly serialize and parse your records, filter, sort, projection, and update queries. You can omit this attribute if your property name is exactly the same as your field's unique name.
IEntity - an interface that every entity class should implement. This will allow us to use the class in provided database methods.
Entity - a class that already implements IEntity interface and can be extended by your entity classes.
TermEntity - a class that should be used for taxonomy references (if your collection has references to taxonomies, use this class for that field).
FileEntity - a class that should be used for file fields.
Entities are your collection data models. In object-oriented programming, this would be a class that is a representation of a collection in your code. Our provide helper tools to make this representation easier to handle.