#ifndef __EXOSITE_HTTP__
#define __EXOSITE_HTTP__

/////////////////////////////////////////
// Defines
/////////////////////////////////////////

/* Hostname */
//Must define EXO_PRODUCT_ID to your product ID string
#define EXO_HOSTNAME ".devmode-m2.exosite.io"
#define EXO_HOSTNAME_LENGTH sizeof(EXO_HOSTNAME) + sizeof(EXO_PRODUCTI_ID)

/* Urls */
#define EXO_PROV_URL "/provision/activate"
#define EXO_PROV_TEST_URL "/provision/download"
#define EXO_UPDATE_URL "/onep:v1/stack/alias"
#define EXO_TIMESTAMP_URL "/timestamp"

/* Headers */
#define EXO_CONT_TYPE_HEADER "Content-Type: application/x-www-form-urlencoded; charset=utf-8"
#define EXO_CIK_HEADER "X-Exosite-CIK: "

/* Provisioning */
#define EXO_DEV_ID_KEY "id"

//Can define alternative ID format. Printf call expects a single formatted number in string.
#ifndef EXO_DEV_ID_FORMAT
#define EXO_DEV_ID_FORMAT "pic18f4620_%03u"
#endif

//Must define alternative length if define ID format is shorter that expected string
#ifndef EXO_DEV_ID_FORMAT_LENGTH
#define EXO_DEV_ID_FORMAT_LENGTH sizeof(EXO_DEV_ID_FORMAT)
#endif

//Can define alternative number to be used for ID
#ifndef EXO_DEV_ID_NUM
#define EXO_DEV_ID_NUM 1
#endif

/* Authentication token (CIK) */
#define EXO_EEPROM_iS_PROV_ADDR 0
#define EXO_EEPROM_PROV_CIK_ADDR 1
#define EXO_PROV_CIK_LENGTH 40


/* Resources */
#define EXO_TEMPERATURE_ALIAS "Temperature"
#define EXO_HUMIDITY_ALIAS "Humidity"
#define EXO_UPTIME_ALIAS "Uptime"

#endif //ifndef __EXOSITE_HTTP__
