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

# Update an account's post defaults

> Set the settings every new post on an account starts from, or clear them.

> [!NOTE]
>
> Needs `accounts:update`, and a role in the workspace that can edit accounts. Keys made with **Everything** (`*`) and older keys with `accounts` have it. See [Permissions](/docs/essentials/authentication.md#permissions).

Send `defaults` with the settings every new post on this account should start from, in the same shape as the account's `settings` on [Create a post](/docs/api-reference/posts/create.md#all-settings-by-network). The answer is what [Get an account's post defaults](/docs/api-reference/accounts/get-account-defaults.md) gives.

```json theme={null}
{
  "defaults": {
    "privacy_level": "PUBLIC_TO_EVERYONE",
    "disable_comment": false,
    "disable_duet": true,
    "disable_stitch": true,
    "hashtags": ["#haldencoffee", "#latteart"]
  }
}
```

* `defaults` replaces what the account has. A key you leave out is no longer a default. To change one key, read the defaults first and send them back with the change.
* `{"defaults": {}}` clears them.
* Only posts the account is added to from now on start from them. A draft, a scheduled post or a published post keeps the settings it has.
* Values are checked the way they are on a post: a TikTok `privacy_level` must be one of its values, `hashtags` up to 30, and so on. A switch must be `true` or `false`.
* A text can be up to 2,048 characters, a link or an ID included (`first_comment` has its network's own limit).
* An empty value (`""`, `[]` or `null`) sets nothing. The answer gives the defaults back the way a post reads them: `hashtags` as a list, Instagram's `reel` as `REELS`.

## What can be a default

Post text, media and polls belong to each post, so they can't be defaults. Neither can TikTok's `brand_content_toggle` and `brand_organic_toggle`: TikTok wants the content disclosure off until it is turned on for a post. Sending one of these is refused with `422` under `defaults.<key>`: "title can't be a default: it belongs to the post." A key the network doesn't have is refused the same way: "playlist\_id isn't a TikTok setting."

| Network | Keys |
| - | - |
| TikTok | `privacy_level`, `disable_comment`, `disable_duet`, `disable_stitch`, `post_mode`, `auto_add_music`, `is_aigc`, `hashtags` |
| YouTube | `privacyStatus`, `selfDeclaredMadeForKids`, `notifySubscribers`, `video_type`, `category_id`, `playlist_id`, `tags`, `license`, `embeddable`, `containsSyntheticMedia`, `language`, `hasPaidProductPlacement`, `first_comment` |
| Instagram | `post_type`, `share_to_feed`, `reel_trial_enabled`, `graduation_strategy`, `collaborators`, `ai_generated`, `hashtags`, `first_comment` |
| Facebook | `post_type`, `hashtags`, `first_comment` |
| Pinterest | `board_id`, `board_section_id`, `link`, `hashtags` |
| LinkedIn | `visibility`, `hashtags`, `first_comment` |
| Threads | `reply_control`, `reply_approvals`, `topic_tag`, `ai_generated`, `hashtags`, `first_comment` |
| X | `reply_settings`, `community_id`, `share_with_followers`, `for_super_followers_only`, `hashtags`, `first_comment` |
| Google Business Profile | `topic_type`, `call_to_action` |
| Bluesky | `languages`, `reply_rules`, `allow_quotes`, `content_labels`, `hashtags`, `first_comment` |
| Mastodon | `visibility`, `sensitive`, `language`, `quote_approval_policy`, `hashtags`, `first_comment` |
| Telegram | `disable_notification`, `protect_content`, `pin_message`, `has_spoiler`, `show_caption_above_media` |

`hashtags` are added after the account's text when it is published, and `first_comment` is posted a minute after the post when the post has no first comment of its own. See `hashtags` and `first_comment` in [All settings by network](/docs/api-reference/posts/create.md#all-settings-by-network).

## Errors

| Status | `error` | When | Retry? |
| - | - | - | - |
| 401 | | No API key, or not a valid one. | No: fix the key. |
| 403 | | The key lacks `accounts:update`, or its user is inactive. | No: grant it in Settings → API. |
| 403 | | Your role in the workspace can't edit accounts. | No. |
| 404 | | No account with that id in the workspaces the key can reach. | No. |
| 422 | | `defaults` is missing, a key can't be a default for the account's network, or a value is one the setting refuses. `errors` names the key under `defaults.<key>`. Nothing changed. | No: fix the request. |
| 429 | | More than 60 requests a minute. | Yes, after `Retry-After` seconds. |

## Related

* [Get an account's post defaults](/docs/api-reference/accounts/get-account-defaults.md): what the account has now.
* [Post defaults guide](/docs/guides/account-defaults.md): when they apply, and TikTok.
* [Create a post](/docs/api-reference/posts/create.md#post-defaults): `use_account_defaults` to leave them out of one post.


## OpenAPI

````yaml PUT /accounts/{account}/defaults
openapi: 3.0.3
info:
  title: PostSyncer API
  description: >-
    Post to 12 social networks from your code: posts, media, comments,
    analytics, webhooks and more.
  version: 1.0.0
servers:
  - url: https://postsyncer.com/api/v1
security:
  - bearerAuth: []
tags:
  - name: Workspaces
    description: The workspaces the key can reach.
  - name: Accounts
    description: Connected social accounts, links to connect more, and disconnecting them.
  - name: Posts
    description: Drafts, scheduled and published posts, approvals and a post's history.
  - name: Post settings
    description: A post's auto-plug, comment moderation and contact collection.
  - name: Media
    description: >-
      The media library: file uploads, URL imports, and reading videos and
      social posts' files.
  - name: Folders
    description: Folders that organise the media library.
  - name: Comments
    description: >-
      Comments on your posts: reading, replying, editing, hiding, deleting and
      syncing them.
  - name: Reviews
    description: Google Business Profile reviews and your replies to them.
  - name: Analytics
    description: Workspace, account and post performance.
  - name: Brand
    description: >-
      A workspace's brand: identity, voice, look, accounts, competitors,
      learnings and rules.
  - name: Labels
    description: Labels used to tag posts.
  - name: Campaigns
    description: Campaigns used to group posts.
  - name: Snippets
    description: Saved snippets and hashtag groups to drop into posts.
  - name: Webhooks
    description: Signed webhook endpoints that get your notification events.
  - name: Billing
    description: >-
      The owner's plan, invoices and the links that pay for, change or cancel
      it.
  - name: Team
    description: A workspace's teammates and invitations, and their roles.
  - name: Notifications
    description: >-
      Your bell and notification settings, and the workspace's Slack, Discord
      and Telegram channels.
  - name: Blog-to-social
    description: Blog feeds that turn a workspace's new articles into posts.
  - name: Products
    description: Products the workspace's posts can promote.
  - name: Contacts
    description: People who commented on the workspace's posts, and the lists they are on.
  - name: Profile
    description: 'The key''s user: their name and sign-in email.'
  - name: API keys
    description: 'Your API keys: listing and deleting them.'
  - name: Agent sign-up
    description: >-
      An AI agent signs a person up with a code emailed to them, and gets their
      first key. No key needed.
paths:
  /accounts/{account}/defaults:
    put:
      tags:
        - Accounts
      summary: Update an account's post defaults
      description: >-
        Needs `accounts:update`. Replaces the account's post defaults with
        `defaults`: a key you leave out is no longer a default, and `{}` clears
        them all. Only posts the account is added to from now on start from
        them; a post already on the account keeps its settings, whatever its
        status. A key that isn't one of the network's settings, or that belongs
        to the post (its text, media, a poll, TikTok's branded-content
        switches), is refused with `422` under `defaults.<key>`, and values are
        checked as they are on a post. Also needs a role in the workspace that
        can edit accounts.
      operationId: updateAccountDefaults
      parameters:
        - name: account
          in: path
          required: true
          description: The account's id.
          schema:
            type: integer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - defaults
              properties:
                defaults:
                  allOf:
                    - $ref: '#/components/schemas/PostDefaultsSettings'
                  description: >-
                    The whole set of defaults for the account's network. It
                    replaces what the account has; `{}` clears them.
            examples:
              default:
                summary: 'TikTok: who can watch, interactions and hashtags'
                value:
                  defaults:
                    privacy_level: PUBLIC_TO_EVERYONE
                    disable_comment: false
                    disable_duet: true
                    disable_stitch: true
                    hashtags:
                      - '#haldencoffee'
                      - '#latteart'
              youtube:
                summary: 'YouTube: Shorts, to a playlist'
                value:
                  defaults:
                    video_type: short
                    privacyStatus: public
                    playlist_id: PLrAXtmErZgOeiKm4sgNOknGvNjby9efdf
                    notifySubscribers: false
              clear:
                summary: Clear them
                value:
                  defaults: {}
      responses:
        '200':
          description: Saved. The account's network and its post defaults as they are now.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/AccountPostDefaults'
              examples:
                default:
                  summary: A TikTok account with defaults
                  value:
                    data:
                      account_id: 306
                      platform: tiktok
                      defaults:
                        privacy_level: PUBLIC_TO_EVERYONE
                        disable_comment: false
                        disable_duet: true
                        disable_stitch: true
                        hashtags:
                          - '#haldencoffee'
                          - '#latteart'
                youtube:
                  summary: 'A YouTube channel: Shorts, to a playlist'
                  value:
                    data:
                      account_id: 305
                      platform: youtube
                      defaults:
                        video_type: short
                        privacyStatus: public
                        playlist_id: PLrAXtmErZgOeiKm4sgNOknGvNjby9efdf
                        notifySubscribers: false
                none:
                  summary: No defaults yet
                  value:
                    data:
                      account_id: 302
                      platform: linkedin
                      defaults: {}
        '401':
          $ref: '#/components/responses/Unauthorized401'
        '403':
          description: >-
            The key lacks `accounts:update`, its user is inactive, or your role
            in the workspace can't edit accounts.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                missing_permission:
                  summary: The key lacks accounts:update
                  value:
                    message: >-
                      This API key does not have the "accounts:update"
                      permission. Edit the key in PostSyncer under Settings →
                      API to grant it.
                role:
                  summary: The role can't edit accounts
                  value:
                    message: >-
                      Your role in the workspace "Halden Coffee" does not allow
                      you to edit accounts. Ask the workspace owner or a manager
                      to do it, or to change your role.
                inactive_account:
                  summary: The key's user is inactive
                  value:
                    message: Your account is inactive.
        '404':
          $ref: '#/components/responses/NotFound404'
        '422':
          description: >-
            `defaults` is missing, names a key that can't be a default, or holds
            a value the network's setting refuses. Nothing changed. `errors`
            names the key under `defaults.<key>`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
              examples:
                post_text:
                  summary: Post text can't be a default
                  value:
                    message: 'title can''t be a default: it belongs to the post.'
                    errors:
                      defaults.title:
                        - 'title can''t be a default: it belongs to the post.'
                unknown_key:
                  summary: Not a setting of the network
                  value:
                    message: playlist_id isn't a TikTok setting.
                    errors:
                      defaults.playlist_id:
                        - playlist_id isn't a TikTok setting.
                missing_defaults:
                  summary: No defaults object
                  value:
                    message: The defaults field must be present.
                    errors:
                      defaults:
                        - The defaults field must be present.
        '429':
          $ref: '#/components/responses/RateLimited429'
components:
  schemas:
    PostDefaultsSettings:
      type: object
      additionalProperties: true
      description: >-
        An account's post defaults: the settings a new post on the account
        starts from, in the same shape as `accounts[].settings` on [Create a
        post](/api-reference/posts/create), for the account's network. Only the
        keys someone set are here; `{}` when none are. Post text (titles,
        captions, descriptions, polls), media and TikTok's
        `brand_content_toggle` and `brand_organic_toggle` are never defaults.
        [Post defaults](/guides/account-defaults) lists the keys each network
        takes.
    AccountPostDefaults:
      type: object
      description: An account's post defaults, with the account and its network.
      required:
        - account_id
        - platform
        - defaults
      properties:
        account_id:
          type: integer
          description: The account's id.
        platform:
          type: string
          enum:
            - twitter
            - linkedin
            - instagram
            - facebook
            - tiktok
            - youtube
            - threads
            - pinterest
            - bluesky
            - telegram
            - mastodon
            - google_business
          description: >-
            The account's network, which decides the keys `defaults` takes.
            `twitter` is X; `google_business` is Google Business Profile.
        defaults:
          allOf:
            - $ref: '#/components/schemas/PostDefaultsSettings'
          description: >-
            The settings a new post on the account starts from. `{}` when none
            are set.
    Error:
      type: object
      description: >-
        An error answer. Every one has `message`, in plain words; some add an
        `error` code and fields of their own.
      required:
        - message
      properties:
        message:
          type: string
          description: What went wrong and what to do about it.
        error:
          type: string
          description: >-
            A code a few errors add, such as `rate_limited`. See [Handle
            errors](/essentials/error-handling#answers-with-an-error-code).
    ValidationError:
      type: object
      description: '422: the request didn''t pass validation, and nothing changed.'
      required:
        - message
        - errors
      properties:
        message:
          type: string
          description: >-
            The first error and, when there are more, how many: `(and 1 more
            error)`, `(and 2 more errors)`.
        errors:
          type: object
          description: >-
            The messages, by field. A field inside a list is named with dots:
            `accounts.0.id`.
          additionalProperties:
            type: array
            items:
              type: string
  responses:
    Unauthorized401:
      description: No API key, or not a valid one.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            unauthenticated:
              summary: No valid API key
              value:
                message: Unauthenticated.
    NotFound404:
      description: Nothing with that id in the workspaces the key can reach.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            not_found:
              summary: Not found
              value:
                message: Not found.
    RateLimited429:
      description: >-
        More than 60 requests in a minute from this key's user (the API and the
        MCP server share the count). Wait `Retry-After` seconds.
      headers:
        Retry-After:
          description: Seconds until requests are allowed again.
          schema:
            type: integer
        X-RateLimit-Limit:
          description: Requests allowed a minute.
          schema:
            type: integer
        X-RateLimit-Remaining:
          description: Requests left this minute.
          schema:
            type: integer
        X-RateLimit-Reset:
          description: When requests are allowed again, as a Unix timestamp.
          schema:
            type: integer
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            too_many_attempts:
              summary: Too many requests
              value:
                message: Too Many Attempts.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.