Actions13
- User Actions
- Activity Actions
- Message Actions
Activity → Get Current KPI Value
AI-generatedOverview
This node interacts with a coaching platform API to retrieve or update various user and activity-related data. Specifically, the Activity - Get Current KPI Value operation fetches the current Key Performance Indicator (KPI) value for a given user’s activity on a specified date or by activity ID.
Typical use cases include:
- Monitoring real-time performance metrics of users in a coaching or training program.
- Integrating KPI data into dashboards or reports for managers or coaches.
- Automating workflows that depend on up-to-date KPI values, such as triggering alerts or personalized coaching messages.
For example, you might use this node to get the current sales KPI for a salesperson on a particular day or for a specific activity they performed, enabling timely feedback or intervention.
Properties
| Name | Meaning |
|---|---|
| Authentication | Choose between two authentication methods: "Company Api" or "System Api". |
| User ID | The unique identifier of the user whose KPI data you want to retrieve. |
| Activity Date | (Optional) The date of the activity for which to get the current KPI value. |
| Activity ID | (Optional) The specific activity identifier to get the current KPI value for. |
Output
The output is a JSON object containing the response from the coaching platform API endpoint /crmApi/get-current-kpi-value. This typically includes the current KPI value(s) associated with the specified user and activity parameters.
The exact structure depends on the API response but generally will contain fields representing KPI metrics, timestamps, and possibly metadata about the activity or user.
No binary data output is produced by this operation.
Dependencies
- Requires an API key credential for authentication, either via "Company Api" or "System Api".
- Makes HTTP POST requests to
https://coachtriggerapp.com/crmApi/get-current-kpi-value. - The node expects valid user IDs and optionally activity IDs or dates to query the KPI data.
- Proper configuration of credentials in n8n is necessary to authenticate requests successfully.
Troubleshooting
- Invalid Credentials Error: If authentication fails, verify that the correct API key is configured and selected under the Authentication property.
- Missing Required Parameters: Ensure the User ID is provided; otherwise, the API call will fail.
- Empty or Unexpected Response: Check if the Activity Date or Activity ID corresponds to existing records. Omitting both may result in incomplete data.
- Network or API Errors: Confirm network connectivity and that the external API service is operational.
- JSON Parsing Errors: The node attempts to parse string responses as JSON; malformed responses could cause errors.
Links and References
- Coach Platform API Documentation (hypothetical link)
- n8n HTTP Request Node documentation for understanding request/response handling: https://docs.n8n.io/nodes/n8n-nodes-base.httpRequest/