> ## 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.

# Reconcile an Anthropic vault/credential webhook event (cleanup + analytics)



## OpenAPI

````yaml /api-reference/openapi.json post /v2/vaults/-/reconcile-event
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/vaults/-/reconcile-event:
    post:
      tags:
        - vaults
      summary: >-
        Reconcile an Anthropic vault/credential webhook event (cleanup +
        analytics)
      operationId: vault_reconcile_event
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/VaultEventReconcileInput'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VaultEventReconcileOutput'
components:
  schemas:
    VaultEventReconcileInput:
      type: object
      properties:
        event_id:
          type: string
          description: Webhook event id
          example: wevt_123
        event_type:
          type: string
          enum:
            - vault.created
            - vault.archived
            - vault.deleted
            - vault_credential.created
            - vault_credential.archived
            - vault_credential.deleted
            - vault_credential.refresh_failed
        resource_id:
          type: string
          description: >-
            Provider resource id that triggered the event (vault or credential
            id)
        vault_id:
          type: string
          description: Provider vault id the event belongs to
        organization_id:
          type: string
        workspace_id:
          type: string
        created_at:
          type: string
        owner_user_id:
          type: string
          nullable: true
          description: Base39 owner user id resolved from vault metadata
        owner_org_id:
          type: string
          nullable: true
          description: Base39 owner org id resolved from vault metadata
        owner_org_slug:
          type: string
          nullable: true
          description: Base39 owner org slug resolved from vault metadata
      required:
        - event_id
        - event_type
        - resource_id
        - vault_id
        - organization_id
        - workspace_id
        - created_at
        - owner_user_id
        - owner_org_id
        - owner_org_slug
    VaultEventReconcileOutput:
      type: object
      properties:
        reconciled:
          type: boolean
          description: Whether the vault event was reconciled (analytics captured)
        cleanedUsers:
          type: number
          description: Number of users whose ant_vault_id was cleared (vault.deleted only)
        ownerResolved:
          type: boolean
          description: Whether the Base39 owner was resolved from vault metadata
      required:
        - reconciled
        - cleanedUsers
        - ownerResolved
  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

````