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

# Process a judicial-monitoring webhook delivery (novo_processo)



## OpenAPI

````yaml /api-reference/openapi.json post /v2/tasks/-/webhook/process
openapi: 3.1.0
info:
  title: Base39 API
  description: Base39 API
  version: 1.0.0
  contact:
    name: Base39 Team
    url: https://base39.com.br
    email: suporte@base39.com.br
  termsOfService: https://base39.com.br/termos
  license:
    name: Proprietary
    url: https://base39.com.br/termos
servers:
  - url: http://localhost:3000
    description: Local
  - url: https://api.dev.base39.cloud
    description: Development
  - url: https://api.base39.com.br
    description: Production
security:
  - OAuth2: []
tags:
  - name: pages
    description: Profiles and reports pages
  - name: pipelines
    description: Pipeline boards (kanban) of pages
  - name: blocks
    description: Blocks operations
  - name: search
    description: Search across content
  - name: targets
    description: Lookup targets via datasets
  - name: CognitoTriggers
    description: Cognito triggers
paths:
  /v2/tasks/-/webhook/process:
    post:
      tags:
        - tasks
      summary: Process a judicial-monitoring webhook delivery (novo_processo)
      operationId: task_process_webhook
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TaskWebhookProcessInput'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskWebhookProcessOutput'
components:
  schemas:
    TaskWebhookProcessInput:
      type: object
      properties:
        event:
          type: string
          enum:
            - novo_processo
          example: novo_processo
        monitoramento:
          $ref: '#/components/schemas/TaskWebhookMonitoringInput'
        processo:
          $ref: '#/components/schemas/TaskWebhookProcessoInput'
        uuid:
          type: string
          description: Unique webhook delivery id (idempotency key)
          example: evt_123
      required:
        - event
        - monitoramento
        - processo
        - uuid
    TaskWebhookProcessOutput:
      type: object
      properties:
        handled:
          type: boolean
          description: Whether at least one task was handled
        task_ids:
          description: Ids of the tasks that processed the event
          type: array
          items:
            type: string
      required:
        - handled
        - task_ids
    TaskWebhookMonitoringInput:
      type: object
      properties:
        id:
          type: number
          description: Remote monitoring resource id
          example: 12345
        termo:
          type: string
          description: Monitored term
          example: '12345678000190'
        criado_em:
          type: string
          description: Monitoring creation timestamp
          example: '2024-01-01T00:00:00Z'
        variacoes:
          description: Term variations
          type: array
          items:
            type: string
        termos_auxiliares:
          description: Auxiliary terms
          type: array
          items:
            type: string
      required:
        - id
        - termo
        - criado_em
        - variacoes
        - termos_auxiliares
    TaskWebhookProcessoInput:
      type: object
      properties:
        numero_cnj:
          type: string
          description: CNJ number of the detected lawsuit
          example: 0000000-00.0000.0.00.0000
        data_inicio:
          type: string
          nullable: true
          description: Distribution date
        tribunal:
          type: string
          nullable: true
          description: Court name
        estado_origem:
          nullable: true
          allOf:
            - $ref: '#/components/schemas/TaskWebhookProcessoEstadoOrigemInput'
      required:
        - numero_cnj
    TaskWebhookProcessoEstadoOrigemInput:
      type: object
      properties:
        nome:
          type: string
          nullable: true
        sigla:
          type: string
          nullable: true
  securitySchemes:
    OAuth2:
      type: oauth2
      flows:
        authorizationCode:
          authorizationUrl: https://id.local.base39.cloud/oauth2/authorize
          tokenUrl: https://id.local.base39.cloud/oauth2/token
          scopes:
            profile: Read user profile
            email: Read user email
            openid: OpenID authentication
      description: OAuth2 Authorization Code flow

````