# GET /automations/:automation_id/actions/:action_id/custom-script

**Resource:** [Custom Scripts](./custom-scripts.md)  
**MCP tool:** `get_custom_script`  
**Scopes:** `automations:read`  
**Write operation:** no

Get a Custom Script action's current state — description, generated code, approval/deploy status, secret names, last test result.

## Parameters

| Name | In | Type | Required | Description |
|------|----|------|----------|-------------|
| `automation_id` | path | string | yes |  |
| `action_id` | path | string | yes |  |

## Request example

```bash
curl   "https://api.trustpager.com/functions/v1/api/v1/automations/:automation_id/actions/:action_id/custom-script"   -H "Authorization: Bearer YOUR_API_KEY"
```

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