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

Error: Invalid parameter subscriberId: null

ANSWERED

https://dev.fitbit.com/build/reference/web-api/developer-guide/using-subscriptions/#Creating-a-Subsc...

Following the above guide I attempted to implement subscriptions but, I keep getting the following error:

{
    "errors": [
        {
            "errorType""validation",
            "fieldName""subscriberId",
            "message""Invalid parameter subscriberId: null"
        }
    ]
}
 
The link I used to get this response:
 
What can I do to fix this problem?
Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

@WeFitterTech Thanks for confirming that information.

 

Your request appears to be missing the content-length header and this is required as per the documentation. Can you confirm you're including the size of the payload body?

View best answer in original post

Best Answer
4 REPLIES 4

@WeFitterTech

 

Sorry to hear that you're encountering this error.

 

Can you post your full HTTP message that you're requesting here? I need to see the endpoint, headers, and body of your request. I also want to know the error status code you're receiving. Please also PM me your Client ID (as it is sensitive).

 

Thanks!

Best Answer

@JohnFitbit 

 

The endpoint: https://api.fitbit.com/1/user/-/body/apiSubscriptions/B7JJT6-body.json

The header contains the Bearer token and the body is empty. I also sent the client ID in a PM.

Thanks for your reply!

Best Answer
0 Votes

@WeFitterTech Thanks for confirming that information.

 

Your request appears to be missing the content-length header and this is required as per the documentation. Can you confirm you're including the size of the payload body?

Best Answer

That seems to be the solution, I must have missed that. Thank you so much for the support!

Best Answer
0 Votes