Lamina API — Quick Start
Base URL:https://app.uselamina.ai
Auth header: x-api-key: lma_your_api_key
This guide assumes you already created a workspace API key in Lamina.
This is the canonical Lamina flow:
- discover an app
- inspect its parameters
- start an execution
- receive results by webhook or polling
1. Discover an app
search when you know the capability you want:
appId from the response.
2. Inspect the input schema
name as the key when sending inputs. For options, send the label from the options array.
3. Start execution
Optionally pass?webhook=<url> to receive results pushed to your server when complete.
You can still poll the execution status regardless — webhooks and polling work side by side.
4. Get results
Via webhook: If you passed?webhook=, your callback URL receives a POST with the results when the execution completes. The payload has the same structure as the polling response below, signed with ED25519 headers for verification.
Via polling: If not using webhooks, poll every 3-5 seconds:
queued → running → completed or failed
When status is "completed", output type changes from "pending" to "image", "video", or "text", and value contains the result:
status is "failed", check errorMessage and each output’s error field.
5. Discover other apps
appId and parameter schema change.
Production Notes
- prefer webhooks over tight polling loops for long-running image or video jobs
- cache app metadata if you call the same app repeatedly
- validate
inputsagainst the latestGET /v1/apps/{appId}response before execution - use Capability Recipes when you want business-facing documentation for specific use cases