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

# Create

> Create a new PKI discovery configuration



## OpenAPI

````yaml POST /api/v1/cert-manager/discovery-jobs
openapi: 3.0.3
info:
  title: Infisical 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
security: []
paths:
  /api/v1/cert-manager/discovery-jobs:
    post:
      tags:
        - PKI Discovery
      description: Create a new PKI discovery configuration
      operationId: createPkiDiscovery
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  minLength: 1
                  maxLength: 100
                  description: Name of the discovery configuration
                description:
                  type: string
                  maxLength: 500
                  description: Description of the discovery configuration
                discoveryType:
                  type: string
                  enum:
                    - network
                  default: network
                  description: Type of discovery scan
                targetConfig:
                  type: object
                  properties:
                    ipRanges:
                      type: array
                      items:
                        type: string
                        maxLength: 64
                    domains:
                      type: array
                      items:
                        type: string
                        maxLength: 253
                    ports:
                      type: string
                      default: 443, 8443, 636, 993, 995
                  additionalProperties: false
                  description: Target configuration for discovery scans
                isAutoScanEnabled:
                  type: boolean
                  default: false
                  description: Enable automatic scheduled scans
                scanIntervalDays:
                  type: number
                  minimum: 1
                  maximum: 365
                  description: Interval in days between automatic scans
                gatewayId:
                  type: string
                  format: uuid
                  description: Gateway ID for scanning private networks
                gatewayPoolId:
                  type: string
                  format: uuid
                  description: Gateway pool ID for scanning private networks
              required:
                - name
                - targetConfig
              additionalProperties: false
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                  name:
                    type: string
                  description:
                    type: string
                    nullable: true
                  discoveryType:
                    type: string
                    default: network
                  targetConfig: {}
                  isAutoScanEnabled:
                    type: boolean
                    default: false
                  scanIntervalDays:
                    type: number
                    nullable: true
                  gatewayId:
                    type: string
                    format: uuid
                    nullable: true
                  isActive:
                    type: boolean
                    default: true
                  lastScanStatus:
                    type: string
                    nullable: true
                  lastScanJobId:
                    type: string
                    nullable: true
                  lastScanMessage:
                    type: string
                    nullable: true
                  lastScannedAt:
                    type: string
                    format: date-time
                    nullable: true
                  createdAt:
                    type: string
                    format: date-time
                  updatedAt:
                    type: string
                    format: date-time
                  gatewayPoolId:
                    type: string
                    format: uuid
                    nullable: true
                required:
                  - id
                  - name
                  - createdAt
                  - updatedAt
                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

````