Skip to content

App clients

An App client is how a system, rather than a person, calls into Kiln. For example, a telematics feed that sends a signal when a vehicle event fires, which a flow turns into a record, a portal that runs a flow and reads the result, or a system that asks for a document to be rendered.

It is the reverse of a Connection. A Connection is how Kiln authenticates to another system. An App client is how another system authenticates to Kiln.

For a step by step walkthrough, see Give another system access.

A new client can do nothing. Its authority is a list of grants, and each grant has three parts: an action, a type of resource, and which resources of that type it covers.

The actions are: render a template, run a flow, read a flow run’s state, discover which flows exist, and create a resource.

Discovery is a separate grant. Permission to run a flow does not let a client list your flows or read their structure. If an integration should find out what is available rather than being configured with it, grant discovery as well.

Create applies to a whole resource type. Other grants name the resources they cover, but a resource that does not exist yet has no identifier. A client allowed to send signals may send any signal. A signal only says that something happened; what it means is decided by your flow.

A client secret is generated in Kiln and shown once. Only a hash of it is stored, so neither you nor Antero can retrieve it later. If it is lost, generate a new one.

The secret is machine generated with high entropy, so a fast hash is appropriate. Slow, salted hashing defends against guessable, human chosen passwords, which does not apply here.

A client can hold more than one secret at a time, so rotation needs no downtime: generate a new secret, move the integration across, and revoke the old one once it is no longer in use.

Secrets, which Kiln uses to reach outward, work differently: they hold one value per name and have no overlap period.

The client exchanges its secret for a short lived access token and sends that token with each request. The token is signed and carries the client’s grants as they stood when it was issued. On each request Kiln checks the signature and the expiry, whether the token’s secret has been revoked or the client archived, and whether the client’s owner is still a member of the tenant.

A client may request less authority than it holds. A request for a scope the client does not hold is refused with invalid_scope rather than silently narrowed, so a misconfigured integration fails at the point of the mistake.

These stop tokens already issued, on their next request:

  • Revoking a secret stops the tokens that secret issued. Other secrets on the client keep working.
  • Archiving the client stops all of its tokens.
  • The client’s owner leaving the tenant, being removed from it, or having their membership disabled stops all of the client’s tokens.

Removing a grant stops new tokens from carrying it, but not tokens already issued. A token keeps the grants it was issued with until it expires. The same applies when the owner loses a role but stays a member of the tenant.

Tokens last twelve hours by default. A client can be configured with a different lifetime, up to thirty days. Keep the lifetime as short as the integration allows, because it is the longest a token keeps a grant that has been removed.

To cut off an integration at once, revoke its secret or archive the client.

An App client is not a user account. It has no roles, is not a member of your tenant, and cannot use the builder. Its authority is only the grants on it.

People get access by being invited to the tenant and assigned roles.