1. Packages
  2. Impart Security
  3. API Docs
  4. Spec
Viewing docs for Impart Security v0.11.3
published on Wednesday, Mar 18, 2026 by Impart Security
impart logo
Viewing docs for Impart Security v0.11.3
published on Wednesday, Mar 18, 2026 by Impart Security

    Manage a specification.

    Create Spec Resource

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

    Constructor syntax

    new Spec(name: string, args: SpecArgs, opts?: CustomResourceOptions);
    @overload
    def Spec(resource_name: str,
             args: SpecArgs,
             opts: Optional[ResourceOptions] = None)
    
    @overload
    def Spec(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             name: Optional[str] = None,
             source_file: Optional[str] = None,
             learning_config: Optional[SpecLearningConfigArgs] = None,
             source_hash: Optional[str] = None)
    func NewSpec(ctx *Context, name string, args SpecArgs, opts ...ResourceOption) (*Spec, error)
    public Spec(string name, SpecArgs args, CustomResourceOptions? opts = null)
    public Spec(String name, SpecArgs args)
    public Spec(String name, SpecArgs args, CustomResourceOptions options)
    
    type: impart:Spec
    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 SpecArgs
    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 SpecArgs
    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 SpecArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SpecArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SpecArgs
    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 specResource = new Impart.Index.Spec("specResource", new()
    {
        Name = "string",
        SourceFile = "string",
        LearningConfig = new Impart.Inputs.SpecLearningConfigArgs
        {
            LearningMode = "string",
            IncludeQueryParams = false,
            IncludeRequestBody = false,
            IncludeRequestHeaders = false,
            IncludeResponseBody = false,
            IncludeResponseHeaders = false,
        },
        SourceHash = "string",
    });
    
    example, err := impart.NewSpec(ctx, "specResource", &impart.SpecArgs{
    	Name:       pulumi.String("string"),
    	SourceFile: pulumi.String("string"),
    	LearningConfig: &impart.SpecLearningConfigArgs{
    		LearningMode:           pulumi.String("string"),
    		IncludeQueryParams:     pulumi.Bool(false),
    		IncludeRequestBody:     pulumi.Bool(false),
    		IncludeRequestHeaders:  pulumi.Bool(false),
    		IncludeResponseBody:    pulumi.Bool(false),
    		IncludeResponseHeaders: pulumi.Bool(false),
    	},
    	SourceHash: pulumi.String("string"),
    })
    
    var specResource = new Spec("specResource", SpecArgs.builder()
        .name("string")
        .sourceFile("string")
        .learningConfig(SpecLearningConfigArgs.builder()
            .learningMode("string")
            .includeQueryParams(false)
            .includeRequestBody(false)
            .includeRequestHeaders(false)
            .includeResponseBody(false)
            .includeResponseHeaders(false)
            .build())
        .sourceHash("string")
        .build());
    
    spec_resource = impart.Spec("specResource",
        name="string",
        source_file="string",
        learning_config={
            "learning_mode": "string",
            "include_query_params": False,
            "include_request_body": False,
            "include_request_headers": False,
            "include_response_body": False,
            "include_response_headers": False,
        },
        source_hash="string")
    
    const specResource = new impart.Spec("specResource", {
        name: "string",
        sourceFile: "string",
        learningConfig: {
            learningMode: "string",
            includeQueryParams: false,
            includeRequestBody: false,
            includeRequestHeaders: false,
            includeResponseBody: false,
            includeResponseHeaders: false,
        },
        sourceHash: "string",
    });
    
    type: impart:Spec
    properties:
        learningConfig:
            includeQueryParams: false
            includeRequestBody: false
            includeRequestHeaders: false
            includeResponseBody: false
            includeResponseHeaders: false
            learningMode: string
        name: string
        sourceFile: string
        sourceHash: string
    

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

    Name string
    The name for this specification.
    SourceFile string
    The specification file.
    LearningConfig SpecLearningConfig
    Configuration for spec learning.
    SourceHash string
    The specification source hash.
    Name string
    The name for this specification.
    SourceFile string
    The specification file.
    LearningConfig SpecLearningConfigArgs
    Configuration for spec learning.
    SourceHash string
    The specification source hash.
    name String
    The name for this specification.
    sourceFile String
    The specification file.
    learningConfig SpecLearningConfig
    Configuration for spec learning.
    sourceHash String
    The specification source hash.
    name string
    The name for this specification.
    sourceFile string
    The specification file.
    learningConfig SpecLearningConfig
    Configuration for spec learning.
    sourceHash string
    The specification source hash.
    name str
    The name for this specification.
    source_file str
    The specification file.
    learning_config SpecLearningConfigArgs
    Configuration for spec learning.
    source_hash str
    The specification source hash.
    name String
    The name for this specification.
    sourceFile String
    The specification file.
    learningConfig Property Map
    Configuration for spec learning.
    sourceHash String
    The specification source hash.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Spec 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 Spec Resource

    Get an existing Spec 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?: SpecState, opts?: CustomResourceOptions): Spec
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            learning_config: Optional[SpecLearningConfigArgs] = None,
            name: Optional[str] = None,
            source_file: Optional[str] = None,
            source_hash: Optional[str] = None) -> Spec
    func GetSpec(ctx *Context, name string, id IDInput, state *SpecState, opts ...ResourceOption) (*Spec, error)
    public static Spec Get(string name, Input<string> id, SpecState? state, CustomResourceOptions? opts = null)
    public static Spec get(String name, Output<String> id, SpecState state, CustomResourceOptions options)
    resources:  _:    type: impart:Spec    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:
    LearningConfig SpecLearningConfig
    Configuration for spec learning.
    Name string
    The name for this specification.
    SourceFile string
    The specification file.
    SourceHash string
    The specification source hash.
    LearningConfig SpecLearningConfigArgs
    Configuration for spec learning.
    Name string
    The name for this specification.
    SourceFile string
    The specification file.
    SourceHash string
    The specification source hash.
    learningConfig SpecLearningConfig
    Configuration for spec learning.
    name String
    The name for this specification.
    sourceFile String
    The specification file.
    sourceHash String
    The specification source hash.
    learningConfig SpecLearningConfig
    Configuration for spec learning.
    name string
    The name for this specification.
    sourceFile string
    The specification file.
    sourceHash string
    The specification source hash.
    learning_config SpecLearningConfigArgs
    Configuration for spec learning.
    name str
    The name for this specification.
    source_file str
    The specification file.
    source_hash str
    The specification source hash.
    learningConfig Property Map
    Configuration for spec learning.
    name String
    The name for this specification.
    sourceFile String
    The specification file.
    sourceHash String
    The specification source hash.

    Supporting Types

    SpecLearningConfig, SpecLearningConfigArgs

    LearningMode string
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    IncludeQueryParams bool
    Include query parameters during spec learning.
    IncludeRequestBody bool
    Include request body during spec learning.
    IncludeRequestHeaders bool
    Include request headers during spec learning.
    IncludeResponseBody bool
    Include response body during spec learning.
    IncludeResponseHeaders bool
    Include response headers during spec learning.
    LearningMode string
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    IncludeQueryParams bool
    Include query parameters during spec learning.
    IncludeRequestBody bool
    Include request body during spec learning.
    IncludeRequestHeaders bool
    Include request headers during spec learning.
    IncludeResponseBody bool
    Include response body during spec learning.
    IncludeResponseHeaders bool
    Include response headers during spec learning.
    learningMode String
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    includeQueryParams Boolean
    Include query parameters during spec learning.
    includeRequestBody Boolean
    Include request body during spec learning.
    includeRequestHeaders Boolean
    Include request headers during spec learning.
    includeResponseBody Boolean
    Include response body during spec learning.
    includeResponseHeaders Boolean
    Include response headers during spec learning.
    learningMode string
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    includeQueryParams boolean
    Include query parameters during spec learning.
    includeRequestBody boolean
    Include request body during spec learning.
    includeRequestHeaders boolean
    Include request headers during spec learning.
    includeResponseBody boolean
    Include response body during spec learning.
    includeResponseHeaders boolean
    Include response headers during spec learning.
    learning_mode str
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    include_query_params bool
    Include query parameters during spec learning.
    include_request_body bool
    Include request body during spec learning.
    include_request_headers bool
    Include request headers during spec learning.
    include_response_body bool
    Include response body during spec learning.
    include_response_headers bool
    Include response headers during spec learning.
    learningMode String
    Spec learning mode configuration options. Valid values: all, pathsonly, pathscustom. Note: When using 'all' or 'paths*only' modes, the include** flags will be preserved in state but are not applicable as the mode overrides these settings.
    includeQueryParams Boolean
    Include query parameters during spec learning.
    includeRequestBody Boolean
    Include request body during spec learning.
    includeRequestHeaders Boolean
    Include request headers during spec learning.
    includeResponseBody Boolean
    Include response body during spec learning.
    includeResponseHeaders Boolean
    Include response headers during spec learning.

    Import

    The pulumi import command can be used, for example:

    !/bin/bash

    $ pulumi import impart:index/spec:Spec example "<id>"
    

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

    Package Details

    Repository
    impart impart-security/pulumi-impart
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the impart Terraform Provider.
    impart logo
    Viewing docs for Impart Security v0.11.3
    published on Wednesday, Mar 18, 2026 by Impart Security
      Try Pulumi Cloud free. Your team will thank you.