websiteclassificationapi 2.14__py3-none-any.whl → 2.15.1__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.
test/__init__.py CHANGED
@@ -1,62 +1,62 @@
1
- """
2
- Python wrapper for website categorization API (service of www.websitecategorizationapi.com)
3
-
4
- Explanation of available classifiers:
5
-
6
- Classifier_type should be set to either iab1 (Tier 1 categorization) or iab2 (Tier 2 categorization) for general websites or ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites.
7
-
8
- IAB Tier 1 categorization returns probabilities of text being classified as one of 29 possible categories.
9
-
10
- IAB Tier 2 categorization returns probabilities of text being classified as one of 447 possible categories.
11
-
12
- Ecommerce Tier 1 categorization returns probabilities of text being classified as one of 21 possible categories.
13
-
14
- Ecommerce Tier 2 website categorization returns probabilities of text being classified as one of 182 possible categories.
15
-
16
- Ecommerce Tier 3 website categorization returns probabilities of text being classified as one of 1113 possible categories.
17
- """
18
-
19
- import requests
20
- import json
21
-
22
- class websiteclassificationapi:
23
- def __init__(self):
24
- pass
25
-
26
- @staticmethod
27
- def get_categorization(url,api_key,category_type):
28
- """
29
- url = URL of website
30
- api_key = api key
31
- category_type = iab1 or iab2 for general websites, ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites
32
- """
33
- if category_type=='iab1':
34
- url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category1_url.php"
35
- elif category_type=='iab2':
36
- url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category2_url.php"
37
- elif category_type=='ecommerce1':
38
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category1.php"
39
- elif category_type=='ecommerce2':
40
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category2.php"
41
- elif category_type=='ecommerce3':
42
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category3.php"
43
-
44
- if (('http://' not in url) or ('https://' not in url)):
45
- url = 'http://'+url
46
- try:
47
- url = requests.utils.quote(url)
48
- print("URL:", url)
49
- payload='query='+url+'&api_key='+api_key+'&data_type=url'
50
- headers = {
51
- 'Content-Type': 'application/x-www-form-urlencoded'
52
- }
53
- response = requests.request("POST", url_api, headers=headers, data=payload)
54
- data = json.loads(response.text)
55
- try:
56
- category = data['classification'][0]['category']
57
- except:
58
- category = 'url could not be loaded'
59
- return category
60
- except Exception as e:
61
- print(e)
1
+ """
2
+ Python wrapper for website categorization API (service of www.websitecategorizationapi.com)
3
+
4
+ Explanation of available classifiers:
5
+
6
+ Classifier_type should be set to either iab1 (Tier 1 categorization) or iab2 (Tier 2 categorization) for general websites or ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites.
7
+
8
+ IAB Tier 1 categorization returns probabilities of text being classified as one of 29 possible categories.
9
+
10
+ IAB Tier 2 categorization returns probabilities of text being classified as one of 447 possible categories.
11
+
12
+ Ecommerce Tier 1 categorization returns probabilities of text being classified as one of 21 possible categories.
13
+
14
+ Ecommerce Tier 2 website categorization returns probabilities of text being classified as one of 182 possible categories.
15
+
16
+ Ecommerce Tier 3 website categorization returns probabilities of text being classified as one of 1113 possible categories.
17
+ """
18
+
19
+ import requests
20
+ import json
21
+
22
+ class websiteclassificationapi:
23
+ def __init__(self):
24
+ pass
25
+
26
+ @staticmethod
27
+ def get_categorization(url,api_key,category_type):
28
+ """
29
+ url = URL of website
30
+ api_key = api key
31
+ category_type = iab1 or iab2 for general websites, ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites
32
+ """
33
+ if category_type=='iab1':
34
+ url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category1_url.php"
35
+ elif category_type=='iab2':
36
+ url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category2_url.php"
37
+ elif category_type=='ecommerce1':
38
+ url_api = "https://www.websitecategorizationapi.com/api/iab/gpt_category1.php"
39
+ elif category_type=='ecommerce2':
40
+ url_api = "https://www.websitecategorizationapi.com/api/iab/gpt_category2.php"
41
+ elif category_type=='ecommerce3':
42
+ url_api = "https://www.websitecategorizationapi.com/api/gpt_new1/gpt_category3.php"
43
+
44
+ if (('http://' not in url) or ('https://' not in url)):
45
+ url = 'http://'+url
46
+ try:
47
+ url = requests.utils.quote(url)
48
+ print("URL:", url)
49
+ payload='query='+url+'&api_key='+api_key+'&data_type=url'
50
+ headers = {
51
+ 'Content-Type': 'application/x-www-form-urlencoded'
52
+ }
53
+ response = requests.request("POST", url_api, headers=headers, data=payload)
54
+ data = json.loads(response.text)
55
+ try:
56
+ category = data['classification'][0]['category']
57
+ except:
58
+ category = 'url could not be loaded'
59
+ return category
60
+ except Exception as e:
61
+ print(e)
62
62
  pass
