apiverve-spfvalidator 1.1.14__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2024 APIVerve, and Evlar LLC
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,585 @@
1
+ Metadata-Version: 2.4
2
+ Name: apiverve-spfvalidator
3
+ Version: 1.1.14
4
+ Summary: SPF Validator checks the Sender Policy Framework (SPF) DNS record for a domain to verify if it’s valid and optionally whether a given IP address is authorized to send emails for that domain.
5
+ Author-email: APIVerve <hello@apiverve.com>
6
+ License: MIT
7
+ Project-URL: Homepage, https://apiverve.com?utm_source=pypi
8
+ Project-URL: Repository, https://github.com/apiverve/spfvalidator-api
9
+ Project-URL: Documentation, https://docs.apiverve.com/api/spfvalidator?utm_source=pypi
10
+ Project-URL: Twitter, https://twitter.com/apivervehq
11
+ Classifier: Development Status :: 5 - Production/Stable
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Intended Audience :: Developers
15
+ Classifier: Intended Audience :: Financial and Insurance Industry
16
+ Classifier: Intended Audience :: Healthcare Industry
17
+ Classifier: Intended Audience :: Education
18
+ Classifier: Intended Audience :: Science/Research
19
+ Classifier: Intended Audience :: Information Technology
20
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
21
+ Classifier: Topic :: Utilities
22
+ Classifier: Topic :: Scientific/Engineering
23
+ Classifier: Topic :: Education
24
+ Classifier: Topic :: Internet :: WWW/HTTP :: Indexing/Search
25
+ Classifier: Topic :: Internet :: WWW/HTTP :: Site Management
26
+ Classifier: Topic :: Internet :: WWW/HTTP
27
+ Classifier: Topic :: Software Development :: Libraries
28
+ Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
29
+ Classifier: Topic :: Internet
30
+ Classifier: Topic :: Communications
31
+ Classifier: Topic :: Office/Business
32
+ Classifier: Topic :: Text Processing
33
+ Classifier: Topic :: Security
34
+ Classifier: Topic :: Database
35
+ Classifier: Topic :: Software Development :: Code Generators
36
+ Classifier: Topic :: Software Development :: Pre-processors
37
+ Classifier: Topic :: Software Development :: Quality Assurance
38
+ Classifier: Topic :: Software Development :: Testing
39
+ Classifier: Natural Language :: English
40
+ Requires-Python: >=3.7
41
+ Description-Content-Type: text/markdown
42
+ License-File: LICENSE
43
+ Requires-Dist: requests>=2.25.0
44
+ Dynamic: license-file
45
+
46
+ SPF Validator API
47
+ ============
48
+
49
+ SPF Validator checks the Sender Policy Framework (SPF) DNS record for a domain to verify if it’s valid and optionally whether a given IP address is authorized to send emails for that domain.
50
+
51
+ ![Build Status](https://img.shields.io/badge/build-passing-green)
52
+ ![Code Climate](https://img.shields.io/badge/maintainability-B-purple)
53
+ ![Prod Ready](https://img.shields.io/badge/production-ready-blue)
54
+
55
+ This is a Python API Wrapper for the [SPF Validator API](https://spfvalidator.apiverve.com?utm_source=pypi&utm_medium=readme)
56
+
57
+ ---
58
+
59
+ ## Installation
60
+
61
+ Using `pip`:
62
+
63
+ ```bash
64
+ pip install apiverve-spfvalidator
65
+ ```
66
+
67
+ Using `pip3`:
68
+
69
+ ```bash
70
+ pip3 install apiverve-spfvalidator
71
+ ```
72
+
73
+ ---
74
+
75
+ ## Configuration
76
+
77
+ Before using the spfvalidator API client, you have to setup your account and obtain your API Key.
78
+ You can get it by signing up at [https://apiverve.com](https://apiverve.com?utm_source=pypi&utm_medium=readme)
79
+
80
+ ---
81
+
82
+ ## Quick Start
83
+
84
+ Here's a simple example to get you started quickly:
85
+
86
+ ```python
87
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient
88
+
89
+ # Initialize the client with your APIVerve API key
90
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]")
91
+
92
+ query = { "domain": "myspace.com" }
93
+
94
+ try:
95
+ # Make the API call
96
+ result = api.execute(query)
97
+
98
+ # Print the result
99
+ print(result)
100
+ except Exception as e:
101
+ print(f"Error: {e}")
102
+ ```
103
+
104
+ ---
105
+
106
+ ## Usage
107
+
108
+ The SPF Validator API documentation is found here: [https://docs.apiverve.com/ref/spfvalidator](https://docs.apiverve.com/ref/spfvalidator?utm_source=pypi&utm_medium=readme).
109
+ You can find parameters, example responses, and status codes documented here.
110
+
111
+ ### Setup
112
+
113
+ ```python
114
+ # Import the client module
115
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient
116
+
117
+ # Initialize the client with your APIVerve API key
118
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]")
119
+ ```
120
+
121
+ ---
122
+
123
+ ## Perform Request
124
+
125
+ Using the API client, you can perform requests to the API.
126
+
127
+ ###### Define Query
128
+
129
+ ```python
130
+ query = { "domain": "myspace.com" }
131
+ ```
132
+
133
+ ###### Simple Request
134
+
135
+ ```python
136
+ # Make a request to the API
137
+ result = api.execute(query)
138
+
139
+ # Print the result
140
+ print(result)
141
+ ```
142
+
143
+ ###### Example Response
144
+
145
+ ```json
146
+ {
147
+ "status": "ok",
148
+ "error": null,
149
+ "data": {
150
+ "authorized_ips": {
151
+ "ipv4": [
152
+ "63.208.226.34",
153
+ "204.16.32.0/22",
154
+ "67.134.143.0/24",
155
+ "216.205.243.0/24",
156
+ "34.85.156.5/32",
157
+ "35.245.108.108/32",
158
+ "34.86.129.193/32",
159
+ "34.86.134.94/32",
160
+ "34.85.222.234/32",
161
+ "34.86.176.234/32",
162
+ "34.86.125.212/32",
163
+ "34.85.224.60/32",
164
+ "34.86.160.49/32",
165
+ "35.245.64.166/32",
166
+ "35.188.226.11/32",
167
+ "34.86.208.228/32",
168
+ "34.85.216.144/32",
169
+ "35.221.22.153/32",
170
+ "34.86.137.108/32",
171
+ "34.86.51.35/32",
172
+ "34.150.221.40/32",
173
+ "34.85.216.70/32",
174
+ "34.86.37.191/32",
175
+ "34.85.214.215/32",
176
+ "35.236.234.82/32",
177
+ "34.86.161.241/32",
178
+ "216.32.181.16",
179
+ "216.178.32.0/20",
180
+ "168.235.224.0/24",
181
+ "195.130.217.0/24",
182
+ "91.220.42.0/24",
183
+ "146.101.78.0/24",
184
+ "207.82.80.0/24",
185
+ "213.167.81.0/25",
186
+ "193.7.207.0/25",
187
+ "213.167.75.0/25",
188
+ "185.58.85.0/24",
189
+ "185.58.86.0/24",
190
+ "193.7.206.0/25",
191
+ "147.28.36.0/24",
192
+ "207.211.31.0/25",
193
+ "205.139.110.0/24",
194
+ "216.205.24.0/24",
195
+ "170.10.129.0/24",
196
+ "63.128.21.0/24",
197
+ "170.10.133.0/24",
198
+ "185.58.84.93/32",
199
+ "207.211.41.113/32",
200
+ "207.211.30.64/26",
201
+ "207.211.30.128/25",
202
+ "216.145.221.0/24",
203
+ "170.10.128.0/24",
204
+ "170.10.132.56/29",
205
+ "170.10.132.64/29",
206
+ "41.74.192.0/22",
207
+ "41.74.200.0/23",
208
+ "41.74.196.0/22",
209
+ "41.74.204.0/23",
210
+ "41.74.206.0/24",
211
+ "51.163.158.0/24",
212
+ "194.104.109.0/24",
213
+ "194.104.111.0/24",
214
+ "194.104.110.21/32",
215
+ "194.104.110.240/28",
216
+ "62.140.10.21/32",
217
+ "62.140.7.0/24",
218
+ "194.104.108.240/29",
219
+ "194.104.108.21/32",
220
+ "103.13.69.0/24",
221
+ "124.47.150.0/24",
222
+ "124.47.189.0/24",
223
+ "103.96.23.0/24",
224
+ "103.96.21.0/24",
225
+ "180.189.28.0/24",
226
+ "216.145.217.0/24",
227
+ "103.96.22.96/28",
228
+ "103.96.22.22/32",
229
+ "103.96.20.22/32",
230
+ "103.96.20.96/28",
231
+ "170.10.145.0/24",
232
+ "170.10.147.0/24",
233
+ "170.10.144.126/32",
234
+ "170.10.146.126/32",
235
+ "170.10.144.240/29",
236
+ "170.10.146.240/29",
237
+ "216.145.216.0/24"
238
+ ]
239
+ },
240
+ "dns_lookups_num": 8,
241
+ "domains_extracted": [
242
+ "myspace.com",
243
+ "_netblocks.mimecast.com",
244
+ "eu._netblocks.mimecast.com",
245
+ "us._netblocks.mimecast.com",
246
+ "za._netblocks.mimecast.com",
247
+ "de._netblocks.mimecast.com",
248
+ "au._netblocks.mimecast.com",
249
+ "ca._netblocks.mimecast.com"
250
+ ],
251
+ "elapsed_ms": 1118,
252
+ "has_issues": false,
253
+ "has_spf_record": true,
254
+ "host": "myspace.com",
255
+ "ip_pass": false,
256
+ "macros_found": false,
257
+ "spf_record": "v=spf1 mx ip4:63.208.226.34 ip4:204.16.32.0/22 ip4:67.134.143.0/24 ip4:216.205.243.0/24 ip4:34.85.156.5/32 ip4:35.245.108.108/32 ip4:34.86.129.193/32 ip4:34.86.134.94/32 ip4:34.85.222.234/32 ip4:34.86.176.234/32 ip4:34.86.125.212/32 ip4:34.85.224.60/32 ip4:34.86.160.49/32 ip4:35.245.64.166/32 ip4:35.188.226.11/32 ip4:34.86.208.228/32 ip4:34.85.216.144/32 ip4:35.221.22.153/32 ip4:34.86.137.108/32 ip4:34.86.51.35/32 ip4:34.150.221.40/32 ip4:34.85.216.70/32 ip4:34.86.37.191/32 ip4:34.85.214.215/32 ip4:35.236.234.82/32 ip4:34.86.161.241/32 ip4:216.32.181.16 ip4:216.178.32.0/20 ip4:168.235.224.0/24 include:_netblocks.mimecast.com -all",
258
+ "spf_records_list": [
259
+ {
260
+ "authorized_ips": {
261
+ "ipv4": [
262
+ "63.208.226.34",
263
+ "204.16.32.0/22",
264
+ "67.134.143.0/24",
265
+ "216.205.243.0/24",
266
+ "34.85.156.5/32",
267
+ "35.245.108.108/32",
268
+ "34.86.129.193/32",
269
+ "34.86.134.94/32",
270
+ "34.85.222.234/32",
271
+ "34.86.176.234/32",
272
+ "34.86.125.212/32",
273
+ "34.85.224.60/32",
274
+ "34.86.160.49/32",
275
+ "35.245.64.166/32",
276
+ "35.188.226.11/32",
277
+ "34.86.208.228/32",
278
+ "34.85.216.144/32",
279
+ "35.221.22.153/32",
280
+ "34.86.137.108/32",
281
+ "34.86.51.35/32",
282
+ "34.150.221.40/32",
283
+ "34.85.216.70/32",
284
+ "34.86.37.191/32",
285
+ "34.85.214.215/32",
286
+ "35.236.234.82/32",
287
+ "34.86.161.241/32",
288
+ "216.32.181.16",
289
+ "216.178.32.0/20",
290
+ "168.235.224.0/24"
291
+ ]
292
+ },
293
+ "chars_num": 637,
294
+ "domains": [
295
+ "_netblocks.mimecast.com"
296
+ ],
297
+ "origin": "myspace.com",
298
+ "record": "v=spf1 mx ip4:63.208.226.34 ip4:204.16.32.0/22 ip4:67.134.143.0/24 ip4:216.205.243.0/24 ip4:34.85.156.5/32 ip4:35.245.108.108/32 ip4:34.86.129.193/32 ip4:34.86.134.94/32 ip4:34.85.222.234/32 ip4:34.86.176.234/32 ip4:34.86.125.212/32 ip4:34.85.224.60/32 ip4:34.86.160.49/32 ip4:35.245.64.166/32 ip4:35.188.226.11/32 ip4:34.86.208.228/32 ip4:34.85.216.144/32 ip4:35.221.22.153/32 ip4:34.86.137.108/32 ip4:34.86.51.35/32 ip4:34.150.221.40/32 ip4:34.85.216.70/32 ip4:34.86.37.191/32 ip4:34.85.214.215/32 ip4:35.236.234.82/32 ip4:34.86.161.241/32 ip4:216.32.181.16 ip4:216.178.32.0/20 ip4:168.235.224.0/24 include:_netblocks.mimecast.com -all",
299
+ "use_macro": false
300
+ },
301
+ {
302
+ "chars_num": 221,
303
+ "domains": [
304
+ "eu._netblocks.mimecast.com",
305
+ "us._netblocks.mimecast.com",
306
+ "za._netblocks.mimecast.com",
307
+ "de._netblocks.mimecast.com",
308
+ "au._netblocks.mimecast.com",
309
+ "ca._netblocks.mimecast.com"
310
+ ],
311
+ "origin": "_netblocks.mimecast.com",
312
+ "record": "v=spf1 include:eu._netblocks.mimecast.com include:us._netblocks.mimecast.com include:za._netblocks.mimecast.com include:de._netblocks.mimecast.com include:au._netblocks.mimecast.com include:ca._netblocks.mimecast.com ~all",
313
+ "use_macro": false
314
+ },
315
+ {
316
+ "authorized_ips": {
317
+ "ipv4": [
318
+ "195.130.217.0/24",
319
+ "91.220.42.0/24",
320
+ "146.101.78.0/24",
321
+ "207.82.80.0/24",
322
+ "213.167.81.0/25",
323
+ "193.7.207.0/25",
324
+ "213.167.75.0/25",
325
+ "185.58.85.0/24",
326
+ "185.58.86.0/24",
327
+ "193.7.206.0/25",
328
+ "147.28.36.0/24"
329
+ ]
330
+ },
331
+ "chars_num": 225,
332
+ "origin": "eu._netblocks.mimecast.com",
333
+ "record": "v=spf1 ip4:195.130.217.0/24 ip4:91.220.42.0/24 ip4:146.101.78.0/24 ip4:207.82.80.0/24 ip4:213.167.81.0/25 ip4:193.7.207.0/25 ip4:213.167.75.0/25 ip4:185.58.85.0/24 ip4:185.58.86.0/24 ip4:193.7.206.0/25 ip4:147.28.36.0/24 ~all",
334
+ "use_macro": false
335
+ },
336
+ {
337
+ "authorized_ips": {
338
+ "ipv4": [
339
+ "207.211.31.0/25",
340
+ "205.139.110.0/24",
341
+ "216.205.24.0/24",
342
+ "170.10.129.0/24",
343
+ "63.128.21.0/24",
344
+ "170.10.133.0/24",
345
+ "185.58.84.93/32",
346
+ "207.211.41.113/32",
347
+ "207.211.30.64/26",
348
+ "207.211.30.128/25",
349
+ "216.145.221.0/24",
350
+ "170.10.128.0/24",
351
+ "170.10.132.56/29",
352
+ "170.10.132.64/29"
353
+ ]
354
+ },
355
+ "chars_num": 299,
356
+ "origin": "us._netblocks.mimecast.com",
357
+ "record": "v=spf1 ip4:207.211.31.0/25 ip4:205.139.110.0/24 ip4:216.205.24.0/24 ip4:170.10.129.0/24 ip4:63.128.21.0/24 ip4:170.10.133.0/24 ip4:185.58.84.93/32 ip4:207.211.41.113/32 ip4:207.211.30.64/26 ip4:207.211.30.128/25 ip4:216.145.221.0/24 ip4:170.10.128.0/24 ip4:170.10.132.56/29 ip4:170.10.132.64/29 ~all",
358
+ "use_macro": false
359
+ },
360
+ {
361
+ "authorized_ips": {
362
+ "ipv4": [
363
+ "41.74.192.0/22",
364
+ "41.74.200.0/23",
365
+ "41.74.196.0/22",
366
+ "41.74.204.0/23",
367
+ "41.74.206.0/24"
368
+ ]
369
+ },
370
+ "chars_num": 106,
371
+ "origin": "za._netblocks.mimecast.com",
372
+ "record": "v=spf1 ip4:41.74.192.0/22 ip4:41.74.200.0/23 ip4:41.74.196.0/22 ip4:41.74.204.0/23 ip4:41.74.206.0/24 ~all",
373
+ "use_macro": false
374
+ },
375
+ {
376
+ "authorized_ips": {
377
+ "ipv4": [
378
+ "51.163.158.0/24",
379
+ "194.104.109.0/24",
380
+ "194.104.111.0/24",
381
+ "194.104.110.21/32",
382
+ "194.104.110.240/28",
383
+ "62.140.10.21/32",
384
+ "62.140.7.0/24",
385
+ "194.104.108.240/29",
386
+ "194.104.108.21/32"
387
+ ]
388
+ },
389
+ "chars_num": 201,
390
+ "origin": "de._netblocks.mimecast.com",
391
+ "record": "v=spf1 ip4:51.163.158.0/24 ip4:194.104.109.0/24 ip4:194.104.111.0/24 ip4:194.104.110.21/32 ip4:194.104.110.240/28 ip4:62.140.10.21/32 ip4:62.140.7.0/24 ip4:194.104.108.240/29 ip4:194.104.108.21/32 ~all",
392
+ "use_macro": false
393
+ },
394
+ {
395
+ "authorized_ips": {
396
+ "ipv4": [
397
+ "103.13.69.0/24",
398
+ "124.47.150.0/24",
399
+ "124.47.189.0/24",
400
+ "103.96.23.0/24",
401
+ "103.96.21.0/24",
402
+ "180.189.28.0/24",
403
+ "216.145.217.0/24",
404
+ "103.96.22.96/28",
405
+ "103.96.22.22/32",
406
+ "103.96.20.22/32",
407
+ "103.96.20.96/28"
408
+ ]
409
+ },
410
+ "chars_num": 229,
411
+ "origin": "au._netblocks.mimecast.com",
412
+ "record": "v=spf1 ip4:103.13.69.0/24 ip4:124.47.150.0/24 ip4:124.47.189.0/24 ip4:103.96.23.0/24 ip4:103.96.21.0/24 ip4:180.189.28.0/24 ip4:216.145.217.0/24 ip4:103.96.22.96/28 ip4:103.96.22.22/32 ip4:103.96.20.22/32 ip4:103.96.20.96/28 ~all",
413
+ "use_macro": false
414
+ },
415
+ {
416
+ "authorized_ips": {
417
+ "ipv4": [
418
+ "170.10.145.0/24",
419
+ "170.10.147.0/24",
420
+ "170.10.144.126/32",
421
+ "170.10.146.126/32",
422
+ "170.10.144.240/29",
423
+ "170.10.146.240/29",
424
+ "216.145.216.0/24"
425
+ ]
426
+ },
427
+ "chars_num": 160,
428
+ "origin": "ca._netblocks.mimecast.com",
429
+ "record": "v=spf1 ip4:170.10.145.0/24 ip4:170.10.147.0/24 ip4:170.10.144.126/32 ip4:170.10.146.126/32 ip4:170.10.144.240/29 ip4:170.10.146.240/29 ip4:216.145.216.0/24 ~all",
430
+ "use_macro": false
431
+ }
432
+ ],
433
+ "spf_valid": true
434
+ }
435
+ }
436
+ ```
437
+
438
+ ---
439
+
440
+ ## Error Handling
441
+
442
+ The API client provides comprehensive error handling through the `SpfvalidatorAPIClientError` exception. Here are some examples:
443
+
444
+ ### Basic Error Handling
445
+
446
+ ```python
447
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient, SpfvalidatorAPIClientError
448
+
449
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]")
450
+
451
+ query = { "domain": "myspace.com" }
452
+
453
+ try:
454
+ result = api.execute(query)
455
+ print("Success!")
456
+ print(result)
457
+ except SpfvalidatorAPIClientError as e:
458
+ print(f"API Error: {e.message}")
459
+ if e.status_code:
460
+ print(f"Status Code: {e.status_code}")
461
+ if e.response:
462
+ print(f"Response: {e.response}")
463
+ ```
464
+
465
+ ### Handling Specific Error Types
466
+
467
+ ```python
468
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient, SpfvalidatorAPIClientError
469
+
470
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]")
471
+
472
+ query = { "domain": "myspace.com" }
473
+
474
+ try:
475
+ result = api.execute(query)
476
+
477
+ # Check for successful response
478
+ if result.get('status') == 'success':
479
+ print("Request successful!")
480
+ print(result.get('data'))
481
+ else:
482
+ print(f"API returned an error: {result.get('error')}")
483
+
484
+ except SpfvalidatorAPIClientError as e:
485
+ # Handle API client errors
486
+ if e.status_code == 401:
487
+ print("Unauthorized: Invalid API key")
488
+ elif e.status_code == 429:
489
+ print("Rate limit exceeded")
490
+ elif e.status_code >= 500:
491
+ print("Server error - please try again later")
492
+ else:
493
+ print(f"API error: {e.message}")
494
+ except Exception as e:
495
+ # Handle unexpected errors
496
+ print(f"Unexpected error: {str(e)}")
497
+ ```
498
+
499
+ ### Using Context Manager (Recommended)
500
+
501
+ The client supports the context manager protocol for automatic resource cleanup:
502
+
503
+ ```python
504
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient, SpfvalidatorAPIClientError
505
+
506
+ query = { "domain": "myspace.com" }
507
+
508
+ # Using context manager ensures proper cleanup
509
+ with SpfvalidatorAPIClient("[YOUR_API_KEY]") as api:
510
+ try:
511
+ result = api.execute(query)
512
+ print(result)
513
+ except SpfvalidatorAPIClientError as e:
514
+ print(f"Error: {e.message}")
515
+ # Session is automatically closed here
516
+ ```
517
+
518
+ ---
519
+
520
+ ## Advanced Features
521
+
522
+ ### Debug Mode
523
+
524
+ Enable debug logging to see detailed request and response information:
525
+
526
+ ```python
527
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient
528
+
529
+ # Enable debug mode
530
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]", debug=True)
531
+
532
+ query = { "domain": "myspace.com" }
533
+
534
+ # Debug information will be printed to console
535
+ result = api.execute(query)
536
+ ```
537
+
538
+ ### Manual Session Management
539
+
540
+ If you need to manually manage the session lifecycle:
541
+
542
+ ```python
543
+ from apiverve_spfvalidator.apiClient import SpfvalidatorAPIClient
544
+
545
+ api = SpfvalidatorAPIClient("[YOUR_API_KEY]")
546
+
547
+ query = { "domain": "myspace.com" }
548
+
549
+ try:
550
+ result = api.execute(query)
551
+ print(result)
552
+ finally:
553
+ # Manually close the session when done
554
+ api.close()
555
+ ```
556
+
557
+ ---
558
+
559
+ ## Customer Support
560
+
561
+ Need any assistance? [Get in touch with Customer Support](https://apiverve.com/contact?utm_source=pypi&utm_medium=readme).
562
+
563
+ ---
564
+
565
+ ## Updates
566
+ Stay up to date by following [@apiverveHQ](https://twitter.com/apiverveHQ) on Twitter.
567
+
568
+ ---
569
+
570
+ ## Legal
571
+
572
+ All usage of the APIVerve website, API, and services is subject to the [APIVerve Terms of Service](https://apiverve.com/terms?utm_source=pypi&utm_medium=readme) and all legal documents and agreements.
573
+
574
+ ---
575
+
576
+ ## License
577
+ Licensed under the The MIT License (MIT)
578
+
579
+ Copyright (&copy;) 2026 APIVerve, and EvlarSoft LLC
580
+
581
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
582
+
583
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
584
+
585
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.