opportify-sdk 0.1.3__py3-none-any.whl → 0.2.0__py3-none-any.whl

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.

Potentially problematic release.


This version of opportify-sdk might be problematic. Click here for more details.

Files changed (69) hide show
  1. openapi_client/__init__.py +19 -1
  2. openapi_client/api/email_insights_api.py +564 -1
  3. openapi_client/api/ip_insights_api.py +564 -1
  4. openapi_client/api_client.py +2 -2
  5. openapi_client/configuration.py +1 -1
  6. openapi_client/exceptions.py +18 -1
  7. openapi_client/models/__init__.py +19 -1
  8. openapi_client/models/abuse_contact.py +1 -1
  9. openapi_client/models/admin_contact.py +1 -1
  10. openapi_client/models/analyze_email200_response.py +1 -1
  11. openapi_client/models/analyze_email400_response.py +1 -1
  12. openapi_client/models/analyze_email400_response_error.py +1 -1
  13. openapi_client/models/analyze_email403_response.py +1 -1
  14. openapi_client/models/analyze_email403_response_error.py +1 -1
  15. openapi_client/models/analyze_email500_response.py +1 -1
  16. openapi_client/models/analyze_email500_response_error.py +1 -1
  17. openapi_client/models/analyze_email_request.py +1 -1
  18. openapi_client/models/analyze_ip200_response.py +1 -1
  19. openapi_client/models/analyze_ip400_response.py +1 -1
  20. openapi_client/models/analyze_ip400_response_error.py +1 -1
  21. openapi_client/models/analyze_ip404_response.py +1 -1
  22. openapi_client/models/analyze_ip500_response.py +1 -1
  23. openapi_client/models/analyze_ip_request.py +1 -1
  24. openapi_client/models/asn.py +1 -1
  25. openapi_client/models/batch_analyze_emails202_response.py +101 -0
  26. openapi_client/models/batch_analyze_emails400_response.py +91 -0
  27. openapi_client/models/batch_analyze_emails400_response_error.py +137 -0
  28. openapi_client/models/batch_analyze_emails403_response.py +91 -0
  29. openapi_client/models/batch_analyze_emails403_response_error.py +89 -0
  30. openapi_client/models/batch_analyze_emails413_response.py +91 -0
  31. openapi_client/models/batch_analyze_emails413_response_error.py +89 -0
  32. openapi_client/models/batch_analyze_emails_request.py +91 -0
  33. openapi_client/models/batch_analyze_ips400_response.py +91 -0
  34. openapi_client/models/batch_analyze_ips400_response_error.py +137 -0
  35. openapi_client/models/batch_analyze_ips_request.py +89 -0
  36. openapi_client/models/block_listed.py +1 -1
  37. openapi_client/models/email_dns.py +1 -1
  38. openapi_client/models/geo.py +1 -1
  39. openapi_client/models/get_email_batch_status200_response.py +109 -0
  40. openapi_client/models/get_email_batch_status200_response_download_urls.py +93 -0
  41. openapi_client/models/get_email_batch_status404_response.py +91 -0
  42. openapi_client/models/get_email_batch_status404_response_error.py +89 -0
  43. openapi_client/models/internalerror.py +1 -1
  44. openapi_client/models/invaliddata.py +89 -0
  45. openapi_client/models/invaliddata1.py +89 -0
  46. openapi_client/models/invalidemail.py +1 -1
  47. openapi_client/models/invalidplan.py +1 -1
  48. openapi_client/models/invalidtoken.py +1 -1
  49. openapi_client/models/ipvalidationfailed.py +1 -1
  50. openapi_client/models/malformedrequest.py +1 -1
  51. openapi_client/models/malformedrequest1.py +1 -1
  52. openapi_client/models/malformedrequest2.py +89 -0
  53. openapi_client/models/notfound.py +1 -1
  54. openapi_client/models/organization.py +1 -1
  55. openapi_client/models/risk_report_email.py +1 -1
  56. openapi_client/models/risk_report_ip.py +1 -1
  57. openapi_client/models/tech_contact.py +1 -1
  58. openapi_client/models/trusted_provider.py +1 -1
  59. openapi_client/models/whois.py +1 -1
  60. openapi_client/rest.py +1 -1
  61. opportify_sdk/email_insights.py +79 -0
  62. opportify_sdk/ip_insights.py +74 -0
  63. opportify_sdk-0.2.0.dist-info/METADATA +239 -0
  64. opportify_sdk-0.2.0.dist-info/RECORD +70 -0
  65. {opportify_sdk-0.1.3.dist-info → opportify_sdk-0.2.0.dist-info}/WHEEL +1 -1
  66. openapi_client/models/risk_report.py +0 -89
  67. opportify_sdk-0.1.3.dist-info/METADATA +0 -115
  68. opportify_sdk-0.1.3.dist-info/RECORD +0 -53
  69. {opportify_sdk-0.1.3.dist-info → opportify_sdk-0.2.0.dist-info}/top_level.txt +0 -0
