The customer's AI proposes subjects, copy or a design using the brand kit (ai.use; nothing is applied)
const url = 'https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/ai/suggestions';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"kind":"subject","brief":"example","language":"es-MX","count":3,"bodyText":"example","currentSubject":"example","tone":"formal","customTone":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/ai/suggestions \ --header 'Content-Type: application/json' \ --data '{ "kind": "subject", "brief": "example", "language": "es-MX", "count": 3, "bodyText": "example", "currentSubject": "example", "tone": "formal", "customTone": "example" }'Uses the customer’s AI key. Returns variants already checked by code (clean subjects and copy; design with the kit’s colors, logos and fonts, and size measured against the 100 KB limit). The user decides with :accept or :reject.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Example
brd_01hx0000000000000000000000Request Bodyrequired
Section titled “Request Bodyrequired”object
What to communicate. It is data for the AI, not instructions.
Variants for the A/B test.
Email body text, so the subject reflects it.
Predefined subject tone.
Custom tone, in the user’s own words. Cannot be combined with tone.
object
What to communicate. It is data for the AI, not instructions.
object
What to communicate. It is data for the AI, not instructions.
Versions from the brand’s drive that the AI may use (only these).
Https URL of the button. The AI never writes it.
Responses
Section titled “Responses”Proposal pending decision
object
object
object
object
Example
{ "kind": "subject", "status": "proposed"}Invalid data
object
object
Example
{ "error": { "code": "not_found" }}No session, expired session, or invalid, expired or revoked API key
object
object
Example
{ "error": { "code": "not_found" }}Not allowed, API key missing the scope, IP not allowed, or request rejected (csrf_rejected)
object
object
Example
{ "error": { "code": "not_found" }}Does not exist or is not visible to you
object
object
Example
{ "error": { "code": "not_found" }}Conflict
object
object
Example
{ "error": { "code": "not_found" }}Error
object
object
Example
{ "error": { "code": "not_found" }}Error
object
object
Example
{ "error": { "code": "not_found" }}Error
object
object
Example
{ "error": { "code": "not_found" }}Too many attempts
object
object
Example
{ "error": { "code": "not_found" }}Internal error
object
object
Example
{ "error": { "code": "not_found" }}Error
object
object
Example
{ "error": { "code": "not_found" }}Service temporarily unavailable
object
object
Example
{ "error": { "code": "not_found" }}