keenauth_permission

The keenauth_permission resource defines a permission (an OAuth scope) of an API, with the texts the consent screen shows. The provider does not manage the API itself: pass the ID of an existing API as api_id. Put the permission into a role with keenauth_role.

resource "keenauth_permission" "invoices_read" {
  api_id       = "api_01j9zq3v8c5m2x7k4t6r1n0b3d"
  value        = "invoices:read"
  display_name = "Read invoices"
  description  = "See the invoices of the account."
  sensitivity  = "normal"

  consent_text_i18n = {
    de = "Rechnungen ansehen"
    tr = "Faturaları görüntüle"
  }
}

Lifecycle

Import

Import by API ID and permission ID, or by API ID and value:

tofu import keenauth_permission.invoices_read api_01j9zq3v8c5m2x7k4t6r1n0b3d/perm_01j9zq3v8c5m2x7k4t6r1n0b3e
tofu import keenauth_permission.invoices_read api_01j9zq3v8c5m2x7k4t6r1n0b3d/invoices:read