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

# Update who can view a slate



## OpenAPI

````yaml https://platform.usecontextlayer.com/api/openapi.json patch /slates/{target}
openapi: 3.1.0
info:
  title: ContextLayer Platform
  version: 0.1.0
servers:
  - url: https://platform.usecontextlayer.com/api
security: []
tags:
  - name: Slates
  - name: Slate routing
  - name: Slate resources
  - name: Accounts
  - name: Shared secrets
  - name: Agents
  - name: Agent jobs
paths:
  /slates/{target}:
    patch:
      tags:
        - Slates
      summary: Update who can view a slate
      operationId: updateSlateVisibility
      parameters:
        - schema:
            anyOf:
              - type: string
                format: uuid
              - type: string
          required: true
          name: target
          in: path
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                visibility:
                  type: string
                  enum:
                    - public
                    - private
              required:
                - visibility
              additionalProperties: false
      responses:
        '200':
          description: Slate with its saved visibility
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Slate'
        '400':
          description: Invalid slate target or visibility
        '401':
          description: A valid ContextLayer login is required
        '403':
          description: Only the Owner or owning organization members may update this slate
        '404':
          description: Slate not found
      security:
        - bearerAuth: []
        - webCookie: []
        - localWebCookie: []
components:
  schemas:
    Slate:
      type: object
      properties:
        id:
          type: string
          format: uuid
        owner_organization_id:
          type:
            - string
            - 'null'
          minLength: 1
        owner_user_id:
          type:
            - string
            - 'null'
          minLength: 1
        public_hostname:
          type: string
        visibility:
          type: string
          enum:
            - public
            - private
      required:
        - id
        - owner_organization_id
        - owner_user_id
        - public_hostname
        - visibility
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http
    webCookie:
      in: cookie
      name: __Secure-better-auth.session_token
      type: apiKey
    localWebCookie:
      in: cookie
      name: better-auth.session_token
      type: apiKey

````

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