1. Packages
  2. Cloudflare Provider
  3. API Docs
  4. getTurnstileWidgets
Cloudflare v6.0.1 published on Wednesday, Apr 16, 2025 by Pulumi

cloudflare.getTurnstileWidgets

Explore with Pulumi AI

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as cloudflare from "@pulumi/cloudflare";

const exampleTurnstileWidgets = cloudflare.getTurnstileWidgets({
    accountId: "023e105f4ecef8ad9ca31a8372d0c353",
    direction: "asc",
    order: "id",
});
Copy
import pulumi
import pulumi_cloudflare as cloudflare

example_turnstile_widgets = cloudflare.get_turnstile_widgets(account_id="023e105f4ecef8ad9ca31a8372d0c353",
    direction="asc",
    order="id")
Copy
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.LookupTurnstileWidgets(ctx, &cloudflare.LookupTurnstileWidgetsArgs{
			AccountId: "023e105f4ecef8ad9ca31a8372d0c353",
			Direction: pulumi.StringRef("asc"),
			Order:     pulumi.StringRef("id"),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudflare = Pulumi.Cloudflare;

return await Deployment.RunAsync(() => 
{
    var exampleTurnstileWidgets = Cloudflare.GetTurnstileWidgets.Invoke(new()
    {
        AccountId = "023e105f4ecef8ad9ca31a8372d0c353",
        Direction = "asc",
        Order = "id",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.CloudflareFunctions;
import com.pulumi.cloudflare.inputs.GetTurnstileWidgetsArgs;
import java.util.List;
import java.util.ArrayList;
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) {
        final var exampleTurnstileWidgets = CloudflareFunctions.getTurnstileWidgets(GetTurnstileWidgetsArgs.builder()
            .accountId("023e105f4ecef8ad9ca31a8372d0c353")
            .direction("asc")
            .order("id")
            .build());

    }
}
Copy
variables:
  exampleTurnstileWidgets:
    fn::invoke:
      function: cloudflare:getTurnstileWidgets
      arguments:
        accountId: 023e105f4ecef8ad9ca31a8372d0c353
        direction: asc
        order: id
Copy

Using getTurnstileWidgets

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getTurnstileWidgets(args: GetTurnstileWidgetsArgs, opts?: InvokeOptions): Promise<GetTurnstileWidgetsResult>
function getTurnstileWidgetsOutput(args: GetTurnstileWidgetsOutputArgs, opts?: InvokeOptions): Output<GetTurnstileWidgetsResult>
Copy
def get_turnstile_widgets(account_id: Optional[str] = None,
                          direction: Optional[str] = None,
                          max_items: Optional[int] = None,
                          order: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetTurnstileWidgetsResult
def get_turnstile_widgets_output(account_id: Optional[pulumi.Input[str]] = None,
                          direction: Optional[pulumi.Input[str]] = None,
                          max_items: Optional[pulumi.Input[int]] = None,
                          order: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetTurnstileWidgetsResult]
Copy
func LookupTurnstileWidgets(ctx *Context, args *LookupTurnstileWidgetsArgs, opts ...InvokeOption) (*LookupTurnstileWidgetsResult, error)
func LookupTurnstileWidgetsOutput(ctx *Context, args *LookupTurnstileWidgetsOutputArgs, opts ...InvokeOption) LookupTurnstileWidgetsResultOutput
Copy

> Note: This function is named LookupTurnstileWidgets in the Go SDK.

public static class GetTurnstileWidgets 
{
    public static Task<GetTurnstileWidgetsResult> InvokeAsync(GetTurnstileWidgetsArgs args, InvokeOptions? opts = null)
    public static Output<GetTurnstileWidgetsResult> Invoke(GetTurnstileWidgetsInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetTurnstileWidgetsResult> getTurnstileWidgets(GetTurnstileWidgetsArgs args, InvokeOptions options)
public static Output<GetTurnstileWidgetsResult> getTurnstileWidgets(GetTurnstileWidgetsArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: cloudflare:index/getTurnstileWidgets:getTurnstileWidgets
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

AccountId This property is required. string
Identifier
Direction string
Direction to order widgets. Available values: "asc", "desc".
MaxItems int
Max items to fetch, default: 1000
Order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
AccountId This property is required. string
Identifier
Direction string
Direction to order widgets. Available values: "asc", "desc".
MaxItems int
Max items to fetch, default: 1000
Order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId This property is required. String
Identifier
direction String
Direction to order widgets. Available values: "asc", "desc".
maxItems Integer
Max items to fetch, default: 1000
order String
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId This property is required. string
Identifier
direction string
Direction to order widgets. Available values: "asc", "desc".
maxItems number
Max items to fetch, default: 1000
order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
account_id This property is required. str
Identifier
direction str
Direction to order widgets. Available values: "asc", "desc".
max_items int
Max items to fetch, default: 1000
order str
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId This property is required. String
Identifier
direction String
Direction to order widgets. Available values: "asc", "desc".
maxItems Number
Max items to fetch, default: 1000
order String
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".

getTurnstileWidgets Result

The following output properties are available:

AccountId string
Identifier
Id string
The provider-assigned unique ID for this managed resource.
Results List<GetTurnstileWidgetsResult>
The items returned by the data source
Direction string
Direction to order widgets. Available values: "asc", "desc".
MaxItems int
Max items to fetch, default: 1000
Order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
AccountId string
Identifier
Id string
The provider-assigned unique ID for this managed resource.
Results []GetTurnstileWidgetsResult
The items returned by the data source
Direction string
Direction to order widgets. Available values: "asc", "desc".
MaxItems int
Max items to fetch, default: 1000
Order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId String
Identifier
id String
The provider-assigned unique ID for this managed resource.
results List<GetTurnstileWidgetsResult>
The items returned by the data source
direction String
Direction to order widgets. Available values: "asc", "desc".
maxItems Integer
Max items to fetch, default: 1000
order String
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId string
Identifier
id string
The provider-assigned unique ID for this managed resource.
results GetTurnstileWidgetsResult[]
The items returned by the data source
direction string
Direction to order widgets. Available values: "asc", "desc".
maxItems number
Max items to fetch, default: 1000
order string
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
account_id str
Identifier
id str
The provider-assigned unique ID for this managed resource.
results Sequence[GetTurnstileWidgetsResult]
The items returned by the data source
direction str
Direction to order widgets. Available values: "asc", "desc".
max_items int
Max items to fetch, default: 1000
order str
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".
accountId String
Identifier
id String
The provider-assigned unique ID for this managed resource.
results List<Property Map>
The items returned by the data source
direction String
Direction to order widgets. Available values: "asc", "desc".
maxItems Number
Max items to fetch, default: 1000
order String
Field to order widgets by. Available values: "id", "sitekey", "name", "createdon", "modifiedon".

Supporting Types

GetTurnstileWidgetsResult

BotFightMode This property is required. bool
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
ClearanceLevel This property is required. string
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
CreatedOn This property is required. string
When the widget was created.
Domains This property is required. List<string>
EphemeralId This property is required. bool
Return the Ephemeral ID in /siteverify (ENT only).
Mode This property is required. string
Widget Mode Available values: "non-interactive", "invisible", "managed".
ModifiedOn This property is required. string
When the widget was modified.
Name This property is required. string
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
Offlabel This property is required. bool
Do not show any Cloudflare branding on the widget (ENT only).
Region This property is required. string
Region where this widget can be used. Available values: "world".
Sitekey This property is required. string
Widget item identifier tag.
BotFightMode This property is required. bool
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
ClearanceLevel This property is required. string
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
CreatedOn This property is required. string
When the widget was created.
Domains This property is required. []string
EphemeralId This property is required. bool
Return the Ephemeral ID in /siteverify (ENT only).
Mode This property is required. string
Widget Mode Available values: "non-interactive", "invisible", "managed".
ModifiedOn This property is required. string
When the widget was modified.
Name This property is required. string
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
Offlabel This property is required. bool
Do not show any Cloudflare branding on the widget (ENT only).
Region This property is required. string
Region where this widget can be used. Available values: "world".
Sitekey This property is required. string
Widget item identifier tag.
botFightMode This property is required. Boolean
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
clearanceLevel This property is required. String
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
createdOn This property is required. String
When the widget was created.
domains This property is required. List<String>
ephemeralId This property is required. Boolean
Return the Ephemeral ID in /siteverify (ENT only).
mode This property is required. String
Widget Mode Available values: "non-interactive", "invisible", "managed".
modifiedOn This property is required. String
When the widget was modified.
name This property is required. String
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
offlabel This property is required. Boolean
Do not show any Cloudflare branding on the widget (ENT only).
region This property is required. String
Region where this widget can be used. Available values: "world".
sitekey This property is required. String
Widget item identifier tag.
botFightMode This property is required. boolean
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
clearanceLevel This property is required. string
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
createdOn This property is required. string
When the widget was created.
domains This property is required. string[]
ephemeralId This property is required. boolean
Return the Ephemeral ID in /siteverify (ENT only).
mode This property is required. string
Widget Mode Available values: "non-interactive", "invisible", "managed".
modifiedOn This property is required. string
When the widget was modified.
name This property is required. string
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
offlabel This property is required. boolean
Do not show any Cloudflare branding on the widget (ENT only).
region This property is required. string
Region where this widget can be used. Available values: "world".
sitekey This property is required. string
Widget item identifier tag.
bot_fight_mode This property is required. bool
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
clearance_level This property is required. str
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
created_on This property is required. str
When the widget was created.
domains This property is required. Sequence[str]
ephemeral_id This property is required. bool
Return the Ephemeral ID in /siteverify (ENT only).
mode This property is required. str
Widget Mode Available values: "non-interactive", "invisible", "managed".
modified_on This property is required. str
When the widget was modified.
name This property is required. str
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
offlabel This property is required. bool
Do not show any Cloudflare branding on the widget (ENT only).
region This property is required. str
Region where this widget can be used. Available values: "world".
sitekey This property is required. str
Widget item identifier tag.
botFightMode This property is required. Boolean
If botfightmode is set to true, Cloudflare issues computationally expensive challenges in response to malicious bots (ENT only).
clearanceLevel This property is required. String
If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance, this setting can determine the clearance level to be set Available values: "no_clearance", "jschallenge", "managed", "interactive".
createdOn This property is required. String
When the widget was created.
domains This property is required. List<String>
ephemeralId This property is required. Boolean
Return the Ephemeral ID in /siteverify (ENT only).
mode This property is required. String
Widget Mode Available values: "non-interactive", "invisible", "managed".
modifiedOn This property is required. String
When the widget was modified.
name This property is required. String
Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used.
offlabel This property is required. Boolean
Do not show any Cloudflare branding on the widget (ENT only).
region This property is required. String
Region where this widget can be used. Available values: "world".
sitekey This property is required. String
Widget item identifier tag.

Package Details

Repository
Cloudflare pulumi/pulumi-cloudflare
License
Apache-2.0
Notes
This Pulumi package is based on the cloudflare Terraform Provider.