CiviCRM Entity is a Drupal module which exposes many CiviCRM API entities as true Drupal entity types. That means that almost any module that can use Drupal entities can also access and manipulate CiviCRM data, Drupal style.
4.0.x is compatible with Drupal 10.1 and 11 and CiviCRM 5.60 and above
8.x-3.x for Drupal 8/9 (unsupported)
7.x-2.x is compatible with CiviCRM versions 4.3-5.x, but works best with 4.6 and above.
This module integrates nearly 40 CiviCRM entities as Drupal entities by wrapping CiviCRM API calls in extended Drupal Entity controllers.
- Contacts
- Addresses
- Emails
- Phones
- Events
- Participants
- Contribution Pages
- Contributions
- Line Items
- Financial Transactions
- Price Sets, Price Fields, Price Field Values
- Activities
- Many more...
This means:
- Developers can use the core and contrib Entity API for working with CiviCRM data
- Rules integration
- Display Suite, and Display Suite Forms Integration
- Views integration
- Works with Entity References
- Works with Search API and Facet API.
- Places nicely with Services module
- Works with Entityqueue.
- Native Drupal View Pages (e.g. /civicrm-contact/1)
- Native Drupal Edit Forms (e.g. /civicrm-contact/1/edit)
- Add Drupal fields to CiviCRM Entities
- Extendable by custom modules or CiviCRM extensions to add or alter entities
- Can integrate with Commerce with just a little elbow grease
Development is active and ongoing.
Documentation
See the CiviCRM Entity handbook page on Drupal.org for documentation. Feel free to make improvements, or suggest in #2122645 - Improve documentation. This documentation is so old, its almost pointless. We'll be upgrading this. Until then try looking at blog articles and presentations to glean useful information
The document is old kinda, still useful as an intro but....Just ping me on the CiviCRM Mattermost chat, CiviCRM Entity channel and I'll help you out. Ping @jackrabbithanna . Its free, its cool, and all the Drupal dev expatriates to the CiviCRM world hang out there. If you're thinking, "wow there's a lot of modules here, how does it all work?" Just get on and ask me!
Blog Articles
- Training Video: Getting Started with CiviCRM Entity 3.0 in Drupal 8 & Drupal 9
- Using Layout Builder in Drupal 8 and 9 to Construct Awesome CiviCRM Event Pages
- Customizing Event Pages with Media in Drupal 8 and Drupal 9
- Building better Contribution Reports with Views in Drupal 8 and Drupal 9
- Creating Interactive Maps with CiviCRM Addresses
- Doing More with CiviCRM Contact Data in Drupal 8
- Adding Drupal Fields to CiviCRM entities, and Managing CiviCRM Entity Displays
- Developing with CiviCRM Entity and the Drupal API
- Using CiviCRM Entity Price Set Field, a pure Drupal FAPI Ajax powered CiviCRM Event Registration form
- Using the CiviCRM Entity Reference Field submodule
- CiviCRM Entity and Inline Entity Form
- Using Drupal Search and Facet APIs with CiviCRM Data
- Drupal/CiviCRM Integration - CiviCRM Entity and Webform CiviCRM
Presentations
Introduction to CiviCRM Entity Development
Google Slides, Intro to features , focus on CiviCRM Events.
My CiviCon 2015 Presentation, CiviCRM Drupal Integration
CiviCRM entity is covered in the second half of the slides.
My CiviCon 2016 presentation, Superior Drupal Integration
Developer Information
Developers can alter the information used by CiviCRM Entity to integrate the different CiviCRM entity types.
see civicrm_entity.api.php for details for implementing or read about it here.
hook_civicrm_entity_supported_entity_info()
Despite its name it acts like a standard drupal alter hook
The new hook allows developers to:
- Add entities that aren't exposed by default
- Alter settings for entities that are exposed such as theme template
- Permissions necessary to view/add/create entities
- Set or add display suite formatters for entity properties
- Change the property that is used for the entity label
- create your own access callback for customizing view/add/create access
Contribution
Please use the Drupal.org issue queue for bug reports.
We encourage you fork the GitHub repo, because that is where the actual active development is being coordinated and code discussion takes place. After committing to your fork, create a pull request to receive commit credit.
Join the discussion on CiviCRM's Mattermost site, civicrm entity channel:
Hire Skvare to add the specific feature you want, now. We’ll put it back into the general release and continue building more functionality. Clients have already committed funds to further extend this project. Those who fund development guide the priorities, milestones, and timelines.
Talk to Mark Hanna, CiviCRM Entity maintainer and new development lead. CiviCRM LTS maintainter. @jackrabbithanna on Twitter and chat.civicrm.org
Project information
- Project categories: Integrations
1,837 sites report using this module
- Created by eileenmcnaughton on , updated
Stable releases for this project are covered by the security advisory policy.
Look for the shield icon below.








