1. Packages
  2. dbt Cloud Provider
  3. API Docs
  4. SemanticLayerCredentialServiceTokenMapping
dbt Cloud v1.0.2 published on Tuesday, Jun 24, 2025 by Pulumi

dbtcloud.SemanticLayerCredentialServiceTokenMapping

Explore with Pulumi AI

dbtcloud logo
dbt Cloud v1.0.2 published on Tuesday, Jun 24, 2025 by Pulumi

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as dbtcloud from "@pulumi/dbtcloud";
    
    const testMapping = new dbtcloud.SemanticLayerCredentialServiceTokenMapping("test_mapping", {
        semanticLayerCredentialId: test.id,
        serviceTokenId: testServiceToken.id,
        projectId: testProject.id,
    });
    
    import pulumi
    import pulumi_dbtcloud as dbtcloud
    
    test_mapping = dbtcloud.SemanticLayerCredentialServiceTokenMapping("test_mapping",
        semantic_layer_credential_id=test["id"],
        service_token_id=test_service_token["id"],
        project_id=test_project["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-dbtcloud/sdk/go/dbtcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dbtcloud.NewSemanticLayerCredentialServiceTokenMapping(ctx, "test_mapping", &dbtcloud.SemanticLayerCredentialServiceTokenMappingArgs{
    			SemanticLayerCredentialId: pulumi.Any(test.Id),
    			ServiceTokenId:            pulumi.Any(testServiceToken.Id),
    			ProjectId:                 pulumi.Any(testProject.Id),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using DbtCloud = Pulumi.DbtCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var testMapping = new DbtCloud.SemanticLayerCredentialServiceTokenMapping("test_mapping", new()
        {
            SemanticLayerCredentialId = test.Id,
            ServiceTokenId = testServiceToken.Id,
            ProjectId = testProject.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.dbtcloud.SemanticLayerCredentialServiceTokenMapping;
    import com.pulumi.dbtcloud.SemanticLayerCredentialServiceTokenMappingArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var testMapping = new SemanticLayerCredentialServiceTokenMapping("testMapping", SemanticLayerCredentialServiceTokenMappingArgs.builder()
                .semanticLayerCredentialId(test.id())
                .serviceTokenId(testServiceToken.id())
                .projectId(testProject.id())
                .build());
    
        }
    }
    
    resources:
      testMapping:
        type: dbtcloud:SemanticLayerCredentialServiceTokenMapping
        name: test_mapping
        properties:
          semanticLayerCredentialId: ${test.id}
          serviceTokenId: ${testServiceToken.id}
          projectId: ${testProject.id}
    

    Create SemanticLayerCredentialServiceTokenMapping Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new SemanticLayerCredentialServiceTokenMapping(name: string, args: SemanticLayerCredentialServiceTokenMappingArgs, opts?: CustomResourceOptions);
    @overload
    def SemanticLayerCredentialServiceTokenMapping(resource_name: str,
                                                   args: SemanticLayerCredentialServiceTokenMappingArgs,
                                                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def SemanticLayerCredentialServiceTokenMapping(resource_name: str,
                                                   opts: Optional[ResourceOptions] = None,
                                                   project_id: Optional[int] = None,
                                                   semantic_layer_credential_id: Optional[int] = None,
                                                   service_token_id: Optional[int] = None)
    func NewSemanticLayerCredentialServiceTokenMapping(ctx *Context, name string, args SemanticLayerCredentialServiceTokenMappingArgs, opts ...ResourceOption) (*SemanticLayerCredentialServiceTokenMapping, error)
    public SemanticLayerCredentialServiceTokenMapping(string name, SemanticLayerCredentialServiceTokenMappingArgs args, CustomResourceOptions? opts = null)
    public SemanticLayerCredentialServiceTokenMapping(String name, SemanticLayerCredentialServiceTokenMappingArgs args)
    public SemanticLayerCredentialServiceTokenMapping(String name, SemanticLayerCredentialServiceTokenMappingArgs args, CustomResourceOptions options)
    
    type: dbtcloud:SemanticLayerCredentialServiceTokenMapping
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args SemanticLayerCredentialServiceTokenMappingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args SemanticLayerCredentialServiceTokenMappingArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args SemanticLayerCredentialServiceTokenMappingArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SemanticLayerCredentialServiceTokenMappingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SemanticLayerCredentialServiceTokenMappingArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var semanticLayerCredentialServiceTokenMappingResource = new DbtCloud.SemanticLayerCredentialServiceTokenMapping("semanticLayerCredentialServiceTokenMappingResource", new()
    {
        ProjectId = 0,
        SemanticLayerCredentialId = 0,
        ServiceTokenId = 0,
    });
    
    example, err := dbtcloud.NewSemanticLayerCredentialServiceTokenMapping(ctx, "semanticLayerCredentialServiceTokenMappingResource", &dbtcloud.SemanticLayerCredentialServiceTokenMappingArgs{
    	ProjectId:                 pulumi.Int(0),
    	SemanticLayerCredentialId: pulumi.Int(0),
    	ServiceTokenId:            pulumi.Int(0),
    })
    
    var semanticLayerCredentialServiceTokenMappingResource = new SemanticLayerCredentialServiceTokenMapping("semanticLayerCredentialServiceTokenMappingResource", SemanticLayerCredentialServiceTokenMappingArgs.builder()
        .projectId(0)
        .semanticLayerCredentialId(0)
        .serviceTokenId(0)
        .build());
    
    semantic_layer_credential_service_token_mapping_resource = dbtcloud.SemanticLayerCredentialServiceTokenMapping("semanticLayerCredentialServiceTokenMappingResource",
        project_id=0,
        semantic_layer_credential_id=0,
        service_token_id=0)
    
    const semanticLayerCredentialServiceTokenMappingResource = new dbtcloud.SemanticLayerCredentialServiceTokenMapping("semanticLayerCredentialServiceTokenMappingResource", {
        projectId: 0,
        semanticLayerCredentialId: 0,
        serviceTokenId: 0,
    });
    
    type: dbtcloud:SemanticLayerCredentialServiceTokenMapping
    properties:
        projectId: 0
        semanticLayerCredentialId: 0
        serviceTokenId: 0
    

    SemanticLayerCredentialServiceTokenMapping Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The SemanticLayerCredentialServiceTokenMapping resource accepts the following input properties:

    ProjectId int
    The ID of the project to which the semantic layer credential is associated.
    SemanticLayerCredentialId int
    The ID of the semantic layer credential to map.
    ServiceTokenId int
    The ID of the service token to map to the semantic layer credential.
    ProjectId int
    The ID of the project to which the semantic layer credential is associated.
    SemanticLayerCredentialId int
    The ID of the semantic layer credential to map.
    ServiceTokenId int
    The ID of the service token to map to the semantic layer credential.
    projectId Integer
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId Integer
    The ID of the semantic layer credential to map.
    serviceTokenId Integer
    The ID of the service token to map to the semantic layer credential.
    projectId number
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId number
    The ID of the semantic layer credential to map.
    serviceTokenId number
    The ID of the service token to map to the semantic layer credential.
    project_id int
    The ID of the project to which the semantic layer credential is associated.
    semantic_layer_credential_id int
    The ID of the semantic layer credential to map.
    service_token_id int
    The ID of the service token to map to the semantic layer credential.
    projectId Number
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId Number
    The ID of the semantic layer credential to map.
    serviceTokenId Number
    The ID of the service token to map to the semantic layer credential.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the SemanticLayerCredentialServiceTokenMapping resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing SemanticLayerCredentialServiceTokenMapping Resource

    Get an existing SemanticLayerCredentialServiceTokenMapping resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: SemanticLayerCredentialServiceTokenMappingState, opts?: CustomResourceOptions): SemanticLayerCredentialServiceTokenMapping
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            project_id: Optional[int] = None,
            semantic_layer_credential_id: Optional[int] = None,
            service_token_id: Optional[int] = None) -> SemanticLayerCredentialServiceTokenMapping
    func GetSemanticLayerCredentialServiceTokenMapping(ctx *Context, name string, id IDInput, state *SemanticLayerCredentialServiceTokenMappingState, opts ...ResourceOption) (*SemanticLayerCredentialServiceTokenMapping, error)
    public static SemanticLayerCredentialServiceTokenMapping Get(string name, Input<string> id, SemanticLayerCredentialServiceTokenMappingState? state, CustomResourceOptions? opts = null)
    public static SemanticLayerCredentialServiceTokenMapping get(String name, Output<String> id, SemanticLayerCredentialServiceTokenMappingState state, CustomResourceOptions options)
    resources:  _:    type: dbtcloud:SemanticLayerCredentialServiceTokenMapping    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    ProjectId int
    The ID of the project to which the semantic layer credential is associated.
    SemanticLayerCredentialId int
    The ID of the semantic layer credential to map.
    ServiceTokenId int
    The ID of the service token to map to the semantic layer credential.
    ProjectId int
    The ID of the project to which the semantic layer credential is associated.
    SemanticLayerCredentialId int
    The ID of the semantic layer credential to map.
    ServiceTokenId int
    The ID of the service token to map to the semantic layer credential.
    projectId Integer
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId Integer
    The ID of the semantic layer credential to map.
    serviceTokenId Integer
    The ID of the service token to map to the semantic layer credential.
    projectId number
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId number
    The ID of the semantic layer credential to map.
    serviceTokenId number
    The ID of the service token to map to the semantic layer credential.
    project_id int
    The ID of the project to which the semantic layer credential is associated.
    semantic_layer_credential_id int
    The ID of the semantic layer credential to map.
    service_token_id int
    The ID of the service token to map to the semantic layer credential.
    projectId Number
    The ID of the project to which the semantic layer credential is associated.
    semanticLayerCredentialId Number
    The ID of the semantic layer credential to map.
    serviceTokenId Number
    The ID of the service token to map to the semantic layer credential.

    Import

    using import blocks (requires Terraform >= 1.5)

    import {

    to = dbtcloud_semantic_layer_credential_service_token_mapping.example

    id = “id”

    }

    import {

    to = dbtcloud_semantic_layer_credential_service_token_mapping.example

    id = “12345”

    }

    using the older import command

    $ pulumi import dbtcloud:index/semanticLayerCredentialServiceTokenMapping:SemanticLayerCredentialServiceTokenMapping example "id"
    
    $ pulumi import dbtcloud:index/semanticLayerCredentialServiceTokenMapping:SemanticLayerCredentialServiceTokenMapping example 12345
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    dbtcloud pulumi/pulumi-dbtcloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the dbtcloud Terraform Provider.
    dbtcloud logo
    dbt Cloud v1.0.2 published on Tuesday, Jun 24, 2025 by Pulumi