Rest Api
CRDTN Core supports using of Rest Api in a more convenient way. Sometimes you want to get some data from the internet during runtime of your server. You can use this for various things.
Example of usages
There can be multiple reasons why to use Rest Api. Unfortunately the DayZ support of the rest api is quite limited so you might need to cope with just a couple methods comparing to regular approach of the usage of rest api for instance on the Web Applications you daily use.
Rest Api allows you to call requests on the external network endpoints to receive a response of your desired state.
For example, you can store some data on the external database and access those only through the rest api from your server so you are not caching and storing these data directly on the server memory.
Common usecase might be a usage of an external database for shop database or some player statistics data, which you might also expose on the website of your server or discord.
Another example might be some kind of authentication against backend server to protect your mod from using on somewhere else. This can be unfortunately always reverse engineered and until we do not have any reasonable way how to lock our mod files, this can be always bypassed if someone skilled would find a way to override these lines of codes.
My example of usage
I came to this approach in DayZ mods because I hate how people are not willing to accept hard work behind the mod creation and toxicity of some individuals is above the sky so because of this I decided to go a bit different way and rip off some key logic of my mods to an external server where noone else has access. This makes the mod basically unusable without the rest api. It's the only way I found to be reasonable for me and other users who are willing to accept this fact, that if you use my mod, your server will send a small piece of data to my server. On the other hand, by using my mods and this method, you're going with me against those ass holes who steal the mods and do bad stuff with them.
Last updated