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

# agentReview

> Returns the latest Agent Review session for an underwriting application

`Query`

## Arguments

<ParamField path="applicationId" type="UUID!" required />

## Return type

`UnderwritingApplicationAgentReview`

<ResponseField name="blockers" type="[String!]!" required>
  Short, discrete statements of anything that must be resolved before a decision can be made.
</ResponseField>

<ResponseField name="components" type="[UnderwritingApplicationAgentReviewComponent!]!" required>
  One disposition row per decision component reviewed in this session.

  <Expandable title="child attributes">
    <ResponseField name="componentId" type="UUID!" required>
      The decision component this row reviews.
    </ResponseField>

    <ResponseField name="disposition" type="UnderwritingApplicationAgentReviewDisposition!" required>
      The reviewer's judgment for this component.

      <Expandable title="Possible enum values">
        <ResponseField name="LIKELY_PROBLEM" type="enum" />

        <ResponseField name="LOOKS_ACCEPTABLE" type="enum" />

        <ResponseField name="NEEDS_A_CLOSER_LOOK" type="enum" />

        <ResponseField name="NOT_YET_ASSESSABLE" type="enum" />
      </Expandable>
    </ResponseField>

    <ResponseField name="rationale" type="String!" required>
      The reviewer's rationale for this disposition, citing the specific fields and values it saw.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="leadConcernComponentIds" type="[UUID!]!" required>
  The componentId(s) (from components) that most need the underwriter's attention first.
</ResponseField>

<ResponseField name="sessionId" type="String!" required>
  The agent review session id correlating this record with the agent invocation.
</ResponseField>

<ResponseField name="status" type="UnderwritingApplicationAgentReviewStatus!" required>
  The status of this session — may be IN\_PROGRESS if the review has not yet completed.

  <Expandable title="Possible enum values">
    <ResponseField name="NOT_STARTED" type="enum">
      No agent review has been requested for this application. This is the default for new applications.
    </ResponseField>

    <ResponseField name="COMPLETED" type="enum">
      The agent has finished its review and a final response has been written.
    </ResponseField>

    <ResponseField name="FAILED" type="enum">
      The agent invocation errored or timed out; no completed review is available.
    </ResponseField>

    <ResponseField name="IN_PROGRESS" type="enum">
      The agent is currently reviewing the application or is queued to do so.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="summary" type="String">
  The reviewer's overall summary, including cross-cutting findings not tied to a single decision
  component. Null until the session completes.
</ResponseField>

<RequestExample>
  ```graphql Operation lines expandable theme={null}
  query AgentReview($applicationId: UUID!) {
    agentReview(applicationId: $applicationId) {
      blockers
      components {
        componentId
        disposition
        rationale
      }
      leadConcernComponentIds
      sessionId
      status
      summary
    }
  }
  ```

  ```json Variables lines expandable theme={null}
  {
    "applicationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
  ```

  ```bash cURL lines expandable theme={null}
  curl --request POST \
    --url https://api.sandbox.com/graphql \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Bearer <YOUR_ACCESS_TOKEN>' \
    --data '{
    "query": "query AgentReview($applicationId: UUID!) {\n  agentReview(applicationId: $applicationId) {\n    blockers\n    components {\n      componentId\n      disposition\n      rationale\n    }\n    leadConcernComponentIds\n    sessionId\n    status\n    summary\n  }\n}",
    "variables": {
      "applicationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
    }
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json Response lines expandable theme={null}
  {
    "data": {
      "agentReview": {
        "blockers": [
          "example"
        ],
        "components": [
          {
            "componentId": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
            "disposition": "LIKELY_PROBLEM",
            "rationale": "example"
          }
        ],
        "leadConcernComponentIds": [
          "c9a1e2d3-4b5f-6789-0abc-def123456789"
        ],
        "sessionId": "example",
        "status": "NOT_STARTED",
        "summary": "example"
      }
    }
  }
  ```
</ResponseExample>
