Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .fern/metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@
}
}
},
"originGitCommit": "998225e70e3e266cc158f022dfdd12904d54da2d",
"originGitCommit": "549d014f65c12ff88077dea2ce7f398297b0a3cd",
"sdkVersion": "3.3.5"
}
290 changes: 289 additions & 1 deletion reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -533,12 +533,15 @@ await client.sites.getCustomDomain("580e63e98c9a982ac9b8b741");
<dl>
<dd>

Publishes a site to one or more more domains.
Publishes a site or an individual page to one or more domains.
If multiple individual pages are published to staging, publishing from staging to production publishes all staged changes.

To publish to a specific custom domain, use the domain IDs from the [Get Custom Domains](/data/reference/sites/get-custom-domain) endpoint.

You must include at least one of the `customDomains` or `publishToWebflowSubdomain` properties in the request body.

To publish an individual page instead of the entire site, provide the ID of the page in the `pageId` parameter.

<Note title="Rate limit: 1 publish per minute">This endpoint has a specific rate limit of one successful publish queue per minute.</Note>

Required scope | `sites:write`
Expand Down Expand Up @@ -7474,6 +7477,291 @@ await client.sites.wellKnown.delete("580e63e98c9a982ac9b8b741");
</dl>


</dd>
</dl>
</details>

## Sites GoogleTag
<details><summary><code>client.sites.googleTag.<a href="/src/api/resources/sites/resources/googleTag/client/Client.ts">list</a>(site_id) -> Webflow.GoogleTagIds</code></summary>
<dl>
<dd>

#### 📝 Description

<dl>
<dd>

<dl>
<dd>

List all Google Tag IDs configured for a site, sorted by order.

Required scope: `sites:read`
</dd>
</dl>
</dd>
</dl>

#### 🔌 Usage

<dl>
<dd>

<dl>
<dd>

```typescript
await client.sites.googleTag.list("580e63e98c9a982ac9b8b741");

```
</dd>
</dl>
</dd>
</dl>

#### ⚙️ Parameters

<dl>
<dd>

<dl>
<dd>

**site_id:** `string` — Unique identifier for a Site

</dd>
</dl>

<dl>
<dd>

**requestOptions:** `GoogleTagClient.RequestOptions`

</dd>
</dl>
</dd>
</dl>


</dd>
</dl>
</details>

<details><summary><code>client.sites.googleTag.<a href="/src/api/resources/sites/resources/googleTag/client/Client.ts">deleteAll</a>(site_id) -> void</code></summary>
<dl>
<dd>

#### 📝 Description

<dl>
<dd>

<dl>
<dd>

Delete all Google Tag IDs from a site.

Required scope: `sites:write`
</dd>
</dl>
</dd>
</dl>

#### 🔌 Usage

<dl>
<dd>

<dl>
<dd>

```typescript
await client.sites.googleTag.deleteAll("580e63e98c9a982ac9b8b741");

```
</dd>
</dl>
</dd>
</dl>

#### ⚙️ Parameters

<dl>
<dd>

<dl>
<dd>

**site_id:** `string` — Unique identifier for a Site

</dd>
</dl>

<dl>
<dd>

**requestOptions:** `GoogleTagClient.RequestOptions`

</dd>
</dl>
</dd>
</dl>


</dd>
</dl>
</details>

<details><summary><code>client.sites.googleTag.<a href="/src/api/resources/sites/resources/googleTag/client/Client.ts">upsert</a>(site_id, { ...params }) -> Webflow.GoogleTagIds</code></summary>
<dl>
<dd>

#### 📝 Description

<dl>
<dd>

<dl>
<dd>

Add or update Google Tag IDs for a site. Existing tags not referenced in the request are preserved. A site may have a maximum of 25 tags total.

`order` is optional on input — it is auto-assigned for new tags and returned on all tags in the response.

Required scope: `sites:write`
</dd>
</dl>
</dd>
</dl>

#### 🔌 Usage

<dl>
<dd>

<dl>
<dd>

```typescript
await client.sites.googleTag.upsert("580e63e98c9a982ac9b8b741", {
googleTagIds: [{
order: 0,
displayName: "Main Analytics Tag",
tagId: "G-1234567890"
}]
});

```
</dd>
</dl>
</dd>
</dl>

