# Post target book segment `POST` `/api/v1/crm-connections/{crm_connection_id}/target-books/{target_book_id}/segments` Returns the full updated target book. ## Path parameters | Name | Type | Required | Description | |------|------|----------|-------------| | crm_connection_id | string | yes | UUID of the CRM connection | | target_book_id | string | yes | Salesforce ID of the target book | ## Request body `application/json` | Field | Type | Required | Description | |-------|------|----------|-------------| | maximum_capacity | integer | no | — | | name | string | yes | — | | conditions_operator | string | yes | — | | custom_condition_logic | string | no | — | | conditions | array[object] | yes | — | | conditions.id | string | no | Salesforce ID; present = update existing, absent = create new | | conditions.field | string | yes | Salesforce field API name | | conditions.operator | string | yes | Comparison operator | | conditions.value | string | yes | Value to compare against | | is_locked | boolean | no | — | ## Response `200 OK` — `application/json` | Field | Type | Description | |-------|------|-------------| | id | string | Salesforce ID of the target book record | | name | string | Target book name | | status | string | Status: Active or Deleted | | maximum_capacity | number | Maximum account capacity | | ownership_field | string | Salesforce ownership field API name | | created_at | string | ISO-8601 creation timestamp | | updated_at | string | ISO-8601 last-updated timestamp | | activity_threshold | object | Assigned activity threshold (if any) | | activity_threshold.id | string | Salesforce ID of the threshold definition | | activity_threshold.name | string | Name of the activity threshold | | segments | array[object] | Segments with their conditions (present when include_segments=true) | | reps | array[object] | Active assigned reps (present when include_reps=true) | ## Errors | Status | Description | |--------|-------------| | 400 | Bad Request | | 403 | Forbidden | | 404 | Not Found | | 422 | Unprocessable Entity | | 502 | Bad Gateway |