MISSING_PARAMETER, account_id is required


#1

i am new to advertiser’s api, am using yii2 authclient

when i request https://ads-api.twitter.com/1/accounts i get my two accounts, but when i request https://ads-api.twitter.com/1/accounts/account_id, where the account id is my advertising account’s id, i get Request failed with code: 400, message: {“errors”:[{“code”:“MISSING_PARAMETER”,“message”:"“account_id” is a required parameter",“parameter”:“account_id”}],“request”:{“params”:{}}}

please help as soon as possible


#2

Hi @Omar_Mohamed_33! Make sure the url doesn’t have any extension after the account id.


#3

am not using .json at the end of the request, i typed it only when i was using standard api


#4

Are you using the sandbox or production environment?


#5

production, should i use the sandbox first


#6

No. Could you post your raw request, please? I can’t think of anything…


#7

https://ads-api.twitter.com/1/accounts/account_id


#8

You can post your account id, it is not sensitive information. I’m hoping that a Twitter Staff will be able to check things deeper if they have the account id.


#9

https://ads-api.twitter.com/1/accounts/18ce53ytvd7


#10

Hey @Omar_Mohamed_33 ! I’ve taken a look at those end points you’ve listed and looks like they’re working fine. Can you try to hit those endpoints using our twurl client? Please paste the entire request and response body, and let us know if it works for you.


#11

it’s working now :slight_smile:


#12

Awesome! Closing out this thread


#13