Skip to main content
An OAuth app lets other Flowella organisations connect your product to their account without sharing API keys. Each organisation approves your app on a consent screen and can revoke it at any time. This page shows partners how to register an app and use OAuth, and shows customers how to review and revoke the apps they have installed. For your own scripts and integrations, an API key is simpler.

How it works

Flowella supports three OAuth grants: authorisation code with PKCE for customers’ organisations, client credentials for your own organisation, and refresh tokens. The sequence shows how a customer installs your app with the authorisation code grant.

Before you start

  • You need the Owner or Admin role in the organisation that will own the app. Other roles can see Developer apps in the menu, but the list does not load for them.
  • Your app needs a callback address (redirect URI) that can receive the authorisation code.
  • Your app must send a state value and a PKCE code_challenge made with S256 on every authorisation request.

Register an app

1

Open Developer apps

Go to Settings, then select Developer apps in the Developer group.
2

Start a new app

Select Create app. The Create developer app dialog opens.
3

Name the app

In App name, enter the name customers know your product by, up to 120 characters, for example Acme CRM connector.
4

Add redirect URIs

In Redirect URIs, enter each callback address on its own line, up to 20. During authorisation, the redirect_uri your app sends must match one of these exactly.
5

Choose scopes

Under Scopes, the read scopes are ticked for you. Tick any other scope your app needs and untick the ones it does not. These are the most your app can ever request. See Scopes.
6

Create the app and copy the secret

Select Create app. The Save your client secret dialog shows the client secret, which starts with flc_. Select Copy, store the secret on your server, then select Done.
Flowella shows the client secret only once, and you cannot reset it. If you lose it, you have to delete the app and register a new one, and every organisation that uses your app must approve the new one.
You cannot change an app’s name, redirect URIs or scopes after you create it. To change them, register a new app. The Developer apps list shows each app’s Name, Client ID (it starts with floa_), Redirect URIs and Created date, with a Delete button under Actions.

Send a customer through authorisation

Send the customer’s browser to the authorise endpoint on the Flowella app host:
If the request is invalid, Flowella shows an error instead of the consent screen and does not redirect. This happens, for example, when the redirect_uri does not match or a scope is not allowed.

What the customer sees

  1. If the person is not signed in, Flowella asks them to sign in first.
  2. The person must be an Owner or Admin of the organisation. Anyone else sees the error Owner or admin role required to authorize apps.
  3. The Authorize app screen shows your Client ID: and the Requested scopes:. If your app did not send a scope, it says This app will receive its default allowed scopes.
  4. The person selects Allow access or Deny.
Allow access sends the browser to your redirect_uri with code and state in the query string. The code is valid for 10 minutes and works once. Deny sends the browser to your redirect_uri with error=access_denied, an error_description and your state.

Exchange the code for tokens

Your server exchanges the code at the token endpoint. Authenticate with your client ID and secret, either with HTTP Basic authentication or as client_id and client_secret in the body. The body can be form-encoded or JSON.
The response contains the tokens:
The token endpoint accepts 30 requests a minute for each client ID and IP address. Above that, it returns 429 with a Retry-After header.

Call the API

Send the access token as a bearer token, exactly like an API key:
The token works only for the organisation that approved it, and only for the scopes it was granted. A request outside those scopes returns 403 INSUFFICIENT_SCOPE. Each access token has its own rate limit. See the API introduction.
POST /v1/templates/send accepts API keys only and refuses OAuth access tokens with 401.

Refresh an access token

Before the access token expires, request a new one with grant_type=refresh_token, the refresh_token and your client authentication. The response has a new access token and a new refresh token, and the old refresh token stops working. If someone presents a refresh token that was already used, Flowella revokes every token issued from that authorisation, and the customer has to approve your app again.

Access your own organisation

To call the API for the organisation that owns the app, use grant_type=client_credentials with your client authentication and an optional scope. You get an access token without a refresh token. Your app then appears under Installed apps in your own organisation.

Revoke or inspect a token

Both endpoints need your client authentication. The discovery document at https://app.flowella.io/.well-known/oauth-authorization-server lists every endpoint and supported option.

Review and revoke installed apps

Customers manage the apps they have approved under Installed apps. You need the Owner or Admin role. The list shows: To revoke an app:
  1. Go to Settings, then select Installed apps in the Developer group.
  2. Select Revoke on the app’s row.
  3. Confirm the prompt Revoke this install? Existing tokens stop working.
The app’s tokens stop working at once, and it cannot refresh them. The row stays in the list with a Revoked badge. To give the app access again, an Owner or Admin approves it again on the consent screen.
Revoking your own app in your own organisation does not stop the client credentials grant: the app can request a new token, which turns the install back on. To cut off your own app completely, delete it under Developer apps.

Delete an app

In Developer apps, select Delete on the app’s row and confirm Delete this app and its tokens? Flowella removes the app, its install in every organisation that approved it, and all its tokens. This cannot be undone.

Troubleshooting

Only Owners and Admins can view these screens. Ask an Owner or Admin to manage the app for you. Roles can’t be changed in the app: see Change someone’s role.
The redirect_uri in the request must match one of the app’s registered redirect URIs exactly, including the scheme, path and any trailing slash. The same value must be sent again when you exchange the code. You cannot edit an app’s redirect URIs, so register a new app if you need a different one.
A requested scope is misspelt or is not one of the app’s scopes. Request only scopes you ticked when you registered the app.
The person approving the app is not an Owner or Admin of the organisation. Ask an Owner or Admin to complete the authorisation.
The messages Authorization code expired and Authorization code already used mean you need to start the authorisation again: codes last 10 minutes and work once. PKCE verification failed means the code_verifier does not match the code_challenge you sent.

API introduction

Authentication, scopes, rate limits and errors.

Developer hub

Recent API requests, quickstarts and the API sandbox.

API keys

Simpler access for your own scripts and integrations.

Webhooks reference

React to events in the organisations that install your app.
Last modified on October 24, 2026