# Get Message Analytics

## Get message analysis

> Retrieve comprehensive bot message analytics and statistics across all platforms.\
> \
> This endpoint provides:\
> \- Line platform statistics (quota, consumption, reply/push/broadcast amounts)\
> \- Multi-platform conversation analytics (average conversation values and times)\
> \- Platform integration status for all platforms\
> \*\*Platforms covered:\*\* Line, Facebook, Instagram, LiveChat, WhatsApp

```json
{"openapi":"3.0.3","info":{"title":"Manta OpenAPI","version":"0.318.0"},"tags":[{"name":"Core","description":"Core OpenAPI functionality for customer management and broadcasting"}],"servers":[{"url":"https://mantago.cc/api","description":"MantaGo Openapi host url"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token for API authentication"}},"schemas":{"MessageAnalysisRequest":{"type":"object","properties":{"secret":{"type":"string","description":"Secret key for API authentication"}},"required":["secret"]},"MessageAnalysisResponse":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"lineQuota":{"type":"integer","description":"Line platform quota limit"},"lineQuotaConsumption":{"type":"integer","description":"Line platform quota consumption"},"lineReplyAmounts":{"type":"integer","description":"Number of Line reply messages"},"linePushAmounts":{"type":"integer","description":"Number of Line push messages"},"lineBroadcastAmounts":{"type":"integer","description":"Number of Line broadcast messages"},"lineProgram":{"type":"string","description":"Line program data","enum":["輕用量","中用量","高用量"]},"lineAverageConversationValue":{"type":"integer","description":"Average conversation value for Line platform"},"lineAverageConversationTime":{"type":"integer","description":"Average conversation time for Line platform (in seconds)"},"fbAverageConversationValue":{"type":"integer","description":"Average conversation value for Facebook platform"},"fbAverageConversationTime":{"type":"integer","description":"Average conversation time for Facebook platform (in seconds)"},"igAverageConversationValue":{"type":"integer","description":"Average conversation value for Instagram platform"},"igAverageConversationTime":{"type":"integer","description":"Average conversation time for Instagram platform (in seconds)"},"liveChatAverageConversationValue":{"type":"integer","description":"Average conversation value for LiveChat platform"},"liveChatAverageConversationTime":{"type":"integer","description":"Average conversation time for LiveChat platform (in seconds)"},"whatsappAverageConversationValue":{"type":"integer","description":"Average conversation value for WhatsApp platform"},"whatsappAverageConversationTime":{"type":"integer","description":"Average conversation time for WhatsApp platform (in seconds)"},"lineIsIntegration":{"type":"boolean","description":"Whether Line platform is integrated"},"fbIsIntegration":{"type":"boolean","description":"Whether Facebook platform is integrated"},"instagramIsIntegration":{"type":"boolean","description":"Whether Instagram platform is integrated"},"liveChatIsIntegration":{"type":"boolean","description":"Whether LiveChat platform is integrated"},"whatsappIsIntegration":{"type":"boolean","description":"Whether WhatsApp platform is integrated"}}},"ErrorResponse":{"type":"object","properties":{"success":{"type":"boolean"},"errResponse":{"type":"object","properties":{"message":{"type":"string"},"code":{"type":"integer"},"botId":{"type":"string"}},"required":["message","code"]}},"required":["success","errResponse"]}},"responses":{"TokenError":{"description":"JWT token is invalid or expired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"PermissionError":{"description":"Permission denied - insufficient access rights","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"GetOpenApiError":{"description":"OpenAPI configuration not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"InternalServerError":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/openapi/message/analysis":{"post":{"tags":["Core"],"summary":"Get message analysis","description":"Retrieve comprehensive bot message analytics and statistics across all platforms.\n\nThis endpoint provides:\n- Line platform statistics (quota, consumption, reply/push/broadcast amounts)\n- Multi-platform conversation analytics (average conversation values and times)\n- Platform integration status for all platforms\n**Platforms covered:** Line, Facebook, Instagram, LiveChat, WhatsApp","parameters":[{"name":"botId","in":"query","required":true,"schema":{"type":"string"},"description":"The bot ID for the API request"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageAnalysisRequest"}}}},"responses":{"200":{"description":"Get Messages Analysis Successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageAnalysisResponse"}}}},"401":{"$ref":"#/components/responses/TokenError"},"403":{"$ref":"#/components/responses/PermissionError"},"404":{"$ref":"#/components/responses/GetOpenApiError"},"500":{"$ref":"#/components/responses/InternalServerError"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.mantago.cc/mantago-en/messages/get-message-analytics.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
