# POST /lead-magnets/:lead_magnet_id/gift-script/test

**Resource:** [LEAD_MAGNETS](./lead-magnets.md)  
**MCP tool:** `test_lead_magnet_gift_script`  
**Scopes:** `lead_magnets:write`, `automations-trigger:trigger`  
**Write operation:** yes

Try the gift script on a sample reader (or one you describe) without approving it. Runs in the background: read the outcome with get_lead_magnet_gift_script (last_test_status, last_test_result) a few seconds later. Charged like one Custom Script run.

## Parameters

| Name | In | Type | Required | Description |
|------|----|------|----------|-------------|
| `lead_magnet_id` | path | string | yes | The lead magnet whose Made for you gift the script makes. |
| `reader` | body | object | no | Optional reader to test with (first_name, business_name, industry, city, state, postcode, website, why_now); anything left out comes from the sample reader. |
| `require_approval` | body | boolean | no | Optional. Set true to route this write into the approval queue for human review instead of executing it immediately (returns 202 + an approval_id). Works even when your key/token has permission to execute directly. |

## Request example

```bash
curl -X POST   "https://api.trustpager.com/functions/v1/api/v1/lead-magnets/:lead_magnet_id/gift-script/test"   -H "Authorization: Bearer YOUR_API_KEY"   -H "Content-Type: application/json"   -d '{"reader":"...","require_approval":"..."}'
```

---
Base URL: `https://api.trustpager.com/functions/v1/api/v1` — Auth: `Authorization: Bearer YOUR_API_KEY`