<commit_before># createsend-ruby history

## v4.0.0 - 6 Feb, 2014

* Updated to v3.1 API

## v3.4.0 - 5 Jul, 2013<commit_msg>Add more detail to 4.0.0 release notes<commit_after># createsend-ruby history

## v4.0.0 - 6 Feb, 2014

* Updated to v3.1 API
* Added support for new segments structure
  * Create and Update calls now require the new `rule_groups` structure, instead of a `rules` structure.

    ```ruby
    CreateSend::Segment.create(auth, list_id, title, rule_groups)
    CreateSend::Segment.update(title, rule_groups)
    ```

    So for example, when you _previously_ would have created an argument like so:

    ```ruby
    rules = [ { :Subject => "EmailAddress", :Clauses => [ "CONTAINS example.com" ] } ]
    ```

    You would _now_ do this:

    ```ruby
    rule_groups = [ { :Rules => [ { :RuleType => "EmailAddress", :Clause => "CONTAINS example.com" } ] } ]
    ```
    
  * The Add Rule call is now Add Rule Group, taking a collection of rules in a single `rule_group` argument instead of separate `subject` & `clauses` arguments.

    ```ruby
    CreateSend::Segment.add_rule_group(rule_group)
    ```

    So for example, when you _previously_ would have added a rule like so:

    ```ruby
    @segment.add_rule "EmailAddress", [ "CONTAINS example.com" ]
    ```

    You would _now_ do this:

    ```ruby
    @segment.add_rule_group [ { :RuleType => "EmailAddress", :Clause => "CONTAINS @hello.com" } ]
    ```

## v3.4.0 - 5 Jul, 2013
{'fraction_non_alphanumeric': 0.13091158327621658, 'fraction_numerical': 0.026730637422892393, 'mean_word_length': 3.1954022988505746, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 10, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '698972', 'n_tokens_mistral': 507, 'n_tokens_neox': 468, 'n_words': 153}