# Ingestion Rules

> SDK methods for the Ingestion Rules module, accessed via `soat.ingestionRules`. See the [Ingestion Rules module docs](/docs/modules/ingestion-rules) for permissions and data model, and each method's REST page for the full request/response schema.

# Ingestion Rules

SDK methods for the Ingestion Rules module, accessed via `soat.ingestionRules`. See the [Ingestion Rules module docs](/docs/modules/ingestion-rules) for permissions and data model, and each method's REST page for the full request/response schema.

### `soat.ingestionRules.listIngestionRules()`

List ingestion rules

- Method: `GET`
- Path: `/api/v1/ingestion-rules`

```ts
await soat.ingestionRules.listIngestionRules({
  query: { /* + optional */ },
});
```

→ [Request & response schema](/docs/api/ingestion-rules/list-ingestion-rules)

### `soat.ingestionRules.createIngestionRule()`

Create an ingestion rule

- Method: `POST`
- Path: `/api/v1/ingestion-rules`

```ts
await soat.ingestionRules.createIngestionRule({
  body: { content_type_glob, /* + optional */ },
});
```

→ [Request & response schema](/docs/api/ingestion-rules/create-ingestion-rule)

### `soat.ingestionRules.getIngestionRule()`

Get an ingestion rule

- Method: `GET`
- Path: `/api/v1/ingestion-rules/{ingestion_rule_id}`

```ts
await soat.ingestionRules.getIngestionRule({
  path: { ingestion_rule_id },
});
```

→ [Request & response schema](/docs/api/ingestion-rules/get-ingestion-rule)

### `soat.ingestionRules.updateIngestionRule()`

Update an ingestion rule

- Method: `PATCH`
- Path: `/api/v1/ingestion-rules/{ingestion_rule_id}`

```ts
await soat.ingestionRules.updateIngestionRule({
  path: { ingestion_rule_id },
  body: { /* + optional */ },
});
```

→ [Request & response schema](/docs/api/ingestion-rules/update-ingestion-rule)

### `soat.ingestionRules.deleteIngestionRule()`

Delete an ingestion rule

- Method: `DELETE`
- Path: `/api/v1/ingestion-rules/{ingestion_rule_id}`

```ts
await soat.ingestionRules.deleteIngestionRule({
  path: { ingestion_rule_id },
});
```

→ [Request & response schema](/docs/api/ingestion-rules/delete-ingestion-rule)
