> ## Documentation Index
> Fetch the complete documentation index at: https://docs.automate.ax/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Automate.ax automations are TypeScript programs.
> Use Bun for installation and command examples.
> Use Automate.ax for the product name and automate.ax for the package, CLI, and domain.
> Treat documented public APIs as current; do not invent transitional or deprecated names.

# Register hosted script

> Registers a hosted script URL, version, attributes, and integrity.

`webflow.registerHostedScript` registers a hosted script URL, version, attributes, and integrity.

## Example

```ts automations/webflow-register-hosted-script.automation.ts theme={null}
import { automation, onDashboardRun } from "automate.ax"
import { webflow } from "automate.ax/webflow"

export default automation("Register hosted script", () => {
  onDashboardRun({ title: "Register hosted script" })

  webflow.registerHostedScript({
    siteId: "site-id",
    displayName: "Analytics",
    hostedLocation: "https://cdn.example.com/analytics.js",
    integrityHash:
      "sha384-J+YlJ8v0gpaRoKH7SbFbEmxOZlAxLiwNjfSsBhDooGa5roXlPPpXbEevck4J7YZ+",
    version: "1.0.0",
  })
})
```

## Inputs

Every input accepts a compatible signal. It requires the `custom_code:write` OAuth scope.

| Field            | Type      | Required | Description                                                 |
| ---------------- | --------- | -------- | ----------------------------------------------------------- |
| `hostedLocation` | `string`  | Yes      | URL of the externally hosted JavaScript.                    |
| `integrityHash`  | `string`  | Yes      | SHA-256, SHA-384, or SHA-512 SRI hash for the hosted bytes. |
| `canCopy`        | `boolean` | No       | Webflow `canCopy` value.                                    |
| `version`        | `string`  | Yes      | Semantic version such as `"1.0.0"`.                         |
| `displayName`    | `string`  | Yes      | From 1 through 50 letters, numbers, or spaces.              |
| `siteId`         | `string`  | Yes      | Webflow site ID.                                            |

## Output

Returns an object with the fields below. Automate.ax converts provider `Date` values to ISO 8601 strings.

| Field            | Type      | Description                     |
| ---------------- | --------- | ------------------------------- |
| `id`             | `string`  | Webflow `id` value.             |
| `canCopy`        | `boolean` | Webflow `canCopy` value.        |
| `displayName`    | `string`  | Webflow `displayName` value.    |
| `hostedLocation` | `string`  | Webflow `hostedLocation` value. |
| `integrityHash`  | `string`  | Webflow `integrityHash` value.  |
| `createdOn`      | `string`  | Webflow `createdOn` value.      |
| `lastUpdated`    | `string`  | Webflow `lastUpdated` value.    |
| `version`        | `string`  | Webflow `version` value.        |
