---
title: Custom Csrs
---

[Skip to content](#%5Ftop) 

[API Reference](https://developers.cloudflare.com/api/terraform)

Copy Markdown

Open in **Claude**

Open in **ChatGPT**

Open in **Cursor**

---

**Copy Markdown**

**View as Markdown**

# Custom Csrs

#### resource cloudflare\_custom\_csr

##### required Expand Collapse 

common\_name: String

The common name (domain) for the CSR. Must be at most 64 characters.

country: String

Two-letter ISO 3166-1 alpha-2 country code.

locality: String

City or locality name.

organization: String

Organization name.

state: String

State or province name.

sans: List\[String\]

Subject Alternative Names for the CSR. At least one SAN is required.

##### optional Expand Collapse 

account\_id?: String

The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.

zone\_id?: String

The Zone ID to use for this endpoint. Mutually exclusive with the Account ID.

description?: String

Optional description for the CSR.

name?: String

Human-readable name for the CSR.

organizational\_unit?: String

Organizational unit name.

key\_type?: String

Key algorithm to use for the CSR. Defaults to rsa2048 if not specified.

##### computed Expand Collapse 

id: String

Custom CSR identifier tag.

account\_tag: String

Account identifier associated with this CSR.

created\_at: Time

When the CSR was created.

csr: String

The PEM-encoded Certificate Signing Request.

### cloudflare\_custom\_csr

Terraform

HTTPHTTP

TypeScriptTypeScript

PythonPython

GoGo

TerraformTerraform

```
resource "cloudflare_custom_csr" "example_custom_csr" {
  common_name = "example.com"
  country = "US"
  locality = "San Francisco"
  organization = "Cloudflare, Inc."
  sans = ["example.com", "www.example.com"]
  state = "California"
  zone_id = "zone_id"
  description = "CSR for example.com wildcard"
  key_type = "rsa2048"
  name = "My Custom CSR"
  organizational_unit = "Engineering"
}

```

#### data cloudflare\_custom\_csr

##### optional Expand Collapse 

custom\_csr\_id?: String

Custom CSR identifier tag.

account\_id?: String

The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.

zone\_id?: String

The Zone ID to use for this endpoint. Mutually exclusive with the Account ID.

filter?: Attributes

direction?: String

The direction to sort by.

order?: String

The field to sort the returned custom CSRs by.

##### computed Expand Collapse 

id: String

Custom CSR identifier tag.

account\_tag: String

Account identifier associated with this CSR.

common\_name: String

The common name (domain) for the CSR.

country: String

Two-letter ISO 3166-1 alpha-2 country code.

created\_at: Time

When the CSR was created.

csr: String

The PEM-encoded Certificate Signing Request.

description: String

Optional description for the CSR.

key\_type: String

The key algorithm used to generate the CSR.

locality: String

City or locality name.

name: String

Human-readable name for the CSR.

organization: String

Organization name.

organizational\_unit: String

Organizational unit name.

state: String

State or province name.

sans: List\[String\]

Subject Alternative Names included in the CSR.

### cloudflare\_custom\_csr

Terraform

HTTPHTTP

TypeScriptTypeScript

PythonPython

GoGo

TerraformTerraform

```
data "cloudflare_custom_csr" "example_custom_csr" {
  custom_csr_id = "7b163417-1d2b-4c84-a38a-2fb7a0cd7752"
  account_id = "account_id"
  zone_id = "zone_id"
}

```

#### data cloudflare\_custom\_csrs

##### optional Expand Collapse 

account\_id?: String

The Account ID to use for this endpoint. Mutually exclusive with the Zone ID.

zone\_id?: String

The Zone ID to use for this endpoint. Mutually exclusive with the Account ID.

direction?: String

The direction to sort by.

order?: String

The field to sort the returned custom CSRs by.

max\_items?: Int64

Max items to fetch, default: 1000

##### computed Expand Collapse 

result: List\[Attributes\]

The items returned by the data source

id: String

Custom CSR identifier tag.

created\_at: Time

When the CSR was created.

key\_type: String

The key algorithm used to generate the CSR.

account\_tag: String

Account identifier associated with this CSR.

common\_name: String

The common name (domain) for the CSR.

country: String

Two-letter ISO 3166-1 alpha-2 country code.

csr: String

The PEM-encoded Certificate Signing Request.

description: String

Optional description for the CSR.

locality: String

City or locality name.

name: String

Human-readable name for the CSR.

organization: String

Organization name.

organizational\_unit: String

Organizational unit name.

sans: List\[String\]

Subject Alternative Names included in the CSR.

state: String

State or province name.

### cloudflare\_custom\_csrs

Terraform

HTTPHTTP

TypeScriptTypeScript

PythonPython

GoGo

TerraformTerraform

```
data "cloudflare_custom_csrs" "example_custom_csrs" {
  account_id = "account_id"
  zone_id = "zone_id"
}

```