Admin - This is our Backend API (with SDK wrappers) intended to be used server-side.
Client - This is our Frontend SDK intended to be used client-side.
Together these allow you to install and integrate Kana wherever you may need to in your application and beyond. How you want to integrate Kana will dictate which you need to install and setup. We go more into what each does and how to install below.
Our Admin API is by far our most flexible and powerful. You can take all actions you need with Kana server-side, both reading from and writing data to Kana as is necessary.
Our Client SDK is perfect for building out all read-only flows and components which utilise Kana data directly from the client. Imagine paywalls, information on feature usage, and package overviews - easily and readily available on demand.
import { KanaUserClient } from "@usekana/client-kana-js";const apiKey = "pub_live_xyz"; //Make sure this is your PUBLIC API Key// Stored client-side to be assigned to this constantconst currentUser = { id: "123456", name: "Zach Read", email: "zach@usekana.com",};const kanaUserClient = new KanaUserClient({ apiKey: apiKey, userId: currentUser.id,});
Congratulations 🎉 You’ve now successfully installed and initialized Kana.
You’ll want to ensure first that you have created all your features and packages within the Kana Dashboard. You can see more on these concepts within the Kana Concepts page, and more on how to create features and packages through the following guides.