Step 2: Embedding the Importer
Add OneSchema to your application
This guide will help you embed an importer in your application using a provided code-snippet.
Generate a Code Snippet
- From the main Dashboard, navigate to Code Snippet under the
Developers
section in the left sidebar.
![](https://files.readme.io/494e20d-Screenshot_2023-10-10_at_11.14.47_AM.png)
- Ensure that the Development environment is selected in "Step 1".
- Select the template you'd like to use in "Step 2".
- Click Generate Snippet in the bottom right corner.
Note: a JWT is auto-generated for you in "Step 3". More on this later.
Using the code snippet
- Note the tabs for
React
,Javascript
, andAngular
and select your desired language. - If relevant, install the package using NPM.
- Paste the code snippet into your application and click the provided button to launch the OneSchema Embedded Importer.
![](https://files.readme.io/f808cd6-Screenshot_2023-10-11_at_10.25.24_AM.png)
Using Other OneSchema Environments
By default the development environment allows OneSchema to be embedded on any page. Other environments like Staging and Production require an Allowed Domains list, essentially a "whitelist" of where OneSchema can be embedded.
![](https://files.readme.io/0ee24d2-Screenshot_2023-10-10_at_11.29.11_AM.png)
Click Add a domain to set up your domain(s) list. Note that OneSchema assumes https://
so http://
needs to be specified when appropriate.
Updated 10 months ago