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

# Search User Docs

> Searches for documents associated with a specific user.

Parameters:
    x_developer_id (UUID): The unique identifier of the developer associated with the user.
    search_params (TextOnlyDocSearchRequest | VectorDocSearchRequest | HybridDocSearchRequest): The parameters for the search.
    user_id (UUID): The unique identifier of the user associated with the documents.
Returns:
    DocSearchResponse: The search results.



## OpenAPI

````yaml https://api.julep.ai/api/openapi.json post /users/{user_id}/search
openapi: 3.1.0
info:
  title: Julep Agents API
  description: API for Julep Agents
  termsOfService: https://www.julep.ai/terms
  contact:
    name: Julep
    url: https://www.julep.ai/
    email: developers@julep.ai
  version: 0.4.0
servers:
  - url: /api
security: []
paths:
  /users/{user_id}/search:
    post:
      tags:
        - docs
      summary: Search User Docs
      description: |-
        Searches for documents associated with a specific user.

        Parameters:
            x_developer_id (UUID): The unique identifier of the developer associated with the user.
            search_params (TextOnlyDocSearchRequest | VectorDocSearchRequest | HybridDocSearchRequest): The parameters for the search.
            user_id (UUID): The unique identifier of the user associated with the documents.
        Returns:
            DocSearchResponse: The search results.
      operationId: search_user_docs_users__user_id__search_post
      parameters:
        - name: user_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: User Id
        - name: connection_pool
          in: query
          required: false
          schema:
            title: Connection Pool
      requestBody:
        required: true
        content:
          application/json:
            schema:
              anyOf:
                - $ref: '#/components/schemas/TextOnlyDocSearchRequest'
                - $ref: '#/components/schemas/VectorDocSearchRequest'
                - $ref: '#/components/schemas/HybridDocSearchRequest'
              title: Search Params
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DocSearchResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKeyHeader: []
components:
  schemas:
    TextOnlyDocSearchRequest:
      properties:
        limit:
          type: integer
          maximum: 50
          minimum: 1
          title: Limit
          default: 10
        metadata_filter:
          type: object
          title: Metadata Filter
          default: {}
        include_embeddings:
          type: boolean
          title: Include Embeddings
          default: true
        text:
          type: string
          title: Text
        lang:
          type: string
          title: Lang
          default: en-US
        trigram_similarity_threshold:
          anyOf:
            - type: number
              maximum: 1
              minimum: 0
            - type: 'null'
          title: Trigram Similarity Threshold
      type: object
      required:
        - text
      title: TextOnlyDocSearchRequest
    VectorDocSearchRequest:
      properties:
        limit:
          type: integer
          maximum: 50
          minimum: 1
          title: Limit
          default: 10
        metadata_filter:
          type: object
          title: Metadata Filter
          default: {}
        include_embeddings:
          type: boolean
          title: Include Embeddings
          default: true
        vector:
          items:
            type: number
          type: array
          title: Vector
        confidence:
          type: number
          maximum: 1
          minimum: -1
          title: Confidence
          default: 0.5
        mmr_strength:
          type: number
          exclusiveMaximum: 1
          minimum: 0
          title: Mmr Strength
          default: 0.5
      type: object
      required:
        - vector
      title: VectorDocSearchRequest
    HybridDocSearchRequest:
      properties:
        limit:
          type: integer
          maximum: 50
          minimum: 1
          title: Limit
          default: 10
        metadata_filter:
          type: object
          title: Metadata Filter
          default: {}
        include_embeddings:
          type: boolean
          title: Include Embeddings
          default: true
        text:
          type: string
          title: Text
        lang:
          type: string
          title: Lang
          default: en-US
        trigram_similarity_threshold:
          anyOf:
            - type: number
              maximum: 1
              minimum: 0
            - type: 'null'
          title: Trigram Similarity Threshold
        vector:
          items:
            type: number
          type: array
          title: Vector
        confidence:
          type: number
          maximum: 1
          minimum: -1
          title: Confidence
          default: 0.5
        mmr_strength:
          type: number
          exclusiveMaximum: 1
          minimum: 0
          title: Mmr Strength
          default: 0.5
        alpha:
          type: number
          maximum: 1
          minimum: 0
          title: Alpha
          default: 0.5
        k_multiplier:
          type: integer
          maximum: 10
          minimum: 1
          title: K Multiplier
          default: 5
      type: object
      required:
        - text
        - vector
      title: HybridDocSearchRequest
    DocSearchResponse:
      properties:
        docs:
          items:
            $ref: '#/components/schemas/DocReference'
          type: array
          title: Docs
        time:
          type: number
          exclusiveMinimum: 0
          title: Time
      type: object
      required:
        - docs
        - time
      title: DocSearchResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    DocReference:
      properties:
        metadata:
          anyOf:
            - type: object
            - type: 'null'
          title: Metadata
        owner:
          $ref: '#/components/schemas/DocOwner'
        id:
          type: string
          format: uuid
          title: Id
          readOnly: true
        title:
          anyOf:
            - type: string
            - type: 'null'
          title: Title
        snippet:
          $ref: '#/components/schemas/Snippet'
        distance:
          anyOf:
            - type: number
            - type: 'null'
          title: Distance
      type: object
      required:
        - owner
        - id
        - snippet
      title: DocReference
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    DocOwner:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        role:
          type: string
          enum:
            - user
            - agent
          title: Role
      type: object
      required:
        - id
        - role
      title: DocOwner
    Snippet:
      properties:
        index:
          type: integer
          title: Index
        content:
          type: string
          title: Content
        embedding:
          anyOf:
            - items:
                type: number
              type: array
            - type: 'null'
          title: Embedding
      type: object
      required:
        - index
        - content
      title: Snippet
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: Authorization

````