Create Persona
curl --request POST \
--url https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"country": "US",
"description": "A consultant who flies each week and works on the plane.",
"name": "Frequent flyer",
"city": "Chicago",
"properties": {}
}
'import requests
url = "https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas"
payload = {
"country": "US",
"description": "A consultant who flies each week and works on the plane.",
"name": "Frequent flyer",
"city": "Chicago",
"properties": {}
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
country: 'US',
description: 'A consultant who flies each week and works on the plane.',
name: 'Frequent flyer',
city: 'Chicago',
properties: {}
})
};
fetch('https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"description": "<string>",
"id": 123,
"name": "<string>",
"city": "<string>",
"country": "<string>",
"properties": {}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}Personas
Create Persona
Create a persona. Give it to a topic with persona_id.
The answer engines answer the scenarios of the topic as they answer a
person in country and city. A name that the brand has gets 409
conflict, and a persona that the plan cannot hold gets 403
plan_limit_reached.
POST
/
customer
/
v1
/
brands
/
{brand_id}
/
personas
Create Persona
curl --request POST \
--url https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"country": "US",
"description": "A consultant who flies each week and works on the plane.",
"name": "Frequent flyer",
"city": "Chicago",
"properties": {}
}
'import requests
url = "https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas"
payload = {
"country": "US",
"description": "A consultant who flies each week and works on the plane.",
"name": "Frequent flyer",
"city": "Chicago",
"properties": {}
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
country: 'US',
description: 'A consultant who flies each week and works on the plane.',
name: 'Frequent flyer',
city: 'Chicago',
properties: {}
})
};
fetch('https://app.backend.genezio.ai/customer/v1/brands/{brand_id}/personas', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"description": "<string>",
"id": 123,
"name": "<string>",
"city": "<string>",
"country": "<string>",
"properties": {}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}{
"error": {
"code": "brand_access_denied",
"message": "This API key has no access to this brand",
"details": [
{
"field": "page_size",
"message": "Input should be less than or equal to 100"
}
],
"request_id": "4f3c2e1a-9b7d-4c1e-8f2a-1d3e5b7c9a0f"
}
}Authorizations
An API key of your account, from Settings > API Keys. It starts with gnz-.
Headers
Any unique string, such as a UUID. Send the same key again to get the first answer and not a second write. The API keeps an answer for 24 hours.
Path Parameters
Body
application/json
ISO 3166-1 alpha-2, such as US or RO.
Example:
"US"
Required string length:
1 - 5000Example:
"A consultant who flies each week and works on the plane."
Required string length:
1 - 255Example:
"Frequent flyer"
Maximum string length:
255Example:
"Chicago"
The sections that describe the persona.
Show child attributes
Show child attributes