> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# GetBlogSettings

# Package: blog

# Namespace: BlogSettingsV3Service

# Method link: https://dev.wix.com/docs/api-reference/business-solutions/blog/blog-settings/get-blog-settings.md

## Permission Scopes:
Read Blog : SCOPE.DC-BLOG.READ-BLOGS

## Introduction

Retrieves the site's blog settings.

A site has one blog settings object. If the site has none yet, this method creates the default blog settings and returns them.

Specify `language` to retrieve `allPostsFeedLabel` in that language. Comments are not translated.

---

## REST API

### Schema

```
 Method: getBlogSettings
 Description: Retrieves the site's blog settings.  A site has one blog settings object. If the site has none yet, this method creates the default blog settings and returns them.  Specify `language` to retrieve `allPostsFeedLabel` in that language. Comments are not translated.
 URL: https://www.wixapis.com/v3/blog-settings/v3/blog-settings
 Method: GET
 This method is cacheable: Responses from this method are cached for optimal performance.
 Method parameters:
   query param name: language | type: language | description: Language of `allPostsFeedLabel` to retrieve, in IETF BCP 47 language tag format. Typically, this is a lowercase 2-letter language code, followed by a hyphen, followed by an uppercase 2-letter country code. For example, `en-US` for U.S. English, and `de-DE` for Germany German.  When omitted, the language of the current request is used when the request includes one. Otherwise the primary language is used. If that language has no translation, the primary label is returned.  | validation: format LANGUAGE_TAG
 Return type: GetBlogSettingsResponse
  - name: blogSettings | type: BlogSettings | description: Retrieved blog settings.  
     - name: revision | type: string | description: Revision number, which increments by 1 each time the blog settings are updated. To prevent conflicting changes, the current revision must be passed when updating the blog settings.  | read-only: true | validation: format int64
     - name: allPostsFeedLabel | type: string | description: Label of the feed that lists all posts.  Translatable. Specify `language` on Get Blog Settings or Update Blog Settings to read or write this label in a specific language.  Default: `All posts` when the site has no saved blog settings.  | validation: minLength 1, maxLength 35
     - name: comments | type: Comments | description: Comment settings for the blog.  When updating comments, include `enabled`, `anonymousEnabled`, `ratingsEnabled`, and `ratingsMandatory` together. A partial comments object is rejected.  
        - name: enabled | type: boolean | description: Whether comments are turned on for the blog.  Default: `true` when the site has no saved blog settings.  
        - name: anonymousEnabled | type: boolean | description: Whether visitors can comment without signing in.  Default: `false` when the site has no saved blog settings.  
        - name: ratingsEnabled | type: boolean | description: Whether visitors can rate a post when they comment.  Default: `false` when the site has no saved blog settings.  
        - name: ratingsMandatory | type: boolean | description: Whether a rating is required when a visitor leaves a comment.  Default: `false` when the site has no saved blog settings.  


```

### Examples

### Get the site's blog settings in a specific language
Retrieves blog settings and the all-posts feed label for en-US.

```curl
curl -X GET \
'https://www.wixapis.com/v3/blog-settings?language=en-US' \
-H 'Authorization: <AUTH>'
```

---

## JavaScript SDK

### Schema

```
 Method: wixClientAdmin.blog.blogSettings.getBlogSettings(options)
 Description: Retrieves the site's blog settings.  A site has one blog settings object. If the site has none yet, this method creates the default blog settings and returns them.  Specify `language` to retrieve `allPostsFeedLabel` in that language. Comments are not translated.
 This method is cacheable: Responses from this method are cached for optimal performance.
 Method parameters:
   param name: options | type: GetBlogSettingsOptions  none  
        - name: language | type: string | description: Language of `allPostsFeedLabel` to retrieve, in IETF BCP 47 language tag format. Typically, this is a lowercase 2-letter language code, followed by a hyphen, followed by an uppercase 2-letter country code. For example, `en-US` for U.S. English, and `de-DE` for Germany German.  When omitted, the language of the current request is used when the request includes one. Otherwise the primary language is used. If that language has no translation, the primary label is returned.  | validation: format LANGUAGE_TAG
 Return type: PROMISE<BlogSettings>
  - name: revision | type: string | description: Revision number, which increments by 1 each time the blog settings are updated. To prevent conflicting changes, the current revision must be passed when updating the blog settings.  | read-only: true | validation: format int64
  - name: allPostsFeedLabel | type: string | description: Label of the feed that lists all posts.  Translatable. Specify `language` on Get Blog Settings or Update Blog Settings to read or write this label in a specific language.  Default: `All posts` when the site has no saved blog settings.  | validation: minLength 1, maxLength 35
  - name: comments | type: Comments | description: Comment settings for the blog.  When updating comments, include `enabled`, `anonymousEnabled`, `ratingsEnabled`, and `ratingsMandatory` together. A partial comments object is rejected.  
     - name: enabled | type: boolean | description: Whether comments are turned on for the blog.  Default: `true` when the site has no saved blog settings.  
     - name: anonymousEnabled | type: boolean | description: Whether visitors can comment without signing in.  Default: `false` when the site has no saved blog settings.  
     - name: ratingsEnabled | type: boolean | description: Whether visitors can rate a post when they comment.  Default: `false` when the site has no saved blog settings.  
     - name: ratingsMandatory | type: boolean | description: Whether a rating is required when a visitor leaves a comment.  Default: `false` when the site has no saved blog settings.  


```

### Examples

### Get the site's blog settings in a specific language
Retrieves blog settings and the all-posts feed label for en-US.

```javascript
import { blogSettings } from "@wix/blog";

async function getBlogSettings() {
  const response = await blogSettings.getBlogSettings({
    language: "en-US",
  });
}

/* Promise resolves to:
 * {
 *   "revision": "1",
 *   "allPostsFeedLabel": "All posts",
 *   "comments": {
 *     "enabled": true,
 *     "anonymousEnabled": false,
 *     "ratingsEnabled": false,
 *     "ratingsMandatory": false
 *   }
 * }
 */

```

### getBlogSettings (self-managed)
Self-managed SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md).

```javascript
import { createClient } from '@wix/sdk';
import { blogSettings } from '@wix/blog';
// Import the auth strategy for the relevant access type
// Import the relevant host module if needed

const myWixClient = createClient ({
  modules: { blogSettings },
  // Include the auth strategy and host as relevant
});


async function getBlogSettings(options) {
  const response = await myWixClient.blogSettings.getBlogSettings(options);
};
```

---