@@ -1,62 +1,62 @@
1
- """
2
- Python wrapper for website categorization API (service of www.websitecategorizationapi.com)
3
-
4
- Explanation of available classifiers:
5
-
6
- Classifier_type should be set to either iab1 (Tier 1 categorization) or iab2 (Tier 2 categorization) for general websites or ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites.
7
-
8
- IAB Tier 1 categorization returns probabilities of text being classified as one of 29 possible categories.
9
-
10
- IAB Tier 2 categorization returns probabilities of text being classified as one of 447 possible categories.
11
-
12
- Ecommerce Tier 1 categorization returns probabilities of text being classified as one of 21 possible categories.
13
-
14
- Ecommerce Tier 2 website categorization returns probabilities of text being classified as one of 182 possible categories.
15
-
16
- Ecommerce Tier 3 website categorization returns probabilities of text being classified as one of 1113 possible categories.
17
- """
18
-
19
- import requests
20
- import json
21
-
22
- class websiteclassificationapi:
23
- def __init__(self):
24
- pass
25
-
26
- @staticmethod
27
- def get_categorization(url,api_key,category_type):
28
- """
29
- url = URL of website
30
- api_key = api key
31
- category_type = iab1 or iab2 for general websites, ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites
32
- """
33
- if category_type=='iab1':
34
- url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category1_url.php"
35
- elif category_type=='iab2':
36
- url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category2_url.php"
37
- elif category_type=='ecommerce1':
38
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category1.php"
39
- elif category_type=='ecommerce2':
40
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category2.php"
41
- elif category_type=='ecommerce3':
42
- url_api = "https://www.websitecategorizationapi.com/api/iab/gpt/gpt_category3.php"
43
-
44
- if (('http://' not in url) or ('https://' not in url)):
45
- url = 'http://'+url
46
- try:
47
- url = requests.utils.quote(url)
48
- print("URL:", url)
49
- payload='query='+url+'&api_key='+api_key+'&data_type=url'
50
- headers = {
51
- 'Content-Type': 'application/x-www-form-urlencoded'
52
- }
53
- response = requests.request("POST", url_api, headers=headers, data=payload)
54
- data = json.loads(response.text)
55
- try:
56
- category = data['classification'][0]['category']
57
- except:
58
- category = 'url could not be loaded'
59
- return category
60
- except Exception as e:
61
- print(e)
1
+ """
2
+ Python wrapper for website categorization API (service of www.websitecategorizationapi.com)
3
+
4
+ Explanation of available classifiers:
5
+
6
+ Classifier_type should be set to either iab1 (Tier 1 categorization) or iab2 (Tier 2 categorization) for general websites or ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites.
7
+
8
+ IAB Tier 1 categorization returns probabilities of text being classified as one of 29 possible categories.
9
+
10
+ IAB Tier 2 categorization returns probabilities of text being classified as one of 447 possible categories.
11
+
12
+ Ecommerce Tier 1 categorization returns probabilities of text being classified as one of 21 possible categories.
13
+
14
+ Ecommerce Tier 2 website categorization returns probabilities of text being classified as one of 182 possible categories.
15
+
16
+ Ecommerce Tier 3 website categorization returns probabilities of text being classified as one of 1113 possible categories.
17
+ """
18
+
19
+ import requests
20
+ import json
21
+
22
+ class websiteclassificationapi:
23
+ def __init__(self):
24
+ pass
25
+
26
+ @staticmethod
27
+ def get_categorization(url,api_key,category_type):
28
+ """
29
+ url = URL of website
30
+ api_key = api key
31
+ category_type = iab1 or iab2 for general websites, ecommerce1, ecommerce2 and ecommerce3 for E-commerce or product websites
32
+ """
33
+ if category_type=='iab1':
34
+ url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category1_url.php"
35
+ elif category_type=='iab2':
36
+ url_api = "https://www.websitecategorizationapi.com/api/iab/iab_category2_url.php"
37
+ elif category_type=='ecommerce1':
38
+ url_api = "https://www.websitecategorizationapi.com/api/iab/gpt_category1.php"
39
+ elif category_type=='ecommerce2':
40
+ url_api = "https://www.websitecategorizationapi.com/api/iab/gpt_category2.php"
41
+ elif category_type=='ecommerce3':
42
+ url_api = "https://www.websitecategorizationapi.com/api/gpt_new1/gpt_category3.php"
43
+
44
+ if (('http://' not in url) or ('https://' not in url)):
45
+ url = 'http://'+url
46
+ try:
47
+ url = requests.utils.quote(url)
48
+ print("URL:", url)
49
+ payload='query='+url+'&api_key='+api_key+'&data_type=url'
50
+ headers = {
51
+ 'Content-Type': 'application/x-www-form-urlencoded'
52
+ }
53
+ response = requests.request("POST", url_api, headers=headers, data=payload)
54
+ data = json.loads(response.text)
55
+ try:
56
+ category = data['classification'][0]['category']
57
+ except:
58
+ category = 'url could not be loaded'
59
+ return category
60
+ except Exception as e:
61
+ print(e)
62
62
  pass
