name and period_value must be supplied. Every other field has a default — see the field descriptions.Accept: application/jsonAccept: application/json.idid updates that package instead of creating one, and still replies with an "Added Successfully" message. Use the Edit Package endpoint when you mean to update.branch_id is stored as null when you leave it out — the column default is not applied. Because Get All Packages only returns packages of the current branch, a package created without branch_id will not appear in that list. Send branch_id explicitly unless you intend the package to belong to no branch. The same holds for product_id, which is stored as null when omitted.created, modified and deleted_at are managed for you and should be omitted.curl --location --globoff 'https://.daftara.com/api2/package' \
--header 'Accept: application/json' \
--header 'apikey: ' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"name": "Gold Membership",
"type": "membership",
"price": 250,
"period_value": 1,
"period_unit": "monthly",
"status": 1,
"description": "Unlimited access",
"branch_id": 1
}'{
"message": "Package Added Successfully",
"id": 7
}