@@ -3,7 +3,7 @@
3
3
  """
4
4
  Opportify Insights API
5
5
 
6
- ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, corporate or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api-reference/email-insights) - [**IP Insights:**](/docs/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
6
+ ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, private or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api/api-reference/email-insights) - [**IP Insights:**](/docs/api/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
7
7
 
8
8
  The version of the OpenAPI document: 1.0.0
9
9
  Generated by OpenAPI Generator (https://openapi-generator.tech)
@@ -16,8 +16,13 @@ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
16
  from typing import Any, Dict, List, Optional, Tuple, Union
17
17
  from typing_extensions import Annotated
18
18
 
19
+ from pydantic import Field, StrictStr
20
+ from typing_extensions import Annotated
19
21
  from openapi_client.models.analyze_ip200_response import AnalyzeIp200Response
20
22
  from openapi_client.models.analyze_ip_request import AnalyzeIpRequest
23
+ from openapi_client.models.batch_analyze_emails202_response import BatchAnalyzeEmails202Response
24
+ from openapi_client.models.batch_analyze_ips_request import BatchAnalyzeIpsRequest
25
+ from openapi_client.models.get_email_batch_status200_response import GetEmailBatchStatus200Response
21
26
 
22
27
  from openapi_client.api_client import ApiClient, RequestSerialized
23
28
  from openapi_client.api_response import ApiResponse
@@ -321,3 +326,561 @@ class IPInsightsApi:
321
326
  )
322
327
 
323
328
 
329
+
330
+
331
+ @validate_call
332
+ def batch_analyze_ips(
333
+ self,
334
+ batch_analyze_ips_request: BatchAnalyzeIpsRequest,
335
+ _request_timeout: Union[
336
+ None,
337
+ Annotated[StrictFloat, Field(gt=0)],
338
+ Tuple[
339
+ Annotated[StrictFloat, Field(gt=0)],
340
+ Annotated[StrictFloat, Field(gt=0)]
341
+ ]
342
+ ] = None,
343
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
344
+ _content_type: Optional[StrictStr] = None,
345
+ _headers: Optional[Dict[StrictStr, Any]] = None,
346
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
347
+ ) -> BatchAnalyzeEmails202Response:
348
+ """Batch Analyze IPs
349
+
350
+ The **Batch Analyze IPs** endpoint enables processing of large volumes of IP addresses asynchronously. This endpoint accepts various input formats and returns a job ID for tracking the analysis progress. ### Features: - **Asynchronous Processing**: Submit large lists of IP addresses for background processing. - **Multiple Input Formats**: Submit data as JSON arrays, CSV files, or line-separated text. - **Job Tracking**: Monitor processing status using the returned job ID. ### Input Formats: - **JSON Array**: Submit a JSON object containing an array of IP addresses. - **CSV Upload**: Upload a CSV file with IP addresses in a single column (with header row). - **Line-Separated Text**: Submit a plain text file with one IP address per line. ### Example JSON Request: ```json { \"ips\": [ \"192.168.0.1\", \"10.0.0.1\", \"172.16.0.1\" ] } ``` ### Authentication & Security - **API Key:** Access requires an API key in the request headers. - **ACL Rules:** Optional IP-based access restrictions for enhanced security. - **No Query Parameters:** All data is transmitted securely through headers or request body. ### Payload Limits - Maximum payload size: 3MB
351
+
352
+ :param batch_analyze_ips_request: (required)
353
+ :type batch_analyze_ips_request: BatchAnalyzeIpsRequest
354
+ :param _request_timeout: timeout setting for this request. If one
355
+ number provided, it will be total request
356
+ timeout. It can also be a pair (tuple) of
357
+ (connection, read) timeouts.
358
+ :type _request_timeout: int, tuple(int, int), optional
359
+ :param _request_auth: set to override the auth_settings for an a single
360
+ request; this effectively ignores the
361
+ authentication in the spec for a single request.
362
+ :type _request_auth: dict, optional
363
+ :param _content_type: force content-type for the request.
364
+ :type _content_type: str, Optional
365
+ :param _headers: set to override the headers for a single
366
+ request; this effectively ignores the headers
367
+ in the spec for a single request.
368
+ :type _headers: dict, optional
369
+ :param _host_index: set to override the host_index for a single
370
+ request; this effectively ignores the host_index
371
+ in the spec for a single request.
372
+ :type _host_index: int, optional
373
+ :return: Returns the result object.
374
+ """ # noqa: E501
375
+
376
+ _param = self._batch_analyze_ips_serialize(
377
+ batch_analyze_ips_request=batch_analyze_ips_request,
378
+ _request_auth=_request_auth,
379
+ _content_type=_content_type,
380
+ _headers=_headers,
381
+ _host_index=_host_index
382
+ )
383
+
384
+ _response_types_map: Dict[str, Optional[str]] = {
385
+ '202': "BatchAnalyzeEmails202Response",
386
+ '400': "BatchAnalyzeIps400Response",
387
+ '413': "BatchAnalyzeEmails413Response",
388
+ '403': "BatchAnalyzeEmails403Response",
389
+ '500': "AnalyzeEmail500Response",
390
+ }
391
+ response_data = self.api_client.call_api(
392
+ *_param,
393
+ _request_timeout=_request_timeout
394
+ )
395
+ response_data.read()
396
+ return self.api_client.response_deserialize(
397
+ response_data=response_data,
398
+ response_types_map=_response_types_map,
399
+ ).data
400
+
401
+
402
+ @validate_call
403
+ def batch_analyze_ips_with_http_info(
404
+ self,
405
+ batch_analyze_ips_request: BatchAnalyzeIpsRequest,
406
+ _request_timeout: Union[
407
+ None,
408
+ Annotated[StrictFloat, Field(gt=0)],
409
+ Tuple[
410
+ Annotated[StrictFloat, Field(gt=0)],
411
+ Annotated[StrictFloat, Field(gt=0)]
412
+ ]
413
+ ] = None,
414
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
415
+ _content_type: Optional[StrictStr] = None,
416
+ _headers: Optional[Dict[StrictStr, Any]] = None,
417
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
418
+ ) -> ApiResponse[BatchAnalyzeEmails202Response]:
419
+ """Batch Analyze IPs
420
+
421
+ The **Batch Analyze IPs** endpoint enables processing of large volumes of IP addresses asynchronously. This endpoint accepts various input formats and returns a job ID for tracking the analysis progress. ### Features: - **Asynchronous Processing**: Submit large lists of IP addresses for background processing. - **Multiple Input Formats**: Submit data as JSON arrays, CSV files, or line-separated text. - **Job Tracking**: Monitor processing status using the returned job ID. ### Input Formats: - **JSON Array**: Submit a JSON object containing an array of IP addresses. - **CSV Upload**: Upload a CSV file with IP addresses in a single column (with header row). - **Line-Separated Text**: Submit a plain text file with one IP address per line. ### Example JSON Request: ```json { \"ips\": [ \"192.168.0.1\", \"10.0.0.1\", \"172.16.0.1\" ] } ``` ### Authentication & Security - **API Key:** Access requires an API key in the request headers. - **ACL Rules:** Optional IP-based access restrictions for enhanced security. - **No Query Parameters:** All data is transmitted securely through headers or request body. ### Payload Limits - Maximum payload size: 3MB
422
+
423
+ :param batch_analyze_ips_request: (required)
424
+ :type batch_analyze_ips_request: BatchAnalyzeIpsRequest
425
+ :param _request_timeout: timeout setting for this request. If one
426
+ number provided, it will be total request
427
+ timeout. It can also be a pair (tuple) of
428
+ (connection, read) timeouts.
429
+ :type _request_timeout: int, tuple(int, int), optional
430
+ :param _request_auth: set to override the auth_settings for an a single
431
+ request; this effectively ignores the
432
+ authentication in the spec for a single request.
433
+ :type _request_auth: dict, optional
434
+ :param _content_type: force content-type for the request.
435
+ :type _content_type: str, Optional
436
+ :param _headers: set to override the headers for a single
437
+ request; this effectively ignores the headers
438
+ in the spec for a single request.
439
+ :type _headers: dict, optional
440
+ :param _host_index: set to override the host_index for a single
441
+ request; this effectively ignores the host_index
442
+ in the spec for a single request.
443
+ :type _host_index: int, optional
444
+ :return: Returns the result object.
445
+ """ # noqa: E501
446
+
447
+ _param = self._batch_analyze_ips_serialize(
448
+ batch_analyze_ips_request=batch_analyze_ips_request,
449
+ _request_auth=_request_auth,
450
+ _content_type=_content_type,
451
+ _headers=_headers,
452
+ _host_index=_host_index
453
+ )
454
+
455
+ _response_types_map: Dict[str, Optional[str]] = {
456
+ '202': "BatchAnalyzeEmails202Response",
457
+ '400': "BatchAnalyzeIps400Response",
458
+ '413': "BatchAnalyzeEmails413Response",
459
+ '403': "BatchAnalyzeEmails403Response",
460
+ '500': "AnalyzeEmail500Response",
461
+ }
462
+ response_data = self.api_client.call_api(
463
+ *_param,
464
+ _request_timeout=_request_timeout
465
+ )
466
+ response_data.read()
467
+ return self.api_client.response_deserialize(
468
+ response_data=response_data,
469
+ response_types_map=_response_types_map,
470
+ )
471
+
472
+
473
+ @validate_call
474
+ def batch_analyze_ips_without_preload_content(
475
+ self,
476
+ batch_analyze_ips_request: BatchAnalyzeIpsRequest,
477
+ _request_timeout: Union[
478
+ None,
479
+ Annotated[StrictFloat, Field(gt=0)],
480
+ Tuple[
481
+ Annotated[StrictFloat, Field(gt=0)],
482
+ Annotated[StrictFloat, Field(gt=0)]
483
+ ]
484
+ ] = None,
485
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
486
+ _content_type: Optional[StrictStr] = None,
487
+ _headers: Optional[Dict[StrictStr, Any]] = None,
488
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
489
+ ) -> RESTResponseType:
490
+ """Batch Analyze IPs
491
+
492
+ The **Batch Analyze IPs** endpoint enables processing of large volumes of IP addresses asynchronously. This endpoint accepts various input formats and returns a job ID for tracking the analysis progress. ### Features: - **Asynchronous Processing**: Submit large lists of IP addresses for background processing. - **Multiple Input Formats**: Submit data as JSON arrays, CSV files, or line-separated text. - **Job Tracking**: Monitor processing status using the returned job ID. ### Input Formats: - **JSON Array**: Submit a JSON object containing an array of IP addresses. - **CSV Upload**: Upload a CSV file with IP addresses in a single column (with header row). - **Line-Separated Text**: Submit a plain text file with one IP address per line. ### Example JSON Request: ```json { \"ips\": [ \"192.168.0.1\", \"10.0.0.1\", \"172.16.0.1\" ] } ``` ### Authentication & Security - **API Key:** Access requires an API key in the request headers. - **ACL Rules:** Optional IP-based access restrictions for enhanced security. - **No Query Parameters:** All data is transmitted securely through headers or request body. ### Payload Limits - Maximum payload size: 3MB
493
+
494
+ :param batch_analyze_ips_request: (required)
495
+ :type batch_analyze_ips_request: BatchAnalyzeIpsRequest
496
+ :param _request_timeout: timeout setting for this request. If one
497
+ number provided, it will be total request
498
+ timeout. It can also be a pair (tuple) of
499
+ (connection, read) timeouts.
500
+ :type _request_timeout: int, tuple(int, int), optional
501
+ :param _request_auth: set to override the auth_settings for an a single
502
+ request; this effectively ignores the
503
+ authentication in the spec for a single request.
504
+ :type _request_auth: dict, optional
505
+ :param _content_type: force content-type for the request.
506
+ :type _content_type: str, Optional
507
+ :param _headers: set to override the headers for a single
508
+ request; this effectively ignores the headers
509
+ in the spec for a single request.
510
+ :type _headers: dict, optional
511
+ :param _host_index: set to override the host_index for a single
512
+ request; this effectively ignores the host_index
513
+ in the spec for a single request.
514
+ :type _host_index: int, optional
515
+ :return: Returns the result object.
516
+ """ # noqa: E501
517
+
518
+ _param = self._batch_analyze_ips_serialize(
519
+ batch_analyze_ips_request=batch_analyze_ips_request,
520
+ _request_auth=_request_auth,
521
+ _content_type=_content_type,
522
+ _headers=_headers,
523
+ _host_index=_host_index
524
+ )
525
+
526
+ _response_types_map: Dict[str, Optional[str]] = {
527
+ '202': "BatchAnalyzeEmails202Response",
528
+ '400': "BatchAnalyzeIps400Response",
529
+ '413': "BatchAnalyzeEmails413Response",
530
+ '403': "BatchAnalyzeEmails403Response",
531
+ '500': "AnalyzeEmail500Response",
532
+ }
533
+ response_data = self.api_client.call_api(
534
+ *_param,
535
+ _request_timeout=_request_timeout
536
+ )
537
+ return response_data.response
538
+
539
+
540
+ def _batch_analyze_ips_serialize(
541
+ self,
542
+ batch_analyze_ips_request,
543
+ _request_auth,
544
+ _content_type,
545
+ _headers,
546
+ _host_index,
547
+ ) -> RequestSerialized:
548
+
549
+ _host = None
550
+
551
+ _collection_formats: Dict[str, str] = {
552
+ }
553
+
554
+ _path_params: Dict[str, str] = {}
555
+ _query_params: List[Tuple[str, str]] = []
556
+ _header_params: Dict[str, Optional[str]] = _headers or {}
557
+ _form_params: List[Tuple[str, str]] = []
558
+ _files: Dict[
559
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
560
+ ] = {}
561
+ _body_params: Optional[bytes] = None
562
+
563
+ # process the path parameters
564
+ # process the query parameters
565
+ # process the header parameters
566
+ # process the form parameters
567
+ # process the body parameter
568
+ if batch_analyze_ips_request is not None:
569
+ _body_params = batch_analyze_ips_request
570
+
571
+
572
+ # set the HTTP header `Accept`
573
+ if 'Accept' not in _header_params:
574
+ _header_params['Accept'] = self.api_client.select_header_accept(
575
+ [
576
+ 'application/json'
577
+ ]
578
+ )
579
+
580
+ # set the HTTP header `Content-Type`
581
+ if _content_type:
582
+ _header_params['Content-Type'] = _content_type
583
+ else:
584
+ _default_content_type = (
585
+ self.api_client.select_header_content_type(
586
+ [
587
+ 'application/json',
588
+ 'multipart/form-data',
589
+ 'text/plain'
590
+ ]
591
+ )
592
+ )
593
+ if _default_content_type is not None:
594
+ _header_params['Content-Type'] = _default_content_type
595
+
596
+ # authentication setting
597
+ _auth_settings: List[str] = [
598
+ 'opportifyToken'
599
+ ]
600
+
601
+ return self.api_client.param_serialize(
602
+ method='POST',
603
+ resource_path='/ip/batch',
604
+ path_params=_path_params,
605
+ query_params=_query_params,
606
+ header_params=_header_params,
607
+ body=_body_params,
608
+ post_params=_form_params,
609
+ files=_files,
610
+ auth_settings=_auth_settings,
611
+ collection_formats=_collection_formats,
612
+ _host=_host,
613
+ _request_auth=_request_auth
614
+ )
615
+
616
+
617
+
618
+
619
+ @validate_call
620
+ def get_ip_batch_status(
621
+ self,
622
+ job_id: Annotated[StrictStr, Field(description="The unique identifier of the batch job to retrieve status for.")],
623
+ _request_timeout: Union[
624
+ None,
625
+ Annotated[StrictFloat, Field(gt=0)],
626
+ Tuple[
627
+ Annotated[StrictFloat, Field(gt=0)],
628
+ Annotated[StrictFloat, Field(gt=0)]
629
+ ]
630
+ ] = None,
631
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
632
+ _content_type: Optional[StrictStr] = None,
633
+ _headers: Optional[Dict[StrictStr, Any]] = None,
634
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
635
+ ) -> GetEmailBatchStatus200Response:
636
+ """Get IP Batch Status
637
+
638
+ The **Get IP Batch Status** endpoint allows you to retrieve the current status of a previously submitted batch processing job. Use this endpoint to track the progress of your batch IP analysis request and retrieve results when processing is complete. ### Response Information: - When status is `QUEUED`: The job is in the processing queue waiting to be processed. - When status is `PROCESSING`: The job is actively being processed. - When status is `COMPLETED`: The job has finished successfully. - When status is `ERROR`: An issue occurred during processing; check the statusDescription for details.
639
+
640
+ :param job_id: The unique identifier of the batch job to retrieve status for. (required)
641
+ :type job_id: str
642
+ :param _request_timeout: timeout setting for this request. If one
643
+ number provided, it will be total request
644
+ timeout. It can also be a pair (tuple) of
645
+ (connection, read) timeouts.
646
+ :type _request_timeout: int, tuple(int, int), optional
647
+ :param _request_auth: set to override the auth_settings for an a single
648
+ request; this effectively ignores the
649
+ authentication in the spec for a single request.
650
+ :type _request_auth: dict, optional
651
+ :param _content_type: force content-type for the request.
652
+ :type _content_type: str, Optional
653
+ :param _headers: set to override the headers for a single
654
+ request; this effectively ignores the headers
655
+ in the spec for a single request.
656
+ :type _headers: dict, optional
657
+ :param _host_index: set to override the host_index for a single
658
+ request; this effectively ignores the host_index
659
+ in the spec for a single request.
660
+ :type _host_index: int, optional
661
+ :return: Returns the result object.
662
+ """ # noqa: E501
663
+
664
+ _param = self._get_ip_batch_status_serialize(
665
+ job_id=job_id,
666
+ _request_auth=_request_auth,
667
+ _content_type=_content_type,
668
+ _headers=_headers,
669
+ _host_index=_host_index
670
+ )
671
+
672
+ _response_types_map: Dict[str, Optional[str]] = {
673
+ '200': "GetEmailBatchStatus200Response",
674
+ '404': "GetEmailBatchStatus404Response",
675
+ '403': "BatchAnalyzeEmails403Response",
676
+ '500': "AnalyzeEmail500Response",
677
+ }
678
+ response_data = self.api_client.call_api(
679
+ *_param,
680
+ _request_timeout=_request_timeout
681
+ )
682
+ response_data.read()
683
+ return self.api_client.response_deserialize(
684
+ response_data=response_data,
685
+ response_types_map=_response_types_map,
686
+ ).data
687
+
688
+
689
+ @validate_call
690
+ def get_ip_batch_status_with_http_info(
691
+ self,
692
+ job_id: Annotated[StrictStr, Field(description="The unique identifier of the batch job to retrieve status for.")],
693
+ _request_timeout: Union[
694
+ None,
695
+ Annotated[StrictFloat, Field(gt=0)],
696
+ Tuple[
697
+ Annotated[StrictFloat, Field(gt=0)],
698
+ Annotated[StrictFloat, Field(gt=0)]
699
+ ]
700
+ ] = None,
701
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
702
+ _content_type: Optional[StrictStr] = None,
703
+ _headers: Optional[Dict[StrictStr, Any]] = None,
704
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
705
+ ) -> ApiResponse[GetEmailBatchStatus200Response]:
706
+ """Get IP Batch Status
707
+
708
+ The **Get IP Batch Status** endpoint allows you to retrieve the current status of a previously submitted batch processing job. Use this endpoint to track the progress of your batch IP analysis request and retrieve results when processing is complete. ### Response Information: - When status is `QUEUED`: The job is in the processing queue waiting to be processed. - When status is `PROCESSING`: The job is actively being processed. - When status is `COMPLETED`: The job has finished successfully. - When status is `ERROR`: An issue occurred during processing; check the statusDescription for details.
709
+
710
+ :param job_id: The unique identifier of the batch job to retrieve status for. (required)
711
+ :type job_id: str
712
+ :param _request_timeout: timeout setting for this request. If one
713
+ number provided, it will be total request
714
+ timeout. It can also be a pair (tuple) of
715
+ (connection, read) timeouts.
716
+ :type _request_timeout: int, tuple(int, int), optional
717
+ :param _request_auth: set to override the auth_settings for an a single
718
+ request; this effectively ignores the
719
+ authentication in the spec for a single request.
720
+ :type _request_auth: dict, optional
721
+ :param _content_type: force content-type for the request.
722
+ :type _content_type: str, Optional
723
+ :param _headers: set to override the headers for a single
724
+ request; this effectively ignores the headers
725
+ in the spec for a single request.
726
+ :type _headers: dict, optional
727
+ :param _host_index: set to override the host_index for a single
728
+ request; this effectively ignores the host_index
729
+ in the spec for a single request.
730
+ :type _host_index: int, optional
731
+ :return: Returns the result object.
732
+ """ # noqa: E501
733
+
734
+ _param = self._get_ip_batch_status_serialize(
735
+ job_id=job_id,
736
+ _request_auth=_request_auth,
737
+ _content_type=_content_type,
738
+ _headers=_headers,
739
+ _host_index=_host_index
740
+ )
741
+
742
+ _response_types_map: Dict[str, Optional[str]] = {
743
+ '200': "GetEmailBatchStatus200Response",
744
+ '404': "GetEmailBatchStatus404Response",
745
+ '403': "BatchAnalyzeEmails403Response",
746
+ '500': "AnalyzeEmail500Response",
747
+ }
748
+ response_data = self.api_client.call_api(
749
+ *_param,
750
+ _request_timeout=_request_timeout
751
+ )
752
+ response_data.read()
753
+ return self.api_client.response_deserialize(
754
+ response_data=response_data,
755
+ response_types_map=_response_types_map,
756
+ )
757
+
758
+
759
+ @validate_call
760
+ def get_ip_batch_status_without_preload_content(
761
+ self,
762
+ job_id: Annotated[StrictStr, Field(description="The unique identifier of the batch job to retrieve status for.")],
763
+ _request_timeout: Union[
764
+ None,
765
+ Annotated[StrictFloat, Field(gt=0)],
766
+ Tuple[
767
+ Annotated[StrictFloat, Field(gt=0)],
768
+ Annotated[StrictFloat, Field(gt=0)]
769
+ ]
770
+ ] = None,
771
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
772
+ _content_type: Optional[StrictStr] = None,
773
+ _headers: Optional[Dict[StrictStr, Any]] = None,
774
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
775
+ ) -> RESTResponseType:
776
+ """Get IP Batch Status
777
+
778
+ The **Get IP Batch Status** endpoint allows you to retrieve the current status of a previously submitted batch processing job. Use this endpoint to track the progress of your batch IP analysis request and retrieve results when processing is complete. ### Response Information: - When status is `QUEUED`: The job is in the processing queue waiting to be processed. - When status is `PROCESSING`: The job is actively being processed. - When status is `COMPLETED`: The job has finished successfully. - When status is `ERROR`: An issue occurred during processing; check the statusDescription for details.
779
+
780
+ :param job_id: The unique identifier of the batch job to retrieve status for. (required)
781
+ :type job_id: str
782
+ :param _request_timeout: timeout setting for this request. If one
783
+ number provided, it will be total request
784
+ timeout. It can also be a pair (tuple) of
785
+ (connection, read) timeouts.
786
+ :type _request_timeout: int, tuple(int, int), optional
787
+ :param _request_auth: set to override the auth_settings for an a single
788
+ request; this effectively ignores the
789
+ authentication in the spec for a single request.
790
+ :type _request_auth: dict, optional
791
+ :param _content_type: force content-type for the request.
792
+ :type _content_type: str, Optional
793
+ :param _headers: set to override the headers for a single
794
+ request; this effectively ignores the headers
795
+ in the spec for a single request.
796
+ :type _headers: dict, optional
797
+ :param _host_index: set to override the host_index for a single
798
+ request; this effectively ignores the host_index
799
+ in the spec for a single request.
800
+ :type _host_index: int, optional
801
+ :return: Returns the result object.
802
+ """ # noqa: E501
803
+
804
+ _param = self._get_ip_batch_status_serialize(
805
+ job_id=job_id,
806
+ _request_auth=_request_auth,
807
+ _content_type=_content_type,
808
+ _headers=_headers,
809
+ _host_index=_host_index
810
+ )
811
+
812
+ _response_types_map: Dict[str, Optional[str]] = {
813
+ '200': "GetEmailBatchStatus200Response",
814
+ '404': "GetEmailBatchStatus404Response",
815
+ '403': "BatchAnalyzeEmails403Response",
816
+ '500': "AnalyzeEmail500Response",
817
+ }
818
+ response_data = self.api_client.call_api(
819
+ *_param,
820
+ _request_timeout=_request_timeout
821
+ )
822
+ return response_data.response
823
+
824
+
825
+ def _get_ip_batch_status_serialize(
826
+ self,
827
+ job_id,
828
+ _request_auth,
829
+ _content_type,
830
+ _headers,
831
+ _host_index,
832
+ ) -> RequestSerialized:
833
+
834
+ _host = None
835
+
836
+ _collection_formats: Dict[str, str] = {
837
+ }
838
+
839
+ _path_params: Dict[str, str] = {}
840
+ _query_params: List[Tuple[str, str]] = []
841
+ _header_params: Dict[str, Optional[str]] = _headers or {}
842
+ _form_params: List[Tuple[str, str]] = []
843
+ _files: Dict[
844
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
845
+ ] = {}
846
+ _body_params: Optional[bytes] = None
847
+
848
+ # process the path parameters
849
+ if job_id is not None:
850
+ _path_params['jobId'] = job_id
851
+ # process the query parameters
852
+ # process the header parameters
853
+ # process the form parameters
854
+ # process the body parameter
855
+
856
+
857
+ # set the HTTP header `Accept`
858
+ if 'Accept' not in _header_params:
859
+ _header_params['Accept'] = self.api_client.select_header_accept(
860
+ [
861
+ 'application/json'
862
+ ]
863
+ )
864
+
865
+
866
+ # authentication setting
867
+ _auth_settings: List[str] = [
868
+ 'opportifyToken'
869
+ ]
870
+
871
+ return self.api_client.param_serialize(
872
+ method='GET',
873
+ resource_path='/ip/batch/{jobId}',
874
+ path_params=_path_params,
875
+ query_params=_query_params,
876
+ header_params=_header_params,
877
+ body=_body_params,
878
+ post_params=_form_params,
879
+ files=_files,
880
+ auth_settings=_auth_settings,
881
+ collection_formats=_collection_formats,
882
+ _host=_host,
883
+ _request_auth=_request_auth
884
+ )
885
+
886
+
@@ -3,7 +3,7 @@
3
3
  """
