published on Thursday, Jul 16, 2026 by Pulumi
published on Thursday, Jul 16, 2026 by Pulumi
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as cloudflare from "@pulumi/cloudflare";
const exampleShareResource = new cloudflare.ShareResource("example_share_resource", {
accountId: "023e105f4ecef8ad9ca31a8372d0c353",
shareId: "3fd85f74b32742f1bff64a85009dda07",
meta: {},
resourceAccountId: "023e105f4ecef8ad9ca31a8372d0c353",
resourceId: "023e105f4ecef8ad9ca31a8372d0c353",
resourceType: "custom-ruleset",
});
import pulumi
import pulumi_cloudflare as cloudflare
example_share_resource = cloudflare.ShareResource("example_share_resource",
account_id="023e105f4ecef8ad9ca31a8372d0c353",
share_id="3fd85f74b32742f1bff64a85009dda07",
meta={},
resource_account_id="023e105f4ecef8ad9ca31a8372d0c353",
resource_id="023e105f4ecef8ad9ca31a8372d0c353",
resource_type="custom-ruleset")
package main
import (
"github.com/pulumi/pulumi-cloudflare/sdk/v6/go/cloudflare"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudflare.NewShareResource(ctx, "example_share_resource", &cloudflare.ShareResourceArgs{
AccountId: pulumi.String("023e105f4ecef8ad9ca31a8372d0c353"),
ShareId: pulumi.String("3fd85f74b32742f1bff64a85009dda07"),
Meta: pulumi.String{},
ResourceAccountId: pulumi.String("023e105f4ecef8ad9ca31a8372d0c353"),
ResourceId: pulumi.String("023e105f4ecef8ad9ca31a8372d0c353"),
ResourceType: pulumi.String("custom-ruleset"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudflare = Pulumi.Cloudflare;
return await Deployment.RunAsync(() =>
{
var exampleShareResource = new Cloudflare.ShareResource("example_share_resource", new()
{
AccountId = "023e105f4ecef8ad9ca31a8372d0c353",
ShareId = "3fd85f74b32742f1bff64a85009dda07",
Meta = null,
ResourceAccountId = "023e105f4ecef8ad9ca31a8372d0c353",
ResourceId = "023e105f4ecef8ad9ca31a8372d0c353",
ResourceType = "custom-ruleset",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.ShareResource;
import com.pulumi.cloudflare.ShareResourceArgs;
import java.util.ArrayList;
import java.util.Arrays;
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 exampleShareResource = new ShareResource("exampleShareResource", ShareResourceArgs.builder()
.accountId("023e105f4ecef8ad9ca31a8372d0c353")
.shareId("3fd85f74b32742f1bff64a85009dda07")
.meta(Map.ofEntries(
))
.resourceAccountId("023e105f4ecef8ad9ca31a8372d0c353")
.resourceId("023e105f4ecef8ad9ca31a8372d0c353")
.resourceType("custom-ruleset")
.build());
}
}
resources:
exampleShareResource:
type: cloudflare:ShareResource
name: example_share_resource
properties:
accountId: 023e105f4ecef8ad9ca31a8372d0c353
shareId: 3fd85f74b32742f1bff64a85009dda07
meta: {}
resourceAccountId: 023e105f4ecef8ad9ca31a8372d0c353
resourceId: 023e105f4ecef8ad9ca31a8372d0c353
resourceType: custom-ruleset
pulumi {
required_providers {
cloudflare = {
source = "pulumi/cloudflare"
}
}
}
resource "cloudflare_shareresource" "example_share_resource" {
account_id = "023e105f4ecef8ad9ca31a8372d0c353"
share_id = "3fd85f74b32742f1bff64a85009dda07"
meta = {}
resource_account_id = "023e105f4ecef8ad9ca31a8372d0c353"
resource_id = "023e105f4ecef8ad9ca31a8372d0c353"
resource_type = "custom-ruleset"
}
Create ShareResource Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ShareResource(name: string, args: ShareResourceArgs, opts?: CustomResourceOptions);@overload
def ShareResource(resource_name: str,
args: ShareResourceInitArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ShareResource(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
meta: Optional[str] = None,
resource_account_id: Optional[str] = None,
resource_id: Optional[str] = None,
resource_type: Optional[str] = None,
share_id: Optional[str] = None)func NewShareResource(ctx *Context, name string, args ShareResourceArgs, opts ...ResourceOption) (*ShareResource, error)public ShareResource(string name, ShareResourceArgs args, CustomResourceOptions? opts = null)
public ShareResource(String name, ShareResourceArgs args)
public ShareResource(String name, ShareResourceArgs args, CustomResourceOptions options)
type: cloudflare:ShareResource
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "cloudflare_share_resource" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args ShareResourceArgs
- 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 ShareResourceInitArgs
- 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 ShareResourceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ShareResourceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ShareResourceArgs
- 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 shareResourceResource = new Cloudflare.ShareResource("shareResourceResource", new()
{
AccountId = "string",
Meta = "string",
ResourceAccountId = "string",
ResourceId = "string",
ResourceType = "string",
ShareId = "string",
});
example, err := cloudflare.NewShareResource(ctx, "shareResourceResource", &cloudflare.ShareResourceArgs{
AccountId: pulumi.String("string"),
Meta: pulumi.String("string"),
ResourceAccountId: pulumi.String("string"),
ResourceId: pulumi.String("string"),
ResourceType: pulumi.String("string"),
ShareId: pulumi.String("string"),
})
resource "cloudflare_share_resource" "shareResourceResource" {
lifecycle {
create_before_destroy = true
}
account_id = "string"
meta = "string"
resource_account_id = "string"
resource_id = "string"
resource_type = "string"
share_id = "string"
}
var shareResourceResource = new ShareResource("shareResourceResource", ShareResourceArgs.builder()
.accountId("string")
.meta("string")
.resourceAccountId("string")
.resourceId("string")
.resourceType("string")
.shareId("string")
.build());
share_resource_resource = cloudflare.ShareResource("shareResourceResource",
account_id="string",
meta="string",
resource_account_id="string",
resource_id="string",
resource_type="string",
share_id="string")
const shareResourceResource = new cloudflare.ShareResource("shareResourceResource", {
accountId: "string",
meta: "string",
resourceAccountId: "string",
resourceId: "string",
resourceType: "string",
shareId: "string",
});
type: cloudflare:ShareResource
properties:
accountId: string
meta: string
resourceAccountId: string
resourceId: string
resourceType: string
shareId: string
ShareResource 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 ShareResource resource accepts the following input properties:
- Account
Id string - Account identifier.
- Meta string
- Resource Metadata.
- Resource
Account stringId - Account identifier.
- Resource
Id string - Share Resource identifier.
- Resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- string
- Share identifier tag.
- Account
Id string - Account identifier.
- Meta string
- Resource Metadata.
- Resource
Account stringId - Account identifier.
- Resource
Id string - Share Resource identifier.
- Resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- string
- Share identifier tag.
- account_
id string - Account identifier.
- meta string
- Resource Metadata.
- resource_
account_ stringid - Account identifier.
- resource_
id string - Share Resource identifier.
- resource_
type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- string
- Share identifier tag.
- account
Id String - Account identifier.
- meta String
- Resource Metadata.
- resource
Account StringId - Account identifier.
- resource
Id String - Share Resource identifier.
- resource
Type String - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- String
- Share identifier tag.
- account
Id string - Account identifier.
- meta string
- Resource Metadata.
- resource
Account stringId - Account identifier.
- resource
Id string - Share Resource identifier.
- resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- string
- Share identifier tag.
- account_
id str - Account identifier.
- meta str
- Resource Metadata.
- resource_
account_ strid - Account identifier.
- resource_
id str - Share Resource identifier.
- resource_
type str - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- str
- Share identifier tag.
- account
Id String - Account identifier.
- meta String
- Resource Metadata.
- resource
Account StringId - Account identifier.
- resource
Id String - Share Resource identifier.
- resource
Type String - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- String
- Share identifier tag.
Outputs
All input properties are implicitly available as output properties. Additionally, the ShareResource resource produces the following output properties:
- Created string
- When the share was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Modified string
- When the share was modified.
- Resource
Version int - Resource Version.
- Status string
- Resource Status. Available values: "active", "deleting", "deleted".
- Created string
- When the share was created.
- Id string
- The provider-assigned unique ID for this managed resource.
- Modified string
- When the share was modified.
- Resource
Version int - Resource Version.
- Status string
- Resource Status. Available values: "active", "deleting", "deleted".
- created string
- When the share was created.
- id string
- The provider-assigned unique ID for this managed resource.
- modified string
- When the share was modified.
- resource_
version number - Resource Version.
- status string
- Resource Status. Available values: "active", "deleting", "deleted".
- created String
- When the share was created.
- id String
- The provider-assigned unique ID for this managed resource.
- modified String
- When the share was modified.
- resource
Version Integer - Resource Version.
- status String
- Resource Status. Available values: "active", "deleting", "deleted".
- created string
- When the share was created.
- id string
- The provider-assigned unique ID for this managed resource.
- modified string
- When the share was modified.
- resource
Version number - Resource Version.
- status string
- Resource Status. Available values: "active", "deleting", "deleted".
- created str
- When the share was created.
- id str
- The provider-assigned unique ID for this managed resource.
- modified str
- When the share was modified.
- resource_
version int - Resource Version.
- status str
- Resource Status. Available values: "active", "deleting", "deleted".
- created String
- When the share was created.
- id String
- The provider-assigned unique ID for this managed resource.
- modified String
- When the share was modified.
- resource
Version Number - Resource Version.
- status String
- Resource Status. Available values: "active", "deleting", "deleted".
Look up Existing ShareResource Resource
Get an existing ShareResource 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?: ShareResourceState, opts?: CustomResourceOptions): ShareResource@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
created: Optional[str] = None,
meta: Optional[str] = None,
modified: Optional[str] = None,
resource_account_id: Optional[str] = None,
resource_id: Optional[str] = None,
resource_type: Optional[str] = None,
resource_version: Optional[int] = None,
share_id: Optional[str] = None,
status: Optional[str] = None) -> ShareResourcefunc GetShareResource(ctx *Context, name string, id IDInput, state *ShareResourceState, opts ...ResourceOption) (*ShareResource, error)public static ShareResource Get(string name, Input<string> id, ShareResourceState? state, CustomResourceOptions? opts = null)public static ShareResource get(String name, Output<String> id, ShareResourceState state, CustomResourceOptions options)resources: _: type: cloudflare:ShareResource get: id: ${id}import {
to = cloudflare_share_resource.example
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.
- Account
Id string - Account identifier.
- Created string
- When the share was created.
- Meta string
- Resource Metadata.
- Modified string
- When the share was modified.
- Resource
Account stringId - Account identifier.
- Resource
Id string - Share Resource identifier.
- Resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- Resource
Version int - Resource Version.
- string
- Share identifier tag.
- Status string
- Resource Status. Available values: "active", "deleting", "deleted".
- Account
Id string - Account identifier.
- Created string
- When the share was created.
- Meta string
- Resource Metadata.
- Modified string
- When the share was modified.
- Resource
Account stringId - Account identifier.
- Resource
Id string - Share Resource identifier.
- Resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- Resource
Version int - Resource Version.
- string
- Share identifier tag.
- Status string
- Resource Status. Available values: "active", "deleting", "deleted".
- account_
id string - Account identifier.
- created string
- When the share was created.
- meta string
- Resource Metadata.
- modified string
- When the share was modified.
- resource_
account_ stringid - Account identifier.
- resource_
id string - Share Resource identifier.
- resource_
type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- resource_
version number - Resource Version.
- string
- Share identifier tag.
- status string
- Resource Status. Available values: "active", "deleting", "deleted".
- account
Id String - Account identifier.
- created String
- When the share was created.
- meta String
- Resource Metadata.
- modified String
- When the share was modified.
- resource
Account StringId - Account identifier.
- resource
Id String - Share Resource identifier.
- resource
Type String - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- resource
Version Integer - Resource Version.
- String
- Share identifier tag.
- status String
- Resource Status. Available values: "active", "deleting", "deleted".
- account
Id string - Account identifier.
- created string
- When the share was created.
- meta string
- Resource Metadata.
- modified string
- When the share was modified.
- resource
Account stringId - Account identifier.
- resource
Id string - Share Resource identifier.
- resource
Type string - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- resource
Version number - Resource Version.
- string
- Share identifier tag.
- status string
- Resource Status. Available values: "active", "deleting", "deleted".
- account_
id str - Account identifier.
- created str
- When the share was created.
- meta str
- Resource Metadata.
- modified str
- When the share was modified.
- resource_
account_ strid - Account identifier.
- resource_
id str - Share Resource identifier.
- resource_
type str - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- resource_
version int - Resource Version.
- str
- Share identifier tag.
- status str
- Resource Status. Available values: "active", "deleting", "deleted".
- account
Id String - Account identifier.
- created String
- When the share was created.
- meta String
- Resource Metadata.
- modified String
- When the share was modified.
- resource
Account StringId - Account identifier.
- resource
Id String - Share Resource identifier.
- resource
Type String - Resource Type. Available values: "custom-ruleset", "gateway-policy", "gateway-destination-ip", "gateway-block-page-settings", "gateway-extended-email-matching", "idp-federation-grant".
- resource
Version Number - Resource Version.
- String
- Share identifier tag.
- status String
- Resource Status. Available values: "active", "deleting", "deleted".
Import
$ pulumi import cloudflare:index/shareResource:ShareResource example '<account_id>/<share_id>/<share_resource_id>'
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Cloudflare pulumi/pulumi-cloudflare
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
cloudflareTerraform Provider.
published on Thursday, Jul 16, 2026 by Pulumi