Getting Started
9 min
quickly integrate ai powered image, video, and audio generation into your application using the floyo api this guide walks you through creating your api key, running your first workflow, and monitoring usage — you'll be up and running in minutes step 1 create an api key all requests to the floyo api require an api key for authentication before you begin, follow the steps below to create your credentials and secure your integration to begin integrating, you first need to generate a secure authentication credential navigate to team settings > floyo api within your dashboard and select create api key you’ll be prompted to provide a descriptive name for the key to help you identify its use case later once generated, your secret key will be revealed store it safely keep your secret safe this is the only time your full api key will be displayed for security reasons, floyo does not store the raw secret, meaning you will not be able to retrieve it again once you leave this screen we recommend storing it immediately in a secure vault or environment manager step 2 floyo api node js demo app to help you get up and running quickly, we’ve provided a lightweight demo project this sample application demonstrates how to make authenticated requests to floyo api, run a workflow and retrieve a run metadata follow these steps to set up the project on your local machine clone the repository pull the demo code to your local environment using git git clone git\@github com\ floyoai/floyo api nodejs demo git cd floyo api nodejs demo install dependencies install the necessary packages (such as dotenv) using npm npm install configure your environment the project uses environment variables to manage your credentials securely create a env file by copying the example provided cp env example env open the env file and replace the placeholder with your actual floyo api key run any of the demo examples execute one of the scripts in readme md to see the floyo api in action node examples/run workflow node examples/download file node examples/upload file node examples/upload and run with input step 3 run different workflows the workflow api json is a streamlined execution graph that removes all ui specific metadata like node positions, colors, and groups it is the "bare bones" format required by the comfyui server to process a prompt programmatically follow these steps to export your workflow api json from floyo access the floyo menu open the workflow menu and select copy floyo api code in the popup that appears, select workflow json only and click the copy to clipboard button integrate you can now paste this api json directly into your project files or include it as the payload in your api request body in the floyo api node js demo app , the workflow json is saved in the /data/base workflow\ json file step 4 view run history and usage team admins or owners can see floyo api workflow runs in the run history and the full usage in the the team's settings > usage view active and past workflow runs select the floyo api tab in the run history to see active and past floyo api runs the floyo api tab is only available if you are a team admin or owner and you have created at least 1 floyo api key view floyo api and team member usage navigate to your team's settings > usage to view your floyo api usage alongside team member usage
