Actions21
- پیامک | Message Actions
- پیام صوتی | Voice Actions
- حساب کاربری | Account Actions
- گزارش و صندوق ورودی | Report & Inbox Actions
- پترن | Pattern Actions
- دفترتلفن | Phonebook Actions
دفترتلفن | Phonebook → افزودن گروهی مخاطب | Add Contacts in Bulk
AI-generatedSummary
Add or update up to 500 contacts in bulk within a specified phonebook using a single API request.
Inputs
- Phonebook ID (required) — The target phonebook's ID, obtained from the 'getPhonebooks' operation.
- Contacts (JSON) (required) — A JSON array of contacts (maximum 500). Each contact must include a 'mobile' field. Optional accepted fields are 'name', 'prefix' (one of man/woman/co/org), and 'attributes'. Any other fields are ignored.
Output shape
a single response object with a success boolean and API response data indicating the result of the bulk add or update operation
Validates the contact list as JSON and the array length does not exceed 500. Throws errors if invalid JSON, empty array, or over-limit contacts are provided. Returns success status and details from Farazsms API response.
Examples
Example 1: Add multiple contacts to a phonebook in one call
Provide the phonebook ID and supply a JSON array of contacts each with required 'mobile' and optionally 'name', 'prefix', and 'attributes'. The node returns the API response indicating successful insertion/updating.