Exemplo n.º 1
0
 def get_entity_type_reference(self, entity_type=None):
     if entity_type:
         entity_type = entity_type.upper()
     response = self.request(
         endpoint="/entity-reference",
         method='get',
         params={"entity_type": entity_type} if entity_type else None,
         stream=True,
     )
     return EntityTypeReference(http_response=response)
Exemplo n.º 2
0
 def get_entity_type_reference(self, entity_type=None):
     if entity_type:
         entity_type = entity_type.upper()
     assert entity_type in ENTITY_TYPES, "Please provide a valid entity type, one of %s" % ENTITY_TYPES
     response = self.request(
         endpoint="/entity-reference",
         method='get',
         params={"entity_type": entity_type} if entity_type else None,
         stream=True,
     )
     return EntityTypeReference(http_response=response)
Exemplo n.º 3
0
 def get_entity_type_reference_from_file(file_path):
     return EntityTypeReference(file_path=file_path)