1st assignment

 Hello Zuri,


This is my first assignment. 


I am a lawyer, and my goal with this training is to build some sort of app or website to solve a problen for lawyers. Still trying to figure it out. Hope to figure it out and solve the said problem in 8 weeks. 

I think my stack will be the front end stack. 


The figma tutorial

I got this snippet from this link ==) https://www.figma.com/developers/api


Introduction

Welcome to Figma, the world's first collaborative interface design tool. Figma allows designers to create and prototype their digital experiences - together in real-time and in one place - helping them turn their ideas and visions into products, faster. Figma's mission is to make design accessible to everyone. The Figma API is one of the ways we aim to do that.

What can I do with the Figma API?

The Figma API supports read access and interactions with Figma files. This gives you the ability to view and extract any objects or layers, and their properties, so you can render them as images outside of Figma. You can then present your designs, connect them to other applications, or use them to expand on your vision. Future versions of the API will unlock even greater functionality around Files.

How does it work?

The Figma API is based on the REST structure. We support authentication via access tokens and OAuth2. Requests are made via HTTP endpoints with clear functions and appropriate response codes. Endpoints allow you to request filesimagesfile versionsuserscommentsteam projects and project files.

Once granted access, you can use the Figma API to inspect a JSON representation of the file. Every layer or object in a file will be represented within the file by a node (subtree). You will then be able to access and isolate the object and any properties associated with it. In addition to accessing files and layers, you will be able to GET and POST comments to files.

Getting started

If you’re not already using Figma, the first step is to sign up and create an account over here.

Once you have a Figma account, the next step is to authenticate with the API. This can be done using either OAuth2 or access tokens.

You can then browse our endpoints and start making queries against the Figma API. We recommend starting with the basics by learning about Figma files, before moving on to more advanced topics such as commentsusersversion history, and projects.

If you plan on building a fully-fledged app, that others can share and use, then you can register your app by heading to My apps in your Figma account.

Authentication

Before you can access an endpoint within Figma, you will need to provide valid authentication. You can authenticate your request to the Figma API in two ways:

  1. Generate a personal access token through your user profile page. This gives you access to the Figma API as if you were a single user.
  2. Recommended: register a callback via OAuth2 and collect a client secret. This allows you non-specific access to the Figma API, without having to act on behalf of a specific user.

Access tokens
A personal access token gives the holder access to an account through the API as if they were the user who generated the token.
Generate a personal access token

  1. Login to your Figma account.
  2. Head to the account settings from the top-left menu inside Figma.
  3. Find the personal access tokens section.
  4. Click Create new token.
  5. A token will be generated. This will be your only chance to copy the token, so make sure you keep a copy of this in a secure place.

From the account settings page, you will also be able to see when the token was last used (give or take a few minutes). If you see any activity on a token that you did not initiate, revoke the token immediately. Revocations are instant and can be made at any time.

You can also generate an access token from this page to explore our endpoints. The token generated here functions exactly the same as a token generated from the account settings page as in the instructions above.

Use the personal access token

You can now use the token to make requests to the Figma API. You can do so by passing the token to the API in the header of your request. We’ve shown you an example of how this would look.

The name of the token header is X-Figma-Token.


This was around where I stopped. 

Using the token to make requests

Here is also a git tutorial link

https://m.youtube.com/watch?v=8JJ101D3knE

Thank you so much. 


 https://zuri.team 

https://internship.zuri.team 

https://training.zuri.team 

Comments