Search code examples
resttwitterpostmansttwitterapi

tweeting using "@" and "#" through tweeter api


I am new to tweeter api(beginner level experience), have been exploring tweeter rest api. so far I managed to read user timeline, followers count and also able to tweet.

However in a tweet, I wish to mention users by using "@" symbol. example something like this.

This is how I am Entering mentions

This is not working, also the same case with hashtags "#" getting error as Error when @ is used

If I remove "@", then it works and posts a message.

Also referred the reference api https://developer.twitter.com/en/docs/tweets/post-and-engage/api-reference/post-statuses-update

However neither could i figure out any relevant parameter that I can use nor able to find any example while surfing.

For this POC, Twitter standard api is used(Just thinking if this feature is allowed in standard api)

Thanks and appreciate any advice/guidance

Ashish


Solution

  • This is because of the way that Postman is encoding your request, which breaks OAuth 1.0A for Twitter. You can try the following:

    • Disable all params in Params tab
    • Open Body tab and click x-www-form-urlencoded, then add params as needed