---
title: "NOTE: Searches personal and service principal API keys"
method: POST
path: "/api/v1/search/iam/api_keys"
tags: ["Personal Client"]
---

# NOTE: Searches personal and service principal API keys

`POST /api/v1/search/iam/api_keys`

## Request

- Base URL: `https://example.conductor.one`
- URL: `https://example.conductor.one/api/v1/search/iam/api_keys`
- Auth: HTTP bearer and OAuth 2
  - Client credentials
  - Token URL: `/auth/v1/token`

Search finds personal client credentials and service principal credentials, with optional filtering by query text or key type.
 Request a modest page_size (≤25) to keep responses small.

## Request body

- C1ApiApiKeyV1APIKeySearchServiceSearchRequest: The APIKeySearchServiceSearchRequest message.
  - `pageSize` integer: The maximum number of results to return per page.
  - `pageToken` string: A pagination token returned from a previous Search call.
  - `query` string: A text query to filter API keys by display name.
  - `types` string[], nullable: The key types to return. When empty, both types are returned.

## Response `200`

Successful response

- C1ApiApiKeyV1APIKeySearchServiceSearchResponse: The APIKeySearchServiceSearchResponse message.
  - `list` C1ApiApiKeyV1APIKey[], nullable: The list of API keys matching the search criteria.
    - `personalClient` C1ApiIamV1PersonalClient: The PersonalClient message contains information about a presonal client credential.
      - `allowSourceCidr` string[], nullable: If set, only allows the CIDRs in the array to use the credential. Accepts IPv4 (e.g. 10.0.0.0/24) or IPv6 (e.g. 2001:db8::/32) CIDRs.
      - `clientId` string: The clientID of the credential.
      - `createdAt` string, date-time, nullable
      - `deletedAt` string, date-time, nullable
      - `displayName` string: The display name of the personal client credential.
      - `expiresTime` string, date-time, nullable
      - `id` string: The unique ID of the personal client credential.
      - `lastUsedAt` string, date-time, nullable
      - `scopedRoles` string[], nullable: scoped_roles provides a list of IAM Roles that this OAuth2 Client's API permissions are reduced to. The permissions granted to OAuth2 Client are AND'ed against the owning User's own permissions.
      - `updatedAt` string, date-time, nullable
      - `userId` string: The ID of the user that this credential is created for.
    - `servicePrincipalKey` C1ApiApiKeyV1ServicePrincipalAPIKey: ServicePrincipalAPIKey is a service principal credential with the caller's permissions on its service principal.
      - `credential` C1ApiServicePrincipalV1ServicePrincipalCredential: ServicePrincipalCredential represents a client credential for a service principal.
        - `allowSourceCidrs` string[], nullable: CIDR restrictions for this credential.
        - `clientId` string: The full client ID in format: ${cutename}@${tenant}.${installation}/spc
        - `createdAt` string, date-time, nullable
        - `displayName` string: The display name of the credential.
        - `expiresAt` string, date-time, nullable
        - `id` string: The unique ID of the credential (cutename format).
        - `lastUsedAt` string, date-time, nullable
        - `requireDpop` boolean: Whether DPoP proof-of-possession is required for this credential.
        - `scopedRoleIds` string[], nullable: Scoped role IDs for this credential (intersection with SP roles at token issuance).
        - `servicePrincipalId` string: The service principal user ID this credential belongs to.
      - `objectPermissions` C1ApiAuthorizationV1ActorObjectPermissions: ActorObjectPermissions describes which actions the calling user is permitted to perform on an object, as determined by policy.
        - `delete` boolean: The delete field.
        - `edit` boolean: The edit field.
        - `extra` object: The extra field.
        - `read` boolean: The read field.
  - `nextPageToken` string: A token to retrieve the next page of results, or empty if there are no more results.

## Changes

- **2026-10-20** `fe943bedf41b`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/conductorone/apis/c1-api/changes/api/v1/search/iam/api_keys/post.md)

---

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