# Latest Posts About Trump

**Use case:** 

Gain insights into the most recent discussions surrounding Trump on X. This task returns the latest 40 posts, complete with URLs, content, publication dates, author details, and engagement metrics. Perfect for tracking brand mentions and monitoring public conversations in real time.

## Input

```json
{
  "query": "Trump",
  "resultsCount": 40,
  "searchType": "latest"
}
```

## Output

```json
{
  "postUrl": {
    "label": "Post URL",
    "format": "link"
  },
  "postId": {
    "label": "Post ID",
    "format": "text"
  },
  "postText": {
    "label": "Post Text",
    "format": "text"
  },
  "timestamp": {
    "label": "Timestamp",
    "format": "number"
  },
  "conversationId": {
    "label": "Conversation ID",
    "format": "text"
  },
  "media": {
    "label": "Media",
    "format": "object"
  },
  "author": {
    "label": "Author",
    "format": "object"
  },
  "replyCount": {
    "label": "Reply Count",
    "format": "number"
  },
  "quoteCount": {
    "label": "Quote Count",
    "format": "number"
  },
  "favouriteCount": {
    "label": "Favourite Count",
    "format": "number"
  }
}
```

## How it works

### 1. Sign up on Apify or log in

The X (Twitter) Posts Search Actor is ready to run with the inputs already set for "Latest Posts About Trump". [Sign up or log in](https://console.apify.com/create-task-from-example/ctumveJLb1sVaW9SO) and you'll land in Apify Console with a copy of this exact task.

### 2. Start the "Latest Posts About Trump" task

The X (Twitter) Posts Search Actor will start running based on the input automatically. You can also change all the input fields, like search query, number of results, and more, to match your specific use case.

### 3. Receive the "Latest Posts About Trump" output

Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as post url, post id, post text, and more.

### 4. Integrate into your workflow

The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also [run the "Latest Posts About Trump" task via API](https://apify.com/scraper_one/x-posts-search.md).

## FAQ

### What data does the Latest Posts About Trump task return?

The Latest Posts About Trump task returns post URLs, content, publication dates, author details, and engagement metrics for posts about Trump.

### How many Twitter posts can I retrieve with this task?

The Latest Posts About Trump task is configured to retrieve a maximum of 40 recent posts.

### What specific engagement metrics are included in the output?

The output includes reply count, quote count, and favourite count for each post.

### Can I filter the Twitter posts by a specific time window?

Yes, the task can filter posts based on a time window, allowing users to search the latest posts within a specified number of hours or days.

### Do I need a special account to use this task?

No, a special account is not required to use the Latest Posts About Trump task.

### Can I run the Latest Posts About Trump task automatically?

Yes, the task can be scheduled to run automatically in the Apify Console.

## About this Actor

This example demonstrates how to use [X (Twitter) Posts Search](https://apify.com/scraper_one/x-posts-search.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/scraper_one/x-posts-search.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/scraper_one/x-posts-search.md

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).
