Infisical Project Templates API

The Project Templates API from Infisical — 2 operation(s) for project templates.

OpenAPI Specification

infisical-project-templates-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Infisical Admin Project Templates API
  description: List of all available APIs that can be consumed
  version: 0.0.1
servers:
- url: https://us.infisical.com
  description: Production server (US)
- url: https://eu.infisical.com
  description: Production server (EU)
- url: http://localhost:8080
  description: Local server
tags:
- name: Project Templates
paths:
  /api/v1/project-templates:
    get:
      tags:
      - Project Templates
      description: List project templates for the current organization.
      parameters:
      - schema:
          type: string
          enum:
          - secret-manager
          - cert-manager
          - kms
          - ssh
          - secret-scanning
          - pam
          - ai
        in: query
        name: type
        required: false
        description: The type of project template to list.
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  projectTemplates:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: uuid
                        name:
                          type: string
                        description:
                          type: string
                          nullable: true
                        roles:
                          type: array
                          items:
                            type: object
                            properties:
                              name:
                                type: string
                                minLength: 1
                              slug:
                                type: string
                                minLength: 1
                                maxLength: 64
                              permissions:
                                type: array
                                items:
                                  type: object
                                  properties:
                                    subject:
                                      anyOf:
                                      - type: string
                                        minLength: 1
                                      - type: array
                                        items:
                                          type: string
                                    action:
                                      anyOf:
                                      - type: string
                                        minLength: 1
                                      - type: array
                                        items:
                                          type: string
                                    conditions: {}
                                    inverted:
                                      type: boolean
                                  required:
                                  - action
                                  additionalProperties: false
                            required:
                            - name
                            - slug
                            - permissions
                            additionalProperties: false
                        environments:
                          type: array
                          items:
                            type: object
                            properties:
                              name:
                                type: string
                                minLength: 1
                              slug:
                                type: string
                                minLength: 1
                                maxLength: 64
                              position:
                                type: number
                                minimum: 1
                            required:
                            - name
                            - slug
                            - position
                            additionalProperties: false
                          nullable: true
                        orgId:
                          type: string
                          format: uuid
                        createdAt:
                          type: string
                          format: date-time
                        updatedAt:
                          type: string
                          format: date-time
                        type:
                          type: string
                          default: secret-manager
                        projectManagedIdentities:
                          type: array
                          items:
                            type: object
                            properties:
                              name:
                                type: string
                                minLength: 1
                              roles:
                                type: array
                                items:
                                  type: string
                            required:
                            - name
                            - roles
                            additionalProperties: false
                          nullable: true
                        users:
                          type: array
                          items:
                            type: object
                            properties:
                              username:
                                type: string
                                minLength: 1
                              roles:
                                type: array
                                items:
                                  type: string
                            required:
                            - username
                            - roles
                            additionalProperties: false
                          nullable: true
                        groups:
                          type: array
                          items:
                            type: object
                            properties:
                              groupSlug:
                                type: string
                              roles:
                                type: array
                                items:
                                  type: string
                            required:
                            - groupSlug
                            - roles
                            additionalProperties: false
                          nullable: true
                        identities:
                          type: array
                          items:
                            type: object
                            properties:
                              identityId:
                                type: string
                                format: uuid
                              identityName:
                                type: string
                              roles:
                                type: array
                                items:
                                  type: string
                            required:
                            - identityId
                            - identityName
                            - roles
                            additionalProperties: false
                          nullable: true
                      required:
                      - id
                      - name
                      - roles
                      - environments
                      - orgId
                      - createdAt
                      - updatedAt
                      - projectManagedIdentities
                      - users
                      - groups
                      - identities
                      additionalProperties: false
                required:
                - projectTemplates
                additionalProperties: false
        '400':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 400
                  message:
                    type: string
                  error:
                    type: string
                  details: {}
                required:
                - reqId
                - statusCode
                - message
                - error
                additionalProperties: false
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 401
                  message:
                    type: string
                  error:
                    type: string
                required:
                - reqId
                - statusCode
                - message
                - error
                additionalProperties: false
        '403':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 403
                  message:
                    type: string
                  details: {}
                  error:
                    type: string
                required:
                - reqId
                - statusCode
                - message
                - error
                additionalProperties: false
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 404
                  message:
                    type: string
                  error:
                    type: string
                required:
                - reqId
                - statusCode
                - message
                - error
                additionalProperties: false
        '422':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 422
                  message: {}
                  error:
                    type: string
                required:
                - reqId
                - statusCode
                - error
                additionalProperties: false
        '500':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  reqId:
                    type: string
                  statusCode:
                    type: number
                    enum:
                    - 500
                  message:
                    type: string
                  error:
                    type: string
                required:
                - reqId
                - statusCode
                - message
                - error
                additionalProperties: false
    post:
      tags:
      - Project Templates
      description: Create a project template.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  minLength: 1
                  maxLength: 64
                  description: The name of the project template to be created. Must be slug-friendly.
                description:
                  type: string
                  maxLength: 256
                  description: An optional description of the project template.
                roles:
                  type: array
                  items:
                    type: object
                    properties:
                      name:
                        type: string
                        minLength: 1
                      slug:
                        type: string
                        minLength: 1
                        maxLength: 64
                      permissions:
                        type: array
                        items:
                          anyOf:
                          - type: object
                            properties:
                              subject:
                                type: string
                                enum:
                                - secrets
                                description: The entity this permission pertains to.
                              inverted:
                                type: boolean
                                description: Whether rule allows or forbids.
                              action:
                                anyOf:
                                - type: string
                                  enum:
                                  - read
                                  - describeSecret
                                  - readValue
                                  - create
                                  - edit
                                  - delete
                                - type: array
                                  items:
                                    type: string
                                    enum:
                                    - read
                                    - describeSecret
                                    - readValue
                                    - create
                                    - edit
                                    - delete
                                  minItems: 1
                                description: Describe what action an entity can take.
                              conditions:
                                type: object
                                properties:
                                  environment:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  secretPath:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  secretName:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  secretTags:
                                    type: object
                                    properties:
                                      $in:
                                        type: array
                                        items:
                                          type: string
                                          minLength: 1
                                      $all:
                                        type: array
                                        items:
                                          type: string
                                          minLength: 1
                                    additionalProperties: false
                                  eventType:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                      additionalProperties: false
                                additionalProperties: false
                                description: When specified, only matching conditions will be allowed to access given resource.
                            required:
                            - subject
                            - action
                            additionalProperties: false
                          - type: object
                            properties:
                              subject:
                                type: string
                                enum:
                                - secret-folders
                                description: The entity this permission pertains to.
                              inverted:
                                type: boolean
                                description: Whether rule allows or forbids.
                              action:
                                anyOf:
                                - type: string
                                  enum:
                                  - read
                                  - create
                                  - edit
                                  - delete
                                - type: array
                                  items:
                                    type: string
                                    enum:
                                    - read
                                    - create
                                    - edit
                                    - delete
                                  minItems: 1
                                description: Describe what action an entity can take.
                              conditions:
                                type: object
                                properties:
                                  environment:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                      additionalProperties: false
                                  secretPath:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                additionalProperties: false
                                description: When specified, only matching conditions will be allowed to access given resource.
                            required:
                            - subject
                            - action
                            additionalProperties: false
                          - type: object
                            properties:
                              subject:
                                type: string
                                enum:
                                - secret-imports
                                description: The entity this permission pertains to.
                              inverted:
                                type: boolean
                                description: Whether rule allows or forbids.
                              action:
                                anyOf:
                                - type: string
                                  enum:
                                  - read
                                  - create
                                  - edit
                                  - delete
                                - type: array
                                  items:
                                    type: string
                                    enum:
                                    - read
                                    - create
                                    - edit
                                    - delete
                                  minItems: 1
                                description: Describe what action an entity can take.
                              conditions:
                                type: object
                                properties:
                                  environment:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  secretPath:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                additionalProperties: false
                                description: When specified, only matching conditions will be allowed to access given resource.
                            required:
                            - subject
                            - action
                            additionalProperties: false
                          - type: object
                            properties:
                              subject:
                                type: string
                                enum:
                                - dynamic-secrets
                                description: The entity this permission pertains to.
                              inverted:
                                type: boolean
                                description: Whether rule allows or forbids.
                              action:
                                anyOf:
                                - type: string
                                  enum:
                                  - read-root-credential
                                  - create-root-credential
                                  - edit-root-credential
                                  - delete-root-credential
                                  - lease
                                - type: array
                                  items:
                                    type: string
                                    enum:
                                    - read-root-credential
                                    - create-root-credential
                                    - edit-root-credential
                                    - delete-root-credential
                                    - lease
                                  minItems: 1
                                description: Describe what action an entity can take.
                              conditions:
                                type: object
                                properties:
                                  environment:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  secretPath:
                                    anyOf:
                                    - type: string
                                    - type: object
                                      properties:
                                        $eq:
                                          type: string
                                          minLength: 1
                                        $ne:
                                          type: string
                                          minLength: 1
                                        $in:
                                          type: array
                                          items:
                                            type: string
                                            minLength: 1
                                        $glob:
                                          type: string
                                          minLength: 1
                                      additionalProperties: false
                                  metadata:
                                    type: object
                                    properties:
                                      $elemMatch:
                                        type: object
                                        properties:
                                          key:
                                            type: object
                                            properties:
                                              $eq:
                                                type: string
                                                minLength: 1
                                              $ne:
                                                type: string
                                                minLength: 1
                                              $in:
                                                type: array
                                                items:
                                                  type: string
                                                  minLength: 1
                                            additionalProperties: false
                                          value:
                                            type: object
                                            properties:
                                              $eq:
                                                type: string
                                                minLength: 1

# --- truncated at 32 KB (397 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/infisical/refs/heads/main/openapi/infisical-project-templates-api-openapi.yml