#### ⚙️ Parameters

<dl>
<dd>

<dl>
<dd>

**site_id:** `string` — Unique identifier for a Site

</dd>
</dl>

<dl>
<dd>

**request:** `Webflow.GoogleTagIds`

</dd>
</dl>

<dl>
<dd>

**requestOptions:** `GoogleTagClient.RequestOptions`

</dd>
</dl>
</dd>
</dl>


</dd>
</dl>
</details>

<details><summary><code>client.sites.googleTag.<a href="/src/api/resources/sites/resources/googleTag/client/Client.ts">delete</a>(site_id, tag_id) -> Webflow.GoogleTagIds</code></summary>
<dl>
<dd>

#### 📝 Description

<dl>
<dd>

<dl>
<dd>

Delete a single Google Tag ID from a site. The `order` values of the remaining tags are renormalized after deletion.

Required scope: `sites:write`
</dd>
</dl>
</dd>
</dl>

#### 🔌 Usage

<dl>
<dd>

<dl>
<dd>

```typescript
await client.sites.googleTag.delete("580e63e98c9a982ac9b8b741", "G-XXXXXXXXXX");

```
</dd>
</dl>
</dd>
</dl>

#### ⚙️ Parameters

<dl>
<dd>

<dl>
<dd>

**site_id:** `string` — Unique identifier for a Site

</dd>
</dl>

<dl>
<dd>

**tag_id:** `string` — The Google Tag ID (e.g. G-XXXXXXXXXX)

</dd>
</dl>

<dl>
<dd>

**requestOptions:** `GoogleTagClient.RequestOptions`

</dd>
</dl>
</dd>
</dl>


</dd>
</dl>
</details>
Expand Down
11 changes: 10 additions & 1 deletion src/api/resources/sites/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import * as Webflow from "../../../index";
import { ActivityLogsClient } from "../resources/activityLogs/client/Client";
import { CommentsClient } from "../resources/comments/client/Client";
import { FormsClient } from "../resources/forms/client/Client";
import { GoogleTagClient } from "../resources/googleTag/client/Client";
import { PlansClient } from "../resources/plans/client/Client";
import { RedirectsClient } from "../resources/redirects/client/Client";
import { RobotsTxtClient } from "../resources/robotsTxt/client/Client";
Expand All @@ -33,6 +34,7 @@ export class SitesClient {
protected _plans: PlansClient | undefined;
protected _robotsTxt: RobotsTxtClient | undefined;
protected _wellKnown: WellKnownClient | undefined;
protected _googleTag: GoogleTagClient | undefined;
protected _activityLogs: ActivityLogsClient | undefined;
protected _comments: CommentsClient | undefined;
protected _scripts: ScriptsClient | undefined;
Expand All @@ -58,6 +60,10 @@ export class SitesClient {
return (this._wellKnown ??= new WellKnownClient(this._options));
}

public get googleTag(): GoogleTagClient {
return (this._googleTag ??= new GoogleTagClient(this._options));
}

public get activityLogs(): ActivityLogsClient {
return (this._activityLogs ??= new ActivityLogsClient(this._options));
}
Expand Down Expand Up @@ -825,12 +831,15 @@ export class SitesClient {
}

/**
* Publishes a site to one or more more domains.
* Publishes a site or an individual page to one or more domains.
* If multiple individual pages are published to staging, publishing from staging to production publishes all staged changes.
*
* To publish to a specific custom domain, use the domain IDs from the [Get Custom Domains](/data/reference/sites/get-custom-domain) endpoint.
*
* You must include at least one of the `customDomains` or `publishToWebflowSubdomain` properties in the request body.
*
* To publish an individual page instead of the entire site, provide the ID of the page in the `pageId` parameter.
*
* <Note title="Rate limit: 1 publish per minute">This endpoint has a specific rate limit of one successful publish queue per minute.</Note>
*
* Required scope | `sites:write`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ export interface SitesPublishRequest {
customDomains?: string[];
/** Choice of whether to publish to the default Webflow Subdomain */
publishToWebflowSubdomain?: boolean;
/** The ID of the page to publish */
pageId?: string;
}
Loading