v1
latestOpenAPI 3.0.02026-08-043111167.0 KBAffiliate
Create many affiliates
Create many users, companies, and companyUsers given an array of UsersData
post/affiliates/create
Query parameters
authorizationstring required
Authorization token
productIdstring required
Product id
Request body
Example request
[
{
"name": "John Doe",
"documentTypeId": 1,
"documentNumber": "1234567890"
}
]Response
Affiliate model instance
Example response
{
"companies": [
{
"id": 1,
"name": "John Doe Inc",
"slug": "jhon-doe-inc",
"CompanyProduct": [
{
"id": 1,
"slug": "jhon-doe-inc"
}
],
"errors": [
{
"reason": "Document number already exists",
"documentTypeId": 1,
"documentNumber": "123456789",
"status": "error"
}
]
}
]
}