4
4
  Opportify Insights API
5
5
 
6
- ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, corporate or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api-reference/email-insights) - [**IP Insights:**](/docs/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
6
+ ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, private or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api/api-reference/email-insights) - [**IP Insights:**](/docs/api/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
7
7
 
8
8
  The version of the OpenAPI document: 1.0.0
9
9
  Generated by OpenAPI Generator (https://openapi-generator.tech)
@@ -517,7 +517,7 @@ class ApiClient:
517
517
  if k in collection_formats:
518
518
  collection_format = collection_formats[k]
519
519
  if collection_format == 'multi':
520
- new_params.extend((k, str(value)) for value in v)
520
+ new_params.extend((k, quote(str(value))) for value in v)
521
521
  else:
522
522
  if collection_format == 'ssv':
523
523
  delimiter = ' '
@@ -3,7 +3,7 @@
3
3
  """
4
4
  Opportify Insights API
5
5
 
6
- ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, corporate or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api-reference/email-insights) - [**IP Insights:**](/docs/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
6
+ ## Overview The **Opportify Insights API** provides access to a powerful and up-to-date platform. With advanced data warehousing and AI-driven capabilities, this API is designed to empower your business to make informed, data-driven decisions and effectively assess potential risks. ### Base URL Use the following base URL for all API requests: ```plaintext https://api.opportify.ai/insights/v1/<service>/<endpoint> ``` ### Features - [**Email Insights:**](/docs/api/api-reference/email-insights) - Validate email syntax. - Identify email types (free, disposable, private or unknown). - Real time verifications: - Reachable: Confirms if the email domain has valid MX DNS records using DNS lookup. - Deliverable: Simulates an SMTP handshake to check if the email address exists and is deliverable. - Catch-All: Detects if the domain accepts all emails (catch-all configuration). - Intelligent Error Correction: Automatically corrects well-known misspelled email addresses. - Risk Report: Provides an AI-driven normalized score (200-1000) to evaluate email risk, using predefined thresholds. [Access Documentation >>](/docs/api/api-reference/email-insights) - [**IP Insights:**](/docs/api/api-reference/ip-insights) - Connection types: Detects connection types such as `wired`, `mobile`, `enterprise`, `satellite`, `VPN`, `cloud-provider`, `open-proxy`, or `Tor`. - Geo location: Delivers detailed insights such as country, city, timezone, language preferences, and additional location-based information to enhance regional understanding. - WHOIS: Provides main details including RIR, ASN, organization, and abuse/admin/technical contacts. - Trusted Provider Recognition: Identifies if the IP is part of a known trusted provider (e.g., ZTNA - Zero Trust Network Access). - Blocklist Reports: Retrieves up-to-date blocklist statuses, active reports, and the latest detections. - Risk Report: Delivers an AI-driven normalized score (200-1000) to evaluate IP risk, supported by predefined thresholds. [Access Documentation >>](/docs/api/api-reference/ip-insights) ### Authentication & Security - **API Key:** Access to the API requires an API key, which must be included in the request headers. Businesses can generate unlimited API keys directly from their account, offering flexibility and ease of use. - **ACL Rules:** Enhance security with Access Control Lists (ACL), allowing you to restrict API access from specific IP addresses or ranges. This feature provides an additional layer of protection by ensuring only authorized IPs can interact with the API. - **No Query Parameters:** As a precautionary measure, our API avoids the use of query parameters for all operations, including authentication and handling Personally Identifiable Information (PII). This approach minimizes security risks by preventing sensitive data from being exposed in access logs, browser history, cached URLs, debugging tools, or inadvertently shared URLs. All sensitive information is securely transmitted through headers or the request body.
7
7
 
8
8
  The version of the OpenAPI document: 1.0.0
9
9
  Generated by OpenAPI Generator (https://openapi-generator.tech)