Problem/Motivation

Microblog Publish (on your) Own Site, Syndicate Elsewhere (MPOSSE) is a Drupal module that was created to make it easier to manage your microblogs from other Drupal content that you want to post about.

It provides a plugin definition, which I would like to implement here. This will basically just allow mposse to acknowledge that there is integration for bsky, which will both alter the microblog form and enable posting to bsky during SPC's cron (which is actually just processing a posting queue).

Proposed resolution

Implement the plugin for MPOSSE

Issue fork bsky-3536172

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

megakeegman created an issue. See original summary.

megakeegman’s picture

While there is certainly more to do here, I have successfully posted a message via this plugin implementation in the issue fork. The post here currently only contains a message. Before doing more, I need to review and consider building the post data from the SPC side.

megakeegman’s picture

Title: Implement Social Platform plugin from Social Post Controller » Implement Social Platform plugin from Drutopia Microblog

Issue title was updated to reflect architectural change, where the plugin definition was moved from Social Post Controller (which was renamed and moved to MPOSSE), and moved into its dependency https://www.drupal.org/project/drutopia_microblog. The issue fork will need to be updated to reflect the namespacing of the extended base plugin, just a small change.

freelock’s picture

Hi,

Plugin looks basically fine, but should use dependency injection to get the bsky.post_service service on line 24...

Should be along the lines of implementing the ContainerFactoryPluginInterface with a create() method and a constructor...

Cheers,
John

megakeegman’s picture

Thanks for the feedback, I will try that out

megakeegman’s picture

Alright I did update, haven't tested yet. Currently trying to figure out why my IDE is upset about the create function not being compatible with ContainerFactoryPluginInterface

megakeegman’s picture

Alright was simply using the wrong use statement for ContainerInterface. Will let you know once I have tested this again

megakeegman’s picture

I have tested the code, and it is working okay. I'm not yet ready to add facets or images, as I have work to do on the drutopia microblog side and decisions to make. But it is functional and useful as it is now, too.

megakeegman’s picture

Issue summary: View changes

Opened merge request mostly to make it easier to apply as a patch via composer. Since starting this issue, I have moved the location of the plugin definition twice (back and forth) while making some architectural decisions on the other side. Most of the decisions were around whether the plugin should be responsible for providing definitions for fields (in this case a bluesky post field). Have mostly moved away from that model, though I liked the idea of it. As such, the plugin definition currently requires some things that I am not sure that I will actually end up using at all.

Right now, the main thing this plugin does is instruct mposse how to post. However, my intention is to soon also add a status check method that mposse can use to check whether each plugin is properly set up for mposse to be able to utilize those posting instructions. I think after implementing that we will be in a better spot to merge.

megakeegman’s picture

Title: Implement Social Platform plugin from Drutopia Microblog » Implement Social Platform plugin from MPOSSE
Assigned: Unassigned » megakeegman
megakeegman’s picture

MPOSSE has a few node type configurations, and this integration builds on top of that. Bsky specific configurations in this category so far are related to the rich website card for the post:

  • title
  • description
  • image url

Bsky so far does not deal with node type specific configurations, and understandably because of how it leverages ECA for configuring things. If what I have described above sounds at all useful for other parts of the module, I can implement this in a more generic way that is less specific to the mposse integration. But I won't worry about that unless it sounds useful, and I guess we can make that a separate issue later on too.

megakeegman’s picture

Status: Active » Needs review

On my list of things to review!

lieb’s picture

Please note. The bsky_post module uses bsky and works if you just want to post a node content to Bluesky.
However both of these are very limited in scope due to the underlying phlusky library. This led me to work on a more full featured client for the AT Protocol, which you can see on my Github This project contains a lot of stuff very specific to my site, but some, like atproto_client, which could be extracted and contributed to drupal.org.
My goal is to provide as much integration between Drupal and AT Protocol possible.

megakeegman’s picture

mposse is sort of the glue that combines posting capabilities across multiple Drupal modules that provide posting capabilities to various social media platforms. All modules that support mposse currently also support ECA as an alternative workflow. But mposse aims to provide an easy setup process and integration. Generally speaking, when a content node gets published, regardless of how it gets published (even during cron for example), that is when posts about that node should go out to all of the platforms. The goal is a unified development experience, a unified UX, and hopefully reviving the conversations that occurred surrounding the Social API Initiative now that there are new opportunities for achieveing old goals emerging in this space.

wolcen made their first commit to this issue’s fork.