vysion 2.0.15__tar.gz → 2.0.18__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.
@@ -1,8 +1,7 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.3
2
2
  Name: vysion
3
- Version: 2.0.15
3
+ Version: 2.0.18
4
4
  Summary: The official Python client library for Vysion
5
- Home-page: https://vysion.ai
6
5
  License: Apache-2.0
7
6
  Author: Javier Junquera-Sánchez
8
7
  Author-email: javier.junquera@byronlabs.io
@@ -15,11 +14,13 @@ Classifier: Programming Language :: Python :: 3.9
15
14
  Classifier: Programming Language :: Python :: 3.10
16
15
  Classifier: Programming Language :: Python :: 3.11
17
16
  Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
18
  Requires-Dist: pydantic (>=2.0.1,<3.0.0)
19
19
  Requires-Dist: pymisp (>=2.4.194,<3.0.0)
20
20
  Requires-Dist: requests (>=2.28.1,<3.0.0)
21
21
  Requires-Dist: softenum (==1.0.1)
22
22
  Project-URL: Documentation, https://developers.vysion.ai
23
+ Project-URL: Homepage, https://vysion.ai
23
24
  Project-URL: Repository, https://github.com/ByronLabs/vysion-py
24
25
  Description-Content-Type: text/markdown
25
26
 
@@ -29,7 +30,7 @@ Welcome to the open source repository for vysion-py, our implementation as a Pyt
29
30
 
30
31
  You can request a demo for the web app or an API-key to use in this library at [vysion.ai](https://vysion.ai).
31
32
 
32
- Latest version: [2.0.15](https://pypi.org/project/vysion/)
33
+ Latest version: [2.0.18](https://pypi.org/project/vysion/)
33
34
 
34
35
  You can visit [the documentation](https://developers.vysion.ai/?python) for more information on the searches and requests performed with the library or directly on the API.
35
36
 
@@ -4,7 +4,7 @@ Welcome to the open source repository for vysion-py, our implementation as a Pyt
4
4
 
5
5
  You can request a demo for the web app or an API-key to use in this library at [vysion.ai](https://vysion.ai).
6
6
 
7
- Latest version: [2.0.15](https://pypi.org/project/vysion/)
7
+ Latest version: [2.0.18](https://pypi.org/project/vysion/)
8
8
 
9
9
  You can visit [the documentation](https://developers.vysion.ai/?python) for more information on the searches and requests performed with the library or directly on the API.
10
10
 
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "vysion"
3
- version = "2.0.15"
3
+ version = "2.0.18"
4
4
  description = "The official Python client library for Vysion"
5
5
  homepage = "https://vysion.ai"
6
6
  repository = "https://github.com/ByronLabs/vysion-py"
@@ -331,6 +331,8 @@ class Client(BaseClient):
331
331
  network: Network = None,
332
332
  country: str = None,
333
333
  language: Language = None,
334
+ naics: str = None,
335
+ industry: str = None,
334
336
  ) -> VysionResponse[RansomwareHit]:
335
337
  url = self._build_api_url__(
336
338
  "victim/search",
@@ -342,6 +344,8 @@ class Client(BaseClient):
342
344
  network=network,
343
345
  country=country,
344
346
  language=language,
347
+ naics=naics,
348
+ industry=industry,
345
349
  )
346
350
 
347
351
  result = VysionResponse[RansomwareHit].model_validate(self._make_request(url))
@@ -226,8 +226,8 @@ class RansomwareHit(BaseModel):
226
226
  companyAddress: Optional[str] = None
227
227
  companyLink: Optional[str] = None
228
228
  country: Optional[str] = None
229
- sector: Optional[str] = None
230
- industryGroup: Optional[str] = None
229
+ naics: Optional[str] = None
230
+ industry: Optional[str] = None
231
231
 
232
232
  class DocumentHit(BaseModel):
233
233
  page: Page
@@ -395,6 +395,47 @@ class ImFeedHit(BaseModel):
395
395
  network: str
396
396
 
397
397
 
398
+ class CryptoFeedHit(BaseModel):
399
+ id: str
400
+ url: str
401
+ detectionDate: datetime
402
+ url: str
403
+ network: str
404
+ title: str
405
+ tag: List[Tag] = Field(default_factory=lambda: [])
406
+ bitcoin_address: Optional[List[BitcoinAddress]] = Field(default_factory=lambda: [])
407
+ polkadot_address: Optional[List[PolkadotAddress]] = Field(default_factory=lambda: [])
408
+ ethereum_address: Optional[List[EthereumAddress]] = Field(default_factory=lambda: [])
409
+ monero_address: Optional[List[MoneroAddress]] = Field(default_factory=lambda: [])
410
+ ripple_address: Optional[List[RippleAddress]] = Field(default_factory=lambda: [])
411
+ zcash_address: Optional[List[ZcashAddress]] = Field(default_factory=lambda: [])
412
+
413
+ model_config = ConfigDict(
414
+ arbitrary_types_allowed=True,
415
+ exclude_defaults=True,
416
+ validate_assignment=True
417
+ )
418
+
419
+ @model_validator(mode="after")
420
+ def remove_empty_lists(cls, values):
421
+ """Remove empty cryptocurrency lists from output"""
422
+ crypto_fields = [
423
+ "bitcoin_address",
424
+ "polkadot_address",
425
+ "ethereum_address",
426
+ "monero_address",
427
+ "ripple_address",
428
+ "zcash_address"
429
+ ]
430
+
431
+ for field_name in crypto_fields:
432
+ field_value = getattr(values, field_name, None)
433
+ if isinstance(field_value, list) and not field_value:
434
+ setattr(values, field_name, None)
435
+
436
+ return values
437
+
438
+
398
439
  class RansomFeedHit(BaseModel):
399
440
  id: str
400
441
  companyName: Optional[str]
@@ -404,8 +445,8 @@ class RansomFeedHit(BaseModel):
404
445
  detectionDate: datetime
405
446
  text: Optional[str]
406
447
  country: Optional[str]
407
- sector: Optional[str]
408
- industryGroup: Optional[str]
448
+ naics: Optional[str]
449
+ industry: Optional[str]
409
450
 
410
451
  model_config = ConfigDict(arbitrary_types_allowed=True)
411
452
 
@@ -15,4 +15,4 @@ See the License for the specific language governing permissions and
15
15
  limitations under the License.
16
16
  """
17
17
 
18
- __version__ = "2.0.15"
18
+ __version__ = "2.0.18"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes