---
title: Creates bulk DOS event with relationships and indicators
---

[Skip to content](#%5Ftop) 

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

[Cloudforce One](https://developers.cloudflare.com/api/python/resources/cloudforce%5Fone)

[Threat Events](https://developers.cloudflare.com/api/python/resources/cloudforce%5Fone/subresources/threat%5Fevents)

Copy Markdown

Open in **Claude**

Open in **ChatGPT**

Open in **Cursor**

---

**Copy Markdown**

**View as Markdown**

# Creates bulk DOS event with relationships and indicators

Deprecated: This endpoint is deprecated and will be removed in a future version.

cloudforce\_one.threat\_events.bulk\_create\_relationships(ThreatEventBulkCreateRelationshipsParams\*\*kwargs)  \-> [ThreatEventBulkCreateRelationshipsResponse](https://developers.cloudflare.com/api/python/resources/cloudforce%5Fone#%28resource%29%20cloudforce%5Fone.threat%5Fevents%20%3E%20%28model%29%20threat%5Fevent%5Fbulk%5Fcreate%5Frelationships%5Fresponse%20%3E%20%28schema%29)

POST/accounts/{account\_id}/cloudforce-one/events/create/bulk/relationships

This method is deprecated. Please use `event_create_bulk` instead

##### Security

API Token

The preferred authorization scheme for interacting with the Cloudflare API. [Create a token](https://developers.cloudflare.com/fundamentals/api/get-started/create-token/).

**Example:**`Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY`

##### Accepted Permissions (at least one required)

`Cloudforce One Write` `Cloudforce One Read`

##### ParametersExpand Collapse 

account\_id: str

Account ID.

data: Iterable\[Data\]

category: str

date: Union\[str, datetime\]

formatdate-time

event: str

raw: DataRaw

data: Optional\[Dict\[str, object\]\]

source: Optional\[str\]

tlp: Optional\[str\]

tlp: str

account\_id: Optional\[float\]

attacker: Optional\[str\]

attacker\_country: Optional\[str\]

dataset\_id: Optional\[str\]

indicator: Optional\[str\]

indicators: Optional\[Iterable\[DataIndicator\]\]

Array of indicators for this event. Supports multiple indicators per event for complex scenarios.

indicator\_type: str

The type of indicator (e.g., DOMAIN, IP, JA3, HASH)

value: str

The indicator value (e.g., domain name, IP address, hash)

indicator\_type: Optional\[str\]

insight: Optional\[str\]

tags: Optional\[Sequence\[str\]\]

target\_country: Optional\[str\]

target\_industry: Optional\[str\]

dataset\_id: str

##### ReturnsExpand Collapse 

class ThreatEventBulkCreateRelationshipsResponse: …

Result of bulk relationship creation operation

created\_events\_count: float

Number of events created

created\_indicators\_count: float

Number of indicators created

created\_relationships\_count: float

Number of relationships created

error\_count: float

Number of errors encountered

errors: Optional\[List\[Error\]\]

Array of error details

error: str

Error message

event\_index: float

Index of the event that caused the error

### Creates bulk DOS event with relationships and indicators

Python

HTTPHTTP

TypeScriptTypeScript

PythonPython

GoGo

TerraformTerraform

```
import os
from datetime import datetime
from cloudflare import Cloudflare

client = Cloudflare(
    api_token=os.environ.get("CLOUDFLARE_API_TOKEN"),  # This is the default and can be omitted
)
response = client.cloudforce_one.threat_events.bulk_create_relationships(
    account_id="account_id",
    data=[{
        "category": "Domain Resolution",
        "date": datetime.fromisoformat("2022-04-01T00:00:00"),
        "event": "An attacker registered the domain domain.com",
        "raw": {
            "data": {
                "foo": "bar"
            }
        },
        "tlp": "amber",
    }],
    dataset_id="durableObjectName",
)
print(response.created_events_count)
```

200 example

```
{
  "createdEventsCount": 0,
  "createdIndicatorsCount": 0,
  "createdRelationshipsCount": 0,
  "errorCount": 0,
  "errors": [
    {
      "error": "error",
      "eventIndex": 0
    }
  ]
}
```

##### Returns Examples

200 example

```
{
  "createdEventsCount": 0,
  "createdIndicatorsCount": 0,
  "createdRelationshipsCount": 0,
  "errorCount": 0,
  "errors": [
    {
      "error": "error",
      "eventIndex": 0
    }
  ]
}
```