published on Sunday, Oct 11, 2026 by Descope
published on Sunday, Oct 11, 2026 by Descope
Manages the FGA (fine-grained authorization) schema for a Descope project as a single DSL string. Setting an empty schema, or destroying the resource, clears the project’s FGA schema (which also removes any FGA relations that depend on it).
Create FgaSchema Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new FgaSchema(name: string, args: FgaSchemaArgs, opts?: CustomResourceOptions);@overload
def FgaSchema(resource_name: str,
args: FgaSchemaArgs,
opts: Optional[ResourceOptions] = None)
@overload
def FgaSchema(resource_name: str,
opts: Optional[ResourceOptions] = None,
project_id: Optional[str] = None,
schema: Optional[str] = None)func NewFgaSchema(ctx *Context, name string, args FgaSchemaArgs, opts ...ResourceOption) (*FgaSchema, error)public FgaSchema(string name, FgaSchemaArgs args, CustomResourceOptions? opts = null)
public FgaSchema(String name, FgaSchemaArgs args)
public FgaSchema(String name, FgaSchemaArgs args, CustomResourceOptions options)
type: descope:FgaSchema
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "descope_fga_schema" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args FgaSchemaArgs
- 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 FgaSchemaArgs
- 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 FgaSchemaArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FgaSchemaArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args FgaSchemaArgs
- 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 fgaSchemaResource = new Descope.FgaSchema("fgaSchemaResource", new()
{
ProjectId = "string",
Schema = "string",
});
example, err := descope.NewFgaSchema(ctx, "fgaSchemaResource", &descope.FgaSchemaArgs{
ProjectId: pulumi.String("string"),
Schema: pulumi.String("string"),
})
resource "descope_fga_schema" "fgaSchemaResource" {
lifecycle {
create_before_destroy = true
}
project_id = "string"
schema = "string"
}
var fgaSchemaResource = new FgaSchema("fgaSchemaResource", FgaSchemaArgs.builder()
.projectId("string")
.schema("string")
.build());
fga_schema_resource = descope.FgaSchema("fgaSchemaResource",
project_id="string",
schema="string")
const fgaSchemaResource = new descope.FgaSchema("fgaSchemaResource", {
projectId: "string",
schema: "string",
});
type: descope:FgaSchema
properties:
projectId: string
schema: string
FgaSchema 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 FgaSchema resource accepts the following input properties:
- Project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- Schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- Project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- Schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project_
id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id String - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema String
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project_
id str - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema str
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id String - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema String
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
Outputs
All input properties are implicitly available as output properties. Additionally, the FgaSchema 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 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 FgaSchema Resource
Get an existing FgaSchema 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?: FgaSchemaState, opts?: CustomResourceOptions): FgaSchema@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
project_id: Optional[str] = None,
schema: Optional[str] = None) -> FgaSchemafunc GetFgaSchema(ctx *Context, name string, id IDInput, state *FgaSchemaState, opts ...ResourceOption) (*FgaSchema, error)public static FgaSchema Get(string name, Input<string> id, FgaSchemaState? state, CustomResourceOptions? opts = null)public static FgaSchema get(String name, Output<String> id, FgaSchemaState state, CustomResourceOptions options)resources: existingFgaSchema: type: descope:FgaSchema get: id: ${id}import {
to = descope_fga_schema.example
id = "${id}"
}
- name string
- The unique name of the resulting resource.
- id Input<ID>
- The unique provider ID of the resource to look up.
- state FgaSchemaState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resulting resource.
- id str
- The unique provider ID of the resource to look up.
- 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 resulting resource.
- id IDInput
- The unique provider ID of the resource to look up.
- state FgaSchemaState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resulting resource.
- id Input<string>
- The unique provider ID of the resource to look up.
- state FgaSchemaState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resulting resource.
- id Output<String>
- The unique provider ID of the resource to look up.
- state FgaSchemaState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
- Project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- Schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- Project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- Schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project_
id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id String - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema String
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id string - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema string
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project_
id str - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema str
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
- project
Id String - The ID of the project that this FGA schema belongs to. Changing this value will require the resource to be deleted and recreated.
- schema String
- The project's FGA (fine-grained authorization) schema, configured in the Descope console under the FGA tab. Use the code view to get the schema text and paste it as the value for this attribute. When set, the schema must start with
model AuthZ. Setting an empty schema, or destroying the resource, clears the project's FGA schema, which also removes any FGA relations that depend on it.
Package Details
- Repository
- descope descope/pulumi-descope
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
descopeTerraform Provider.
published on Sunday, Oct 11, 2026 by Descope