🧑Installation & Initialization
Connect
Indicates your intention for users to have the ability to link their preferred services, such as email or SMS sending credentials, or connecting their social media accounts.
Use
This feature implies that you intend to enable users to utilize their connected services. It should be employed alongside the Connect capability. In essence, if this feature is not included, users will only have the ability to link their services without the functionality to actually use them.
Installing Lamba
Installing Lamba is as simple as adding up the javascript library with a script tag, and the css with a link tag:
<script type="text/javascript" src="https://sdk.lambahq.com/v1.js"></script>
<link rel="stylesheet" href="https://sdk.lambahq.com/v1.min.css">
Initializing Lamba
The next step is initializing the Lamba Js library. This is shown below:
function openBuilder(){
// calling with `new window.Lamba({});` OR
const lamba = new Lamba({
title: "Lamba",
icon: 'https://ik.imagekit.io/lambahq/lamba-dark.png',
theme: "light", // or "dark"
appId: "65aabeba6182d6903a2ea355", // (REQUIRED) the id of your app in your Lamba account
customerId: "cus_x1847", // (REQUIRED) the customerId of the customer/user added to your app
enabledServices: [], // (OPTIONAL) can be omitted if you need to display all available services
usageCapabilities: ['connect','use'], // (REQUIRED) atleast one of "connect" and "use" must be provided
});
// call the `open` method on the lamba instance to open up the Lamba interface
lamba.open();
}
Now that you've known how to install and initialize Lamba, the next thing is to get acquainted with the possible parameters you can pass to the Lamba object when calling new Lamba({...});
Go to the next content to get started.
Last updated
Was this helpful?