Manager
psengine.entity_match.entity_match_mgr.EntityMatchMgr
¶
Manages requests for Recorded Future Entity Match API.
PARAMETER | DESCRIPTION |
---|---|
rf_token
|
Recorded Future API token.
TYPE:
|
Source code in psengine/entity_match/entity_match_mgr.py
lookup
¶
lookup(id_: str) -> EntityLookup
Look up a Recorded Future ID for entity details.
PARAMETER | DESCRIPTION |
---|---|
id_
|
Recorded Future ID to look up.
TYPE:
|
Endpoint
entity-match/entity/{id}
RAISES | DESCRIPTION |
---|---|
ValidationError
|
If any supplied parameter is of incorrect type. |
MatchApiError
|
If connection error occurs. |
RETURNS | DESCRIPTION |
---|---|
EntityLookup
|
EntityLookup object containing entity details. |
Source code in psengine/entity_match/entity_match_mgr.py
lookup_bulk
¶
lookup_bulk(
ids: list[str], max_workers: Optional[int] = 0
) -> list[EntityLookup]
Look up multiple Recorded Future IDs for entity details.
PARAMETER | DESCRIPTION |
---|---|
ids
|
List of Recorded Future IDs to look up.
TYPE:
|
max_workers
|
Number of workers to multithread requests.
TYPE:
|
Endpoint
entity-match/entity/{id}
RAISES | DESCRIPTION |
---|---|
ValidationError
|
If any supplied parameter is of incorrect type. |
MatchApiError
|
If connection error occurs. |
RETURNS | DESCRIPTION |
---|---|
list[EntityLookup]
|
List of EntityLookup objects containing entity details. |
Source code in psengine/entity_match/entity_match_mgr.py
match
¶
match(
entity_name: str,
entity_type: Optional[Union[list, str]] = None,
limit: int = DEFAULT_LIMIT,
) -> list[ResolvedEntity]
Match a text string using the entity match API.
PARAMETER | DESCRIPTION |
---|---|
entity_name
|
Name of the entity.
TYPE:
|
entity_type
|
Type or list of types of the entity, if known.
TYPE:
|
limit
|
Maximum number of matches to return.
TYPE:
|
Endpoint
entity-match/match
RAISES | DESCRIPTION |
---|---|
ValidationError
|
If any supplied parameter is of incorrect type. |
MatchApiError
|
If connection error occurs. |
RETURNS | DESCRIPTION |
---|---|
list[ResolvedEntity]
|
List of resolved entity matches. |
Source code in psengine/entity_match/entity_match_mgr.py
resolve_entity_id
¶
resolve_entity_id(
entity_name: str,
entity_type: Optional[str] = Field(
min_length=2, default=None
),
limit: Optional[int] = DEFAULT_LIMIT,
) -> ResolvedEntity
Resolve an entity name (and optionally type) to an ID.
PARAMETER | DESCRIPTION |
---|---|
entity_name
|
Name of the entity.
TYPE:
|
entity_type
|
Type of the entity, if known.
TYPE:
|
limit
|
Number of matches to check.
TYPE:
|
Endpoint
entity-match/match
RAISES | DESCRIPTION |
---|---|
ValidationError
|
If any supplied parameter is of incorrect type. |
MatchApiError
|
If connection error occurs. |
RETURNS | DESCRIPTION |
---|---|
ResolvedEntity
|
Resolved entity match. |
Source code in psengine/entity_match/entity_match_mgr.py
resolve_entity_ids
¶
resolve_entity_ids(
entities: Union[list[str], list[tuple[str, str]]],
limit: Optional[int] = DEFAULT_LIMIT,
max_workers: Optional[int] = DEFAULT_MAX_WORKERS,
) -> list[ResolvedEntity]
Resolve a list of entities to their corresponding IDs.
PARAMETER | DESCRIPTION |
---|---|
entities
|
List of entity names or (name, type) tuples.
TYPE:
|
limit
|
Number of matches to return for each entity.
TYPE:
|
max_workers
|
Number of workers to multithread requests.
TYPE:
|
Endpoint
entity-match/match
RAISES | DESCRIPTION |
---|---|
ValidationError
|
If any supplied parameter is of incorrect type. |
MatchApiError
|
If connection error occurs. |
RETURNS | DESCRIPTION |
---|---|
list[ResolvedEntity]
|
Resolved entities for the provided input list. |