podpoint_feeds
Podpoint Feeds is a Drupal module that simplifies importing podcast episodes from Podpoint into your Drupal site. It extends the Feeds module by providing a custom mapping target that automatically scrapes Podpoint URLs from the Podpoint RSS Feed and creates a Media entity with bundle type Podpoint that will render as a Podpoint embed.
FEATURES
- Automated Scraping: When provided with a URL to a page containing a Podpoint embed, the module automatically visits the page and extracts the correct embed URL.
- Media Integration: Automatically creates or references Media entities (provided by the
podpoint_media_sourcemodule) and attaches them to your imported content. - Generic Mapping: Works with any content type or entity that uses an Entity Reference field targeting Media.
REQUIREMENTS
- Drupal 10.x or 11.x.
- Feeds: For importing data from RSS or other sources.
- Podpoint Media Source: To provide the Podpoint media type.
- Guzzle: (Core) Used for web scraping.
- A Podpoint RSS to provide to the Feed
INSTALLATION
Install as you would normally install a contributed Drupal module. Visit: https://www.drupal.org/node/1897420 for further information.
CONFIGURATION
Setup your content type to include a field that will contain the Podpoint Media item
You should edit your content type that will hold your podcast to include a field to hold the Podpoint media item
- Go to Structure > Content Types (admin/structure/types)
- Click Manage Fields on the content type that you plan to use with the feed importer
- Create a new field (or modify an existing field) to use Entity reference with:
- Reference type: Media
- Media type: Podpoint
- (The Podpoint media type is provided by the required module podpoint_media_source)
- Create a GUID field on the content type. This will store the unique identifier for the podpoint podcast that this content item stores. WITHOUT THIS IT WILL NOT RUN PROPERLY
- Save your changes
Create or update the Feed Type
To use this module, you must configure a Feed Type with the following settings:
- Go to Structure > Feed types (/admin/structure/feeds) and edit your feed type (or create a new one).
- Make sure the feed type has the following settings:
- Fetcher: Download from URL
- Parser: RSS/Atom
- Processor: Node
- Content Type: The content type you want to add the Podpoint podcast to
Add the GUID mapping
- Go to Structure > Feed types (/admin/structure/feeds) and edit your feed type
- Go to the Mappings tab. Add a new mapping:
- Target: Select the GUID field that you created above
- Source: Select the
Item GUIDsource
Add the Podpoint Media mapping
- Add a new mapping:
- Target: Select the Media Reference field on your content type. You will notice there will be two, you MUST SELECT the one that has the format
podpoint_embed:[field_name]. (e.g. podpoint_embed:field_podpoint_audio) - Source: Select the source that contains the URL to the episode page (often called "Item URL" in RSS feeds).
- Target: Select the Media Reference field on your content type. You will notice there will be two, you MUST SELECT the one that has the format
- Click the gear icon (settings) for this mapping to further customize how the target will be mapped. You only need to do this if you want to override the media type to map to.
- Media Bundle: Select your Podpoint media bundle (default:
podpoint). - URL Field: Enter the machine name of the field on the Media entity that stores the Podpoint URL (default:
field_media_podpoint_url).
- Media Bundle: Select your Podpoint media bundle (default:
- Save your mappings.
Create a Feed of the Feed Type you just created or updated
- Create a new Feed of the type you created above
- Make sure to set the Feed URL to the value of the RSS feed for your Podpoint podcast
- Run the feed
HOW IT WORKS
When the Feed import runs:
- The module takes the source URL.
- It performs an HTTP GET request to that URL.
- It searches the HTML for an iframe with a source matching
podpoint.com/episode/embed/. - It checks if a Media entity already exists with that specific Podpoint embed URL.
- If it exists, it returns that Media ID.
- If it doesn't exist, it creates a new Media entity, saves the embed URL, and returns the new ID.
- Feeds then saves this ID into your entity's reference field.
CRITICAL WARNING: It is extremely important that users do not create duplicate sermon names in Podpoint. Drupal generally expects unique labels for content items of the same type (especially when using modules like Pathauto to generate URLs from titles). If two sermons in Podpoint share the exact same name, it will likely lead to naming conflicts or broken aliases within Drupal. Always ensure each sermon title in Podpoint is unique.
SUPPORT DEVELOPMENT ON THIS MODULE
A lot of hard work and dedication has gone into developing this module. If you find it helpful and would like to support ongoing development, consider buying me a coffee! Your support helps ensure that I can continue enhancing and maintaining this module for everyone. Thank you for your generosity!