Improve Private App Logs to include Form API calls

Status: Idea Submitted

Dear Hubspot community and Hubspot product teams,

We are implementing functionality that performs Form Submission by calling the API as part of a complexer integration flow. During our testing we are using the Private App tab ‘Logs’ to see which API calls are being performed and what their HTTP reponse code is.

We saw that currently the Form Submissions via API do not generate a Log record, which is not aligned to the other API calls that do get logged. For clarity, we can acknowledge the API Form submission worked using the Form Submission overview.

Our idea improvement: Could you please align the Form API to the other API’s and include the Form API call in the Logs?

Form API we are using: https://api.hsforms.com/submissions/v3/integration/submit/

Many thanks

  1. Determine which private app is responsible for handling the Form API calls. Make sure you have access to the source code of the private app.
  2. Enable logging: In the private app’s codebase, locate the logging mechanism or module used to capture and store logs. This could be a custom logging library or a built-in logging framework provided by the programming language or framework used.
  3. Modify logging configuration: Adjust the logging configuration to include the Form API calls. Typically, this involves modifying the log format or log message to include relevant information such as the request method, endpoint, and payload. Ensure that the logging configuration is set to an appropriate log level (e.g., DEBUG or INFO) to capture the desired logs.
  4. Instrument Form API calls: Within the private app’s code, add logging statements or hooks at key points of kitchen showrooms glasgow where Form API calls are made. This could include before making the API request, after receiving the response, or during error handling. Insert the necessary logging code to capture the relevant details of the Form API calls.

Hi @kcoffee , thanks for the suggestion. But to be clear, our idea is to enable logging in Hubspot side so it is aligned with other API usage and logging on Hubspot side. We believe this will improve the Hubspot product, why we posted it in the Hubspot Ideas and not as a topic in the Hubspot community.

We have already implemented logging in the private app, which in our case is also using a middleware and logging is actually done in the middleware.

Our use case for this idea is also to streamline and simplify how we do our daily checks and root cause analysis related to Hubspot.

Hi, after feedback from Claus Schiller he highlighted this is an unauthenticated API.

To reflect on that: I assume this is the API Hubspot uses internally and hasn’t formally been made available for external usage. If this is called internally with the form submissions, it makes sense. But from custom development perspective, where we ‘abuse’ the API a bit, I would like to have an authenticated version that is logged.

Thanks Claus!

Kind regards,

Wouter