Beispiel #1
0
 def create(self, card: Card) -> NewCardResponse:
     response = self._post(self._format_url(), json=card.as_dict())
     return NewCardResponse(**response)
Beispiel #2
0
 def testAsDict(self):
     card = Card(**sample)
     self.assertDictEqual(card.as_dict(), sample)
Beispiel #3
0
 def verify(self, card: Card) -> bool:
     response = self._post(self._format_url(card_id="verification"),
                           json=card.as_dict())
     return response.get("status") == "VERIFIED"