Syncfusion Setup
Three quick steps. We hold the Syncfusion license — you just plug in.
1. Enable the engine.
WebOffice is a broker: our Syncfusion license runs on our servers, so you don't need your own. One click activates the Word Processor engine on your account.
2. Create API keys for your apps.
Create one key per app you develop — just like opencode-go keys. If a key leaks, revoke it here: your balance stays safe and other apps keep running. Click the copy icon on any key to copy its full secret again at any time.
No API keys yet. Create your first one above.
3. Download the JumpStart, claim coins, enjoy!
Click Here to download the JumpStart content, then paste one of your API keys from Step 2 where indicated. The cost is 1 Coin or US$ 0.01 per API Call. New users also get 1,000 Welcome Coins — claim below!
Free Coins!
1,000 Coins
Waiting for you — hit Claim Now below.
Already added to your balance. Enjoy!
Bronze
US$ 100.00 (FREE 100 Coins)
Silver
US$ 500.00 (FREE 1,000 Coins)
Gold
US$ 1,000.00 (FREE 5,000 Coins)
Embedding the DOCX editor in your web app
WebOffice is a broker — the editor itself comes straight from Syncfusion, so their official guide is the source of truth for embedding. Use the JavaScript (ES5) track for plain script-tag embeds (the ES6 track is TypeScript with npm/webpack). Metering still goes through your WebOffice API key, as shown in the JumpStart above.
Hosted on help.syncfusion.com — opens in a new tab.
Documentation
How the Syncfusion JumpStart is wired to WebOffice — setup, editor modes, and metering.
JumpStart setup — what to change
The JumpStart is a complete reference integration: the Syncfusion Document Editor runs in the browser while WebOffice meters every call. Two files carry everything you need to edit — both in the JumpStart folder:
| File | Value | What to put |
|---|---|---|
index.js |
syncfusionLicense |
your Syncfusion license key — registered in the browser via ej.base.registerLicense() |
index.js |
webOfficeLicense |
your WebOffice API key wo_live_… from Step 2 |
index.js |
currentUser |
display name for track changes & comments (default 'Current User') |
index.js |
filename |
document name used by Save and Save PDF |
weboffice-helper.js |
usedPath |
'cdn' (default) loads EJ2 from Syncfusion's CDN; 'local' serves the bundled ej2/ folder |
weboffice-helper.js |
serviceUrl |
Syncfusion's hosted import service (default) or your own Document Editor server |
- Edit the values above.
- Serve the folder with PHP —
php -S localhost:8000(Save / Save PDF write throughsave-document.php). - Open
index.htmland press Import.
Editor toolbar & modes
| Button | What it does | Metered |
|---|---|---|
| Import | Opens .docx .dotx .docm .dot .doc .rtf .txt .xml .sfdt; non-SFDT formats are converted through serviceUrl + Import. |
1 call (Processing … File) |
| Save | Exports the document as .sfdt to your server (save-document.php). |
1 call (Export .sfdt File) |
| Save PDF | Renders pages client-side into a PDF and stores it on your server. | 1 call (Export .pdf File) |
| Opens the browser print dialog. | free | |
| Download DOCX | Saves the document as .docx straight from the browser (no server write). |
1 call (Export .docx File) |
Share links — view-only mode (URL parameters)
| URL example | Mode |
|---|---|
?doc=Report.docx |
Edit — full editing (default). |
?doc=Report.docx&user=jane@acme.com |
Edit, labeled as jane in track changes & comments. |
?doc=Report.docx&user=jane@acme.com&readonly=1 |
View-only — content edits blocked; Import / Save / Download DOCX hidden; Print & Save PDF stay available. |
Read-only & track changes in code
The share link drives the editor flag (index.js):
const woReadonly = woQuery.get('readonly') === '1';
new ej.documenteditor.DocumentEditorContainer({
restrictEditing: woReadonly, // true for a view-only share link
// enableTrackChanges: true, // turn on tracked changes markup
currentUser: currentUser,
});
Comment-only mode (comment & reply without editing) is available on the ONLYOFFICE integration.
Metering & usage API
Every import and export calls logUsage() in weboffice-helper.js,
which posts to WebOffice before the action runs:
POST https://dashboard.weboffice.tech/usage/log
Authorization: Bearer <webOfficeLicense>
{ engine: "syncfusion", action, userIp, currentUser, filename }
| Field | Purpose |
|---|---|
engine |
Routes the call to the Syncfusion meter. |
action |
Human label shown in your usage history (e.g. Processing .docx File). |
userIp |
Client IP (resolved by the sample via api.ipify.org). |
currentUser |
Who edited the document. |
filename |
Document name for the usage record. |
1 call = 1 coin or US$ 0.01, billed to the key owner. When the balance is empty the call is denied with Insufficient balance — top up on the Top up page.
Production checklist
- Keep this folder on a trusted host: the sample keeps your WebOffice key in browser JS for simplicity. For public apps, move metering behind your backend proxy — the ONLYOFFICE JumpStart shows the server-side pattern.
- Metering is fail-closed: if the balance check is unreachable, the action is denied instead of running for free.
- Serve over HTTPS, and restrict
save-document.phpto your app's own session and paths before exposing it. - Use
usedPath: 'local'when your deployment has no outbound CDN access.