POST /applications/{applicationId}/ai-analysis
Generate AI analysis for an application
Uses Claude AI to analyze an application and provide a detailed risk assessment, focusing on business stability, financial health, industry risk factors, merchant reputation, and compliance.
Authentication Required
Authorization: Bearer {token}
header string This header is required to access this endpoint
Required Parameters
applicationId
path string The ID of the application to analyze
Optional Parameters
Click here to view an exhaustive list of all available parameters
x-account-id
header string The account ID for the request
Request Body
{}{}Try it out
Loading...
Output:
Responses
Description
AI analysis generated successfully
{ "timestamp": "string", "applicationId": "string", "aiAnalysis": "string", "model": "claude-3-opus-20240229"}Description
Unauthorized - User not authenticated
Description
Forbidden - User does not have permission to analyze this application
Description
Application not found
Description
Failed to perform AI analysis
{ "error": "Failed to perform AI analysis"}References
#/components/parameters/xAccountIdHeader
in: headername: x-account-idschema: type: stringdescription: The account ID for the requestrequired: false|export type xAccountIdHeader = any; // Schema type not fully supported#/components/schemas/AIAnalysis
type: objectdescription: AI-generated analysis of an applicationproperties: timestamp: type: string format: date-time description: When the analysis was generated applicationId: type: string description: ID of the analyzed application aiAnalysis: type: string description: The detailed analysis text generated by the AI model model: type: string description: The AI model used for analysis example: claude-3-opus-20240229required: - timestamp - applicationId - aiAnalysis - model|export interface AIAnalysis { /** When the analysis was generated */ timestamp: Date; /** ID of the analyzed application */ applicationId: string; /** The detailed analysis text generated by the AI model */ aiAnalysis: string; /** The AI model used for analysis */ model: string;}Route Source Code
Check out the source code for this route entrypoint here: /applications/[applicationId]/ai-analysis/route.ts
Or the swagger.yaml spec this documentation was generated from:
/applications/swagger.yaml