Any arduino code you would like to use. The key is to identify which serial port you have connected to the XBee. For instance if you have it connected to Serial1 then you would want to print out the statements you want sent to Thingspeak like so…
Topic posting to includes multiple fields
Topic posting to is field specific to field1:
The #P is the identifier the xbee python code is looking for to identify the data you want sent. the println() includes the \r\n characters that allow the python code to separate multiple post request coming in one after the other.