Reference
//
Bulk create categories an...
Creates multiple categories and subcategories in a single request. Automatically groups subcategories under their parent categories.
Security
oauth2ClientCredentials(Required scopes: categories:write)
Array of category/subcategory items to create
Example:
[ { "category": "Office Expenses", "subcategory": "Water Bill", "code": "405034", "description": "Water bill" }, { "category": "Office Expenses", "subcategory": "Rent", "code": "405035", "description": "HQ RENT" } ]
- Mock serverhttps://developer.boyahq.com/_mock/v2/openapi/categories/bulk
- Productionhttps://api.boyahq.com/v2/categories/bulk
- Sandboxhttps://sandbox.api.boyahq.com/v2/categories/bulk
curl -i -X POST \
https://developer.boyahq.com/_mock/v2/openapi/categories/bulk \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'business_id: string' \
-H 'org_wallet_ref: string' \
-d '{
"items": [
{
"category": "Office Expenses",
"subcategory": "Water Bill",
"code": "405034",
"description": "Water bill"
},
{
"category": "Office Expenses",
"subcategory": "Rent",
"code": "405035",
"description": "HQ RENT"
}
]
}'Categories and subcategories created successfully
Response
{ "categories": [ { … } ], "totalCategories": 2, "totalSubcategories": 5, "message": "Successfully created 2 categories and 5 subcategories" }