# Apply personal defaults

Source: https://immiscible.fly.dev/docs/api/post-api-w-wid-personal-setup

`POST /api/w/:wid/personal/setup`

The owner of a personal workspace. Anything left out takes the personal default.

| Field | Description |
|---|---|
| `allowanceMonthly` | pence across every agent in 30 days (default 25,000) |
| `perAgentMonthly` | pence for any one agent, or `null` |
| `neverPay` | website names no agent may pay (default: betting, crypto exchanges and money transfer) |
| `approvalMinutes` | how long an approval waits, 5 to 1440 (default 30) |

## Authentication

Session cookie. A signed-in person: the console's session cookie. Every state-changing request also carries the header `x-immiscible-csrf: 1`, and the member's role decides what it may do. Bearer tokens are ignored on these routes, so no machine credential can reach them.

## Path parameters

- `wid` (string, required): Workspace id

## Request

curl:

```bash
curl -X POST "https://immiscible.fly.dev/api/w/$IMMISCIBLE_WORKSPACE/personal/setup" \
  -H "cookie: __Host-sid=$IMMISCIBLE_SESSION" \
  -H "x-immiscible-csrf: 1" \
  -H "content-type: application/json" \
  -d '{
    "allowanceMonthly": 30000
  }'
```

Node:

```ts
const res = await fetch('https://immiscible.fly.dev/api/w/$IMMISCIBLE_WORKSPACE/personal/setup', {
  method: 'POST',
  headers: {
    cookie: `__Host-sid=${process.env.IMMISCIBLE_SESSION}`,
    'x-immiscible-csrf': '1',
    'content-type': 'application/json',
  },
  body: JSON.stringify({
    allowanceMonthly: 30000,
  }),
});
const data = await res.json();
console.log(res.status, data);
```

Python:

```python
import os
import requests

res = requests.post(
    "https://immiscible.fly.dev/api/w/$IMMISCIBLE_WORKSPACE/personal/setup",
    headers={
        "cookie": f"__Host-sid={os.environ['IMMISCIBLE_SESSION']}",
        "x-immiscible-csrf": "1",
        "content-type": "application/json",
    },
    json={
        "allowanceMonthly": 30000,
    },
)
print(res.status_code, res.json())
```