@@ -1,12 +1,13 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: websiteclassificationapi
3
- Version: 2.14
3
+ Version: 2.15.1
4
4
  Summary: Website classification API
5
5
  Home-page: https://github.com/websitecategorization/websiteclassificationnapi
6
6
  Author-email: info@websitecategorizationapi.com
7
7
  License: UNKNOWN
8
8
  Project-URL: Homepage, https://www.websitecategorizationapi.com
9
9
  Project-URL: AI Tools Blocklist, https://www.aitoolsblocklist.com
10
+ Project-URL: Resume Reader API, http://resumereaderapi.com
10
11
  Keywords: website categorization,classification,categorization
11
12
  Platform: UNKNOWN
12
13
  Classifier: License :: OSI Approved :: MIT License
@@ -121,11 +122,13 @@ Having verticals set up may also mean better filtering and lead to higher conver
121
122
 
122
123
  ## Our other services
123
124
 
124
- Companies that manage internet access often start with a [web filtering database](https://webfilteringdatabase.com) to review how domains are categorized. This supports better decisions around policy cr
125
- eation, reporting, and risk visibility. Many of those teams also evaluate a [web filtering service](https://webfilteringservice.com) to apply those controls in production.
125
+ Companies that manage internet access often start with a [web filtering database](https://www.webfilteringdatabase.com) to review how domains are categorized. This supports better decisions around policy cr
126
+ eation, reporting, and risk visibility. Many of those teams also evaluate a [web filtering service](https://www.webfilteringservice.com) to apply those controls in production.
126
127
 
127
128
 
128
- We also provide APIs for other tasks: [Redaction API](https://www.redactionapi.net) and [Content Moderation API](https://www.contentmoderationapi.net) as well as [Anonymization API](https://www.anonymizationapi.com).
129
+ We also provide an [Anonymization API](https://www.anonymizationapi.com) for privacy-preserving media and data workflows.
130
+
131
+ Schools and libraries subject to the Children's Internet Protection Act need more than generic web categories — they need a purpose-built [CIPA web filtering](https://www.cipawebfiltering.com) database with 120 million domains organized into 57+ content categories aligned to federal compliance requirements. Pairing categorization with threat intelligence strengthens any filtering deployment, and our [phishing detection API](https://www.phishingdetectionapi.com) delivers real-time lookups against 390,000+ DNS-verified active phishing domains so that malicious URLs are blocked before they reach end users. Together, these services give IT teams the classification depth and security coverage needed to protect students, staff, and network infrastructure.
129
132
 
130
133
  ## AI explainability
131
134
 
@@ -178,9 +181,9 @@ Here are e.g. recommendations for company using Mouse Flow: <table class="table"
178
181
 
179
182
 
180
183
 
181
- Our digital solutions are trusted by organizations seeking reliable, secure, and innovative tools. With the [image moderation api](https://www.contentmoderationapi.net), companies gain the ability to filter and manage user-generated visuals, all while staying informed with insights from [Harvard](https://www.harvard.edu). Protect privacy in every scenario using our [image anonymization](https://www.anomyizationapi.com) platform, engineered to meet global standards and inspired by research from [MIT](https://web.mit.edu). When sensitive information must be protected, our [pii redaction service](https://www.redactionapi.net) ensures that personal data is removed efficiently, reflecting approaches found at [Stanford](https://www.stanford.edu).
184
+ Our digital solutions are trusted by organizations seeking reliable, secure, and innovative tools. Protect privacy in every scenario using our [image anonymization](https://www.anonymizationapi.com) platform, engineered to meet global standards and inspired by research from [MIT](https://web.mit.edu), while staying informed with insights from [Harvard](https://www.harvard.edu) and approaches found at [Stanford](https://www.stanford.edu).
182
185
 
183
- Business growth is supported through our [corporate enrichment data](https://www.companydataapi.com), delivering actionable intelligence much like the work at [Cambridge](https://www.cam.ac.uk). For cybersecurity and research teams, our [domain dataset](https://www.urlcategorizationdatabase.com) offers extensive categorization, paralleling the data-centric methods at [Berkeley](https://www.berkeley.edu). Legal departments benefit from our [automated contract review](https://www.aicontractreviewtool.com), streamlining compliance and review processes as promoted by [Oxford](https://www.ox.ac.uk).
186
+ Business growth is supported through our [corporate enrichment data](https://www.companydataapi.com), delivering actionable intelligence much like the work at [Cambridge](https://www.cam.ac.uk). For cybersecurity and research teams, our [domain dataset](https://www.urlcategorizationdatabase.com) offers extensive categorization, paralleling the data-centric methods at [Berkeley](https://www.berkeley.edu).
184
187
 
185
188
  By aligning our solutions with the excellence demonstrated at [Yale](https://www.yale.edu) and [Cornell](https://www.cornell.edu), we ensure that your organization stays at the cutting edge—combining technology, research, and practical results for every challenge.
186
189
 
@@ -317,6 +320,10 @@ Example classification for website www.github.com:
317
320
 
318
321
  For teams building acceptable-use or data-loss-prevention policies around generative AI, the [AI Tools Blocklist](https://www.aitoolsblocklist.com) complements this classifier with a purpose-built feed of AI-tool domains grouped into functional categories (chatbots, code assistants, media generators, voice cloning, and more). It answers a question generic categorization cannot: not just "is this site AI-related," but "which kind of AI tool is it," which is what granular blocking policies require.
319
322
 
323
+ Website classification at massive scale also applies to discovering acquisition candidates across the full web. Our [web-scale deal origination platform](https://www.acquisitionuniverse.com) screens over 100 million classified domains against buyer acquisition theses, extracting 15 operational signals per company from their public web presence. Private equity firms, search funds, and corporate development teams use the pipeline to surface non-obvious targets whose websites reveal strong fit signals — leadership depth, recurring revenue indicators, compliance readiness — that conventional company databases never capture.
324
+
325
+ The same classification engine powers contextual audience segments for programmatic advertising without cookies. Our [cookieless advertising data platform](https://www.cookielessaudiences.com) delivers domain datasets pre-categorized under the IAB content taxonomy, enabling DSPs and publishers to target audiences based on page context rather than user-level tracking. With Chrome, Safari, and Firefox deprecating third-party cookies, domain-level contextual classification is becoming the primary signal for brand-safe, regulation-compliant ad placement at scale.
326
+
320
327
  ## Useful resources used in development of website categorization
321
328
 
322
329
  - [Tensorflow](https://www.tensorflow.org/)
@@ -331,5 +338,6 @@ For teams building acceptable-use or data-loss-prevention policies around genera
331
338
 
332
339
  - [Top shopify stores](https://www.leadsquantum.com)
333
340
  - [AI Tools Blocklist](https://www.aitoolsblocklist.com)
341
+ - [CV parser](http://resumereaderapi.com) — AI resume parsing API that turns PDF/DOCX resumes into structured JSON
334
342
 
335
343
 
@@ -0,0 +1,7 @@
1
+ test/__init__.py,sha256=2CRQNSj3wox7JogFAtEbBDR-3_xnfgmjOm51zq2W4uA,2801
2
+ websiteclassificationapi/__init__.py,sha256=2CRQNSj3wox7JogFAtEbBDR-3_xnfgmjOm51zq2W4uA,2801
3
+ websiteclassificationapi-2.15.1.dist-info/LICENSE,sha256=7Fog1crdAQKBoXwk300JwPHIMJV-386OAuvTrd-N8hs,1083
4
+ websiteclassificationapi-2.15.1.dist-info/METADATA,sha256=zPqN526uvjkNMssR9_8uks7k7LYDpWcMF-Dlf8yTXmI,17968
5
+ websiteclassificationapi-2.15.1.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
6
+ websiteclassificationapi-2.15.1.dist-info/top_level.txt,sha256=e76DP_x4tfbB3dn42joSGBVORT6U6GlMaReN7W-X8nY,30
7
+ websiteclassificationapi-2.15.1.dist-info/RECORD,,
@@ -1,7 +0,0 @@
1
- test/__init__.py,sha256=wTdBA0QbwpUvhKcdWegp481T0tvA6XcAb9BkdSDkzvE,2869
2
- websiteclassificationapi/__init__.py,sha256=wTdBA0QbwpUvhKcdWegp481T0tvA6XcAb9BkdSDkzvE,2869
3
- websiteclassificationapi-2.14.dist-info/LICENSE,sha256=7Fog1crdAQKBoXwk300JwPHIMJV-386OAuvTrd-N8hs,1083
4
- websiteclassificationapi-2.14.dist-info/METADATA,sha256=tBjPVT5FlYpbhXvi_pdE09PJ15bJ0IMYD9XLChXuDj4,16417
5
- websiteclassificationapi-2.14.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
6
- websiteclassificationapi-2.14.dist-info/top_level.txt,sha256=e76DP_x4tfbB3dn42joSGBVORT6U6GlMaReN7W-X8nY,30
7
- websiteclassificationapi-2.14.dist-info/RECORD,,