preheat_open.api.api_post

preheat_open.api.api_post(endpoint, out='json', json_payload=None, bare_url=False)

Method to send a POST request to the API

Parameters:
  • endpoint (str) – URL of the endpoint

  • out (str) – output type (json or csv)

  • json_payload (Optional[dict[str, Any]]) – payload for the request

  • bare_url (bool) – if True, uses the endpoint as full URL (and skips base URL addition)

Return type:

Response

Returns:

API response in request.Response format