> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flowent.chat/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Get started in three simple steps. Register your first custom action with the Flowent API Gateway in minutes.

## Get started in three steps

Register your first custom action with the Flowent API Gateway and start extending Flowent's capabilities.

### Step 1: Create API Credentials

<AccordionGroup>
  <Accordion icon="lock" title="Get your API token">
    1. Log into your Flowent admin panel
    2. Navigate to **Gateway Management** → **API Tokens**
    3. Click **Create New Token** and give it a descriptive name
    4. Copy the token and store it securely (you won't be able to see it again)

    <Tip>Treat API tokens like passwords. Store them in environment variables, never in code.</Tip>
  </Accordion>

  <Accordion icon="shield" title="Create HMAC key">
    1. In Gateway Management, go to **HMAC Keys**
    2. Click **Create New Key**
    3. Copy the key and store it securely on your server

    You'll use this key to validate webhook signatures from Flowent.
  </Accordion>
</AccordionGroup>

### Step 2: Exchange Token for JWT

Before making API calls, exchange your API token for a JWT token:

```bash theme={null}
curl -X POST https://your-flowent-instance.com/api/v1/gateway/token/exchange \
  -H "Content-Type: application/json" \
  -d '{
    "api_token": "your-api-token-here"
  }'
```

Response:

```json theme={null}
{
  "jwt_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "token_type": "Bearer",
  "expires_in": 86400
}
```

<Info>
  JWT tokens expire after 24 hours. Exchange your API token again when needed.
</Info>

### Step 3: Register Your First Action

Register an action with your webhook endpoint:

```bash theme={null}
curl -X POST https://your-flowent-instance.com/api/v1/gateway/actions \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "send_email",
    "description": "Send an email to a specified recipient",
    "webhook_url": "https://your-server.com/actions/send_email",
    "json_schema": {
      "type": "object",
      "properties": {
        "recipient": {
          "type": "string",
          "description": "Email address of the recipient"
        },
        "subject": {
          "type": "string",
          "description": "Email subject line"
        },
        "body": {
          "type": "string",
          "description": "Email body content"
        }
      },
      "required": ["recipient", "subject", "body"]
    }
  }'
```

That's it! Flowent will validate your webhook endpoint and your action is ready to use.

## Next steps

<CardGroup cols={2}>
  <Card title="API Concepts" icon="lightbulb" href="/api-concepts">
    Learn about authentication, webhooks, and security.
  </Card>

  <Card title="API Reference" icon="terminal" href="/api-reference/introduction">
    Explore the complete API specification.
  </Card>
</CardGroup>
