Live

Hero Ofertas

I built Hero Ofertas to bring offers and coupons into a catalog curated by discount, with price history and automatic publishing to Telegram and Discord.

PHPMySQLREST APITelegram Bot APIJSON-LD
status: live
networks: 7
campaigns: 14 dates
guides: 5
 
// publishing
telegram · discord
 
// seo
JSON-LD · sitemap
 
address: heroofertas.com.br
Offer catalog

Imports offers from seven networks and stores through drivers with a common contract, bringing them into a single catalog with its own categories and stores.

Discount curation

Minimum discounts across the organization, by category and by store: the strictest applies to the storefront and the publishing queue.

Price history

Each price change creates a row that feeds the offer chart, the lowest price badge and the price drops page.

Coupons and campaigns

Lomadee coupons and 14 campaign dates calculated each year, with a banner, a dedicated page and a badge on cards.

Publishing by channel

A queue that publishes to Telegram and Discord by segment, time window and interval, with editable message templates.

Dictionary descriptions

A dictionary that recognizes terms in the name and brand and composes descriptions for offers that arrive without text.

Buying guides

Five guides with catalog offers, frequently asked questions, structured data and prices checked before publishing.

API per organization

A REST API with a token and daily quota for products, storefront, categories, stores, coupons and link conversion.

Offers portal on top of NoName

I developed Hero Ofertas, at heroofertas.com.br, as a portal for offers and coupons from partner stores. Visitors find prices, history by product, buying guides and public channels. In the survey on October 17, 2026, the public listings contained 3,424 offers, and the partner strip on the home page showed 17 stores.

I built the portal on top of NoName, my modular platform for multiple organizations. The affiliate, website, blog, contact and email modules support publishing and administration. Offers come from affiliate networks and game stores, with periodic imports through the NoName scheduler. The portal earns a commission on purchases made through affiliate links, keeping the same price for the buyer. Steam and Epic Games use direct store links, without an affiliate program.

flow
Affiliate networks and game stores
↓
Import through drivers
↓
Single offer catalog
↓
Public storefront
↓
Channels and API

Seven networks and stores in one catalog

I organized the Hero Ofertas integrations into drivers with a common contract: test the connection, import offers and generate affiliate links. Each source has its own format and default frequency.

NetworkSourceSynchronization frequency
AwinCSV datafeed, read as a stream30 minutes
LomadeeREST API45 minutes
AliExpressOfficial SDK240 minutes, one new promotion per run
ShopeeGraphQL API120 minutes
SteamPublic featured items API360 minutes
Epic GamesPublic free games API360 minutes
GOGGiveaway pageOn demand

The "Catálogo de redes" (Network catalog) runs a daily scan and preserves the identifiers and names of stores and categories at the source. Through the admin interface, the administrator chooses what to import, including by exclusion.

I created rules to map network categories, or words in the offer name, to the catalog's own categories. The organization's rule takes priority over the default. The installation includes 60 categories with emoji. On Shopee, each seller becomes a child store of the marketplace.


Minimum discounts across the organization, by category and by store

I implemented three minimum discount percentages in Hero Ofertas: across the organization, by category and by store. For each offer, the highest required percentage among the three applies. The calculation uses the received prices: old price minus current price, divided by old price.

This minimum determines which offers appear in the storefront, category and store counts and the sitemap. It also controls entry into the publishing queue. The same rule therefore guides public selection and publishing to channels.

Free games count as a 100% discount and pass the filter. Offers without an original price also pass the storefront filter. I kept all offers available in the admin interface and preserved direct access to their pages, including when the discount falls below the minimum, to preserve links already published.


Price history and lowest price badge

I used the offer table itself as the price history for Hero Ofertas. When the price changes, the system deactivates the previous row and writes another, keeping one active row per offer. An unchanged price keeps the existing record. If an offer leaves the network and returns at the same price, the corresponding row is reactivated.

price history
Initial price → first active row
↓
Price change → previous row deactivated + new active row
↓
Another change → previous row deactivated + new active row

I drew the chart in SVG on the server, without a chart library or JavaScript: the value and date of each point appear on hover, keyboard focus or touch. It only appears with two distinct prices. The default window is 12 months, configurable from 1 to 36.

The badge appears when the current price is the lowest in the window and the offer has more than one price point. The default window is 3 months, configurable from 1 to 36. It states how long the price has been the lowest, as in "Menor preço desde 12/10" (Lowest price since 12/10), or, when it has never been higher, "Menor preço em 3 meses" (Lowest price in 3 months). The badges on a screen come from a single database query.

