Skip to content
Release: Australia · Updated: 2026-03-12 · Official documentation · View source

Map credentials between Cloud Provisioning and Governance and Terraform

Map credential types and service account fields between Cloud Provisioning and Governance and Terraform using Credential Mapping.

Before you begin

The latest Cloud Services Catalog Terraform Connector must be installed from the ServiceNow Store.

Role required: sn_cmp.cloud_admin, admin

About this task

Use the Credential Mapping module to perform credential and service account mappings for datacenter credentials used by the Terraform provider to provision datacenter resources and Cloud Provisioning and Governance for discovery.

Procedure

  1. Navigate to All > Design > Credential Mapping.

  2. Select New.

Image omitted: new-credential-mapping-terraform.png
Terraform Datacenter Mapping form
  1. On the form, fill in the fields.

    FieldDescription
    Terraform ProviderName of the Terraform provider.
    Datacenter BlockThe resource block whose credentials you are mapping from the lookup table.
    Credential TypeThe appropriate credential type from the lookup table. For example, Azure Service Principal [azure_service_principal].
    Credential ResolverAn appropriate MID Server script include from the lookup table. For example, Search and select the TerraformProviderCredentialResolver script.
  2. Select Submit.

    The Terraform provider credentials record is created and displayed in the Terraform Datacenter Mappings list.

  3. On the record you created, navigate to the Credentials Mappings related list, and then select New.

    1. Complete the Credential Mapping form.

      FieldDescription
      Provider Authentication KeyAuthentication key (variable) field name as used by the provider. For example, the Terraform provider block for (Amazon Web Services) AWS uses the field secret_key.
      Discovery Credential KeyThe corresponding field in the Discovery credentials from the lookup table. For example, access_key field in Terraform corresponds to Secret key field in the ServiceNow instance.
      Terraform Datacenter MappingDatacenter for which you are mapping the credentials.
    2. Select Submit.

  4. Select the Service Account Mappings tab, and then select New.

    1. Complete the Service Account Mapping form.

      FieldDescription
      Provider Authentication KeyAuthentication key (variable) field name as used by the provider. For example, the Terraform provider block for AWS uses the field secret_key.
      Service Account FieldService Account (variable) field name from the lookup table, whose credentials you are mapping to the Provider Authentication Key.
      Terraform Datacenter MappingDatacenter for which you are mapping the credentials.
    2. Select Submit.

    You have mapped the field values that you added under the Credential Mapping and Service Account Mapping related lists to the Terraform provider.

Parent Topic:Using Cloud Services Catalog Terraform Connector