Setting up your In-App
This section covers the process of building and submitting your In-App to ChuttApp store.
Installation
You need to add the @chuttApp/in-app
in your Single Page Application; (React recommended).
With NPM
npm install @chuttApp/in-app
With Yarn
yarn add @chuttApp/in-app
Import and initialize
import * as ChuttApp from '@chuttApp/in-app';
Before you send your In-App to the ChuttApp Store, you need to have a few data points set right.
Please replace
YOUR_USER_ID
andYOUR_APP_ID
with the actual IDs respectively, that can be found in your In-App's detail from the dashboard.If you haven't yet create the In-App from there dasboard, please click here.
const inAppConfig = {
app_id: 'YOUR_APP_ID',
user_id: 'YOUR_USER_ID',
appWindow: window
}
ChuttApp.initialize(inAppConfig);
Creating an In-App
As mentioned in the Overview;
In-App services are essentially a lightweight Single Page Application (SPA) that has access ChuttApp's APIs.
You can build your In-App with HTML, CSS and Javascript, or any framework of your choice, as long as it is a can be opened on the web.
When you have an existing App, we do recommend having a lightweight verison of it for the In-App service.
We have example In-Apps to explore. Please do check them out as you follow through this doc.
- Invoices Left To Pay -> Pay for invoices gathered over time.
- Sneaker Shopman -> Buy sneakers from the Shopman e-store.
- Random Man -> Guess a number, and win some cash when you have it right.
Permissions and Authentication
ChuttApp require that, users sign in your In-App and grant access to your actions you would want to perform.
Users need to review and grant you the permissions to access certain actions/operations.
For more information on actions, see Available actions.
Once current authenticated user clicks the Allow access
button, you are good to go.
The current authenticated user is the user that has opened your app.
Configuration - Configuring your In-App service
App Configuration from ChuttApp
When your In-App service is launched, ChuttApp sends in data and configures your In-App with that data.
See Data from ChuttApp for more info.
Testing your In-App
You will need to complete the above steps and proceed to testing your In-App.
Please follow these steps to test your In-App in ChuttApp.
Please make sure you have developer mode enabled in your ChuttApp.
Enabling developer mode
- Go to Account
- Go to General
- Go to Settings
- Click Developer
- Press
Enable developer mode
.
Once enabled, you can perform Transfer Actions and other actions with your in-development(Test Mode) In-App.
These steps assume your app is not created yet. Otherwise, skip to step 7
- Login to your Developer Dashboard.
- Go to In-Apps
- Press
Create App
button. - In the Create App form, upload your In-App icon.
- And fill out the fields and then press the
Next
button. - Here, select all the capabilities you want for the App and press the
Review
button. - Press
Test in ChuttApp
.
Submitting to ChuttApp Store
Once all the above steps are completed, you will need to let ChuttApp users know where to find your awesome In-App service!
Please follow these steps to complete the submission.
- Login to your Developer Dashboard.
- Go to In-Apps
- Press
Create App
button. - In the Create App form, upload your In-App icon.
- And fill out the fields and then press the
Next
button. - Here, select all the capabilities you want for the App and press the
Review
button. - Once you're done reviewing, you can now submit your In-App.
Wait for some moment or at max, 1 day, for your app to be reviewed and rolled out to the ChuttApp store.
If you have questions or experienced a delay or error, kindly reach out to us.