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

# Update template

> Update template



## OpenAPI

````yaml /openapi-public.yml patch /templates/{templateID}
openapi: 3.1.0
info:
  title: E2B API
  version: 0.1.0
  description: >-
    Complete E2B developer API. Platform endpoints are served on api.e2b.app.
    Sandbox endpoints (envd) are served on the shared sandbox host
    (sandbox.e2b.app); target a specific sandbox with the E2b-Sandbox-Id and
    E2b-Sandbox-Port headers.
servers:
  - url: https://api.e2b.app
    description: E2B Platform API
security: []
tags:
  - name: Sandboxes
  - name: Templates
  - name: Tags
  - name: Volumes
  - name: Envd
  - name: Filesystem
  - name: Process
  - name: Teams
paths:
  /templates/{templateID}:
    servers:
      - url: https://api.e2b.app
        description: E2B Platform API
    patch:
      tags:
        - Templates
      summary: Update template
      description: Update template
      operationId: patchTemplate
      parameters:
        - $ref: '#/components/parameters/templateID'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TemplateUpdateRequest'
      responses:
        '200':
          description: The template was updated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TemplateUpdateResponse'
        '400':
          $ref: '#/components/responses/400'
        '401':
          $ref: '#/components/responses/401'
        '500':
          $ref: '#/components/responses/500'
      deprecated: true
      security:
        - ApiKeyAuth: []
        - AccessTokenAuth: []
components:
  parameters:
    templateID:
      name: templateID
      in: path
      required: true
      schema:
        type: string
  schemas:
    TemplateUpdateRequest:
      properties:
        public:
          type: boolean
          description: Whether the template is public or only accessible by the team
      type: object
    TemplateUpdateResponse:
      required:
        - names
      properties:
        names:
          type: array
          description: Names of the template (namespace/alias format when namespaced)
          items:
            type: string
      type: object
    Error:
      required:
        - code
        - message
      properties:
        code:
          type: integer
          format: int32
          description: Error code
        message:
          type: string
          description: Error
      type: object
  responses:
    '400':
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    '401':
      description: Authentication error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    '500':
      description: Server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
    AccessTokenAuth:
      type: http
      scheme: bearer

````