curl --request POST 'https://core.getfaceage.com/api/v1/business/{business_id}/access' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--data-raw '{
"sites": [
"https://first-domain.com",
"https://second-domain.app"
]
}'
{
"status": true,
"data": {
"id": 9823,
"user_id": 5078,
"name": "my beauty salon",
"main_domain": "mybeauty-salon.com",
"site": "https://www.mybeauty-salon.com",
"country_id": 22,
"business_size": "medium",
"token": "Wdroi9WuX8klSeb6zbN0",
"status": "active",
"created_at": "2024-03-16T11:41:41.000000Z",
"updated_at": "2024-03-16T11:43:00.000000Z",
"access_list": [
{
"id": 309,
"business_id": 9823,
"site": "https://first-domain.com",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
},
{
"id": 310,
"business_id": 9823,
"site": "https://second-domain.app",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
}
]
}
}
{
"status": false,
"message": "Id is not valid"
}
{
"message": "Unauthenticated."
}
Business management
Add access
Restrict your API key to your own domains.
POST
/
business
/
{business_id}
/
access
curl --request POST 'https://core.getfaceage.com/api/v1/business/{business_id}/access' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--data-raw '{
"sites": [
"https://first-domain.com",
"https://second-domain.app"
]
}'
{
"status": true,
"data": {
"id": 9823,
"user_id": 5078,
"name": "my beauty salon",
"main_domain": "mybeauty-salon.com",
"site": "https://www.mybeauty-salon.com",
"country_id": 22,
"business_size": "medium",
"token": "Wdroi9WuX8klSeb6zbN0",
"status": "active",
"created_at": "2024-03-16T11:41:41.000000Z",
"updated_at": "2024-03-16T11:43:00.000000Z",
"access_list": [
{
"id": 309,
"business_id": 9823,
"site": "https://first-domain.com",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
},
{
"id": 310,
"business_id": 9823,
"site": "https://second-domain.app",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
}
]
}
}
{
"status": false,
"message": "Id is not valid"
}
{
"message": "Unauthenticated."
}
Adds domains that are allowed to use your business’s API key. Once domains are set, the key only works on those domains — this protects your credits if the key is copied from your site.
Path parameters
integer
required
ID of the business.
Body
string[]
required
List of your domains, for example
["https://first-domain.com", "https://second-domain.app"].Response
boolean
true when the domains are added.object
The business, including
access_list with every allowed domain.curl --request POST 'https://core.getfaceage.com/api/v1/business/{business_id}/access' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--data-raw '{
"sites": [
"https://first-domain.com",
"https://second-domain.app"
]
}'
{
"status": true,
"data": {
"id": 9823,
"user_id": 5078,
"name": "my beauty salon",
"main_domain": "mybeauty-salon.com",
"site": "https://www.mybeauty-salon.com",
"country_id": 22,
"business_size": "medium",
"token": "Wdroi9WuX8klSeb6zbN0",
"status": "active",
"created_at": "2024-03-16T11:41:41.000000Z",
"updated_at": "2024-03-16T11:43:00.000000Z",
"access_list": [
{
"id": 309,
"business_id": 9823,
"site": "https://first-domain.com",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
},
{
"id": 310,
"business_id": 9823,
"site": "https://second-domain.app",
"created_at": "2024-03-17T06:48:23.000000Z",
"updated_at": "2024-03-17T06:48:23.000000Z"
}
]
}
}
{
"status": false,
"message": "Id is not valid"
}
{
"message": "Unauthenticated."
}