Description:
This template automates creating and posting content on Facebook using Uxer’s AI Assistant. The scenario generates an engaging Facebook post based on the topic of AI Automation and posts it directly to the user’s profile.
How to Use It:
- Copy and paste this template into Uxer’s scenario builder.
- Ensure that you are logged into Facebook in Chrome before running the scenario.
- Save and run the scenario to automate posting on your Facebook profile.
Step-by-Step Process for Setting Up Your Automation Scenario
-
Open Chrome and Navigate to Facebook
The scenario opens Chrome and navigates to Facebook, with incognito mode disabled to ensure the user remains logged into their account.OpenBrowser Chrome "https://www.facebook.com" -Incognito false
-
Start a New Post
The script clicks on the “What’s on” text field to initiate a new post. The full text is “What’s on your mind, Uxer?” but since this text may change over time, we preferred to use a partial match.Click Text "What's on"
-
Generate a Personalized Post Using AskUxer
Uxer’s AI Assistant generates an engaging Facebook post focused on AI Automation and its benefits to a random domain. Change the prompt based on your requirements.{Response} = AskUxer "Create an engaging Facebook post about AI Automation. Avoid generic responses and personalize it based on the content. It should focus on any random domain and explain how this domain benefits from AI Automation. Avoid using AI-like language."
-
Write the Generated Post
The script writes the generated response in the post field, waiting 4 seconds after entering the text to ensure the UI is ready.Write {Response} -WaitAfter 4000
-
Simulate a Space Keypress
The script simulates pressing the space key to ensure the post content is finalized and the “Post” button is activated.SendKeys Space
-
Post the Content
There are multiple “Post” buttons on the page, including one in the “Add to your post” section, which looks like a button. To avoid confusion, we wanted to be specific in selecting the correct “Post” button under the “Add to your post” text. We used an anchor algorithm to click the second “Post” button in relation to the “Add to your post” text. The number [1] indicates clicking the second “Post” button, as the first one is already part of the “Add to your post” section.Click Text "Add to your post" > Text "post" [1] -Double true
Complete Script:
OpenBrowser Chrome "https://www.facebook.com" -Incognito false
Click Text "What's on"
{Response} = AskUxer "Create an engaging Facebook post about AI Automation. Avoid generic responses and personalize it based on the content. It should focus on any random domain and explain how this domain benefits from AI Automation. Avoid using AI like language."
Write {Response} -WaitAfter 4000
SendKeys Space
Click Text "Add to your post" > Text "post" [1] -Double true
Let us know if you need further assistance or additional templates!