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

# Change the HubSpot config

> Changes the top-level settings in `changes`, each to its whole new value; every other key stays. The save runs the app's checks (a refusal is a 422 with their text). Saving an Other account filter schedules its monthly run when none is set. A 409 means the config changed since you read it (or `expected_version` is not the live one): read it again.



## OpenAPI

````yaml /api/statisfy-api.openapi.json patch /v1/integrations/hubspot/config
openapi: 3.1.0
info:
  description: >-
    The agent-first Statisfy API. Authenticate with an API key (`Authorization:
    Bearer stfy_live_…`), then call `GET /v1/meta/capabilities` to discover
    every operation and its schemas.
  title: Statisfy API
  version: 1.0.0
servers:
  - url: https://api.statisfy.com
    description: Production
security: []
paths:
  /v1/integrations/hubspot/config:
    patch:
      tags:
        - integrations
      summary: Change the HubSpot config
      description: >-
        Changes the top-level settings in `changes`, each to its whole new
        value; every other key stays. The save runs the app's checks (a refusal
        is a 422 with their text). Saving an Other account filter schedules its
        monthly run when none is set. A 409 means the config changed since you
        read it (or `expected_version` is not the live one): read it again.
      operationId: integrations_hubspot_update_config
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: false
              properties:
                changes:
                  additionalProperties: true
                  description: >-
                    The top-level settings to change, each with its whole new
                    value (see GET /config for the keys). A key you leave out
                    stays as it is; null removes a key. Empty: nothing changes
                  title: Changes
                  type: object
                expected_version:
                  anyOf:
                    - description: >-
                        The config `version` you read. Sent: a change against a
                        version that is no longer live is a 409 and writes
                        nothing (0 = the config was never saved). Left out, the
                        version this call reads is used, so a change saved
                        between that read and this write is still a 409: read
                        again and retry
                      minimum: 0
                      type: integer
                    - type: 'null'
                  default: null
                  title: Expected Version
                validate_with_api:
                  default: false
                  description: >-
                    Also check each filter and field against the tenant's CRM
                    before saving
                  title: Validate With Api
                  type: boolean
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HubSpotConfig'
          description: Successful Response
      security:
        - HTTPBearer: []
components:
  schemas:
    HubSpotConfig:
      description: The HubSpot settings, by top-level key, with their version.
      properties:
        configuration:
          additionalProperties: true
          description: >-
            The settings, by top-level key, as the app's settings page saves
            them
          title: Configuration
          type: object
        source:
          description: >-
            database: saved in Statisfy. code: never saved, Statisfy's built-in
            config runs. none: no config
          enum:
            - database
            - code
            - none
          title: Source
          type: string
        version:
          description: >-
            The config's version: send it as `expected_version` with a change (0
            = never saved)
          title: Version
          type: integer
      required:
        - version
        - source
        - configuration
      title: HubSpotConfig
      type: object
  securitySchemes:
    HTTPBearer:
      scheme: bearer
      type: http
      description: >-
        An API key, sent as `Authorization: Bearer stfy_live_…`. See
        [Authentication](/rest-api/authentication) for how to get one and which
        scopes it needs.

````

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