Widgets
Leaf Link includes two widgets:- Provider Connection lets your users authenticate with CNHi, CNHI FieldOps, John Deere, Trimble, Climate FieldView, AgLeader, Raven Slingshot, Lindsay, and Stara from inside your application.
- File Upload lets your users drag-and-drop or browse for
.zipfiles containing machine data. Leaf processes these files through the standard conversion pipeline.
Prerequisites
- A Leaf account with at least one Leaf user created.
- A Leaf user API key (created via
POST /api-keys). - For provider connection: provider app credentials registered with Leaf for each provider you want to enable.
Provider setup
Each provider requires a one-time registration of your application credentials with Leaf. You also need to addhttps://widget.withleaf.io as a redirect/callback URL in the provider’s developer portal.
Register credentials by calling
POST /usermanagement/api/app-keys/{Provider}/{appName} with the provider-specific fields.
Installation
React
Angular
Properties
Provider Connection
File Upload
Hooks
Both widgets expose hooks for tracking widget state in your application.Provider Connection hooks
UseuseLeaf() from @withleaf/leaf-link-react:
File Upload hooks
To use hooks in React, wrap your component tree with the
<Leaf> context provider:
(getWidgetStatus) output binding on the <providers> component.
The Angular package does not currently expose
Stara in its provider list.What to do next
- Magic Link for generating shareable authentication and upload links without embedding widgets.
- Leaf Connect for sharing data between API owners.
- Leaf Link API Reference for API key and app info endpoints.

