diff --git a/gnippy/rules.py b/gnippy/rules.py
index 37877f8..be59fcc 100644
--- a/gnippy/rules.py
+++ b/gnippy/rules.py
@@ -31,7 +31,7 @@ def _check_rules_list(rules_list):
     if not isinstance(rules_list, list):
         fail()
 
-    expected = ("value", "tag")
+    expected = ("value", "tag", "id")
     for r in rules_list:
         if not isinstance(r, dict):
             fail()
@@ -77,6 +77,7 @@ def _post(conf, built_rules):
         error_text = "HTTP Response Code: %s, Text: '%s'" % (str(r.status_code), r.text)
         raise RuleAddFailedException(error_text)
 
+
 def _generate_delete_url(conf):
     """
         Generate the Rules URL for a DELETE request.
@@ -89,6 +90,7 @@ def _generate_delete_url(conf):
     else:
         return rules_url + "?_method=delete"
 
+
 def _delete(conf, built_rules):
     """
         Generate the Delete Rules URL and make a POST request.
@@ -112,6 +114,7 @@ def _delete(conf, built_rules):
         error_text = "HTTP Response Code: %s, Text: '%s'" % (str(r.status_code), r.text)
         raise RuleDeleteFailedException(error_text)
 
+
 def build(rule_string, tag=None):
     """
         Takes a rule string and optional tag and turns it into a "built_rule" that looks like:

New rule format breaks delete example
The examples in the README for deleting rules are broken due to the addition of the id field in the rules returned by GNIP.

    from gnippy import rules
    from gnippy.errors import RuleDeleteFailedException, RulesGetFailedException

    try:
        rules_list = rules.get_rules()
        # Suppose I want to delete the first rule in the list
        rules.delete_rule(rules_list[0])
        # OR ... I want to delete ALL rules
        rules.delete_rules(rules_list)

    except RuleDeleteFailedException, RulesGetFailedException:
        pass


At the moment a user needs to either manually remove the `id` field 

    del rule['id']
    rules.delete_rule(rule)

or rebuild the rule using `rules.build`

     rules.delete_rule(rules.build(rule['value'], rule.get('tag')))


diff --git a/gnippy/test/test_rules.py b/gnippy/test/test_rules.py
index cfa1ee4..cbb4202 100644
--- a/gnippy/test/test_rules.py
+++ b/gnippy/test/test_rules.py
@@ -42,7 +42,8 @@ def good_get_no_rules(url, auth):
 
 
 def good_get_one_rule(url, auth):
-    return test_utils.GoodResponse(json={"rules":[{"value": "Hello", "tag": "mytag"}]})
+    return test_utils.GoodResponse(
+        json={"rules": [{"value": "Hello", "tag": "mytag"}]})
 
 
 def bad_delete(url, auth, data):
@@ -54,7 +55,6 @@ def good_delete(url, auth, data):
 
 
 class RulesTestCase(unittest.TestCase):
-
     rule_string = "Hello OR World"
     tag = "my_tag"
 
@@ -79,45 +79,53 @@ class RulesTestCase(unittest.TestCase):
 
     def test_check_one_rule_ok(self):
         """ Check list of one rule. """
-        l = [ { "value": "hello" } ]
+        l = [{"value": "hello"}]
         rules._check_rules_list(l)
 
     def test_check_many_rules_ok(self):
         """ Check list of many rules. """
-        l = [ { "value": "hello" }, { "value": "h", "tag": "w" }]
+        l = [
+            {"value": "hello", "id": 3},
+            {"value": "goodbye", "tag": "w", "id": 4},
+            {"value": "hi again", "tag": "x"},
+            {"value": "bye again"}
+        ]
         rules._check_rules_list(l)
 
     def test_check_rule_tag_none(self):
         """ Check list of rules both with tag and without. """
-        l = [ { "value": "hello", "tag": None }, { "value": "h", "tag": "w" }]
+        l = [{"value": "hello", "tag": None}, {"value": "h", "tag": "w"}]
         rules._check_rules_list(l)
 
     def test_check_one_rule_typo_values(self):
         """ Make sure incorectly formatted rule values fail. """
-        l = [ { "values": "hello" } ]
+        l = [{"values": "hello"}]
         try:
             rules._check_rules_list(l)
         except RulesListFormatException:
             return
-        self.fail("_check_rules_list was supposed to throw a RuleFormatException")
+        self.fail(
+            "_check_rules_list was supposed to throw a RuleFormatException")
 
     def test_check_one_rule_typo_tag(self):
         """ Make sure incorrectly formatted rule tags fail. """
-        l = [ { "value": "hello", "tags": "t" } ]
+        l = [{"value": "hello", "tags": "t"}]
         try:
             rules._check_rules_list(l)
         except RulesListFormatException:
             return
-        self.fail("_check_rules_list was supposed to throw a RuleFormatException")
+        self.fail(
+            "_check_rules_list was supposed to throw a RuleFormatException")
 
     def test_check_one_rule_extra_stuff_in_rule(self):
         """ Make sure rules with unexpected keys fail. """
-        l = [ { "value": "hello", "wat": "man" } ]
+        l = [{"value": "hello", "wat": "man"}]
         try:
             rules._check_rules_list(l)
         except RulesListFormatException:
             return
-        self.fail("_check_rules_list was supposed to throw a RuleFormatException")
+        self.fail(
+            "_check_rules_list was supposed to throw a RuleFormatException")
 
     def test_build_rule_bad_args(self):
         """ Make sure building rules with unexpected args fail. """
@@ -125,7 +133,8 @@ class RulesTestCase(unittest.TestCase):
             rules.build(None)
         except BadArgumentException:
             return
-        self.fail("rules.build_rule was supposed to throw a BadArgumentException")
+        self.fail(
+            "rules.build_rule was supposed to throw a BadArgumentException")
 
     def test_build_rule_without_tag(self):
         """ Build rule without tag. """
@@ -149,18 +158,21 @@ class RulesTestCase(unittest.TestCase):
             rules.add_rule(self.rule_string, self.tag)
         except ConfigFileNotFoundException:
             return
-        self.fail("Rule Add was supposed to fail and throw a ConfigFileNotFoundException")
+        self.fail(
+            "Rule Add was supposed to fail and throw a ConfigFileNotFoundException")
 
     @mock.patch('requests.post', good_post)
     def test_add_one_rule_ok(self):
         """Add one rule with config. """
-        rules.add_rule(self.rule_string, self.tag, config_file_path=test_utils.test_config_path)
+        rules.add_rule(self.rule_string, self.tag,
+                       config_file_path=test_utils.test_config_path)
 
     @mock.patch('requests.post', bad_post)
     def test_add_one_rule_not_ok(self):
         """Add one rule with exception thrown. """
         try:
-            rules.add_rule(self.rule_string, self.tag, config_file_path=test_utils.test_config_path)
+            rules.add_rule(self.rule_string, self.tag,
+                           config_file_path=test_utils.test_config_path)
         except RuleAddFailedException:
             return
         self.fail("Rule Add was supposed to fail and throw a RuleAddException")
@@ -173,20 +185,23 @@ class RulesTestCase(unittest.TestCase):
             rules.add_rule(self.rule_string, self.tag)
         except ConfigFileNotFoundException:
             return
-        self.fail("Rule Add was supposed to fail and throw a ConfigFileNotFoundException")
+        self.fail(
+            "Rule Add was supposed to fail and throw a ConfigFileNotFoundException")
 
     @mock.patch('requests.post', good_post)
     def test_add_many_rules_ok(self):
         """ Add many rules. """
         rules_list = self._generate_rules_list()
-        rules.add_rules(rules_list, config_file_path=test_utils.test_config_path)
+        rules.add_rules(rules_list,
+                        config_file_path=test_utils.test_config_path)
 
     @mock.patch('requests.post', bad_post)
     def test_add_many_rules_not_ok(self):
         """ Add many rules with exception thrown. """
         try:
             rules_list = self._generate_rules_list()
-            rules.add_rules(rules_list, config_file_path=test_utils.test_config_path)
+            rules.add_rules(rules_list,
+                            config_file_path=test_utils.test_config_path)
         except RuleAddFailedException:
             return
         self.fail("Rule Add was supposed to fail and throw a RuleAddException")
@@ -226,7 +241,8 @@ class RulesTestCase(unittest.TestCase):
         try:
             r = rules.get_rules(config_file_path=test_utils.test_config_path)
         except RulesGetFailedException as e:
-            self.assertTrue("GNIP API response did not return a rules object" in str(e))
+            self.assertTrue(
+                "GNIP API response did not return a rules object" in str(e))
             return
         self.fail("rules.get() was supposed to throw a RulesGetFailedException")
 
@@ -245,13 +261,15 @@ class RulesTestCase(unittest.TestCase):
     @mock.patch('requests.post', good_delete)
     def test_delete_rules_single(self):
         """ Delete one rule. """
-        rules.delete_rule({"value": "Hello World"}, config_file_path=test_utils.test_config_path)
+        rules.delete_rule({"value": "Hello World"},
+                          config_file_path=test_utils.test_config_path)
 
     @mock.patch('requests.post', good_delete)
     def test_delete_rules_multiple(self):
         """ Delete multiple rules. """
         rules_list = [
-            { "value": "Hello World" },
-            { "value": "Hello", "tag": "mytag" }
+            {"value": "Hello World"},
+            {"value": "Hello", "tag": "mytag"}
         ]
-        rules.delete_rules(rules_list, config_file_path=test_utils.test_config_path)
\ No newline at end of file
+        rules.delete_rules(rules_list,
+                           config_file_path=test_utils.test_config_path)

pip install -e .
parse_log_pytest
requirements.txt
nose mock pytest
apt-get update apt-get install -y gcc
3.9
requirements-dev.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
cachetools==5.5.2
certifi==2025.1.31
chardet==5.2.0
charset-normalizer==3.4.1
colorama==0.4.6
distlib==0.3.9
exceptiongroup==1.2.2
filelock==3.18.0
-e git+https://github.com/abh1nav/gnippy.git@ce2968934c3d25aabda033a544e3abcc0e80775e#egg=gnippy
idna==3.10
iniconfig==2.1.0
mock==1.0.1
nose==1.3.0
packaging==24.2
platformdirs==4.3.7
pluggy==1.5.0
pyproject-api==1.9.0
pytest==8.3.5
requests==2.32.3
six==1.10.0
tomli==2.2.1
tox==4.25.0
typing_extensions==4.13.0
urllib3==2.3.0
virtualenv==20.29.3

name: gnippy
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=25.0=py39h06a4308_0
  - python=3.9.21=he870216_1
  - readline=8.2=h5eee18b_0
  - setuptools=75.8.0=py39h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - tzdata=2025a=h04d1e81_0
  - wheel=0.45.1=py39h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - cachetools==5.5.2
      - certifi==2025.1.31
      - chardet==5.2.0
      - charset-normalizer==3.4.1
      - colorama==0.4.6
      - distlib==0.3.9
      - exceptiongroup==1.2.2
      - filelock==3.18.0
      - idna==3.10
      - iniconfig==2.1.0
      - mock==1.0.1
      - nose==1.3.0
      - packaging==24.2
      - platformdirs==4.3.7
      - pluggy==1.5.0
      - pyproject-api==1.9.0
      - pytest==8.3.5
      - requests==2.32.3
      - six==1.10.0
      - tomli==2.2.1
      - tox==4.25.0
      - typing-extensions==4.13.0
      - urllib3==2.3.0
      - virtualenv==20.29.3
prefix: /opt/conda/envs/gnippy

gnippy/test/test_rules.py::RulesTestCase::test_check_many_rules_ok
gnippy/test/test_rules.py::RulesTestCase::test_add_many_rules_no_creds gnippy/test/test_rules.py::RulesTestCase::test_add_many_rules_not_ok gnippy/test/test_rules.py::RulesTestCase::test_add_many_rules_ok gnippy/test/test_rules.py::RulesTestCase::test_add_one_rule_no_creds gnippy/test/test_rules.py::RulesTestCase::test_add_one_rule_not_ok gnippy/test/test_rules.py::RulesTestCase::test_add_one_rule_ok gnippy/test/test_rules.py::RulesTestCase::test_build_post_object gnippy/test/test_rules.py::RulesTestCase::test_build_rule_bad_args gnippy/test/test_rules.py::RulesTestCase::test_build_rule_with_tag gnippy/test/test_rules.py::RulesTestCase::test_build_rule_without_tag gnippy/test/test_rules.py::RulesTestCase::test_check_one_rule_extra_stuff_in_rule gnippy/test/test_rules.py::RulesTestCase::test_check_one_rule_ok gnippy/test/test_rules.py::RulesTestCase::test_check_one_rule_typo_tag gnippy/test/test_rules.py::RulesTestCase::test_check_one_rule_typo_values gnippy/test/test_rules.py::RulesTestCase::test_check_rule_tag_none gnippy/test/test_rules.py::RulesTestCase::test_delete_rules_multiple gnippy/test/test_rules.py::RulesTestCase::test_delete_rules_single gnippy/test/test_rules.py::RulesTestCase::test_get_rules_bad_json gnippy/test/test_rules.py::RulesTestCase::test_get_rules_bad_status_code gnippy/test/test_rules.py::RulesTestCase::test_get_rules_no_rules_field_json gnippy/test/test_rules.py::RulesTestCase::test_get_rules_requests_get_exception gnippy/test/test_rules.py::RulesTestCase::test_get_rules_success_no_rules gnippy/test/test_rules.py::RulesTestCase::test_get_rules_success_one_rule
gnippy/rules.py
gnippy/rules.py