The "Produtos com queda de preço" (Products with a price drop) page sorts offers by the reduction from their peak over the last six months.


Coupons and calendar campaigns

I integrated Hero Ofertas coupons with Lomadee, with synchronization every 60 minutes and a store filter on the public page. Display depends on the coupon's presence on the network in the last two days and its end date, when provided. A run that encounters an error preserves the records.

I implemented the annual calculation of 14 dates: Dia do Consumidor (Consumer Day), Páscoa (Easter), Dia das Mães (Mother's Day), Dia dos Namorados (Brazilian Valentine's Day), Dia dos Pais (Father's Day), 9.9, 10.10, Dia das Crianças (Children's Day), 11.11, Black Friday, Cyber Monday, 12.12, Natal (Christmas) and Volta às aulas (Back to school). Creation preserves edits made by the administrator.

Each campaign has a color palette, a strip on the home page, a dedicated page and a badge on cards. The rules combine minimum discount, stores, categories and words.

The campaign state is calculated using the clock in America/Sao_Paulo: "agendada" (scheduled), "em breve" (coming soon), "no ar" (live) or "encerrada" (ended). When it ends, the page receives a notice and noindex. The admin interface also allows campaigns to be added manually and each one to be enabled or disabled.


Automatic publishing and Telegram bot

I developed the Hero Ofertas queue to send offers with a photo to Telegram and with an embed to Discord. The task runs every minute. Each channel has a segment (domestic, international, games or all), a time window and an interval between posts.

I used the database clock for these controls because the PHP time zone differs between web execution and the command line. The same offer at the same price, published in the last seven days, moves to "Repetida" (Repeated) with the reason recorded. Three sending failures end the attempts for that item.

The texts come from editable templates with fields in braces. Rules select the template according to the offer and channel. One template is marked as safe.

The Telegram bot converts AliExpress and Shopee links into the organization's affiliate links. Its token is encrypted, and the webhook validates a secret through a secure comparison. The channels page and the home page banner also present the public Telegram, WhatsApp and Discord channels.


Dictionary-generated descriptions

I created a dictionary to compose descriptions in Hero Ofertas because most offers arrive from the networks without a description. The installation includes 144 definitions. Terms registered by the organization take priority.

The system normalizes the name and brand to lowercase and removes accents before comparison. Matching respects word boundaries: "4k" does not match "24kg". The % symbol acts as a wildcard between words. When terms overlap, the most specific one takes precedence.

Composition applies when the received description has fewer than 60 useful characters, respecting the network's product details and manual edits. The text is assembled when the page is requested, so a dictionary change updates the corresponding descriptions. I included a tester in the admin interface and split long descriptions from stores into paragraphs.


Technical SEO and structured data

I implemented search titles and descriptions in Hero Ofertas using catalog data. The title uses up to 38 characters before the site name. The description uses up to 155. The fields can include offer counts, stores, price and discount. Categories and stores receive their own H1, introduction and canonical.

PageOutput
HomeOrganization and WebSite
OfferProduct with offer, brand, sku and image; BreadcrumbList
First page of a list, category and storeindex,follow; ItemList in listings
Page 2 onward, search and filtersnoindex,follow
Expired offernoindex,follow

Each page has a canonical. The Product includes price, currency, availability, seller and price validity. The sitemap includes the last modification date in each entry.

I configured the first six images on each page to load directly, with high priority for the first. The others use lazy loading and asynchronous decoding. On October 17, 2026, I added a title, description, H1 and sharing image to the home page and started emitting lastmod.


Buying guides designed for search engines and AI assistants

I published five guides on the Hero Ofertas blog: Bluetooth headphones, laptops for work and study, microphones for podcasts and livestreams, Bluetooth speakers and shopping on AliExpress. I chose the topics from the categories with the most offers. Each text contains between 1,240 and 1,440 words.

The guides start with a short answer and use search questions in headings. They include an offer table, cards with a thumbnail, name, price and store, frequently asked questions and a section about the survey. That section states the date, commission and use of AI-generated photos to illustrate the category.

production
Read published products and catalog statistics
↓
Text by ChatGPT with facts and numeric placeholders
↓
Replace placeholders with the day's values
↓
Validate punctuation, links, title and price range

The generator rejects em dashes, links outside the list, search titles over 38 characters and prices incompatible with the declared range. The published values represent the survey date.

