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

# Search People via Query

> 

Search and enrich leads using this endpoint.

This endpoint searches for contacts in bulk using natural language queries and can enrich them with contact details and Personalized AI insights:
- Verified email addresses.
- Verified phone numbers.
- Professional summary.
- Top problems.
- Internal strategic initiatives.
- Public appearances.

You can search for up to 1000 contacts in a single request by adjusting the limit parameter.

To receive the results, you must provide a `webhookUrl`.



## OpenAPI

````yaml /api-reference/combined.json post /v1/leads/search
openapi: 3.1.0
info:
  title: Precept API
  description: >-
    Precept API provides powerful, programmatic access to our AI-driven B2B
    account research, company enrichment, and verified contact data
    capabilities. Use these endpoints to discover high-intent companies, map
    decision-makers, and run personalized enrichment pipelines directly
    integrating with your CRM, spreadsheets, or automated workflows like Make
    and n8n.
  version: 1.0.0
servers:
  - url: https://api.preceptai.co.uk
security:
  - bearerAuth: []
paths:
  /v1/leads/search:
    post:
      tags:
        - People
      summary: Search People via Query
      description: >-


        Search and enrich leads using this endpoint.


        This endpoint searches for contacts in bulk using natural language
        queries and can enrich them with contact details and Personalized AI
        insights:

        - Verified email addresses.

        - Verified phone numbers.

        - Professional summary.

        - Top problems.

        - Internal strategic initiatives.

        - Public appearances.


        You can search for up to 1000 contacts in a single request by adjusting
        the limit parameter.


        To receive the results, you must provide a `webhookUrl`.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/LeadsSearchRequest'
            examples:
              default:
                summary: A default example for searching leads.
                value:
                  query: Marketing heads at SaaS companies in California
                  webhookUrl: https://your-site.com/webhook
                  limit: 50
                  enrichType:
                    - emails
                    - phones
                  findInsights: true
                  name: California SaaS Marketing Heads
                  includeContactDetails: false
              withPostInteractionSignal:
                summary: Search leads with LinkedIn post interaction signal.
                value:
                  query: CTOs and VP Engineering in Fintech
                  webhookUrl: https://your-site.com/webhook
                  limit: 30
                  signal:
                    type: post_interaction
                    keywords:
                      - fraud detection
                      - AML compliance
                  includeContactDetails: false
      responses:
        '202':
          description: >-
            Request accepted. The enrichment is in progress. The response will
            vary based on whether all leads could be processed.
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    properties:
                      message:
                        type: string
                        example: >-
                          Enrichment job successfully created and batches are
                          being processed.
                      enrichment_id:
                        type: string
                        format: uuid
                  - type: object
                    properties:
                      message:
                        type: string
                        example: >-
                          Not enough credits to enrich all leads. 15 leads
                          enrichment in progress. Please upgrade your plan to
                          enrich all leads.
                      enrichment_id:
                        type: string
                        format: uuid
                      skipped_leads:
                        type: array
                        items:
                          $ref: '#/components/schemas/LeadInput'
        '400':
          description: Bad Request - Invalid input.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  message:
                    type: string
              examples:
                default:
                  summary: Example of a 400 error response.
                  value:
                    error: Bad Request
                    message: Invalid input, please check the documentation.
        '402':
          description: Insufficient credits to process any leads.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
              examples:
                default:
                  summary: Example of a 402 error response.
                  value:
                    message: >-
                      Not enough credits to start enrichment. Please upgrade
                      your plan to start enrichment.
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              examples:
                default:
                  summary: Example of a 500 error response.
                  value:
                    error: Internal server error.
components:
  schemas:
    LeadsSearchRequest:
      type: object
      required:
        - query
      properties:
        query:
          type: string
          description: >-
            Natural language query to search for leads (e.g. 'Software
            architects at tech companies in London').
        webhookUrl:
          type: string
          format: uri
          description: >-
            Optional. Your webhook URL to receive the result of the lead search
            operations. If not provided, you can poll the GET /v1/jobs/{jobId}
            endpoint.
        limit:
          type: integer
          maximum: 1000
          description: Maximum number of leads to return (up to 1000).
        enrichType:
          type: array
          description: 'The type of data to find. Possible values: `emails`, `phones`.'
          items:
            type: string
            enum:
              - emails
              - phones
        findInsights:
          type: boolean
          description: >-
            Generate AI insights (summary, top problems, strategic initiatives,
            public appearances) for each lead. Charges 1.1 credits per lead if
            true, else 0.1 credits.
        name:
          type: string
          description: >-
            A readable name for your enrichment job for searching on your
            dashboard.
        includeContactDetails:
          type: boolean
          description: >-
            Whether to include contact details (email and phone) for the
            discovered leads. If true, the webhook results will map back these
            fields as `enrich_email` and `enrich_phone`.
        signal:
          type: object
          description: >-
            Optional LinkedIn activity signal for filtering persona search. Adds
            +5 credits per lead. Finds people matching your query who recently
            engaged (posted, liked, commented) with relevant content. (For post
            author discovery without persona query, use POST
            /v1/leads/post-search).
          required:
            - type
            - keywords
          properties:
            type:
              type: string
              enum:
                - post_interaction
              description: >-
                Find people who recently engaged (posted, liked, commented) with
                LinkedIn posts matching keywords.
            keywords:
              type: array
              items:
                type: string
              minItems: 1
              maxItems: 5
              description: 1 to 5 keywords or phrases to find engaged leads.
        streamingResults:
          type: boolean
          description: >-
            Optional. When true and a `webhookUrl` is provided, contact results
            are progressively streamed in real-time as each lead is enriched
            (with `status: "in_progress"`), followed by a final completion
            webhook when all leads finish.
    LeadInput:
      type: object
      properties:
        linkedinUrl:
          type: string
          format: uri
        firstName:
          type: string
        lastName:
          type: string
        companyName:
          type: string
        companyDomain:
          type: string
        enrichType:
          type: array
          items:
            type: string
            enum:
              - emails
              - phones
        customData:
          type: object
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.