---
title: "POST /api/v1/cert-manager/discovery-jobs"
method: POST
path: "/api/v1/cert-manager/discovery-jobs"
tags: ["PKI Discovery"]
---

# POST /api/v1/cert-manager/discovery-jobs

`POST /api/v1/cert-manager/discovery-jobs`

## Request

- Base URL: `https://us.infisical.com`
- URL: `https://us.infisical.com/api/v1/cert-manager/discovery-jobs`
- Auth: none declared

Create a new PKI discovery configuration

## Request body

- object
  - `name` string, required: Name of the discovery configuration
  - `description` string: Description of the discovery configuration
  - `discoveryType` 'network' | 'linux-server': Type of discovery scan
  - `targetConfig` object, required: Target configuration. Network jobs use domains, ipRanges and ports. Linux Server jobs use connectionIds, searchFolderPaths, skipFolderPaths, maxFolderDepth, maxFileSizeKb and importStandaloneCaCertificates.
    - `ipRanges` string[]: IP addresses or CIDR ranges to scan (Network jobs).
    - `domains` string[]: Domains to scan (Network jobs).
    - `ports` string: Comma-separated ports or ranges (Network jobs).
    - `connectionIds` string[]: IDs of the SSH connections to scan. Each connection must use a gateway.
    - `searchFolderPaths` string[]: Folders to search. Each folder is searched along with the folders below it.
    - `skipFolderPaths` string[]: Folders that are never entered.
    - `maxFolderDepth` integer: How many levels below each search folder to go.
    - `maxFileSizeKb` integer: Files bigger than this, in KB, are skipped.
    - `importStandaloneCaCertificates` boolean: Also import CA certificates found on their own. Leaf certificates always bring their chain.
  - `isAutoScanEnabled` boolean: Enable automatic scheduled scans
  - `scanIntervalDays` number: Interval in days between automatic scans
  - `gatewayId` string, uuid: Gateway ID for scanning private networks
  - `gatewayPoolId` string, uuid: Gateway pool ID for scanning private networks

## Response `200`

Default Response

- object
  - `id` string, uuid, required
  - `name` string, required
  - `description` string, nullable
  - `discoveryType` string
  - `targetConfig` unknown
  - `isAutoScanEnabled` boolean
  - `scanIntervalDays` number, nullable
  - `gatewayId` string, uuid, nullable
  - `isActive` boolean
  - `lastScanStatus` string, nullable
  - `lastScanJobId` string, nullable
  - `lastScanMessage` string, nullable
  - `lastScannedAt` string, date-time, nullable
  - `createdAt` string, date-time, required
  - `updatedAt` string, date-time, required
  - `gatewayPoolId` string, uuid, nullable

## Other responses

- `400`: Default Response
- `401`: Default Response
- `403`: Default Response
- `404`: Default Response
- `422`: Default Response
- `500`: Default Response

## Changes

- **2026-10-22** `0eb777174b0f`: 1 warning, 7 info
  - the `targetConfig/ports` request property's maxLength was set to `256`
  - added the new optional request property `targetConfig/connectionIds`
  - added the new optional request property `targetConfig/importStandaloneCaCertificates`
  - added the new optional request property `targetConfig/maxFileSizeKb`
  - …4 more
- **2026-08-05** `f10a4f8c1d41`: 1 breaking
  - the `description` request property's maxLength was decreased to `255`

[Operation history](https://skmtc.dev/infisical/apis/infisical-api/changes/api/v1/cert-manager/discovery-jobs/post.md)

---

[API](https://skmtc.dev/infisical/apis/infisical-api.md) - [All operations](https://skmtc.dev/infisical/apis/infisical-api/llms.txt) - [OpenAPI document](https://skmtc.dev/infisical/apis/infisical-api/revisions/7f940199c899?raw)
