12 #ifndef AZURE_IOT_HTTP_H
13 #define AZURE_IOT_HTTP_H
17 #include "azure_iot_http_port.h"
24 #define azureiothttpHttpRangeRequestEndOfFile -1
38 eAzureIoTHTTPSuccess = 0,
39 eAzureIoTHTTPInvalidParameter,
40 eAzureIoTHTTPNetworkError,
41 eAzureIoTHTTPPartialResponse,
42 eAzureIoTHTTPNoResponse,
43 eAzureIoTHTTPInsufficientMemory,
44 eAzureIoTHTTPSecurityAlertResponseHeadersSizeLimitExceeded,
45 eAzureIoTHTTPSecurityAlertExtraneousResponseData,
46 eAzureIoTHTTPSecurityAlertInvalidChunkHeader,
47 eAzureIoTHTTPSecurityAlertInvalidProtocolVersion,
48 eAzureIoTHTTPSecurityAlertInvalidStatusCode,
49 eAzureIoTHTTPSecurityAlertInvalidCharacter,
50 eAzureIoTHTTPSecurityAlertInvalidContentLength,
51 eAzureIoTHTTPParserInternalError,
52 eAzureIoTHTTPHeaderNotFound,
53 eAzureIoTHTTPInvalidResponse,
75 uint32_t ulPathLength,
76 char * pucHeaderBuffer,
77 uint32_t ulHeaderBufferLength );
95 uint32_t ulDataBufferLength,
97 uint32_t * pulOutDataLength );
115 uint32_t ulURLLength,
116 const char * pucPath,
117 uint32_t ulPathLength,
118 char * pucHeaderBuffer,
119 uint32_t ulHeaderBufferLength );
132 char * pucDataBuffer,
133 uint32_t ulDataBufferLength );
AzureIoTHTTPResult_t AzureIoTHTTP_Init(AzureIoTHTTPHandle_t xHTTPHandle, AzureIoTTransportInterface_t *pxHTTPTransport, const char *pucURL, uint32_t ulURLLength, const char *pucPath, uint32_t ulPathLength, char *pucHeaderBuffer, uint32_t ulHeaderBufferLength)
Initialize the Azure HTTP client.
AzureIoTHTTP_t * AzureIoTHTTPHandle_t
The handle for the Azure HTTP client.
Definition: azure_iot_http.h:30
int32_t AzureIoTHTTP_RequestSize(AzureIoTHTTPHandle_t xHTTPHandle, char *pucDataBuffer, uint32_t ulDataBufferLength)
Send a size request.
AzureIoTHTTPResult_t AzureIoTHTTP_Request(AzureIoTHTTPHandle_t xHTTPHandle, int32_t lRangeStart, int32_t lRangeEnd, char *pucDataBuffer, uint32_t ulDataBufferLength, char **ppucOutData, uint32_t *pulOutDataLength)
Send an HTTP GET request.
AzureIoTHTTPResult_t AzureIoTHTTP_Deinit(AzureIoTHTTPHandle_t xHTTPHandle)
Deinitialize the Azure HTTP client.
enum AzureIoTHTTPResult AzureIoTHTTPResult_t
Azure HTTP return codes.
AzureIoTHTTPResult_t AzureIoTHTTP_RequestSizeInit(AzureIoTHTTPHandle_t xHTTPHandle, AzureIoTTransportInterface_t *pxHTTPTransport, const char *pucURL, uint32_t ulURLLength, const char *pucPath, uint32_t ulPathLength, char *pucHeaderBuffer, uint32_t ulHeaderBufferLength)
Initialize a size request.
AzureIoTHTTPResult
Azure HTTP return codes.
Definition: azure_iot_http.h:37
Transport interface definition to send and receive data over the network.
The transport layer interface.
Definition: azure_iot_transport_interface.h:159