Developers
C / C++ native: quickstart
Install and first-use steps for sending events to Feralin with C / C++ native. Code samples come from the SDK's own README and statuses from the capability record.
Install
feralin 0.1.0 is published on CMake FetchContent + Git etiketi; install it with your package manager using the command below.
include(FetchContent)
FetchContent_Declare(
feralin
GIT_REPOSITORY https://github.com/feralincom/sdk.git
GIT_TAG sdks/cpp/v0.1.0
GIT_SHALLOW TRUE
SOURCE_SUBDIR sdks/cpp)
FetchContent_MakeAvailable(feralin)
target_link_libraries(uygulamam PRIVATE feralin::feralin)cmake -S sdks/cpp -B sdks/cpp/build -DCMAKE_BUILD_TYPE=Release
cmake --build sdks/cpp/build
cmake --install sdks/cpp/build --prefix /opt/feralinfind_package(feralin CONFIG REQUIRED) # -DCMAKE_PREFIX_PATH=/opt/feralin
target_link_libraries(uygulamam PRIVATE feralin::feralin)First use
#include <feralin/feralin.hpp>
feralin::Options options;
options.project_key = "pk_live_..."; // sk_ reddedilir
options.collect_url = "https://collect.example.com";
options.consent.analytics = true; // kullanıcıdan alınan izin; varsayılan kapalı
auto client = feralin::Client::create(options); // geçersiz seçenekte nullptr
client->track("order_completed", {{"order_id", "ord_1"}, {"amount", 249.9}});
feralin::FlushResult result = client->close(); // kalan olayları en fazla 5 sn içinde gönderir#include <feralin/feralin.h>
feralin_options options;
feralin_options_init(&options);
options.project_key = "pk_live_...";
options.collect_url = "https://collect.example.com";
options.consent = FERALIN_CONSENT_ANALYTICS;
feralin_client* client = NULL;
if (feralin_client_new(&options, &client) != FERALIN_OK) { /* feralin_last_error() */ }
feralin_props* props = feralin_props_new();
feralin_props_set_string(props, "order_id", "ord_1");
feralin_track(client, "order_completed", props, NULL, NULL);
feralin_props_free(props);
feralin_client_free(client); /* kapatır, kalan olayları göndermeyi dener */Code samples are taken as they are from sdks/cpp/README.md; comments inside may be in Turkish. You create the project key in the dashboard.
Capabilities
| Capability | Status |
|---|---|
| Event sending | Supported |
| Batch sending | Partial |
| Consent handling | Supported |
| Identity | Partial |
| Attribution | Not applicable |
| Deep links | Not applicable |
| Revenue | Partial |
| Error capture | Partial |
| Session replay | Not applicable |
| Tracing | Planned |
Verification chain
| Link | Status |
|---|---|
| Source | Passed |
| Build | Passed |
| Test | Passed |
| Registry publication | Passed |
| Clean install | Passed |
| Event receipt | Passed |
| Documentation | Passed |
| Super Admin proof | Not started |
Passed means local evidence: source, build and tests ran. Registry publication and Super Admin proof are separate links; the SDK is not called ready until each has passed.