Title: [Docs request] How to view, rotate and scope credentials for AppBuilder apps: official walkthrough?

Hi Teable team,

I’m building apps with App Builder and want to follow security best practice
for credentials. I couldn’t find one place in the docs that covers this end
to end, so I’m hoping an official answer here can become a reference for
everyone.

My use case: a security scan of an exported copy of my app’s code flagged a
credential in an environment file. I’ve have not removed the file yet, and I’m now
working out how to rotate everything properly. I realised I wasn’t sure
where platform-injected app tokens are managed, how rotation works, or
what else in an export can carry live credentials. I suspect plenty of
people export code for backup or review without realising what’s inside,
so I’d love an official walkthrough that covers it.

My questions:

  1. Credential types
    Which credentials does an App Builder app use (for example personal
    access tokens, platform-injected app tokens, anything else), and where
    in the UI can I see and manage each one?

  2. Rotating a platform-injected app token
    What are the exact steps to revoke and regenerate it? Is there any
    downtime, and does republishing the app change it?

  3. Scoping
    For both token types, can access be limited to specific tables or fields,
    or only to a whole base or space? What scopes are available?

  4. Exporting app code
    When an app’s code is exported, which environment variables or files
    can contain live credentials? What’s the recommended way to share or
    back up code safely?

  5. Duplicating a base or app
    When a base or an app is duplicated, are credentials copied, regenerated,
    or left pointing at the original?

  6. Audit and monitoring
    Can I see when and how a token was used (logs, last-used time, IPs),
    and can I set alerts?

  7. Using MCP safely
    With Teable MCP now available, what are the recommended auth and
    permission settings for connecting external clients or my own MCP
    server?

It would help a lot if the answer could be step-by-step with UI paths,
and mark which parts are documented and which are planned. Happy to
turn the answers into a short community guide, with credit to the Teable
team.

Thanks!

Hi G36, thanks for raising this, and for the clear write-up.

  1. Credential types. An app uses a platform app token (TEABLE_APP_TOKEN), an optional AI key (TEABLE_AI_API_KEY) when AI access is on, and any credentials you grant under Credentials & config. Personal access tokens (Settings → Personal access tokens) aren’t used by app code; they’re for the API, CLI and MCP.
  2. Rotating the app token. Self-serve rotation isn’t available yet. We’re adding it. You can already rotate the AI key under Credentials & config → AI access → Rotate key.
  3. Scoping. The app token has full access to the base the app belongs to and nothing else. Table- or field-level scoping isn’t available. Personal access tokens can be limited to specific spaces/bases and action scopes, with an expiry date.
  4. Exporting code. The .env file in a “Download code” export contains live credentials (the app token, plus the AI key if enabled), so keep it private and out of any repository. Granted credentials are not included. The built-in GitHub sync never commits .env files. We’ll add a clearer warning on export.
  5. Duplicating. A duplicated base or app gets its own new token. Granted integrations aren’t carried over and need to be re-authorized on the copy.
  6. Audit. Personal access tokens show a last-used time, and their changes appear in the audit log. Writes made by an app are recorded in the audit log. Per-token usage history and alerts for app tokens aren’t available yet.
  7. MCP. Connect with OAuth (recommended; clients can be revoked under Settings → MCP), or with a personal access token limited to the bases and actions the client needs. App tokens can’t be used with MCP.

Once rotation ships, we’ll turn this into a docs page and link it here. Thanks for the offer to help with the guide!

Thanks again, this is really helpful. A few follow-ups, mainly so the
eventual docs page covers them:

  1. If I delete or unpublish an app, is its app token revoked? Or only when
    the base is deleted?
  2. Does “Download code” reuse the same app token each time, or issue a
    new one? Does republishing change it, and what is its lifetime?
  3. App tokens look like generic JWTs, so secret scanners only flag them as
    “JWT detected”. Would a recognisable prefix, or registering with
    secret-scanning programs, be possible?
  4. Could the export offer a sanitised option, or leave .env out by default?
  5. When duplicating a base and app, what exactly is copied: records, app
    code, published domain, webhooks, automations?
  6. Where do I view the audit log, how long is it kept, and can app-token
    writes be filtered or exported? Are read logs planned?
  7. Will the upcoming rotation also bring table-scoped app tokens and
    per-token usage history?
  8. For external services (e.g. serverless functions) calling Teable, is a
    personal access token the recommended credential?
  9. Is there a private security contact for reports like this?

Just want to cover all bases and try to flush this out as deep as possible. Thanks for all your help!

Thanks, G36, great list.

  • 1, 2, 5, 6 and 8 are about how things work today, so we’ll answer them in the docs page.
  • 3, 4 and 7 are feature suggestions. Thanks, we’ll take them into account. 4 fits with the export changes we’re already planning.
  • For security reports (9), please use GitHub’s private vulnerability reporting: Sign in to GitHub · GitHub

Hi @G36 , an update: self-serve rotation has shipped, and Download code now leaves live credentials out by default. The details are in the docs: App Builder › Teable Access Token. Here are answers to your follow-ups.

Q1: Delete / unpublish. Deleting an app revokes its token immediately. If you restore the app from the trash, the same token works again. Unpublishing leaves the token unchanged.

Q2: Download code, republishing, lifetime. Download code returns the same token every time, and republishing doesn’t change it either. To rotate, open + → More → Credentials & config in the chat panel and click Rotate on the Platform credentials card.

Q5: Duplicating. Each copied app gets its own new token. Credentials granted to the original aren’t copied; the copy shows Not bound yet until you bind your own.

Q6: Audit. Rotating the access token or AI key, copying env variables and exporting code are recorded in the audit log under Apps. The export entry shows whether the .env was included. A space-level audit log is in progress.

Q8: External services. Yes, use a personal access token (Settings → Developer tools → Personal access tokens). Limit it to the projects or spaces and the scopes it needs, and set an expiry date.

Thanks again for pushing on this!

1 Like

Thanks! Much appreciated!