curl --request POST \
--url https://api.royalti.io/user/bulk/entity \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": [
{
"artistName": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "[email protected]",
"splitShare": 123
}
],
"sendEmail": true,
"redirect_url": "<string>"
}
'{
"message": "Bulk entity creation completed.",
"createdEntities": [
{
"artistName": "Melodic Harmony",
"userName": "Emma Johnson"
}
],
"processedCount": 1,
"errors": [
"Invalid email format for Michael Chen",
"Invalid split share percentage for Sonic Wave"
]
}/user/bulk/entity
curl --request POST \
--url https://api.royalti.io/user/bulk/entity \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": [
{
"artistName": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "[email protected]",
"splitShare": 123
}
],
"sendEmail": true,
"redirect_url": "<string>"
}
'{
"message": "Bulk entity creation completed.",
"createdEntities": [
{
"artistName": "Melodic Harmony",
"userName": "Emma Johnson"
}
],
"processedCount": 1,
"errors": [
"Invalid email format for Michael Chen",
"Invalid split share percentage for Sonic Wave"
]
}/user/bulk/entity endpoint allows the creation of multiple entities in bulk by providing details for each entity, including artist name, first name, last name, email, and split share.
Method:POST
Request Payload:
| Parameter | Type | Description |
|---|---|---|
| data | array | An array of entity objects with their details. |
| sendEmail | boolean | This sends an invite email to the entities, by default it is true. |
| redirect_url (Optional) | string | The URL to redirect after creation. |
const response = await fetch('https://api.royalti.io/user/bulk/entity', {
method: 'POST',
headers: {
'Authorization': `Bearer ${token}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
"data": [
{
"artistName": "sample-artistName",
"firstName": "sample-firstName",
"lastName": "sample-lastName",
"email": "sample-email",
"splitShare": 1
}
],
"sendEmail": true,
"redirect_url": "sample-redirect_url"
})
});
const data = await response.json();
console.log(data);
JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"