Questions tagged [figma-api]

Figma is a tool for prototyping and collaborating on design in the comfort of your browser.

Figma offers an API to integrate with its collaborative platform - https://www.figma.com/developers

49 questions
8
votes
2 answers

Figma API: Accessing user's files, projects or teams

I was trying to play with the Figma API for a side project, and I was wondering if there's any way to access the files, the projects, or the teams for a specific user (after OAuth). I can't find any endpoint that seems to do that on the docs.…
7
votes
1 answer

Cannot find name 'figma' error on setting up Figma plugin

I'm new to TS and JS. Now I'm trying to set up my first plugin using the guide on macOS. At some point I got an error: /code.ts:9:1 - error TS2304: Cannot find name 'figma'. I followed all the steps from the guide I suppose the next action in the…
Nuzhdin Vladimir
  • 1,714
  • 18
  • 36
6
votes
2 answers

Figma doesn't load .fig file

Everytime I try to open a .fig file this message pops: "Files failed to import... newFile.fig Drop .fig files into the file browser to import them" How can I solve this? I already tried on the app of the computer and on the browser.
uint
  • 71
  • 1
  • 1
  • 6
3
votes
1 answer

How to export element as PNG or JPEG using figma rest apis?

I am able to export a Textbox rectangle as PNG or JPEG from figma screens Web App. However, couldn't find any way to export particular element as PNG/JPEG using figma APIs. Figma API documentation doesn't…
Abhishek Kulkarni
  • 3,693
  • 8
  • 35
  • 42
3
votes
1 answer

How do I get Figma API to work with the Google App-script API?

I am thinking of creating a google slides to Figma exporter using Google App Script. Starting out I would first like to route the shapes created in from google Slides to figma. How would I go about setting up my file? And I don't know how to set up…
2
votes
1 answer

How to Convert Figma API response to FIGMA Design Code?

I am using Figma API to get a document. The response is in JSON Object. I want to convert that JSON Object, so that I can copy it into Figma UI or Convert the response to a compatible import file for Figma UI. Any Ideas, How to do that ? I know it…
Arslan
  • 51
  • 3
2
votes
1 answer

Figma plugin VectorNode doesn't have .fillGeometry?

The VectorNode documentation claims that VectorNode has a property called fillGeometry. However, TypeScript disagrees, saying that "property 'fillGeometry' does not exist on type 'VectorNode'" What am I missing here? I would really like an example…
crowhill
  • 2,398
  • 3
  • 26
  • 55
2
votes
2 answers

Figma design to react component

I have a list of React component like Table, button, pagination, etc,. Now I am in a need of creating Figma plugin that generate web page(react class component) from figma design using my React component which i already have. is it possible to do?
Antony Raj
  • 31
  • 4
2
votes
2 answers

All items are fixed in the figma design

I'm trying to convert figma design to html and css but in the design all items' positions are absolute. One of the nav item's styles: position: absolute; width: 79px; height: 16px; right: 395px; top: 13px; Grid items' styles: position:…
Dogukan Aktas
  • 113
  • 10
2
votes
2 answers

Tailwindcss in Figma

I wonder if it is possible to use Tailwindcss with Figma? And if someone does, is there any example to see? I saw that it is possible to export colors from Figma and import them in taiwind config. But what about Tailwindcss utilities? Also that it…
user1665355
  • 3,324
  • 8
  • 44
  • 84
1
vote
0 answers

Figma Api fails to get large files

I am writing a crawler that looks through all the Figma files in a project and finds a certain kind of node. I am using this npm package --> https://www.npmjs.com/package/figma-api which uses the Figma REST API under the hood. Looking at the API…
1
vote
0 answers

Convert Instance or Frame node to Component node through Figma API

is there a way how to convert Instance or Frame node to Component node with Figma API? Through UI it's very easy just right click on element and then Create Component like on screenshot below but I need to do it through Figma API. I found…
delahozzz
  • 33
  • 1
  • 4
1
vote
0 answers

Figma API to HTML/CSS

Trying to write a converter from Figma design to HTML/cSS. What I've followed so far: Fetch the data for a particular Figma file by hitting a GET request using the FIGMA_TOKEN and FILE_ID Parse the file to find children/components and extract the…
nimsrules
  • 2,026
  • 20
  • 22
1
vote
1 answer

Figma API for computed CSS

I have been exploring Figma API to build a Figma plugin that exports a frame into a web component. While I can copy computed CSS from the frame manually via the interface, it looks like there is no way I can access it via API. Am I missing something…
Jikku Jose
  • 18,306
  • 11
  • 41
  • 61
1
vote
1 answer

How can I change the text and image urls in a figma design using the figma API?

I want to be able to dynamically change the text and images in a figma design file, preferably using a JSON to contain the text/image urls. Is this possible with figma api or the figma file?
tommy chheng
  • 9,108
  • 9
  • 55
  • 72
1
2 3 4