# ionoscloud\_ipblock

The **IP Block data source** can be used to search for and return an existing Ip Block. You can provide a string for the id, the name or the location parameters which will be compared with the provisioned Ip Blocks. If a single match is found, it will be returned. If your search results in multiple matches, an error will be returned. When this happens, please refine your search string so that it is specific enough to return only one result.

## Example Usage

### By ID

```hcl
data "ionoscloud_ipblock" "example" {
  id = "ipblock_id"
}
```

### By Name

```hcl
data "ionoscloud_ipblock" "example" {
  name = "IP Block Name"
}
```

### By Location

```hcl
data "ionoscloud_ipblock" "example" {
  location = "us/las"
}
```

### By Name & Location

```
data "ionoscloud_ipblock" "example" {
  name      = "IP Block Name"
  location  = "us/las"
}
```

## Argument reference

* `id` - (Optional) ID of an existing Ip Block that you want to search for.
* `name` - (Optional) Name of an existing Ip Block that you want to search for.
* `location` - (Optional) The regional location for this IP Block: us/las, us/ewr, de/fra, de/fkb.

## Attributes Reference

* `id` - The id of Ip Block
* `name` - The name of Ip Block
* `location` - The regional location for this IP Block: us/las, us/ewr, de/fra, de/fkb.
* `size` - The number of IP addresses to reserve for this block.
* `ips` - The list of IP addresses associated with this block.
* `ip_consumers` Read-Only attribute. Lists consumption detail of an individual ip
  * `ip`
  * `mac`
  * `nic_uuid`
  * `server_id`
  * `server_name`
  * `datacenter_id`
  * `datacenter_name`
  * `k8s_nodepool_uuid`
  * `k8s_cluster_uuid`


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ionos.com/terraform-provider/data-sources/ipblock.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
