1. Packages
  2. stackit
  3. API Docs
  4. ModelservingToken
Viewing docs for stackit v0.0.4
published on Friday, Feb 20, 2026 by stackitcloud
stackit logo
Viewing docs for stackit v0.0.4
published on Friday, Feb 20, 2026 by stackitcloud

    AI Model Serving Auth Token Resource schema.

    Example Usage

    Automatically rotate AI model serving token

    resource "time_rotating" "rotate" {
        rotation_days = 80
    }
    
    resource "stackit_modelserving_token" "example" {
        project_id = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
        name       = "Example token"
        
        rotate_when_changed = {
            rotation = time_rotating.rotate.id
        }
    
    }
    

    Create ModelservingToken Resource

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

    Constructor syntax

    new ModelservingToken(name: string, args: ModelservingTokenArgs, opts?: CustomResourceOptions);
    @overload
    def ModelservingToken(resource_name: str,
                          args: ModelservingTokenArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def ModelservingToken(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          project_id: Optional[str] = None,
                          description: Optional[str] = None,
                          name: Optional[str] = None,
                          region: Optional[str] = None,
                          rotate_when_changed: Optional[Mapping[str, str]] = None,
                          ttl_duration: Optional[str] = None)
    func NewModelservingToken(ctx *Context, name string, args ModelservingTokenArgs, opts ...ResourceOption) (*ModelservingToken, error)
    public ModelservingToken(string name, ModelservingTokenArgs args, CustomResourceOptions? opts = null)
    public ModelservingToken(String name, ModelservingTokenArgs args)
    public ModelservingToken(String name, ModelservingTokenArgs args, CustomResourceOptions options)
    
    type: stackit:ModelservingToken
    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 ModelservingTokenArgs
    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 ModelservingTokenArgs
    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 ModelservingTokenArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ModelservingTokenArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ModelservingTokenArgs
    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 modelservingTokenResource = new Stackit.ModelservingToken("modelservingTokenResource", new()
    {
        ProjectId = "string",
        Description = "string",
        Name = "string",
        Region = "string",
        RotateWhenChanged = 
        {
            { "string", "string" },
        },
        TtlDuration = "string",
    });
    
    example, err := stackit.NewModelservingToken(ctx, "modelservingTokenResource", &stackit.ModelservingTokenArgs{
    	ProjectId:   pulumi.String("string"),
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    	Region:      pulumi.String("string"),
    	RotateWhenChanged: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	TtlDuration: pulumi.String("string"),
    })
    
    var modelservingTokenResource = new ModelservingToken("modelservingTokenResource", ModelservingTokenArgs.builder()
        .projectId("string")
        .description("string")
        .name("string")
        .region("string")
        .rotateWhenChanged(Map.of("string", "string"))
        .ttlDuration("string")
        .build());
    
    modelserving_token_resource = stackit.ModelservingToken("modelservingTokenResource",
        project_id="string",
        description="string",
        name="string",
        region="string",
        rotate_when_changed={
            "string": "string",
        },
        ttl_duration="string")
    
    const modelservingTokenResource = new stackit.ModelservingToken("modelservingTokenResource", {
        projectId: "string",
        description: "string",
        name: "string",
        region: "string",
        rotateWhenChanged: {
            string: "string",
        },
        ttlDuration: "string",
    });
    
    type: stackit:ModelservingToken
    properties:
        description: string
        name: string
        projectId: string
        region: string
        rotateWhenChanged:
            string: string
        ttlDuration: string
    

    ModelservingToken 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 ModelservingToken resource accepts the following input properties:

    ProjectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    Description string
    The description of the AI model serving auth token.
    Name string
    Name of the AI model serving auth token.
    Region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    RotateWhenChanged Dictionary<string, string>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    TtlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    ProjectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    Description string
    The description of the AI model serving auth token.
    Name string
    Name of the AI model serving auth token.
    Region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    RotateWhenChanged map[string]string
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    TtlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    projectId String
    STACKIT project ID to which the AI model serving auth token is associated.
    description String
    The description of the AI model serving auth token.
    name String
    Name of the AI model serving auth token.
    region String
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged Map<String,String>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    ttlDuration String
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    projectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    description string
    The description of the AI model serving auth token.
    name string
    Name of the AI model serving auth token.
    region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged {[key: string]: string}
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    ttlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    project_id str
    STACKIT project ID to which the AI model serving auth token is associated.
    description str
    The description of the AI model serving auth token.
    name str
    Name of the AI model serving auth token.
    region str
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotate_when_changed Mapping[str, str]
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    ttl_duration str
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    projectId String
    STACKIT project ID to which the AI model serving auth token is associated.
    description String
    The description of the AI model serving auth token.
    name String
    Name of the AI model serving auth token.
    region String
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged Map<String>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    ttlDuration String
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    State of the AI model serving auth token.
    Token string
    Content of the AI model serving auth token.
    TokenId string
    The AI model serving auth token ID.
    ValidUntil string
    The time until the AI model serving auth token is valid.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    State of the AI model serving auth token.
    Token string
    Content of the AI model serving auth token.
    TokenId string
    The AI model serving auth token ID.
    ValidUntil string
    The time until the AI model serving auth token is valid.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    State of the AI model serving auth token.
    token String
    Content of the AI model serving auth token.
    tokenId String
    The AI model serving auth token ID.
    validUntil String
    The time until the AI model serving auth token is valid.
    id string
    The provider-assigned unique ID for this managed resource.
    state string
    State of the AI model serving auth token.
    token string
    Content of the AI model serving auth token.
    tokenId string
    The AI model serving auth token ID.
    validUntil string
    The time until the AI model serving auth token is valid.
    id str
    The provider-assigned unique ID for this managed resource.
    state str
    State of the AI model serving auth token.
    token str
    Content of the AI model serving auth token.
    token_id str
    The AI model serving auth token ID.
    valid_until str
    The time until the AI model serving auth token is valid.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    State of the AI model serving auth token.
    token String
    Content of the AI model serving auth token.
    tokenId String
    The AI model serving auth token ID.
    validUntil String
    The time until the AI model serving auth token is valid.

    Look up Existing ModelservingToken Resource

    Get an existing ModelservingToken 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?: ModelservingTokenState, opts?: CustomResourceOptions): ModelservingToken
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            project_id: Optional[str] = None,
            region: Optional[str] = None,
            rotate_when_changed: Optional[Mapping[str, str]] = None,
            state: Optional[str] = None,
            token: Optional[str] = None,
            token_id: Optional[str] = None,
            ttl_duration: Optional[str] = None,
            valid_until: Optional[str] = None) -> ModelservingToken
    func GetModelservingToken(ctx *Context, name string, id IDInput, state *ModelservingTokenState, opts ...ResourceOption) (*ModelservingToken, error)
    public static ModelservingToken Get(string name, Input<string> id, ModelservingTokenState? state, CustomResourceOptions? opts = null)
    public static ModelservingToken get(String name, Output<String> id, ModelservingTokenState state, CustomResourceOptions options)
    resources:  _:    type: stackit:ModelservingToken    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:
    Description string
    The description of the AI model serving auth token.
    Name string
    Name of the AI model serving auth token.
    ProjectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    Region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    RotateWhenChanged Dictionary<string, string>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    State string
    State of the AI model serving auth token.
    Token string
    Content of the AI model serving auth token.
    TokenId string
    The AI model serving auth token ID.
    TtlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    ValidUntil string
    The time until the AI model serving auth token is valid.
    Description string
    The description of the AI model serving auth token.
    Name string
    Name of the AI model serving auth token.
    ProjectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    Region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    RotateWhenChanged map[string]string
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    State string
    State of the AI model serving auth token.
    Token string
    Content of the AI model serving auth token.
    TokenId string
    The AI model serving auth token ID.
    TtlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    ValidUntil string
    The time until the AI model serving auth token is valid.
    description String
    The description of the AI model serving auth token.
    name String
    Name of the AI model serving auth token.
    projectId String
    STACKIT project ID to which the AI model serving auth token is associated.
    region String
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged Map<String,String>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    state String
    State of the AI model serving auth token.
    token String
    Content of the AI model serving auth token.
    tokenId String
    The AI model serving auth token ID.
    ttlDuration String
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    validUntil String
    The time until the AI model serving auth token is valid.
    description string
    The description of the AI model serving auth token.
    name string
    Name of the AI model serving auth token.
    projectId string
    STACKIT project ID to which the AI model serving auth token is associated.
    region string
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged {[key: string]: string}
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    state string
    State of the AI model serving auth token.
    token string
    Content of the AI model serving auth token.
    tokenId string
    The AI model serving auth token ID.
    ttlDuration string
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    validUntil string
    The time until the AI model serving auth token is valid.
    description str
    The description of the AI model serving auth token.
    name str
    Name of the AI model serving auth token.
    project_id str
    STACKIT project ID to which the AI model serving auth token is associated.
    region str
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotate_when_changed Mapping[str, str]
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    state str
    State of the AI model serving auth token.
    token str
    Content of the AI model serving auth token.
    token_id str
    The AI model serving auth token ID.
    ttl_duration str
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    valid_until str
    The time until the AI model serving auth token is valid.
    description String
    The description of the AI model serving auth token.
    name String
    Name of the AI model serving auth token.
    projectId String
    STACKIT project ID to which the AI model serving auth token is associated.
    region String
    Region to which the AI model serving auth token is associated. If not defined, the provider region is used
    rotateWhenChanged Map<String>
    A map of arbitrary key/value pairs that will force recreation of the token when they change, enabling token rotation based on external conditions such as a rotating timestamp. Changing this forces a new resource to be created.
    state String
    State of the AI model serving auth token.
    token String
    Content of the AI model serving auth token.
    tokenId String
    The AI model serving auth token ID.
    ttlDuration String
    The TTL duration of the AI model serving auth token. E.g. 5h30m40s,5h,5h30m,30m,30s
    validUntil String
    The time until the AI model serving auth token is valid.

    Package Details

    Repository
    stackit stackitcloud/pulumi-stackit
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the stackit Terraform Provider.
    stackit logo
    Viewing docs for stackit v0.0.4
    published on Friday, Feb 20, 2026 by stackitcloud
      Try Pulumi Cloud free. Your team will thank you.