The Twitter extension comes with a pre-configured plugin interact with Twitter's v1.1 API "GET" endpoints.


Before you can leverage this plugin you need to head to Settings > Extensions > Twitter Extension and enter your API credentials from

Getting Started

You can start an API request and configure it by using the twitter function and chaining options. The twitter endpoint requires the desired endpoint as the one and only argument. Let's take a look at a similar example as demonstrated on the connection page:

{% set recent = twitter('statuses/user_timeline')

{% for tweet in recent %}
    <p>{{ tweet.text }}</p>
{% endfor %}

For a closer look at what's inside the above return data use dd on the results:

{{ dd(recent) }}