When the cURL request is made, I need to take value in the string compare on line 20 and make it an unsigned int with the data payload from the post. I'm not sure how I would get the data payload converted to an unsigned int... or if it's even possible.

However, that creates a signed integer between -32768 and 32767. For unsigned I would suggest using its sister function "atol" to convert to a signed long, then cast that back to an unsigned int. That way the long can store the numbers greater than 32867, and the casting will retain anything between 0 and 65535.