Coverage for polar/customer_portal/schemas/downloadables.py: 100%

23 statements  

« prev     ^ index     » next       coverage.py v7.10.6, created at 2025-12-05 15:52 +0000

1from datetime import datetime 1a

2 

3from pydantic import UUID4 1a

4 

5from polar.benefit.schemas import BenefitID 1a

6from polar.file.schemas import FileDownload 1a

7from polar.kit.schemas import Schema 1a

8from polar.models.downloadable import DownloadableStatus 1a

9 

10 

11class DownloadableURL(Schema): 1a

12 url: str 1a

13 expires_at: datetime 1a

14 

15 

16class DownloadableRead(Schema): 1a

17 id: UUID4 1a

18 benefit_id: UUID4 1a

19 

20 file: FileDownload 1a

21 

22 

23class DownloadableCreate(Schema): 1a

24 file_id: UUID4 1a

25 customer_id: UUID4 1a

26 benefit_id: BenefitID 1a

27 status: DownloadableStatus 1a

28 

29 

30class DownloadableUpdate(Schema): 1a

31 file_id: UUID4 1a

32 customer_id: UUID4 1a

33 benefit_id: BenefitID 1a

34 status: DownloadableStatus 1a