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

# Change the AI tools settings of the company

> Change some of the company's AI tools settings and return them all, as `getAiToolsSettings` does. Only the fields sent change, at least one. A list sent replaces the whole list: to ignore one more severity or rule, read the settings with `getAiToolsSettings` first and send the full list with the change (a rule by its code from `rules`). Ignoring a severity, a rule, the devices assigned to no employee or the devices in stock takes their findings out of every AI tools read and the cockpit at once; nothing changes on the devices. `defaultPolicy` applies to the tools a device reports for the first time, never to a tool already seen: its policy is `setAiToolPolicy`. AI tools are what Primo finds on Macs (assistant apps, coding agents, IDE plugins, browser extensions, MCP servers, AI connections, agent instruction files), as of the last report (`lastSyncedAt` of `getAiToolsOverview`, every 5 minutes), with Primo's severities, less the findings the company's AI tools settings ignore. They are not the software catalog (`getSoftwares`, `getDeviceSoftware`), the company's own AI agents (`listAgents`) nor AI credits (`getAiUsage`). A company without AI tools monitoring gets a 403, final.

Key: WriteScope: Company


## OpenAPI

````yaml https://api.getprimo.com/openapi.json patch /ai-tools/settings
openapi: 3.1.1
info:
  title: Public API - BETA
  description: Read docs on https://docs.getprimo.com/
  version: '1.0'
  contact: {}
servers:
  - url: https://api.getprimo.com
security:
  - apikey: []
tags: []
paths:
  /ai-tools/settings:
    patch:
      tags:
        - AiTools
      summary: Change the AI tools settings of the company
      description: >-
        Change some of the company's AI tools settings and return them all, as
        `getAiToolsSettings` does. Only the fields sent change, at least one. A
        list sent replaces the whole list: to ignore one more severity or rule,
        read the settings with `getAiToolsSettings` first and send the full list
        with the change (a rule by its code from `rules`). Ignoring a severity,
        a rule, the devices assigned to no employee or the devices in stock
        takes their findings out of every AI tools read and the cockpit at once;
        nothing changes on the devices. `defaultPolicy` applies to the tools a
        device reports for the first time, never to a tool already seen: its
        policy is `setAiToolPolicy`. AI tools are what Primo finds on Macs
        (assistant apps, coding agents, IDE plugins, browser extensions, MCP
        servers, AI connections, agent instruction files), as of the last report
        (`lastSyncedAt` of `getAiToolsOverview`, every 5 minutes), with Primo's
        severities, less the findings the company's AI tools settings ignore.
        They are not the software catalog (`getSoftwares`, `getDeviceSoftware`),
        the company's own AI agents (`listAgents`) nor AI credits
        (`getAiUsage`). A company without AI tools monitoring gets a 403, final.
      operationId: updateAiToolsSettings
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateAiToolsSettingsBody'
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAiToolsSettingsResponse_Output'
components:
  schemas:
    UpdateAiToolsSettingsBody:
      type: object
      properties:
        defaultPolicy:
          type: string
          description: >-
            The policy a tool gets the first time a device reports it; the tools
            already seen keep theirs
          enum:
            - not_reviewed
            - approved
            - blocked
        ignoredSeverities:
          type: array
          description: The severities whose findings the company ignores, e.g. `["low"]`
          items:
            type: string
            enum:
              - critical
              - high
              - medium
              - low
        ignoredRules:
          type: array
          description: >-
            The rule codes whose findings the company ignores whatever their
            severity, e.g. `["unpinned_dependency"]`
          maxItems: 200
          items:
            type: string
            minLength: 1
            maxLength: 100
        excludeUnassignedDevices:
          type: boolean
          description: >-
            true: a device assigned to no employee raises no finding (its tools
            stay listed)
        excludeInStockDevices:
          type: boolean
          description: 'true: a device in stock raises no finding (its tools stay listed)'
    GetAiToolsSettingsResponse_Output:
      type: object
      properties:
        defaultPolicy:
          type: string
          description: >-
            The policy a tool gets the first time a device reports it; the tools
            already seen keep theirs
          enum:
            - not_reviewed
            - approved
            - blocked
        ignoredSeverities:
          type: array
          description: The severities whose findings the company ignores, e.g. `["low"]`
          items:
            type: string
            enum:
              - critical
              - high
              - medium
              - low
        ignoredRules:
          type: array
          description: >-
            The rule codes whose findings the company ignores whatever their
            severity, e.g. `["unpinned_dependency"]`
          maxItems: 200
          items:
            type: string
            minLength: 1
            maxLength: 100
        excludeUnassignedDevices:
          type: boolean
          description: >-
            true: a device assigned to no employee raises no finding (its tools
            stay listed)
        excludeInStockDevices:
          type: boolean
          description: 'true: a device in stock raises no finding (its tools stay listed)'
        rules:
          type: array
          description: Every rule Primo rates, worst severity first
          items:
            type: object
            properties:
              rule:
                description: Primo's code of the risk, e.g. `plaintext_secret`
                type: string
              severity:
                description: Primo's severity of the rule
                type: string
                enum:
                  - critical
                  - high
                  - medium
                  - low
              severityLabel:
                description: The severity in words, e.g. `Critical`
                type: string
              title:
                description: >-
                  What the rule means in a few words; the code itself for a rule
                  Primo has not rated yet
                type: string
              description:
                description: One line on what the rule detects
                anyOf:
                  - type: string
                  - type: 'null'
              ignored:
                description: >-
                  Whether the company ignores its findings, by its code or by
                  its severity
                type: boolean
            required:
              - rule
              - severity
              - severityLabel
              - title
              - description
              - ignored
            additionalProperties: false
      required:
        - defaultPolicy
        - ignoredSeverities
        - ignoredRules
        - excludeUnassignedDevices
        - excludeInStockDevices
        - rules
      additionalProperties: false
  securitySchemes:
    apikey:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Use your Primo API key in the Authorization header as `Bearer
        <API_KEY>`.

````

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