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

# Choose which capabilities your consumers are offered

> Turns capabilities on or off for all your consumers and sets the mode preselected where a consumer can choose. A capability that is off is absent for your consumers and stops running for them; turned on again, it runs again for the consumers who had selected it. Selections, mapping values and answers are never deleted. `cron` sets when the sync runs for every consumer that enabled it; it can always be started by hand.



## OpenAPI

````yaml put /syncs/{syncid}/capabilities
openapi: 3.1.0
info:
  title: Chift API
  description: >-
    The Chift API is a universal API giving you access to financial data from
    the software of your clients. It helps software companies to offer native
    integrations to their clients without the effort needed to maintain those
    native integrations. By using the APIs (Accounting, POS, eCommerce) of
    Chift, you connect once and allow your clients to use their software
    packages.
  version: 1.0.0
servers:
  - url: https://api.chift.eu
    description: Chift
security:
  - bearerAuth: []
paths:
  /syncs/{syncid}/capabilities:
    put:
      tags:
        - Syncs
      summary: Choose which capabilities your consumers are offered
      description: >-
        Turns capabilities on or off for all your consumers and sets the mode
        preselected where a consumer can choose. A capability that is off is
        absent for your consumers and stops running for them; turned on again,
        it runs again for the consumers who had selected it. Selections, mapping
        values and answers are never deleted. `cron` sets when the sync runs for
        every consumer that enabled it; it can always be started by hand.
      operationId: agentic_syncs_update_sync_capabilities
      parameters:
        - name: syncid
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Syncid
        - name: language
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              ISO 639-1 code of the language of the texts (en, fr, nl, de, es;
              any case), falling back to English. Without it, translation keys.
            title: Language
          description: >-
            ISO 639-1 code of the language of the texts (en, fr, nl, de, es; any
            case), falling back to English. Without it, translation keys.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateSyncCapabilities'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SyncCapabilities'
        '404':
          content:
            application/json:
              example:
                message: The sync does not exist
                status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Not Found
        '422':
          content:
            application/json:
              examples:
                Unknown capability:
                  value:
                    message: “{capability}” is not part of this synchronisation.
                    status: error
                Not offered:
                  value:
                    message: “{capability}” is not offered.
                    status: error
                Not selectable:
                  value:
                    message: >-
                      “{capability}” is added automatically when another
                      capability needs it.
                    status: error
                Not available:
                  value:
                    message: Your accounting software cannot receive journal entries.
                    status: error
                Needed by another:
                  value:
                    message: “{capability}” is needed by “{required_by}”.
                    status: error
              schema:
                $ref: '#/components/schemas/ChiftError'
          description: Unprocessable Entity
components:
  schemas:
    UpdateSyncCapabilities:
      properties:
        offered:
          additionalProperties:
            type: boolean
          type: object
          title: Offered
          description: Capability key -> offered. A capability left out keeps its value.
          examples:
            - spend_to_accounting.Payments: false
        default_modes:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Default Modes
          description: >-
            Capability key -> mode key. Replaces every default mode when given;
            leave it out to keep them.
        cron:
          anyOf:
            - type: string
            - type: 'null'
          title: Cron
          description: >-
            When the sync runs for each consumer that enabled it, as a cron
            expression; it can always be started by hand. Null: only by hand.
          examples:
            - 0 * * * *
      type: object
      required:
        - cron
      title: UpdateSyncCapabilities
    SyncCapabilities:
      properties:
        capabilities:
          items:
            $ref: '#/components/schemas/SyncCapabilityItem'
          type: array
          title: Capabilities
          description: Every capability of the sync, offered or not.
        cron:
          anyOf:
            - type: string
            - type: 'null'
          title: Cron
          description: >-
            When the sync runs for each consumer that enabled it, as a cron
            expression. Null: it runs only when started by hand.
          examples:
            - 0 * * * *
      type: object
      required:
        - capabilities
        - cron
      title: SyncCapabilities
      description: >-
        What the account offers its consumers. Whether a capability is available
        depends on each consumer's connections.
    ChiftError:
      properties:
        message:
          type: string
          title: Message
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
          default: error
        detail:
          anyOf:
            - type: string
            - type: 'null'
          title: Detail
          default: ''
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Code
      type: object
      required:
        - message
      title: ChiftError
    SyncCapabilityItem:
      properties:
        key:
          type: string
          title: Key
          description: >-
            Stable key, e.g. 'spend_to_accounting.SupplierInvoices'. Send it
            back as is.
          examples:
            - spend_to_accounting.SupplierInvoices
        id:
          type: string
          format: uuid
          title: Id
          description: >-
            The stable uuid derived from the key, as the legacy sync routes
            identify the same item.
        title:
          type: string
          title: Title
          description: >-
            Name to show, in the requested language; its translation key without
            one.
          examples:
            - Supplier invoices
        description:
          type: string
          title: Description
          description: >-
            What it does, the tooltip: in the requested language, its
            translation key without one.
        kind:
          type: string
          enum:
            - main
            - supporting
          title: Kind
          description: >-
            'main': the consumer chooses it. 'supporting': shown as a tooltip,
            turned on by what needs it.
        offered:
          type: boolean
          title: Offered
          description: >-
            Whether your consumers can use it. A capability not offered is
            absent for them.
        default_mode:
          anyOf:
            - type: string
            - type: 'null'
          title: Default Mode
          description: >-
            The mode preselected on a consumer's screen when it can choose
            between several; the consumer still chooses it. Null when none is
            set.
          examples:
            - spend_to_accounting.SupplierInvoices.AsInvoice
        modes:
          items:
            $ref: '#/components/schemas/SyncCapabilityMode'
          type: array
          title: Modes
          description: The alternative ways of doing it. Empty when there is only one.
      type: object
      required:
        - key
        - id
        - title
        - description
        - kind
        - offered
        - default_mode
        - modes
      title: SyncCapabilityItem
    SyncCapabilityMode:
      properties:
        key:
          type: string
          title: Key
          description: Key of the mode.
          examples:
            - spend_to_accounting.SupplierInvoices.AsInvoice
        title:
          type: string
          title: Title
          description: >-
            Name to show, in the requested language; its translation key without
            one.
        description:
          type: string
          title: Description
          description: >-
            What it does, the tooltip: in the requested language, its
            translation key without one.
      type: object
      required:
        - key
        - title
        - description
      title: SyncCapabilityMode
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        This access token needs to be included in each of your request to the
        Chift API.

````

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