Docs and helpConnecting
SDK and API: which connection do you use when?
Two ways to use Neon Studio — the SDK on your own page and the Production API from your own server. What the difference is, and when to reach for which.
There are two ways to tie Neon Studio into your own systems. For most makers the first one is enough.
The SDK — for your website
The SDK is a small JavaScript file you load on the page where your configurator should appear. It places the configurator in an element on your page, with your prices, colours and texts from your portal. Your visitor designs, and the order lands under Orders & quotes.
What the SDK does for you:
- Puts the configurator on your page: one code per product.
- Keeps the height in step with what your customer is doing, so you never have to set one.
- Loads your settings live, so a price change shows up straight away without you pasting anything again.
The SDK runs in your visitor’s browser, so it uses your public key. That key belongs on your website: all it says is “this visitor belongs to this company”. You get the code with your key with Connect on the Use it tab of your software. See Adding Neon Studio to your site.
The Production API — for your own systems
The Production API connects your server to your account. It does not exist yet: there is nothing to call so far, and your portal does not offer it either. It is meant for what does not fit on a web page:
- pull orders from your account into your own ERP or order system;
- fetch production files automatically to your machine or your working folder;
- update statuses from your own planning instead of by hand.
The Production API uses a secret key. That key belongs on your server and never on a web page: whoever holds it talks to your whole account.
Which one do you need?
| What you want | What you use |
|---|---|
| A configurator on your own site | SDK |
| Let customers order without a webshop | SDK |
| Every new order in your own system | The webhook |
| Fetch files automatically | Production API (not available yet) |
Not a programmer? Then the SDK is all you need. You paste the code once and do the rest in your portal at app.mark2form.com.
The package on npm
The SDK is on npm as @mark2form/sdk, with the element
<mark2form-configurator>. Version 1 is tied to the script v1.js: as long as
the version number starts with a 1, what you build keeps working. The options
you pass and the events you can listen to are in the README of that package.
Most makers do not need it. Just copy the code from your portal: it has the version that is correct today, with your key in it.
What you can do without writing code:
- Put the configurator on your site. One code, pasted once.
- Send every new order on to Zapier, Make, n8n or your own server, with the webhook.
Want to help shape what you need? Tell us.
What is already fixed
- Your public key belongs on your site; your secret key never does.
- The runtime runs on embed.mark2form.com, in a frame inside your own page. Your visitor needs no account with us and notices nothing.
- Everything you set in your portal is live immediately. You never have to paste the code on your site again.