Menu

Referência da API · Estratégias AI

Estratégias

strategy_generator · strategies · 5 operações

GET/v1/strategy-generator/strategies

List AI paid media strategies

strategy_generator.strategies.list

LeituraIdempotenteDesde 2026-11-01

Lists the organization's AI paid media strategies (generated from a briefing by MB Suite's AI: channel mix, campaigns and budget), newest first, paginated by cursor (limit up to 200). Each row is a summary: name, status (generating, completed or error), objective, ad platforms, currency, monthly budget range (min_budget, max_budget), number of campaigns, label ids and, for a failed one, its error message. Filters status, objective, label_id and search (text in the name) fill the page (a page can come short only for a rare filter after scanning 600 strategies, with has_more true). Read one with strategy_generator.strategies.get. Strategies are generated in the app (AI Strategies): this API reads, edits, exports and deletes them. Requires view access to AI Strategies.

Escopo
strategy_generator:read
Permissão
Ver o módulo
Tool do MCP
strategy_generator_strategies_listNa superfície completa; na compacta, mb_execute_operation com id: "strategy_generator.strategies.list".

Custo declarado: até 202 leituras e 0 escritas por chamada (contam na cota diária).

Parâmetros

limitintegerqueryopcional

How many items this page brings at most (see the maximum and the default in the schema).

Padrão: 50

cursorstringqueryopcional

The next_cursor of the previous page, exactly as it came (only for the same list and filters); without it, the first page.

statusenumqueryopcional

Only strategies in this state: generating, completed or error.

Valores: generating, completed, error

objectiveenumqueryopcional

Only strategies whose briefing has this campaign objective.

Valores: leads, sales, traffic, branding, app_install

label_idstringqueryopcional

Only strategies tagged with this label (strategy_generator.labels.list).

searchstringqueryopcional

Case-insensitive text contained in the strategy name.

Resposta

dataarray<object>
has_moreboolean
next_cursorstring

Erros

Exemplo

curl "https://api.mb-suite.com/v1/strategy-generator/strategies" \
  -H "Authorization: Bearer $MB_API_KEY"

Testar com a sua API key de teste

Com uma API key de teste o pedido vai sempre para a sua organização de prática: dados de exemplo que você pode reiniciar.

curl "https://api.mb-suite.com/v1/strategy-generator/strategies" \
  -H "Authorization: Bearer $MB_TEST_KEY"
GET/v1/strategy-generator/strategies/{strategy_id}

Get one AI paid media strategy

strategy_generator.strategies.get

LeituraIdempotenteDesde 2026-11-01

Returns one strategy: name, status, the briefing it was generated from (input: project, landing page, sector, product, objective, currency, budget mode, ad platforms, countries, languages, audience, interests, keywords and regions by country code), the AI plan, the projections the person adjusted (projections, null until edited or after a regeneration), label ids and the AI model used. result (null until the first generation finishes) holds the AI plan with snake_case keys: executive_summary; recommended_mix (list of {channel, percentage, reason}); detailed_plan (list of campaigns {id, channel, campaign_name, campaign_type, rationale, budget_percentage, kpis}); total_budget_estimation, min_budget, max_budget and currency (the monthly budget range); targeting_personas and audience_insights; the objective's estimated metrics (estimated_cpl, estimated_cpc, estimated_ctr, estimated_conversion_rate, estimated_total_leads, ecommerce_funnel…) and metric_rationales. The prompt sent to the AI and its raw answer are not returned. Not found (strategy_not_found) if the id does not exist in this organization. Requires view access to AI Strategies.

Escopo
strategy_generator:read
Permissão
Ver o módulo
Tool do MCP
strategy_generator_strategies_getNa superfície completa; na compacta, mb_execute_operation com id: "strategy_generator.strategies.get".

Custo declarado: até 1 leituras e 0 escritas por chamada (contam na cota diária).

Parâmetros

strategy_idstringrotaobrigatório

Strategy id (from strategy_generator.strategies.list).

Resposta

idstring

Strategy id.

namestring

Strategy name.

statusenum

generating, completed or error.

Valores: generating, completed, error

inputobject

The briefing it was generated from.

resultobject | null

The AI plan (its keys as the AI wrote them); null until the first generation finishes.

projectionsobject | null

The projection values the person adjusted; null until edited or after a regeneration.

label_idsarray<string>

Labels (strategy_generator.labels.list).

ai_modelstring | null

The AI model that generated it.

error_messagestring | null

Why the generation failed (status error).

created_bystring | null

Who created it (uid).

created_atnumber

Epoch ms.

updated_atnumber

Epoch ms.

created_by_namestring | null

That person's name (null when MB Suite does not know it: a former member).

Erros

Exemplo

curl "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_API_KEY"

Testar com a sua API key de teste

Com uma API key de teste o pedido vai sempre para a sua organização de prática: dados de exemplo que você pode reiniciar.

curl "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_TEST_KEY"
PATCH/v1/strategy-generator/strategies/{strategy_id}

Rename, label or edit an AI paid media strategy

strategy_generator.strategies.update

EscritaIdempotenteDesde 2026-11-01

