curl --request POST \
--url http://localhost:3000/api/attributes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"label": "<string>",
"type": "string",
"category": "user",
"operators": [
"<string>"
],
"suggestions": [
"<string>"
],
"placeholder": "<string>",
"description": "<string>"
}
'{
"statusCode": 123,
"message": "OK",
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"label": "<string>",
"type": "string",
"category": "user",
"operators": [
"<string>"
],
"is_custom": true,
"is_active": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"suggestions": [
"<string>"
],
"placeholder": "<string>",
"description": "<string>",
"created_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}Creates a new custom attribute
curl --request POST \
--url http://localhost:3000/api/attributes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"label": "<string>",
"type": "string",
"category": "user",
"operators": [
"<string>"
],
"suggestions": [
"<string>"
],
"placeholder": "<string>",
"description": "<string>"
}
'{
"statusCode": 123,
"message": "OK",
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"label": "<string>",
"type": "string",
"category": "user",
"operators": [
"<string>"
],
"is_custom": true,
"is_active": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"suggestions": [
"<string>"
],
"placeholder": "<string>",
"description": "<string>",
"created_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Unique attribute key (lowercase, alphanumeric with dots/underscores)
2 - 255Human-readable label
string user Allowed operators for this attribute