Have a figma file with frames in the top level:
Get your Figma token from here
Make an environment variable e.g. $ export FIGMA_TOKEN="XXXX-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
$ stack build
$ stack exec figma-to-pdf-exe "FILEID"
The .pdf will be in the export folder