Skip to main content
Glama
ismaeldosil

FinaShopping MCP Server

by ismaeldosil

get-loan-requirements

Retrieve application requirements for specific loans to prepare documentation needed for submission.

Instructions

Get the requirements to apply for a specific loan. | Obtener los requisitos para solicitar un préstamo específico.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
loanIdYesLoan ID | ID del préstamo

Implementation Reference

  • Handler function that fetches loans, locates the specific loan by ID, determines additional requirements based on loan type (personal, auto, hipotecario), and returns a JSON-structured response with requirements, recommended income, and approval info.
    async ({ loanId }) => {
      const loans = await getLoans();
      const loan = loans.find(l => l.id === loanId);
    
      if (!loan) {
        return {
          content: [{
            type: 'text' as const,
            text: JSON.stringify({
              error: 'Loan not found | Préstamo no encontrado',
              validIds: loans.map(l => ({ id: l.id, name: l.name }))
            })
          }],
          isError: true
        };
      }
    
      // Generate requirements based on loan type (bilingual)
      const baseRequirements = [
        'Valid Uruguayan ID card | Cédula de identidad uruguaya vigente',
        'Proof of address | Comprobante de domicilio',
        'Latest pay stub | Último recibo de sueldo'
      ];
    
      const additionalRequirements: string[] = [];
    
      if (loan.name.toLowerCase().includes('hipotec')) {
        additionalRequirements.push(
          'Property appraisal | Tasación del inmueble',
          'Notarized property certificate | Certificado notarial de la propiedad',
          'Last 3 bank statements | 3 últimos estados de cuenta bancarios',
          'Minimum employment history: 2 years | Antigüedad laboral mínima: 2 años'
        );
      } else if (loan.name.toLowerCase().includes('auto')) {
        additionalRequirements.push(
          'Vehicle invoice or quote | Factura o cotización del vehículo',
          'Mandatory insurance | Seguro obligatorio',
          'Minimum employment history: 1 year | Antigüedad laboral mínima: 1 año'
        );
      } else {
        additionalRequirements.push(
          'Clean credit history | Clearing bancario limpio',
          'Minimum employment history: 6 months | Antigüedad laboral mínima: 6 meses'
        );
      }
    
      return {
        content: [{
          type: 'text' as const,
          text: JSON.stringify({
            loan: {
              id: loan.id,
              name: loan.name,
              institution: loan.institution
            },
            requirements: {
              documentation: [...baseRequirements, ...additionalRequirements],
              income: `Recommended minimum income | Ingreso mínimo recomendado: ${Math.round(loan.monthlyPayment * 3).toLocaleString('es-UY')} $U monthly | mensuales`,
              approval: {
                probability: loan.probability,
                estimatedTime: loan.probability === 'alta' ? '24-48 hours | horas' : '3-5 business days | días hábiles'
              }
            },
            features: loan.features
          }, null, 2)
        }]
      };
    }
  • Input schema for the tool, requiring a numeric loanId parameter.
    {
      loanId: z.number().describe('Loan ID | ID del préstamo')
    },
  • Registration of the get-loan-requirements tool with the MCP server, including name and bilingual description.
    server.tool(
      'get-loan-requirements',
      'Get the requirements to apply for a specific loan. | Obtener los requisitos para solicitar un préstamo específico.',
  • Helper function to fetch all available loans from the API, used by the get-loan-requirements handler.
    async function getLoans(): Promise<Loan[]> {
      const response = await fetchLoans();
      return response.loans;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool retrieves requirements but does not specify if this is a read-only operation, requires authentication, has rate limits, returns structured data, or handles errors. For a tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise and front-loaded, with the primary purpose stated first in English followed by a Spanish translation. Both sentences are directly relevant, but the bilingual format slightly reduces efficiency without adding new information. Overall, it's appropriately sized with minimal waste.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of annotations and output schema, the description is incomplete. It does not explain what the tool returns (e.g., a list of requirements, eligibility criteria, or documentation needs), error handling, or behavioral traits. For a tool that likely provides critical financial information, more context is needed to ensure proper usage.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with the parameter 'loanId' fully documented. The description does not add any semantic details beyond what the schema provides (e.g., it doesn't explain what a loan ID is or how to obtain it). With high schema coverage, the baseline score of 3 is appropriate, as the description doesn't compensate but also doesn't detract.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Get the requirements to apply for a specific loan.' It specifies the verb ('get') and resource ('requirements'), but does not distinguish it from potential sibling tools like 'search-loans' or 'compare-loans', which might also provide loan-related information. The bilingual format adds clarity but doesn't affect the core purpose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It does not mention prerequisites (e.g., needing a loan ID), exclusions, or comparisons to sibling tools like 'search-loans' (which might list loans) or 'get-benefits' (which might provide different loan details). Usage is implied only by the tool name and description.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ismaeldosil/finashopping-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server