> ## 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.

# Approve or block several AI tools, or mark them not reviewed

> Record one decision of the company on up to 100 AI tools (`toolKeys` from `getAiTools`, filtered for instance on `kind` or `policy`): `approved`, `blocked` or `not_reviewed`, and return each policy as JSON `data`. A 404 means no device reports one of the tools, and no policy changed. A decision only: Primo removes nothing from the devices and does not stop the tools. For one tool, `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 put /ai-tools/tools/policy
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/tools/policy:
    put:
      tags:
        - AiTools
      summary: Approve or block several AI tools, or mark them not reviewed
      description: >-
        Record one decision of the company on up to 100 AI tools (`toolKeys`
        from `getAiTools`, filtered for instance on `kind` or `policy`):
        `approved`, `blocked` or `not_reviewed`, and return each policy as JSON
        `data`. A 404 means no device reports one of the tools, and no policy
        changed. A decision only: Primo removes nothing from the devices and
        does not stop the tools. For one tool, `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: setAiToolPolicies
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SetAiToolPoliciesBody'
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SetAiToolPoliciesResponse_Output'
components:
  schemas:
    SetAiToolPoliciesBody:
      type: object
      properties:
        toolKeys:
          description: The tools to decide on, each `toolKey` from `getAiTools`
          minItems: 1
          maxItems: 100
          type: array
          items:
            description: Identifier of the tool, from `getAiTools` or `getAiToolsOverview`
            type: string
            minLength: 1
            maxLength: 300
        status:
          description: >-
            The company's decision on the tool: not_reviewed, approved or
            blocked
          type: string
          enum:
            - not_reviewed
            - approved
            - blocked
      required:
        - toolKeys
        - status
    SetAiToolPoliciesResponse_Output:
      type: object
      properties:
        data:
          type: array
          items:
            type: object
            properties:
              status:
                description: >-
                  The company's decision on the tool: not_reviewed, approved or
                  blocked
                type: string
                enum:
                  - not_reviewed
                  - approved
                  - blocked
              source:
                description: >-
                  default: the policy the settings gave the tool when a device
                  first reported it; admin: a decision
                type: string
                enum:
                  - default
                  - admin
              decidedAt:
                description: >-
                  When the policy was set (ISO 8601); null before the first sync
                  stamps it
                anyOf:
                  - type: string
                  - type: 'null'
              toolKey:
                type: string
            required:
              - status
              - source
              - decidedAt
              - toolKey
            additionalProperties: false
      required:
        - data
      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.