1. Packages
  2. Redpanda Provider
  3. API Docs
  4. Schema
redpanda 1.2.1 published on Wednesday, Sep 10, 2025 by redpanda-data

redpanda.Schema

Explore with Pulumi AI

redpanda logo
redpanda 1.2.1 published on Wednesday, Sep 10, 2025 by redpanda-data

    Schema represents a Schema Registry schema

    Create Schema Resource

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

    Constructor syntax

    new Schema(name: string, args: SchemaArgs, opts?: CustomResourceOptions);
    @overload
    def Schema(resource_name: str,
               args: SchemaArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Schema(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               cluster_id: Optional[str] = None,
               password: Optional[str] = None,
               schema: Optional[str] = None,
               subject: Optional[str] = None,
               username: Optional[str] = None,
               allow_deletion: Optional[bool] = None,
               compatibility: Optional[str] = None,
               references: Optional[Sequence[SchemaReferenceArgs]] = None,
               schema_type: Optional[str] = None)
    func NewSchema(ctx *Context, name string, args SchemaArgs, opts ...ResourceOption) (*Schema, error)
    public Schema(string name, SchemaArgs args, CustomResourceOptions? opts = null)
    public Schema(String name, SchemaArgs args)
    public Schema(String name, SchemaArgs args, CustomResourceOptions options)
    
    type: redpanda:Schema
    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 SchemaArgs
    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 SchemaArgs
    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 SchemaArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SchemaArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SchemaArgs
    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 schemaResource = new Redpanda.Schema("schemaResource", new()
    {
        ClusterId = "string",
        Password = "string",
        Schema = "string",
        Subject = "string",
        Username = "string",
        AllowDeletion = false,
        Compatibility = "string",
        References = new[]
        {
            new Redpanda.Inputs.SchemaReferenceArgs
            {
                Name = "string",
                Subject = "string",
                Version = 0,
            },
        },
        SchemaType = "string",
    });
    
    example, err := redpanda.NewSchema(ctx, "schemaResource", &redpanda.SchemaArgs{
    	ClusterId:     pulumi.String("string"),
    	Password:      pulumi.String("string"),
    	Schema:        pulumi.String("string"),
    	Subject:       pulumi.String("string"),
    	Username:      pulumi.String("string"),
    	AllowDeletion: pulumi.Bool(false),
    	Compatibility: pulumi.String("string"),
    	References: redpanda.SchemaReferenceArray{
    		&redpanda.SchemaReferenceArgs{
    			Name:    pulumi.String("string"),
    			Subject: pulumi.String("string"),
    			Version: pulumi.Float64(0),
    		},
    	},
    	SchemaType: pulumi.String("string"),
    })
    
    var schemaResource = new Schema("schemaResource", SchemaArgs.builder()
        .clusterId("string")
        .password("string")
        .schema("string")
        .subject("string")
        .username("string")
        .allowDeletion(false)
        .compatibility("string")
        .references(SchemaReferenceArgs.builder()
            .name("string")
            .subject("string")
            .version(0.0)
            .build())
        .schemaType("string")
        .build());
    
    schema_resource = redpanda.Schema("schemaResource",
        cluster_id="string",
        password="string",
        schema="string",
        subject="string",
        username="string",
        allow_deletion=False,
        compatibility="string",
        references=[{
            "name": "string",
            "subject": "string",
            "version": 0,
        }],
        schema_type="string")
    
    const schemaResource = new redpanda.Schema("schemaResource", {
        clusterId: "string",
        password: "string",
        schema: "string",
        subject: "string",
        username: "string",
        allowDeletion: false,
        compatibility: "string",
        references: [{
            name: "string",
            subject: "string",
            version: 0,
        }],
        schemaType: "string",
    });
    
    type: redpanda:Schema
    properties:
        allowDeletion: false
        clusterId: string
        compatibility: string
        password: string
        references:
            - name: string
              subject: string
              version: 0
        schema: string
        schemaType: string
        subject: string
        username: string
    

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

    ClusterId string
    The ID of the cluster where the schema is stored.
    Password string
    The SASL password for Schema Registry authentication.
    Schema string
    The schema definition in JSON format.
    Subject string
    The subject name for the schema.
    Username string
    The SASL username for Schema Registry authentication.
    AllowDeletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    Compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    References List<SchemaReference>
    List of schema references.
    SchemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    ClusterId string
    The ID of the cluster where the schema is stored.
    Password string
    The SASL password for Schema Registry authentication.
    Schema string
    The schema definition in JSON format.
    Subject string
    The subject name for the schema.
    Username string
    The SASL username for Schema Registry authentication.
    AllowDeletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    Compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    References []SchemaReferenceArgs
    List of schema references.
    SchemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    clusterId String
    The ID of the cluster where the schema is stored.
    password String
    The SASL password for Schema Registry authentication.
    schema String
    The schema definition in JSON format.
    subject String
    The subject name for the schema.
    username String
    The SASL username for Schema Registry authentication.
    allowDeletion Boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    compatibility String
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    references List<SchemaReference>
    List of schema references.
    schemaType String
    The type of schema (AVRO, JSON, PROTOBUF).
    clusterId string
    The ID of the cluster where the schema is stored.
    password string
    The SASL password for Schema Registry authentication.
    schema string
    The schema definition in JSON format.
    subject string
    The subject name for the schema.
    username string
    The SASL username for Schema Registry authentication.
    allowDeletion boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    references SchemaReference[]
    List of schema references.
    schemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    cluster_id str
    The ID of the cluster where the schema is stored.
    password str
    The SASL password for Schema Registry authentication.
    schema str
    The schema definition in JSON format.
    subject str
    The subject name for the schema.
    username str
    The SASL username for Schema Registry authentication.
    allow_deletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    compatibility str
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    references Sequence[SchemaReferenceArgs]
    List of schema references.
    schema_type str
    The type of schema (AVRO, JSON, PROTOBUF).
    clusterId String
    The ID of the cluster where the schema is stored.
    password String
    The SASL password for Schema Registry authentication.
    schema String
    The schema definition in JSON format.
    subject String
    The subject name for the schema.
    username String
    The SASL username for Schema Registry authentication.
    allowDeletion Boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    compatibility String
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    references List<Property Map>
    List of schema references.
    schemaType String
    The type of schema (AVRO, JSON, PROTOBUF).

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    SchemaId double
    The unique identifier for the schema.
    Version double
    The version of the schema.
    Id string
    The provider-assigned unique ID for this managed resource.
    SchemaId float64
    The unique identifier for the schema.
    Version float64
    The version of the schema.
    id String
    The provider-assigned unique ID for this managed resource.
    schemaId Double
    The unique identifier for the schema.
    version Double
    The version of the schema.
    id string
    The provider-assigned unique ID for this managed resource.
    schemaId number
    The unique identifier for the schema.
    version number
    The version of the schema.
    id str
    The provider-assigned unique ID for this managed resource.
    schema_id float
    The unique identifier for the schema.
    version float
    The version of the schema.
    id String
    The provider-assigned unique ID for this managed resource.
    schemaId Number
    The unique identifier for the schema.
    version Number
    The version of the schema.

    Look up Existing Schema Resource

    Get an existing Schema 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?: SchemaState, opts?: CustomResourceOptions): Schema
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            allow_deletion: Optional[bool] = None,
            cluster_id: Optional[str] = None,
            compatibility: Optional[str] = None,
            password: Optional[str] = None,
            references: Optional[Sequence[SchemaReferenceArgs]] = None,
            schema: Optional[str] = None,
            schema_id: Optional[float] = None,
            schema_type: Optional[str] = None,
            subject: Optional[str] = None,
            username: Optional[str] = None,
            version: Optional[float] = None) -> Schema
    func GetSchema(ctx *Context, name string, id IDInput, state *SchemaState, opts ...ResourceOption) (*Schema, error)
    public static Schema Get(string name, Input<string> id, SchemaState? state, CustomResourceOptions? opts = null)
    public static Schema get(String name, Output<String> id, SchemaState state, CustomResourceOptions options)
    resources:  _:    type: redpanda:Schema    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:
    AllowDeletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    ClusterId string
    The ID of the cluster where the schema is stored.
    Compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    Password string
    The SASL password for Schema Registry authentication.
    References List<SchemaReference>
    List of schema references.
    Schema string
    The schema definition in JSON format.
    SchemaId double
    The unique identifier for the schema.
    SchemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    Subject string
    The subject name for the schema.
    Username string
    The SASL username for Schema Registry authentication.
    Version double
    The version of the schema.
    AllowDeletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    ClusterId string
    The ID of the cluster where the schema is stored.
    Compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    Password string
    The SASL password for Schema Registry authentication.
    References []SchemaReferenceArgs
    List of schema references.
    Schema string
    The schema definition in JSON format.
    SchemaId float64
    The unique identifier for the schema.
    SchemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    Subject string
    The subject name for the schema.
    Username string
    The SASL username for Schema Registry authentication.
    Version float64
    The version of the schema.
    allowDeletion Boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    clusterId String
    The ID of the cluster where the schema is stored.
    compatibility String
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    password String
    The SASL password for Schema Registry authentication.
    references List<SchemaReference>
    List of schema references.
    schema String
    The schema definition in JSON format.
    schemaId Double
    The unique identifier for the schema.
    schemaType String
    The type of schema (AVRO, JSON, PROTOBUF).
    subject String
    The subject name for the schema.
    username String
    The SASL username for Schema Registry authentication.
    version Double
    The version of the schema.
    allowDeletion boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    clusterId string
    The ID of the cluster where the schema is stored.
    compatibility string
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    password string
    The SASL password for Schema Registry authentication.
    references SchemaReference[]
    List of schema references.
    schema string
    The schema definition in JSON format.
    schemaId number
    The unique identifier for the schema.
    schemaType string
    The type of schema (AVRO, JSON, PROTOBUF).
    subject string
    The subject name for the schema.
    username string
    The SASL username for Schema Registry authentication.
    version number
    The version of the schema.
    allow_deletion bool
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    cluster_id str
    The ID of the cluster where the schema is stored.
    compatibility str
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    password str
    The SASL password for Schema Registry authentication.
    references Sequence[SchemaReferenceArgs]
    List of schema references.
    schema str
    The schema definition in JSON format.
    schema_id float
    The unique identifier for the schema.
    schema_type str
    The type of schema (AVRO, JSON, PROTOBUF).
    subject str
    The subject name for the schema.
    username str
    The SASL username for Schema Registry authentication.
    version float
    The version of the schema.
    allowDeletion Boolean
    When enabled, prevents the resource from being deleted if the cluster is unreachable. When disabled (default), the resource will be removed from state without attempting deletion when the cluster is unreachable.
    clusterId String
    The ID of the cluster where the schema is stored.
    compatibility String
    The compatibility level for schema evolution (BACKWARD, BACKWARDTRANSITIVE, FORWARD, FORWARDTRANSITIVE, FULL, FULL_TRANSITIVE, NONE). Defaults to BACKWARD.
    password String
    The SASL password for Schema Registry authentication.
    references List<Property Map>
    List of schema references.
    schema String
    The schema definition in JSON format.
    schemaId Number
    The unique identifier for the schema.
    schemaType String
    The type of schema (AVRO, JSON, PROTOBUF).
    subject String
    The subject name for the schema.
    username String
    The SASL username for Schema Registry authentication.
    version Number
    The version of the schema.

    Supporting Types

    SchemaReference, SchemaReferenceArgs

    Name string
    The name of the referenced schema.
    Subject string
    The subject of the referenced schema.
    Version double
    The version of the referenced schema.
    Name string
    The name of the referenced schema.
    Subject string
    The subject of the referenced schema.
    Version float64
    The version of the referenced schema.
    name String
    The name of the referenced schema.
    subject String
    The subject of the referenced schema.
    version Double
    The version of the referenced schema.
    name string
    The name of the referenced schema.
    subject string
    The subject of the referenced schema.
    version number
    The version of the referenced schema.
    name str
    The name of the referenced schema.
    subject str
    The subject of the referenced schema.
    version float
    The version of the referenced schema.
    name String
    The name of the referenced schema.
    subject String
    The subject of the referenced schema.
    version Number
    The version of the referenced schema.

    Package Details

    Repository
    redpanda redpanda-data/terraform-provider-redpanda
    License
    Notes
    This Pulumi package is based on the redpanda Terraform Provider.
    redpanda logo
    redpanda 1.2.1 published on Wednesday, Sep 10, 2025 by redpanda-data