I included BlogPosting, BreadcrumbList and FAQPage, with questions extracted from the visible text. Updates propagate to the sitemap, API and head. Each post shows three reading suggestions, selected by tags and category, with ties broken by date.


Theme and site pages

I developed the Hero Ofertas theme for the NoName Site module, with light and dark modes. The current version is 2.8.0.

I organized the home page in this sequence: banner, campaign strip, domestic offers, Telegram invitation, games on sale, available channels, international offers, coupons and recent blog content. The channel banner texts can be edited through the admin interface.

Offer cards show the campaign badge when the offer meets the rule and the lowest price badge when the history supports it. For the blog, I created guide and listing templates. The guide uses a 1320 px container, a text reading width of 1040 px, breadcrumbs and an update date.

The theme also includes a 404 page, Sobre (About), Contato (Contact) with a form, Privacidade (Privacy), Termos (Terms) and Planos (Plans). On Hero Ofertas, the Planos page is hidden.


Admin interface and integration health

I organized Hero Ofertas administration under the "Afiliados" (Affiliates) menu, with 16 screens:

  • Visão geral (Overview), Ofertas (Offers), Cupons (Coupons) and Campanhas (Campaigns).
  • Fila de divulgação (Publishing queue), Integrações (Integrations), Catálogo de redes (Network catalog) and Bot Telegram (Telegram bot).
  • Canais de envio (Sending channels), Canais públicos (Public channels), Mensagens (Messages) and Configurações (Settings).
  • Status, Lojas (Stores), Categorias (Categories) and Dicionário (Dictionary).

Each synchronization records its result. On the third consecutive failure, administrators receive a notification in the bell, with optional email delivery. Another notification reports the network's recovery.

The health check runs every 60 minutes and also identifies integrations that have gone more than twice their interval without synchronizing. On the Status screen, the last error appears with a date. After the network recovers, it remains on the screen, marked as "Erro anterior, já superado" (Previous error, already resolved).


Releases, tests and installation

I built the NoName update process around signed packages, distributed through a central service and received through the "Atualizações" (Updates) screen, with integrity checked using sha256. Module installers are idempotent: they create missing structures and update columns, indexes and tables.

Before each version, I run an automated set of 187 test suites. In the current version, all passed. I also use a module and theme checker.

Content tables identify the owning organization, while stores and categories can be shared. Network credentials are encrypted per organization. Hero Ofertas runs one organization on this foundation.

The core handles authentication, users, organizations, permissions, modules, updates and scheduling. I kept business logic in the modules. On October 17, 2026, the portal used NoName 1.50.1, Sistema de Afiliados (Affiliate System) 3.14.0, Site 1.26.0, Blog 1.10.0, Contato 1.8.0 and E-mails (Emails) 2.10.0.

During imports, transient failures are retried after two seconds, with a limit of three retries per run.


REST API and module plans

I exposed a REST API per organization in the Sistema de Afiliados module, authenticated by token and subject to a daily quota. The endpoints provide products with filters and pagination, product lookup, a storefront grouped by segment, categories, stores, coupons and link conversion.

The converter-link endpoint works with AliExpress and Shopee URLs. An incorrect method receives 405 and preserves the quota. The absence of a plan with API access results in 403. Quota exhaustion results in 429.

I structured the Grátis (Free), Pro and Business plans with limits on networks, offers, channels, bot, automatic posting and API. These limits are part of the module I used to build Hero Ofertas. On the portal, the Planos page is hidden, and the public features presented are the catalog, coupons, channels and buying guides.

How it was built

I developed Hero Ofertas with PHP 8 on NoName's own core, using modules for business logic and a custom theme for public pages.

language:: PHP 8, with PHPMailer, Guzzle, firebase/php-jwt and mPDF among the few libraries.
database:: MySQL/MariaDB for offers, price history, settings and the publishing queue.
networks:: cURL, the official AliExpress SDK, Shopee GraphQL, APIs and datafeed.
messaging:: Telegram API through a webhook and Discord webhook.
scheduling:: NoName's own scheduler for synchronization, publishing, cleanup and health checks.
front-end:: Tailwind in the module's CSS, custom CSS in the theme, plain JavaScript, SVG and JSON-LD.
hosting:: shared hosting with LiteSpeed.
platform:: NoName, my modular platform for multiple organizations, with its own core and modules for affiliates, website, blog, contact and emails.