Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Updating goals with Autoweb and Fitbit API

ANSWERED

Does anyone know if there is a problem with the Fitbit API not updating activity goals?

 

I have been using Tasker and Autoweb to update my goals every day based on my average steps for the previous 30 days.

 

This has stopped working recently and I am getting the following error message in Autoweb:

 

{"errors":[{"errorType":"request","fieldName":"type","message":"required query parameter missing"}],"success":false}

 

Thanks in advance for any advice!

 

Paul

 

 

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

@paulbeales Apologies for the delayed response. I'm not able to determine the root cause with the information you provided. Could you provide me the request in HTTP Message format? For example:

curl -X POST "https://api.fitbit.com/1/user/-/activities/goals/daily.json?type=steps&value=10000" \
-H "accept: application/json" \
-H "authorization: Bearer <access_token>" \
-H "content-length: <message_body_size>"

I need to be able to see how your request is being formed in order for me to see why the error is being thrown. If the response fails, which it is, you should be returned with an error status code, to help with identifying the issue.

View best answer in original post

Best Answer
0 Votes
5 REPLIES 5

Hi @paulbeales - your post is moved to the web API forum where you are more likely to get a response.

 

There have been no announcement of problems, try restarting the phone in case a corruption has occurred and check if you received any app updates which may have caused an issue.

Author | ch, passion for improvement.

Best Answer

@paulbeales Thanks for reporting this, and I'll be happy to investigate.

 

Could you please provide me with your full cURL request? I'd like to see the endpoint you used, method, headers, and the body of the request, so that I can make sure your request was formatted correctly. Please redact the authorization bearer token and user id when you post your request.

 

Also, please provide me with the error status code you received. This doesn't appear to be documented on our end.

Best Answer
0 Votes

Hi John,

Thank you for responding.

The error in Tasker looks like this:

 

09.10.14/ActionArgBundle key: JoinOutputArray: replace <null> String value with null

09.10.14/Variables doreplresult: |{"period":"daily","floors":"%Stairs_goal","distance":"%Distance_goal","userid":"-","steps":"%Steps_goal"}| -> |{"period":"daily","floors":"28","distance":"5.8","userid":"-","steps":"6776"}|

09.10.14/ActionArgBundle AutoWeb Web Service: parameters: {"period":"daily","floors":"%Stairs_goal","distance":"%Distance_goal","userid":"-","steps":"%Steps_goal"} -> {"period":"daily","floors":"28","distance":"5.8","userid":"-","steps":"6776"}

09.10.14/E FIRE PLUGIN: AutoWeb Web Service / com.twofortyfouram.locale.intent.action.FIRE_SETTING: 15 bundle keys

09.10.14/E AutoWeb Web Service: plugin comp: com.joaomgcd.autoweb/com.joaomgcd.autoweb.broadcastreceiver.IntentServiceFire

09.10.14/E add wait type Plugin1 time 120

09.10.14/E add wait type Plugin1 done

09.10.14/E handlePluginFinish: taskExeID: 1 result 3

09.10.14/E pending result code

09.10.14/E add wait task

09.10.15/E Error: 819106404

09.10.15/E {"errors":[{"errorType":"request","fieldName":"type","message":"required query parameter missing"}],"success":false}

 

No error code is returned

Cheers,

Paul

Best Answer
0 Votes

@paulbeales Apologies for the delayed response. I'm not able to determine the root cause with the information you provided. Could you provide me the request in HTTP Message format? For example:

curl -X POST "https://api.fitbit.com/1/user/-/activities/goals/daily.json?type=steps&value=10000" \
-H "accept: application/json" \
-H "authorization: Bearer <access_token>" \
-H "content-length: <message_body_size>"

I need to be able to see how your request is being formed in order for me to see why the error is being thrown. If the response fails, which it is, you should be returned with an error status code, to help with identifying the issue.

Best Answer
0 Votes

Hi John,

 

Thanks for trying. 

 

I can't give you the URL request I'm afraid as that is all dealt with within Autoweb and I don't know what it is.

 

I have had to give up on this.

 

It is a mystery as it used to work and I don't know what has changed 😞

 

Best Regards,

 

Paul

Best Answer
0 Votes