# POST /simulations

**Create a simulation**

Creates a new simulation for a notification setting (notification destination).

simulated webhook payloads with real data. The API key making the request needs read permissions:

* For the entities you provided, or the request fails.
* For related entities which aren't nested in the entities you provided, or static examples will be used instead.

For example, when creating a subscription renewal scenario simulation with an API key that has a `subscription.read` permission but not a `transaction.read` permission,
the request succeeds and the subscription data will be used in simulated payloads, but the related transaction data won't be used in payloads and falls back to a static example.

If you don't provide a `config.entities` object, simulated webhook payloads are populated with static examples.

If successful, your response includes a copy of the new simulation entity.

**Required permissions:** `notification_simulation.write`

## Request body



### Request example

```json
{
  "notification_setting_id": "ntfset_01j82d983j814ypzx7m1fw2jpz",
  "name": "Create a failed subscription renewal simulation with subscription ID",
  "type": "subscription_renewal",
  "config": {
    "subscription_renewal": {
      "entities": {
        "subscription_id": "sub_01h04vsc0qhwtsbsxh3422wjs4"
      },
      "options": {
        "payment_outcome": "failed",
        "dunning_exhausted_action": "subscription_canceled"
      }
    }
  }
}
```

## Response (201)

- `data` (required) — Represents a simulation entity.
- `meta`: object (required) — Information about this response.
  - `request_id`: string (required) — Unique ID for the request relating to this response. Provide this when contacting Paddle support about a specific request.

### Response example

```json
{
  "data": {
    "id": "ntfsim_01j82g2mggsgjpb3mjg0xq6p5k",
    "notification_setting_id": "ntfset_01j82d983j814ypzx7m1fw2jpz",
    "name": "Create a subscription renewal simulation with config",
    "type": "subscription_renewal",
    "status": "active",
    "payload": null,
    "config": {
      "subscription_cancellation": null,
      "subscription_creation": null,
      "subscription_pause": null,
      "subscription_renewal": {
        "entities": {
          "subscription_id": "sub_01h04vsc0qhwtsbsxh3422wjs4"
        },
        "options": {
          "payment_outcome": "recovered_updated_payment_method",
          "dunning_exhausted_action": null
        }
      },
      "subscription_resume": null
    },
    "last_run_at": null,
    "created_at": "2024-09-18T12:00:25.616392Z",
    "updated_at": "2024-09-18T12:00:25.616392Z"
  },
  "meta": {
    "request_id": "72351248-13bf-45be-befe-b3a5b5234588"
  }
}
```
