# PATCH /websites/:website_id/connection

**Resource:** [Websites](./websites.md)  
**MCP tool:** `set_website_platform`  
**Scopes:** `websites:write`  
**Write operation:** yes

Record what a website is built on (WordPress, Wix, Squarespace, Shopify, Webflow, a web designer, own code). Every tool's install steps from get_website_tool are then written for that platform. Returns the website's connection, as get_website_connection.

## Parameters

| Name | In | Type | Required | Description |
|------|----|------|----------|-------------|
| `website_id` | path | string | yes | UUID of the website. Get ids from list_websites. |
| `platform` | body | string | yes | What the site is built on: wordpress, wix, squarespace, shopify, webflow, agency, github, other. Every tool's install steps are then written for it. |
| `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 PATCH   "https://api.trustpager.com/functions/v1/api/v1/websites/:website_id/connection"   -H "Authorization: Bearer YOUR_API_KEY"   -H "Content-Type: application/json"   -d '{"platform":"...","require_approval":"..."}'
```

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