IN PROGRESS
Technical summary
NEXUS plugin for SEO intelligence and competitive analysis via Semrush API v3: domain overview (organic/paid traffic, keywords, cost), organic keywords with ranking and volume, backlinks (total, referring domains, authority), domain/URL enrichment in the Intelligence Hub, 7-day cache and Alpine.js interface with 3 slash commands — requires a paid Semrush account.
Executed scope
backend.phpbackend (474 lines):api.semrush.com/?type=...&key=...(query params);keyauthentication (paid Semrush account).- Configuration (
semrush_settings_save):api_keyviaDB::setConfig('semrush_settings', ...)with fallback toSEMRUSH_API_KEYconstant;semrush_get_api_key()resolves priority. - Tables (created by
semrush_install()):semrush_cache(kind, query_key, data, error, status, http_code;UNIQUE uk_kind_key) andsemrush_history(query_type, query_val, status, task_id;idx_created_at). - Cache: fixed TTL
SEMRUSH_CACHE_TTL = 604800(7 days), upsert per kind+key (lowercase key);forceparameter bypasses cache. - HTTP (
semrush_http_request): 4s connect / 10s timeout; handles JSON/CSV errors and formats messages viasemrush_format_api_error. - Domain Overview (
semrush_domain_overview) — GET/domain_rankswithexport_columns Or,Ot,Oc,Ad,At,Ac; returnsorganic_keywords,organic_traffic,organic_cost,adwords_keywords,adwords_traffic,adwords_cost. - Organic Keywords (
semrush_organic_keywords) — GET/domain_organic(limit 10); returns array of keywords withkeyword,position,volume,cpc,url. - Backlinks Overview (
semrush_backlinks_overview) — GET/backlinks_overview(target_type domain); returnstotal_backlinks,referring_domains,authority_score,dofollow_ratio(calculated %). semrush_status— validates the key; returnshas_key, mode ("Semrush API (Conectado)" or "Sem Chave de API") and service status.semrush_history— page and limit ≤ 50; lists queries with type, domain, status and date.- Intelligence Hub:
semrushenricher (priority 60, typesdomain,url) — receives artifacts, normalizes domain, queriesdomain_overview, emits signalseverity: 'info',status: 'active', summarySemrush Overview para {domain}with full domain_overview payload. - API: 6 actions via
PluginManager::registerApiAction(semrush_status, semrush_domain_overview, semrush_organic_keywords, semrush_backlinks_overview, semrush_history, semrush_settings_save). - Alpine.js UI (
tab.php, 363 lines): 3 tabs — Domain Overview (domain input, KPI cards: organic keywords, traffic, cost, adwords), Organic Keywords (table keyword/position/volume/CPC), Backlinks (total, referring domains, score, dofollow %) and History (queries). - Fastr: 3 commands —
/semrush <domain>,/semrush-keywords <domain>,/semrush-backlinks <domain>. - No cron — on-demand plugin (7-day cache reduces repetition).
Stack and tools
- PHP 8 (no framework)
- MySQL 8 (semrush_cache + semrush_history)
- Alpine.js + Tailwind CSS (premium light, indigo ring)
- NEXUS plugin system (PluginManager)
- cURL → Semrush API v3 (api.semrush.com, CSV responses)
Operational tags
- SEO
- Semrush
- Market Intelligence
- Keywords
- Backlinks
- Competitive Analysis
- Plugin NEXUS
Operational outcome
- On-demand SEO analysis: complete overview of organic/paid traffic, keywords, cost and backlinks — all in 3 parallel queries.
- Ranked keywords: top 10 keywords with current ranking, search volume and CPC — real-time content strategy.
- Backlink intelligence: total backlinks, referring domains, site authority and dofollow ratio — link building audit.
- Automatic enrichment: domains/URLs in tasks/comments become structured signals with SEO insights in the Intelligence Hub.
- 7-day cache reduces paid quota consumption;
forceallows immediate refresh. - Auditable history of all queries (type, domain, status, date).
GitHub progress (issues)
Real-time panel with latest repository issues.
live feed
open issues on GitHubcarregando andamento...
não foi possivel carregar as issues agora. abra no github pelo link acima.
Real results
NEXUS plugin for SEO intelligence and competitive analysis via Semrush API v3: domain overview (organic/paid traffic, keywords, cost), organic keywords with ranking and search volume, backlinks overview (total, referring domains, authority, dofollow ratio), domain/URL enrichment in the Intelligence Hub, 7-day cache and Alpine.js interface with 3 slash commands.
Architecture and organization
- PHP 8
- MySQL 8
- Alpine.js
- Tailwind CSS
- Plugin NEXUS
Execution and operations
The project follows reproducible execution flow with technical validation in production-like environments.
Screenshots
Talk about this project
Apply this implementation pattern in your environment and accelerate delivery with technical consistency.