Documentation Index

Fetch the complete documentation index at: /llms.txt

Use this file to discover all available pages before exploring further.

LOCAL DRAFT PREVIEW. Not published. Pages tagged Draft are new, pages tagged Updated have additions. Yellow 'To confirm' boxes are internal questions.

Fini home pagelight logodark logo
    Documentation
    Use cases
    Trust & pricing
    API reference

    API Setup

    • API overview
    • API contract
    • Static IP Addresses
    • Database and Warehouse Connections
    • MCP Connections

    LLM Access

    • Coding agents
    • Claude Plugin

    Agents

    • Overview
    • POST
      Create agent
    • List agents
    • DEL
      Delete agent

    Analytics

    • Overview
    • Get agent analytics
    • Get agent analytics section

    Prompts

    • Overview
    • Get prompts
    • Get prompt history
    • Get prompt version
    • Update prompts
    • POST
      Create prompt draft version
    • Get prompt draft version
    • Publish prompt draft version
    • DEL
      Delete prompt draft version

    Actions

    • Overview
    • List actions
    • Get action
    • POST
      Create action
    • Update action
    • DEL
      Delete action
    • Test action
    • List agent assignments
    • POST
      Assign to agents

    Attributes

    • Overview
    • List attributes
    • Get attribute
    • POST
      Create attribute
    • Update attribute
    • DEL
      Delete attribute
    • Test attribute
    • List agent assignments
    • POST
      Assign to agents

    External API calls

    • Overview
    • List external API calls
    • Get external API call
    • POST
      Create external API call
    • Update external API call
    • DEL
      Delete external API call
    • Test external API call

    Intent Rules

    • Overview
    • List intent rules
    • Get intent rule
    • Get intent-rule fields context
    • POST
      Generate intent-rule draft with AI
    • POST
      Create intent rule
    • Update intent rule
    • List intent-rule versions
    • Get intent-rule version
    • Publish intent-rule draft
    • Restore intent-rule version as draft
    • DEL
      Delete intent-rule draft version
    • Get rule version test paths
    • Preview rule test paths
    • Run rule version test path
    • Run rule test path from config
    • DEL
      Delete intent rule

    Guardrails

    • Overview
    • List guardrail check types
    • List guardrail policies
    • Get guardrail policy
    • POST
      Create guardrail policy
    • Update guardrail policy
    • DEL
      Delete guardrail policy
    • List guardrail runs
    • Get guardrail hits

    Business Rules

    • Overview
    • List Business Rules
    • Get Business Rule
    • Get Business Rule fields context
    • List default Business Rules
    • POST
      Create Business Rule
    • POST
      Duplicate Business Rule
    • POST
      Evaluate Business Rule
    • Get Business Rule test fields
    • Preview Business Rule test fields
    • Update Business Rule
    • DEL
      Delete Business Rule

    Reply Rules

    • Overview
    • Get reply rules
    • Get reply rule fields context
    • Update reply rule

    Tag groups

    • Overview
    • List tag groups
    • Get tag group
    • POST
      Create tag group
    • Update tag group
    • DEL
      Delete tag group

    Tags

    • Overview
    • Get tag
    • List tags in group
    • List tags across groups
    • POST
      Create tag
    • Update tag
    • DEL
      Delete tag

    Conversations

    • Overview
    • List conversations
    • Get conversation
    • Get event metadata
    • POST
      Generate Answer
    • Send conversation feedback
    • Mark feedback resolved
    • POST
      Add feedback note
    • POST
      Evaluate conversation rule
    • DEL
      Delete conversation
    • DEL
      Bulk delete conversations

    Refine with AI

    • Overview
    • POST
      Create Refine with AI iteration
    • Get active Refine with AI session
    • Get Refine with AI session

    Replays

    • Replays
    • POST
      Create replay
    • List replays
    • Get replay
    • Get replay events

    Test Sets

    • Overview
    • List test sets
    • POST
      Create a test set
    • Get fields context
    • Get a test set
    • Update a test set
    • DEL
      Delete a test set
    • POST
      Add criteria
    • Update a criterion
    • DEL
      Delete a criterion
    • List runs
    • Start a run
    • Get a run

    Knowledge

    Updates

    • Changelog
      Draft
    Conversations

    Get event metadata

    > ## Documentation Index
    > Fetch the complete documentation index at: https://docs.usefini.com/llms.txt
    > Use this file to discover all available pages before exploring further.
    
    # Get event metadata
    
    > Fetch reasoning, knowledge, tag, attribute, and rule metadata for one Fini-authored event.
    
    Returns execution metadata for one Fini-authored event in your workspace. Use this endpoint when a conversation export tells you which event to inspect, but you need the detailed trace behind that response: planning, knowledge search, answer reasoning, tag selection, executed Attributes, and executed Rules.
    
    <Tip>
      Use [List conversations](/en/api-reference/list-conversations) or [Get conversation](/en/api-reference/get-conversation) to discover event IDs. This route only returns metadata for events where `role` is `finibot`.
    </Tip>
    
    <Note>
      This public API route is currently registered as `/v2/hc-events/{id}/metadata`, without the `/public` suffix used by most other public endpoints. It still requires a workspace API key with `read` scope.
    </Note>
    
    ## Headers
    
    <ParamField header="Authorization" type="string" required>
      Bearer token containing your Fini workspace API key. Format: `Bearer fini_...` The key needs `read` scope.
    </ParamField>
    
    ## Path parameters
    
    <ParamField path="id" type="string" required>
      Event ID to inspect. The event must belong to your workspace and have `role: "finibot"`.
    </ParamField>
    
    <RequestExample>
      ~~~bash cURL theme={null}
      curl --request GET \
        --url 'https://api-prod.usefini.com/v2/hc-events/2f7dcb2f-2a41-4f5d-a4ad-2b6cbf61d20a/metadata' \
        --header 'Authorization: Bearer fini_your_api_key'
      ~~~
    
      ~~~python Python theme={null}
      import requests
    
      event_id = "2f7dcb2f-2a41-4f5d-a4ad-2b6cbf61d20a"
      response = requests.get(
          f"https://api-prod.usefini.com/v2/hc-events/{event_id}/metadata",
          headers={"Authorization": "Bearer fini_your_api_key"},
      )
      metadata = response.json()
      ~~~
    
      ~~~javascript Node.js theme={null}
      const eventId = "2f7dcb2f-2a41-4f5d-a4ad-2b6cbf61d20a";
    
      const response = await fetch(
        `https://api-prod.usefini.com/v2/hc-events/${eventId}/metadata`,
        {
          headers: {
            Authorization: "Bearer fini_your_api_key",
          },
        }
      );
      const metadata = await response.json();
      ~~~
    </RequestExample>
    
    ## Response
    
    <ResponseField name="planning" type="object | null">
      Planning trace for the response, including reasoning and whether Fini decided to run knowledge search.
    </ResponseField>
    
    <ResponseField name="knowledgeSearch" type="object | null">
      Knowledge-search trace, including top-result reasoning, selection reasoning, and the articles considered for the response.
    </ResponseField>
    
    <ResponseField name="relevantMemories" type="array | null">
      Conversation memory summaries selected for the response. Each item includes `id`, `summary`, and `conversationEndedAt`.
    </ResponseField>
    
    <ResponseField name="generateAnswer" type="object | null">
      Answer-generation reasoning items returned by the model trace.
    </ResponseField>
    
    <ResponseField name="inputTagSelection" type="object | null">
      Input tag-selection reasoning and chosen tags, when input tags were selected for the event.
    </ResponseField>
    
    <ResponseField name="outputTagSelection" type="object | null">
      Output tag-selection reasoning and chosen tags, when output tags were selected for the event.
    </ResponseField>
    
    <ResponseField name="executedUserAttributes" type="array | null">
      Attribute executions exposed for this event, including tool names, success state, extracted data, and external API step results when available.
    </ResponseField>
    
    <ResponseField name="executedRules" type="object | null">
      Rule execution details for the selected rule, including `ruleId`, `ruleName`, and node execution results when available.
    </ResponseField>
    
    <ResponseExample>
      ~~~json 200 OK theme={null}
      {
        "planning": {
          "reasoning": "The customer is asking about refund eligibility, so knowledge search is needed.",
          "performKnowledgeSearch": true
        },
        "knowledgeSearch": {
          "topOneReasoning": "The refund policy article directly answers the question.",
          "selectionReasoning": "Selected the most recent public refund policy article.",
          "articles": [
            {
              "id": "7f1a8c7e-20db-4511-9b7b-95d894f9d1b2",
              "title": "Refund policy",
              "version": 3
            }
          ]
        },
        "relevantMemories": [
          {
            "id": "6c6ec2c1-23cb-4502-8b03-0f6eb8faef26",
            "summary": "The customer previously asked about a delayed refund for order R-1042.",
            "conversationEndedAt": "2026-07-25T14:18:00.000Z"
          }
        ],
        "generateAnswer": {
          "reasoning": [
            {
              "name": "Policy grounding",
              "reasoning": "Use the 30-day refund window and avoid promising exceptions."
            }
          ]
        },
        "inputTagSelection": null,
        "outputTagSelection": {
          "reasoning": "The response resolves a policy question.",
          "chosenTags": {
            "Conversation Status": ["Resolved"],
            "Topic": ["Refunds"]
          }
        },
        "executedUserAttributes": [
          {
            "id": "9c4b8e11-f4f5-4ef4-a82f-34bb080da8c6",
            "name": "Get order status",
            "success": true,
            "extractedData": {
              "orderStatus": "delivered"
            },
            "results": [
              {
                "id": "2d2a7f0e-8b3a-4f7f-9b4b-3b2e4a7a3c23",
                "name": "Fetch order",
                "success": true,
                "data": {
                  "status": "delivered"
                }
              }
            ]
          }
        ],
        "executedRules": {
          "ruleId": "e071d8b6-a780-49fa-a3ac-01f7312b20ef",
          "ruleName": "Refund policy routing",
          "results": [
            {
              "id": "3a70c315-0fe0-42b8-a0c2-ec2ad0fda69d",
              "name": "Check refund window",
              "type": "CONDITION",
              "success": true,
              "result": {
                "eligible": true
              }
            }
          ]
        }
      }
      ~~~
    </ResponseExample>
    
    ## Errors
    
    <AccordionGroup>
      <Accordion title="400 Bad Request" icon="circle-exclamation">
        The event ID is missing, or the event is not from the Fini bot. Only `finibot` events have this metadata response.
      </Accordion>
    
      <Accordion title="401 Unauthorized" icon="lock">
        The API key is missing, malformed, revoked, or invalid. Confirm you are sending `Authorization: Bearer fini_...` with the full key.
      </Accordion>
    
      <Accordion title="403 Forbidden" icon="shield-halved">
        The API key does not include the `read` scope required for this route.
      </Accordion>
    
      <Accordion title="404 Not Found" icon="magnifying-glass">
        The event does not exist or does not belong to the workspace tied to your API key.
      </Accordion>
    </AccordionGroup>
    
    
    ## Related topics
    
    - [Overview](/en/api-reference/conversations.md)
    - [Get replay events](/en/api-reference/get-replay-events.md)
    - [API overview](/en/api-reference/overview.md)
    
    
    This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.
    
    Get conversation
    Generate Answer
    Powered byThis documentation is built and hosted on Mintlify, a developer documentation platform