AI Assistant
Ask a question about a specific JavaScript file analyzed and uploaded via JSMon. This uses Google Gemini AI to generate the answer and tracks conversations.
Workspace ID the user belongs to.
JSMon ID corresponding to the JS file stored in S3.
The question to ask about the JavaScript file.
Type of input. Only 'file' is currently supported.
Optional name of the conversation.
Whether to start a new conversation thread.
false
AI-generated response from Gemini
Bad Request (invalid input or API usage exceeded)
Forbidden (unauthorized access to workspace)
Not Found (JSMon result not found)
Internal Server Error
POST /api/ask-jsmon?wkspId=text HTTP/1.1
Host: api-dev.jsmon.sh
Content-Type: application/json
Accept: */*
Content-Length: 105
{
"jsmonId": "text",
"question": "text",
"type": "file",
"conversationName": "text",
"startNewConversation": false
}
{
"response": "text"
}
Returns 3 random prompt suggestions from the database
Successfully retrieved prompt suggestions
No content
GET /api/v2/promptSuggestions HTTP/1.1
Host: api-dev.jsmon.sh
Accept: */*
Successfully retrieved prompt suggestions
No content
Generates 3 relevant follow-up questions based on the original question and its answer
The original question asked
The response from Gemini
Successfully generated prompt suggestions
Missing required fields
Internal server error
POST /api/v2/generatePromptSuggestions HTTP/1.1
Host: api-dev.jsmon.sh
Content-Type: application/json
Accept: */*
Content-Length: 43
{
"question": "text",
"geminiResponse": "text"
}
{
"message": "text",
"suggestions": [
"text"
]
}