Project, platform and API key
Create the project in the console, register your app's domain and generate an API key for the server.
Everything your app stores (users, tables, files, functions) lives in a project. The SDK needs its ID; the browser needs your app’s domain to be registered; the server needs an API key.
Create the project
Section titled “Create the project”- In the console, open the organization and go to Projects → Create project.
- Give it a name. The Project ID appears on the Overview: it’s the value of
setProject()in the SDKs.
Register the web platform
Section titled “Register the web platform”The browser only talks to the API from a domain registered in the project. Requests from any other domain are rejected (error general_unknown_origin).
- Under Platforms → Add web platform, enter your app’s hostname: just the name, with no
http://and no path. Examples:app.example.comor*.example.com. - To develop on your machine, also register
localhost.
Create the API key
Section titled “Create the API key”The API key is for the server only: it lets your backend act without a user session. It doesn’t follow the permissions of rows and files: what its scopes allow is what counts. Treat it like a password.
- Under API keys → Create API key, give it a name and choose the expiration (never, 30 days, 90 days or 1 year).
- Check only the scopes your backend uses. For the first call with
@owbase/node,users.readis enough. - Copy the secret and store it as a server environment variable (in the examples,
OWBASE_API_KEY).
Next step: install the SDK and make the first call.
Was this page helpful?Thanks for your feedback.