Software feature licensing and usage limits
An export entitlement differs from 500 exports per month. RunFeature checks permission; RunMeteredFeature confirms usage after business success.
Allow 500 exports per month
Add export to the policy's features, then a quota: feature export, limit 500, period Monthly. By default, further use is rejected when exhausted. To allow overage, set its maximum; the system records excess usage for your order system.
Daily and monthly quotas reset at midnight UTC; lifetime quotas do not reset. Changing a limit does not erase consumed usage.
Confirm usage after a successful export
Pass your business callback to the SDK. New jobs need new IDs; retries retain the ID, feature and quantity. Different processes must not run the same job concurrently.
| Language | Metered business call |
|---|---|
| Go | client.RunMeteredFeature(ctx, "export", 1, jobID, exportReport) |
| Java | client.runMeteredFeature("export", 1, jobID, this::exportReport) |
| Node.js | await client.runMeteredFeature("export", 1, jobID, exportReport) |
| Python | client.run_metered_feature("export", 1, job_id, export_report) |
| C# | await client.RunMeteredFeature("export", 1, jobID, ExportReport) |
| C++ | client.RunMeteredFeature("export", 1, jobID, exportReport) |
| Rust | client.run_metered_feature("export", 1, &job_id, || export_report())? |
| Ruby | client.run_metered_feature("export", 1, job_id) { export_report } |
| C | ln_run_metered_feature(client, "export", 1, job_id, export_report, context) |
Configure a meter for the actual feature in your policy, then generate the AI integration prompt. AI should use the language's RunMeteredFeature with a stable business operation ID, preserving that ID when retrying the same task.
If business succeeds but confirmation fails, retrying the same job only confirms; it never repeats business. A crash during business blocks automatic replay. Inspect your durable result, then ResolveMeteredFeature confirms or cancels. Remote usage and local business are not one transaction.
When you need to control reservations yourself
- Create and save a job ID for this export.
- Reserve one unit and export only after pending. committed means the work already finished; do not execute again.
- After exporting successfully and saving the result, call Commit to confirm the use.
- If the export fails before completion, call Cancel to release the hold without consuming units.
Holds last 15 minutes by default, shortened at a UTC reset. Direct API callers can set reservation_seconds to 30–3600 seconds.
| Language | Reserve | Commit / Cancel |
|---|---|---|
| Go | Reserve(ctx, "export", 1, jobID) | Commit / Cancel(ctx, hold.ID, jobID) |
| Java / Node.js | reserve("export", 1, jobID) | commit / cancel(id, jobID) |
| C | ln_reserve(client, "export", 1, jobID) | ln_commit / ln_cancel(client, id, jobID) |
| C++ / C# | Reserve("export", 1, jobID) | Commit / Cancel(id, jobID) |
| Python | reserve("export", 1, jobID) | commit / cancel(id, jobID) |
How to read the response fields
| Field | Meaning |
|---|---|
| reservation_id / operation_id | Reservation ID and original job ID; keep the same values for retries. |
| status / expires_at | Hold status and deadline: pending awaits completion, committed is charged, canceled is released, expired has timed out. |
| consumption.used / reserved | Confirmed uses this period / units held by all active reservations. |
| consumption.limit / remaining | Basic allowance / available basic units. remaining = max(0, limit - used - reserved), excluding permitted overage. |
| consumption.quantity / overage | Units for this job / confirmed units above the basic allowance; no customer payment is collected. |
| consumption.period / reset_at | UTC usage period / next reset; lifetime allowances have reset_at = null. |
For request bodies, responses and field types, see Reserve, Commit and Cancel in the runtime API reference.
After success, do not cancel or export again. Retain the IDs and result and retry Commit. If the hold expired, keep the job for reconciliation. Remote usage and local business work cannot share one atomic transaction.
Consume still records usage immediately. Use reservations to avoid charging failed work. All functional usage endpoints require a connection and are excluded from the platform's four billable API operations.