A post carries two independent campaigns, and both are optional:
- Campaign is the Odoo marketing campaign (utm.campaign), the same
one used by the mailings, the leads and the UTM tracking. Any of them
can be selected.
- Social campaign is the campaign of the social media, the one holding
the budget, the campaign group and the reference used to publish a
sponsored post. Only social campaigns whose social media matches the
accounts selected on the post can be chosen. A connector module
narrows the list further with the rules of its social media, so what
is offered are the campaigns that can actually sponsor this post:
see the LinkedIn ad formats in Social Media Advertising LinkedIn.
- Editing the content of the post can invalidate the social campaign
already chosen. When that happens the field is cleared as soon as the
content changes, instead of letting the post fail when it is
published. Pick another campaign among the ones then offered.
Both are propagated to the publications of the post. A publication
imported from the social media keeps whatever its connector was able to
resolve.
Both are frozen, like the rest of the content of the post, as soon as
one of its accounts publishes: they decide how the post goes out, so
changing them afterwards would no longer describe what is online.

Social Media Advertising
This module adds the advertising layer on top of Social Media Base: the campaigns used to promote the posts, the groups that manage several campaigns as a unit, the tags that classify them and the view of the ads served by the social media.
Everything is generic, so it works with any social media. Each connector module plugs its own social media through the extension hooks, and contributes its own submenu under Advertising: campaign groups, campaigns and ads belong to a single social media, so they are never listed mixed together.
Main features:
Table of contents
Configuration
Security groups.
Advertising environment.
Stages.
Connector modules.
Usage
Choose the advertising account.
Stat buttons of the account.
Generate a campaign group.
Generate a campaign.
Campaign and campaign group stages.
Link the campaigns to a post.
A post carries two independent campaigns, and both are optional:
Both are propagated to the publications of the post. A publication imported from the social media keeps whatever its connector was able to resolve.
Both are frozen, like the rest of the content of the post, as soon as one of its accounts publishes: they decide how the post goes out, so changing them afterwards would no longer describe what is online.
Ads.
Go to Social Media > Advertising > <social media> > Ads
The view is empty until the first synchronization. The Sync ads button brings the sponsored creatives of every account the user is responsible for, and it is the only thing that does: the view shows the picture of the last synchronization, not what the social media serves right now. Each ad carries the moment it was last fetched.
An ad is named after the text of the post it promotes, which is what it is recognized by. An ad promoting a post this database does not know is named Post not available.
Every ad shows its status, its campaign, the publication it promotes and its statistics. The cards carry no image, so they all keep the same shape whether the promoted post has one or not: the images are shown on the publication, which the Publication button opens. The Open ad button opens the ad itself on the social media, not the campaign it belongs to. The status is the one set by the advertiser on the social media, with the name and the colour of the matching stage; the reason why the social media is serving the ad or not is only shown on the form of the ad.
The statistics cover the window shown next to them. They are not the figures of the whole life of the ad.
The search bar is the standard one: filter by creation date, group by account, advertising account, campaign or status, and save a favourite. The panel on the side filters by status and by account.
Only the ads of the advertising account in use are fetched. The ones of the other advertising accounts stay as they were last synchronized and are marked Advertising account not in use; the Advertising account in use filter leaves them out.
Deleting an account permanently takes with it what only that account could reach: its advertising accounts, its ads, and the campaigns and campaign groups that exist on the social media. What was written here and never published is kept, and only loses the account that is going away; so is a campaign shared with an account that stays, and a group that still holds a campaign of somebody else.
An ad the social media stops answering is archived, never deleted: its statistics are the only trace left of what it did, and the connector leaves on it the status its social media gives a deleted ad. The Delete permanently button, reserved to the administrators and to the archived ads, is what removes that history from Odoo when it is not wanted; the confirmation says what is lost. Nothing is deleted on the social media, which no longer serves that ad anyway.
The Delete ad button deletes the ad on the social media, not only in Odoo, and it cannot be undone. It is only shown for the social media whose connector deletes an ad, and only the responsible user of the account and the social media administrators may press it. What the social media answers decides what is left in Odoo: an ad the social media deletes on the spot loses its record here as well, along with its statistics, while one that is only taken for deletion keeps its record with the status the social media reports until it is processed.
An ad the social media stops serving is archived, never deleted, so its statistics survive. Archiving an account archives its ads too; deleting it deletes them.
A cron checks every six hours whether the social media serves ads this database does not know yet. No ad is fetched: it only raises a flag on the account. The responsible user gets a notice on the ads view, and the New ads available badge stays there across reloads until the ads are synchronized, so the user decides when to press Sync ads.
Fetch campaigns.
Archiving.
Campaign ownership.
Notifications you may never see.
Known issues / Roadmap
Kanban view of the campaigns.
The fold field of social.stage is meant for a kanban of the campaigns grouped by stage, which is not implemented yet. Until then the field has no visible effect.
Tags without colour.
social.tag only has a name: it has neither a colour field for the many2many_tags widget nor a uniqueness constraint on the name, so two tags can share it.
Campaign groups and tags are shared data.
social.advertising.campaign.group and social.tag have no responsible and no record rule, so every social media user sees and edits all of them, unlike the advertising accounts, the campaigns and the ads, which are restricted to their responsible. Scoping them is left for a later version.
Campaign visibility of a shared post.
The record rule of social.advertising.campaign restricts a user to the campaigns he is responsible for. If an administrator assigns a post to a user and that post is linked to a campaign of somebody else, that user cannot open the campaign from the post, and the Social Campaign field offers him nothing to choose from. A finer rule, for instance sharing the campaigns of a campaign group, is left for a later version.
Statistics of a single window.
There is no history per day, so the evolution of an ad cannot be charted: a new synchronization replaces the statistics of the previous one. Charting it needs a table of facts per day, the way social_media_base already keeps one for the accounts in social.account.statistics, and giving the advertising models the same treatment is a feature of its own.
remote_ref is writable through RPC.
The views hide remote_ref, and on the ads and the advertising accounts the ACL backs it: a social media user only reads them. The campaigns and the campaign groups are the ones he writes, so on those two he can still change or empty the field through RPC and orphan the record on the social media. Restricting the field is a hardening candidate for a later version.
Connector modules without an advertising layer.
Only LinkedIn has its advertising connector, Social Media Advertising LinkedIn. The other connectors of the family, such as social_media_x, have no advertising module yet: their accounts publish posts but do not manage campaigns.
Records without a social media are out of every menu.
The lists of campaign groups, campaigns and ads are filtered on the social media they belong to. A campaign saved without one, or a campaign group whose campaigns mix social medias, which empties its media, is therefore reachable only through a stat button or a saved filter.
Bug Tracker
Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.
Do not contact contributors directly about support or help with technical issues.
Credits
Authors
Contributors
Other credits
This work has been funded by AEOdoo (Asociación Española de Odoo - https://www.aeodoo.org)
Maintainers
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.
Current maintainer:
This module is part of the OCA/social project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.