# LLMs-Full.txt - Comprehensive GlamAR AI Assistant Guide ## Purpose This file provides an in-depth reference for LLMs to assist users in integrating and troubleshooting GlamAR SDK. It includes all relevant sections in detail. ## Metadata - **Product Name**: GlamAR SDK - **Supported Platforms**: Android, iOS, Web - **Primary Use**: Augmented Reality (AR) SDK for beauty, fashion, and virtual try-ons. - **Integration Methods**: Native (Android/iOS), Web APIs ## Full Documentation ### Introduction # Introduction **Welcome to the GlamAR SDK!** This guide will help you get started and show how to add advanced AR features to your web applications. GlamAR SDK enables seamless integration of AR features into your existing applications. It is fully compatible with web, Android, and iOS platforms, ensuring a versatile and robust solution across multiple environments. The SDK serves as an effect player for GlamAR effects, providing a range of built-in APIs needed to create powerful AR solutions. It acts as the foundational layer for all GlamAR use cases and solutions. The best way to get started with GlamAR SDK is by visiting:
**GlamAR SDK is available for:**Desktop
Mobile
Methods | Description |
---|---|
init | GlamAR.init(containerId, apiKey, openLiveMakeup) |
Parameters:
|
|
Return Value: None | |
Initializes the widget | |
applyMakeupBySku | GlamAR.applyMakeupBySku(skuId, callback) |
Parameters:
|
|
Return Value: None | |
Changes the makeup effect by the given SKU ID, you could retrieve your SKU information from admin panel. | |
addEventListener | GlamAR.addEventListener(eventName, handlerFunction) |
Parameters:
|
|
Return Value: None | |
Adds the listener to the given event name. | |
removeEventListener | GlamAR.removeEventListener(eventName, handlerFunction) |
Parameters:
|
|
Return Value: None | |
Removes the given listener for the event name. | |
getAllSKUs | GlamAR.getAllSKUs() |
Parameters: None |
|
Return Value: Promise that resolves to an array of SKUs available for the given API key. | |
Returns an array of available SKUs for the given API key. | |
reset | GlamAR.reset() |
Parameters: None |
|
Return Value: None | |
Removes all the makeup effects from the canvas. | |
close | GlamAR.close() |
Parameters: None |
|
Return Value: None | |
Closes canvas and back to main widget page. | |
snapshot | GlamAR.snapshot(contentType) |
Parameters:
|
|
Return Value: image in `base64` or `blob` | |
Takes a snapshot of current result window. | |
isLoaded | GlamAR.isLoaded() |
Parameters: None |
|
Return Value: `true` if the module is loaded else `false` | |
Returns status of module loading. | |
isLoading | GlamAR.isLoading() |
Parameters: None |
|
Return Value: `true` if the module is loading else `false` | |
Returns status of module loading. |