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

# Search project logs



## OpenAPI

````yaml /openapi/platform-api.yaml post /o/{organisation_id}/projects/{project_id}/logs
openapi: 3.1.0
info:
  title: Versori Platform API
  version: 0.0.1
  license:
    name: UNLICENSED
servers:
  - description: Production
    url: https://platform.versori.com/api/v2
  - description: Staging
    url: https://platform-staging.versori.com/api/v2
  - description: Development
    url: http://localhost:8901
security:
  - bearerToken: []
  - cookie: []
paths:
  /o/{organisation_id}/projects/{project_id}/logs:
    parameters:
      - $ref: '#/components/parameters/organisation_id'
      - $ref: '#/components/parameters/project_id'
      - $ref: '#/components/parameters/project_env'
    post:
      tags:
        - projects
      summary: Search project logs
      operationId: SearchProjectLogs
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/LogSearch'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Logs'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  parameters:
    organisation_id:
      name: organisation_id
      in: path
      required: true
      schema:
        type: string
        format: ulid
        x-go-type: ulid.ULID
        x-go-name: OrganisationID
        x-go-type-import:
          path: versori.dev/vergo/ulid
    project_id:
      name: project_id
      in: path
      required: true
      schema:
        type: string
        format: ulid
        x-go-type: ulid.ULID
        x-go-name: ProjectID
        x-go-type-import:
          path: versori.dev/vergo/ulid
    project_env:
      name: project_env
      in: query
      required: false
      schema:
        type: string
  schemas:
    LogSearch:
      type: object
      properties:
        build:
          type: boolean
        startTime:
          type: string
          format: timestamp
        endTime:
          type: string
          format: timestamp
        order:
          type: string
        latest:
          type: boolean
          description: only include projcet logs from the latest version
        nextToken:
          type: string
        first:
          type: integer
        filters:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
                x-go-type-skip-optional-pointer: true
                description: >-
                  Required for field-specific matchers (eq, not_eq, reg_eq,
                  not_reg_eq). Must be empty for full-text matchers (search,
                  not_search).
              value:
                type: string
                description: The value to match against. Required for all matchers.
              match:
                type: string
                description: >
                  The type of matching to perform against the value:

                  - 'eq': Exact match on specified field (requires field)

                  - 'not_eq': Negated exact match on specified field (requires
                  field)

                  - 'reg_eq': Regular expression match on specified field
                  (requires field)

                  - 'not_reg_eq': Negated regular expression match on specified
                  field (requires field)

                  - 'search': Full-text search across all fields (field must be
                  empty)

                  - 'not_search': Negated full-text search across all fields
                  (field must be empty)
            required:
              - value
              - match
    Logs:
      type: object
      properties:
        logs:
          type: array
          items:
            $ref: '#/components/schemas/Log'
        nextToken:
          type: string
      required:
        - logs
    Error:
      type: object
      properties:
        code:
          type: string
          description: Code is a machine-readable error code.
        message:
          type: string
          description: Message is a human-readable error message.
        fields:
          type: array
          items:
            $ref: '#/components/schemas/ErrorField'
          x-go-type-skip-optional-pointer: true
        details:
          type: string
          x-go-type-skip-optional-pointer: true
      required:
        - code
        - message
    Log:
      type: object
      properties:
        timestamp:
          type: string
        severity:
          type: string
        message:
          type: string
        error:
          type: string
          x-go-type-skip-optional-pointer: true
        httpRequest:
          type: object
          x-go-type: any
          x-go-type-skip-optional-pointer: true
        fields:
          type: object
          x-go-type: any
          x-go-type-skip-optional-pointer: true
      required:
        - timestamp
        - severity
        - message
    ErrorField:
      description: ErrorField denotes a field which has an error.
      type: object
      properties:
        field:
          type: string
          description: >
            Field is the name of the field which has an error, this may be a
            path to a nested field, including array

            elements. The format of this field is of the form:
            "field1.field2[0].field3"
        message:
          type: string
          description: Message is the error message for this specific field.
      required:
        - field
        - message
  securitySchemes:
    bearerToken:
      description: >
        Bearer token authentication used by the Versori Platform. External
        consumers must provide an API key, however

        internal consumers must provide a JWT id_token issued by our IdP.
      type: http
      scheme: bearer
    cookie:
      description: Cookie authentication used by the Versori Platform.
      type: apiKey
      in: cookie
      name: cookie

````