Skip to main content
This guide verifies your key, lists your workspaces, and shows how to handle an API error.

Prerequisites

  • An Onlyform account.
  • A server, terminal, or API client that can keep secrets private.
1

Create an API key

Open Profile → API keys in the Onlyform dashboard, then select Create API key.Give the key a descriptive name, choose the minimum required scopes, and optionally set an expiration date.
Copy the secret immediately. Onlyform displays the complete key once and cannot recover it later.
2

Store the key

Store the secret in an environment variable. Keys begin with of_live_.
Do not commit the value to source control.
3

Verify the key

Call GET /v1/me to inspect the key owner and its effective scopes.
A successful response looks like this:
4

List your workspaces

Use the same header for every authenticated request.
Collections return an items array and a page object:

Create a complete form

POST /v1/forms accepts the form type, ordered blocks, settings, theme, variables, and hidden fields in one request. Use MULTI for a page-per-question form or SINGLE for a single-page form.
CONVERSATIONAL is reserved for the upcoming conversational renderer. Creation currently returns 422 UNSUPPORTED_FORM_TYPE instead of silently falling back to another layout.

Handle errors

Check the HTTP status and log the returned request_id. It lets Onlyform support trace a specific request.

Authentication and scopes

Choose scopes and rotate keys safely.

API reference

Explore every endpoint in the interactive reference.