SOLVED: "Error claiming the device. Could not claim the device to your account"

You problem sounds somewhat similar to the one in this thread:

Over there, the hostname will not resolve correctly until after a restart of the Particle agent. Have you tried stop/start or restart?