Changes one or more of these, sent inside updates ({ strategy_id, updates: { … } }): name (up to 200 characters); label_ids (replaces the whole list; ids from strategy_generator.labels.list, unknown ones are dropped); result (replaces the WHOLE AI plan: send the complete object you read with strategy_generator.strategies.get, modified, keeping recommended_mix and detailed_plan as lists; up to 400 KB); projections (replaces the projection values: rates, amounts, budget_basis min|avg|max, campaign_budget_mode, hide_revenue). result (null until the first generation finishes) holds the AI plan with snake_case keys: executive_summary; recommended_mix (list of {channel, percentage, reason}); detailed_plan (list of campaigns {id, channel, campaign_name, campaign_type, rationale, budget_percentage, kpis}); total_budget_estimation, min_budget, max_budget and currency (the monthly budget range); targeting_personas and audience_insights; the objective's estimated metrics (estimated_cpl, estimated_cpc, estimated_ctr, estimated_conversion_rate, estimated_total_leads, ecommerce_funnel…) and metric_rationales. The plan can only be edited on a completed strategy (409 strategy_not_ready while it generates or after a failed first generation). Unknown fields are rejected. It does not run the AI: a new plan is generated from the app. Idempotent: sending what the strategy already has changes nothing (changed: false). Returns the strategy. Requires edit access to AI Strategies.

Escopo
strategy_generator:write
Permissão
Editar no módulo
Tool do MCP
strategy_generator_strategies_updateNa superfície completa; na compacta, mb_execute_operation com id: "strategy_generator.strategies.update".

Custo declarado: até 101 leituras e 1 escritas por chamada (contam na cota diária).

Parâmetros

strategy_idstringrotaobrigatório

Strategy id (from strategy_generator.strategies.list).

updatesobjectcorpoobrigatório

What changes (at least one field).

Resposta

strategyobject

The strategy as it is now.

changedboolean

false when the values sent were already the current ones: nothing was written.

Erros

Exemplo

curl -X PATCH "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "updates": {}
}'

Testar com a sua API key de teste

Com uma API key de teste o pedido vai sempre para a sua organização de prática: dados de exemplo que você pode reiniciar.

curl -X PATCH "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_TEST_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "updates": {}
}'
DELETE/v1/strategy-generator/strategies/{strategy_id}

Delete an AI paid media strategy

strategy_generator.strategies.delete

IrreversívelDesde 2026-11-01

Deletes a strategy. It stays 30 days in the trash, where an owner or admin can restore it with the same id, its plan, projections and labels (platform.trash.restore); a strategy deleted while generating loses that run and comes back with its previous plan, or as failed if it had none. Outside the app it needs a dry run and a confirm_token, except a REST DELETE with a key allowed to delete. Emits strategy_generator.strategy.deleted. Requires edit access to AI Strategies.

Com uma API key, este DELETE roda direto: o registro fica 30 dias na lixeira e a resposta traz o seu trash_item_id. Com um token OAuth, e pelo MCP, pede dry_run → confirm_token.

Escopo
strategy_generator:write e «Permitir exclusões» (strategy_generator:delete no OAuth)
Permissão
Editar no módulo
Tool do MCP
strategy_generator_strategies_deleteNa superfície completa; na compacta, mb_execute_operation com id: "strategy_generator.strategies.delete".

Custo declarado: até 1 leituras e 2 escritas por chamada (contam na cota diária).

Parâmetros

strategy_idstringrotaobrigatório

Strategy id (from strategy_generator.strategies.list).

Resposta

oktrue
trash_item_idstring

The trash item this deletion left: the item_id of platform.trash.restore (POST /trash/{item_id}/restore). Missing if nothing went to the trash.

trash_item_idsarray<string>

Only when the deletion left more than one copy: all of them, the first being trash_item_id.

trash_expires_atnumber

When the copy leaves the trash for good (epoch ms): 30 days after the deletion.

Erros

Exemplo

curl -X DELETE "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_API_KEY"

Testar com a sua API key de teste

Com uma API key de teste o pedido vai sempre para a sua organização de prática: dados de exemplo que você pode reiniciar.

curl -X DELETE "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}" \
  -H "Authorization: Bearer $MB_TEST_KEY"
POST/v1/strategy-generator/strategies/{strategy_id}/export-pdf

Export an AI paid media strategy to PDF

strategy_generator.strategies.export_pdf

EscritaDesde 2026-11-01

Renders a strategy to an A4 PDF with the organization's branding and returns a signed download link that expires in 24 hours, plus the file name and size. sections picks what goes in (cover, strategy, projections, briefing; default all four). The projections in the PDF are the ones saved in the strategy. Rendering can take tens of seconds; when the PDF service is slow or not available right now it fails with pdf_unavailable (503): retry after retry_after. A strategy without a generated plan cannot be exported (409 strategy_not_ready). Not idempotent: each call renders a new file. Requires edit access to AI Strategies.

Instruções para agentes

Give the person the download link and say it expires in 24 hours. Do not paste the link anywhere public.

Escopo
strategy_generator:write
Permissão
Editar no módulo
Tool do MCP
strategy_generator_strategies_export_pdfNa superfície completa; na compacta, mb_execute_operation com id: "strategy_generator.strategies.export_pdf".

Custo declarado: até 1 leituras e 0 escritas por chamada (contam na cota diária). Usa uma plataforma externa (pdf): conta na cota de operações externas.

Parâmetros

strategy_idstringrotaobrigatório

Strategy id (from strategy_generator.strategies.list).

sectionsarray<enum>corpoopcional

Sections to include, in this order: cover, strategy, projections, briefing (default: all four).

Valores: cover, strategy, projections, briefing

Resposta

download_urlstring

Signed link to the PDF (24 hours).

file_namestring

The file name.

size_bytesnumber

Its size.

expires_atnumber

When the link stops working (epoch ms).

Erros

Exemplo

curl -X POST "https://api.mb-suite.com/v1/strategy-generator/strategies/{strategy_id}/export-pdf" \
  -H "Authorization: Bearer $MB_API_KEY"

Testar com a sua API key de teste

Com uma API key de teste o pedido vai sempre para a sua organização de prática: dados de exemplo que você pode reiniciar. Na prática esta operação não é simulada (usa outra plataforma): responde 409 sandbox_external_unavailable.